[XeTeX] About Microsoft YaHei font
Jonathan Kew
jonathan_kew at sil.org
Tue May 29 12:00:16 CEST 2007
On 29 May 2007, at 10:42 am, Dongsheng Song wrote:
> Yes.
>
> In FontForge, the font name is 'MicrosoftYaHei', after change to
> 'MicrosoftYaHeiBold', it works.
>
> In FontCreator 5.5, it's more clear. The font's 'postscript name' for
> 'Chinese - PRC' is 'MicrosoftYaHeiBold', But for 'English - United
> States' is 'MicrosoftYaHei', it should be a typo.
OK, this is a bug in the font. According to the OpenType spec (see
http://www.microsoft.com/typography/otspec/name.htm), the "English -
US" name is the only one that matters; the "Chinese" one is
irrelevant. (Remember that this name is for internal use in software/
printers, not for presentation to humans.)
The description of name ID 6 begins:
<quote>
Postscript name for the font; Name ID 6 specifies a string which is
used to invoke a PostScript language font that corresponds to this
OpenType font. If no name ID 6 is present, then there is no defined
method for invoking this font on a PostScript interpreter.
OpenType fonts which include a name with name ID of 6 shall include
these two names with name ID 6, and characteristics as follows:
Platform: 1 [Macintosh]; Platform-specific encoding: 0 [Roman];
Language: 0 [English].
Platform: 3 [Microsoft]; Platform-specific encoding: 1 [Unicode];
Language: 0x409 [English (American)].
Names with name ID 6 other than the above two, if present, must be
ignored.
</quote>
Various software, including the Cocoa text system on Mac OS X, as
well as Postscript printers in general, will rely on the PS name as
the primary identifier of the font; and so if the regular and bold
fonts have the same PS name (as in this case), the software will not
be able to reliably access both faces.
I would suggest reporting this as a bug to Microsoft (or whoever else
distributes this font).
JK
More information about the XeTeX
mailing list