Hi!
I got a problem in using non-embedded TTF fonts while using Zend_Pdf PDF manipulation library.
E.g. if I'm using 'Arial Unicode MS' (which is supplied with Microsoft Office) I see exactly 'Arial Unicode MS' in 'name' table of ARIALUNI.TTF file.
If this name is used to refer a font ('/ArialUnicodeMS') and font embedding is turned off, then I get error when I try to see prepared document in Acrobat Reader even the font is properly installed:
"Cannot find or create the font 'ArialUnicodeMS'. Some characters may not display or print correctly."
As I found, correct name should be '/KCDAHG+ArialUnicodeMS', but I definitely have no idea from which place this prefix come.
PDF Reference says about TrueType fonts:
-----------------------------------------------
The PostScript name for the value of BaseFont is determined in one of two ways:
• Use the PostScript name that is an optional entry in the “name” table of the
TrueType font.
• In the absence of such an entry in the “name” table, derive a PostScript name
from the name by which the font is known in the host operating system. On a
Windows system, the name is based on the lfFaceName field in a LOGFONT
structure; in the Mac OS, it is based on the name of the FOND resource. If the
name contains any spaces, the spaces are removed.
-----------------------------------------------
Does it mean that if we want to operate with non-embedded TTF fonts we must always get font name through the system API instead of parsing font file?
If yes, does it mean, that using non-embeded fonts doesn't work between different platforms?
Could anyone help with it?
Best regards,
Alexander Veremyev.