[reportlab-users] PATCH: Using font ascent to position string content in tables

Matt Folwell mjf at pearson.co.uk
Fri Sep 26 09:19:01 EDT 2008


In ReportLab 2.2, platypus paragraphs have started to read the ascent
from the font to work out where to put the text' baseline.

I think tables should do the same for cells that contain a string, so
you can switch between the two without the text moving, all other things
being equal.

Here's a patch to do that, and a script to generate an example PDF
containing a table with strings in one column and paragraphs in the other.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: table_font_ascent.patch
Url: <http://two.pairlist.net/pipermail/reportlab-users/attachments/20080926/810c3298/attachment.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: table_font_ascent_example.py
Url: <http://two.pairlist.net/pipermail/reportlab-users/attachments/20080926/810c3298/attachment-0001.ksh>


More information about the reportlab-users mailing list