[reportlab-users] Tracking Position on Canvas
Rich Shepard
rshepard at appl-ecosys.com
Fri Nov 9 19:33:03 EST 2007
I have a portion of one report that displays five levels of a hierarchy,
and I'm writing it directly to the canvas rather than trying to integrate a
platypus table into the rest of the report.
When the text is 72 points or less from the bottom of the page I want to
force a new page to begin. To do so, I have written:
place = tb.getY()
if place <= 72:
pg.showPage()
taking advantage of Tim's TextBox() class. I test page position at several
places in the code because it can get below the threshold at more than one
place.
However, it's not working as intended. Rather than getting page breaks, I
get more than 1700 blank pages after the first page.
What might be the better way of paginating?
Rich
--
Richard B. Shepard, Ph.D. | Integrity Credibility
Applied Ecosystem Services, Inc. | Innovation
<http://www.appl-ecosys.com> Voice: 503-667-4517 Fax: 503-667-8863
More information about the reportlab-users
mailing list