TextBlock Height vs RangeHeight

Knowledge exchange related to the VPE Report Engine and PDF Library

Moderator: IDEAL Software Support

TextBlock Height vs RangeHeight

Postby Brent Rose » Tue Jul 15, 2014 9:48 pm

The version 7 documentation states: "Due to historical reasons (16-bit), Print(), Write() and Render() add a small offset to the bottom coordinate of a text object. For compatibilty, WriteTextBlock() does the same...."

It would appear that the "small offset" is 0.02 cm. Can you please confirm if this is indeed the offset value and that it is a constant in all cases.

ie Given a SINGLE LINE text block, for example, the difference between TVPETextBlock.Height and TVPETextBlock.RangeHeight(0, 1) for that one line will always be 0.02 cm no matter what the font settings (for plain text or RTF).

REASON: I'm wanting to explicitly control line spacing and effectively include the "small offset" with EVERY line. This means the height of some lines from a multi-line text block printed one line at a time would be the RangeHeight of those lines plus an extra 0.02 for each line.

Thanks.
Brent Rose
 
Posts: 50
Joined: Wed Mar 21, 2012 8:13 pm

Re: TextBlock Height vs RangeHeight

Postby IDEAL Software Support » Wed Jul 16, 2014 10:32 am

Yes, the offset is 0.02 cm. It is a constant.

For text surrounded with a frame (i.e. PenSize > 0), things are different. But I would need to check the code for details.
IDEAL Software Support
 
Posts: 1633
Joined: Thu Nov 18, 2004 4:03 pm


Return to VPE Open Forum

Who is online

Users browsing this forum: Google [Bot] and 5 guests

cron