Comments (7)
It is difficult to provide the available size because of the dynamic nature of documents. I am not sure what exactly you are trying to accomplish. As far as I understand, you may want to make a try with the ExtendVerical
element 😀
from questpdf.
It doesn't solve my all problem.
In a relative column it actually work pretty well but when have a grid inside of a relative column it doesn't divide the rows for all the space that I have in the column.
I'd love to attach an image but, don't know why, I'm not able to do it.
from questpdf.
Meanwhile I can do a workaround and set the header and footer heigh to a fixed size and that way I always know the free space that I have.
from questpdf.
In a relative column it actually work pretty well but when have a grid inside of a relative column it doesn't divide the rows for all the space that I have in the column.
I'd love to attach an image but, don't know why, I'm not able to do it.
As far as I know, posting an image is simple: just copy the file and paste it into the text. It should be uploaded automatically and attached as markdown 😀
Meanwhile I can do a workaround and set the header and footer heigh to a fixed size and that way I always know the free space that I have.
I expect that in the future, the DynamicComponent will help you with more complex/custom layouts. The development is discussed here. Unfortunately, this is still in the experimental phase as relies on other architectural concepts that are not stable enough to make them public.
from questpdf.
As far as I know, posting an image is simple: just copy the file and paste it into the text. It should be uploaded automatically and attached as markdown 😀
I know :D But is always returning an error when it try to upload the image.
I expect that in the future, the DynamicComponent will help you with more complex/custom layouts. The development is discussed here. Unfortunately, this is still in the experimental phase as relies on other architectural concepts that are not stable enough to make them public.
Ok, no problem. You can close this issue and I'll be looking for future improvements on this.
Btw, congratulations. Excellent job with the library!
from questpdf.
Ok, no problem. You can close this issue and I'll be looking for future improvements on this.
Or please describe your needs more precisely. So even I can understand 😁
from questpdf.
Ok , I'll try to explain it better :p
So, I'm trying to add a complex grid where in the first column I have two rows and in the second column I have only one row.
Example:
`foreach (var groupedSection in groupedSections)
{
var nrColumnsUsed = groupedSection.First().NrColumns;
if (groupedSection.Count() > 1)
{
row.RelativeColumn(nrColumnsUsed)
.Grid(grid =>
{
foreach (var pageSection in groupedSection.OrderBy(a => a.RowNr))
{
grid.Columns(nrColumnsUsed);
grid.Item(nrColumnsUsed)
.Height(((float)pageSection.HeightPercentage / 100) * pageHeight)
.AlignMiddle()
.AlignCenter()
.Stack(columnStack => { ComposePageElements(columnStack, pageSection.PageElements); });
}
});
}
else
{
row.RelativeColumn(nrColumnsUsed)
.Height(pageHeight)
.AlignMiddle()
.AlignCenter()
.Stack(columnStack => { ComposePageElements(columnStack, groupedSection.First().PageElements); });
}
}`
In the first column (the one that have 2 rows) I want to use percentages (this calculation could be made from my side) to define the height of each row in the column.
from questpdf.
Related Issues (20)
- QuestPDF.Drawing.Exceptions.DocumentDrawingException: 'Could not find an appropriate font fallback for the following glyphs: $U-000D ' HOT 16
- Devanagari font rendering Issue Linux HOT 4
- Non-PageBreaking cell of table duplicates data in both pages HOT 2
- Nuget should buildTransitive instead of build for the QuestPDF.targets HOT 2
- Everything stop working correctly after upgrading to latest version HOT 5
- Canvas Deprecated? HOT 2
- unable to load dll 'questpdfskia' on Windows 11 .NET Framework C#
- Rounded corners for borders HOT 2
- SVG: Classes in CSS have no effect. HOT 1
- Black border using SkiaSharp canvas integration HOT 4
- FitArea, FitWidth, FitHeight don't work for SVG images HOT 7
- Allow the pdf to be exported as clean html & css. HOT 1
- Is there any APIs can draw arbitrary line by 2 points?
- QuestPDFSkia DLL is not detected as a dependency. HOT 1
- Calling FontManager.RegisterFont throws an InitializationException HOT 2
- Sporadic AccessViolationException when UseEnvironmentFonts is false and documents are generated in parallel HOT 2
- Lato font is not included in platform-specific builds HOT 2
- Font rendering (line-height) in 2024.3.X HOT 12
- A variant of "ShowEntire" that does not throw an exception. HOT 5
- Column height Inheritance and text spacing HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from questpdf.