[reportlab-users] How to pin a flowable/summary chunk at the bottom of a page?

Robin Becker robin at reportlab.com
Tue May 3 03:52:22 EDT 2005

Eric Hochmeister wrote:
> Hi,
> I'm looking to generate a report such that a particular flowable will
> always be pinned to the bottom of the last page.  The last page may be
> the first page, or the third, fifth, etc.
> The flowable which will be pinned to the bottom of the last page will
> be like a summary / totals flowable.  ie.  if I have tabular data
> which spans multiple pages, I would like this summary flowable to
> always appear at the bottom of the last page.
> Can anyone recommend how to go about doing this?  I was thinking maybe
> I might have to use frames or write my own flowable.  Suggestions?
> Also, any ideas on how to get the table to expand to this flowable? 
> (so that it fills the table with empty rows until only enough space
> exists for the final flowable which is pinned to the last page)  So on
> the last page you may have a half empty table followed by the summary
> chunk.
> Thanks,
> Eric
The final pinned flowable is the key. There are a some special cases.
Suppose there is room for the text part of the pin in the current frame then
just ensure it uses all the space and draws itself at the right place. If there
is not room for the text then presumably you use up all the space on and then
you're back in the first case.
Robin Becker

More information about the reportlab-users mailing list