[reportlab-users] Infinite Loop in tables

Robin Becker reportlab-users@reportlab.com
Tue, 11 Nov 2003 11:52:12 +0000


In article <71674BEFF0E2D41196F500600811AA6B5BADAA@TUP-BO1-EXC>, Henning
von Bargen <H.vonBargen@triestram-partner.de> writes
>Hi,
>
>I have encountered the following problem using Tables in a production
>environment:
>
>If the header line plus the first data line do not fit entirely on the page,
>an infinite loop occurs.
>
>This is likely to happen when generating tables with DB data
>where some cells contain long strings, for example a descriptive text.
>
>This is causing performance problems on the application server.
>As a last resort, I have modified the _splitRows method for Table
>so that it raises an exception when this happens and availHeight > 5cm.
>
>Is there any option that allows to split the CELLS inside the row
>so that the first part of the row will be printed on the current page
>and the rest will overflow to the next row?
>
>Henning
.... This is hard, the flowable wrap, split and draw methods don't know
the container size so it's hard to know when a split is absolutely
required (or detect the overflow). To take the hard case, what does it
mean when the header lines are longer than the page.

It ought to be possible to detect the infinite loop though by other
means.
-- 
Robin Becker