Hi,

as I'm currently on the way to redesign the TrueType/OpenType file
reading, from time to time I stumble over some odd things.

But instead of blindly refactoring, I think its better to ask you
before.

Fonts have among other things the properties ascent, descent and
fontBBox which are defined in the PDF spec chapter 5.7 Font Descriptors.

If I look into PDFFactory rev. 800217 line 1445 - 1483 method
makeFontDescriptor, I see two constructor calls, one for CID fonts and
one for the other fonts. For CID fonts the constructor of
PDFCIDFontDescriptor is called and for the others the constructor of
PDFFontDescriptor is called. PDFCIDFontDescriptor is a subclass of
PDFFontDescriptor.

The odd thing here is, that the call of PDFCIDFontDescriptor doesn't use
the ascent nor the descent of the font descriptor. Instead it uses some
quantities out of the fontBBox to feed the PDFFontDescriptor. This can
be seen inside PDFCIDFontDescriptor rev. 679326.

So as fontBBox, ascent and descent don't be the same thing, I would
recommend to change this. But this would properly break some things,
because we would get other values for ascent and descent in CID fonts.


Best Regards
Alex

-  
e-mail: [email protected]
web:    www.alexanderkiel.net

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to