[reportlab-users] vertically centered text

Rich Shepard rshepard at appl-ecosys.com
Mon Jan 28 17:08:25 EST 2008

On Mon, 28 Jan 2008, Aaron Spike wrote:

> I am able to center text horizontally with the drawCenteredString()

> function that the api provides. I haven't been able to find any way to

> center text vertically (or both vertically and horizontally at the same

> time). Is there any font metric I can access to adjust the vertical

> placement of text so that I can center it on a point?


Trial-and-error while manually tweaking the cursor's position is the way
to go. Not very automated, but you get exceptionally fine control of text
placement this way.


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