dart_pdf icon indicating copy to clipboard operation
dart_pdf copied to clipboard

Split a Table in 2 pages

Open carpentierchloe opened this issue 2 years ago • 5 comments

My table has dynamic rows. But if I have too much rows, I have got the error "This widget created more than 20 pages". What can I do ? If I limit the number of rows of my table, it does not fix the problem as they all do not have the same height.

carpentierchloe avatar Sep 04 '22 03:09 carpentierchloe

Modify the maxPages argument in Page

MichelMelhem avatar Sep 04 '22 10:09 MichelMelhem

@MichelMelhem I think this is actually a bug and maxPages doesn't solve the problem.

For example, my Table has only 50 TableRow all with same height. One page can display 30 TableRow. Now I have 50 means which should fit nicely in 2 pages, but as soon as I have 31 TableRow, pdf will spit out the "max 20 pages" error. Increase maxPages to a high number (say 100) doesn't help.

If I manually split into two tables (30+20) then pdf doesn't have any problem display two tables into 2 pages.

I think that's why @carpentierchloe is asking how to split the table into 2 pages, dynamically.

function1983 avatar Sep 04 '22 17:09 function1983

display

@function1983 I think you are right. I'm facing a similar issue in #1141.

MichelMelhem avatar Sep 04 '22 17:09 MichelMelhem

@function1983 Yes you have understand my issue, is there a solution ? or an alternative one ?

carpentierchloe avatar Sep 05 '22 01:09 carpentierchloe

any updates ?

MichelMelhem avatar Sep 06 '22 16:09 MichelMelhem

This issue is a big blocker because the table row height is dynamic in my project, so I can't even split it manually into multiple pages. @DavBfr Can you please fix it in return for some coffee? :)

teilzeitgeist avatar Oct 07 '22 08:10 teilzeitgeist

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days

github-actions[bot] avatar Nov 15 '22 00:11 github-actions[bot]

Closing this stale issue because it has no activity.

github-actions[bot] avatar Nov 21 '22 00:11 github-actions[bot]