[Lazarus] fpPDF: set clip rect for text

Ondrej Pokorny lazarus at kluug.net
Wed Apr 13 20:04:08 CEST 2016


On 13.04.2016 19:44, Graeme Geldenhuys wrote:
> On 2016-04-13 18:14, Ondrej Pokorny wrote:
>> TextWidth is already in fpTTF / TFPFontCacheItem.
> Yes, but that one only handles TTF fonts that the fontcache found. In
> fpReport I needed to handle Std PDF fonts too - hence I have separate
> implementations for TextWidth() and TextHeight().

Reading your previous email, my opinion is that TextWidth() and 
TextHeight() (and other similar functions) should be supported only by 
fonts that the fontcache found.

If the programmer needs TTF functions on default PDF fonts, he has to 
make sure the TTF files are available. Easy as that :)

Ondrej




More information about the Lazarus mailing list