Question about unicode ranges in X fonts (TrueType)

Shaun Lippy shaun.lippy at oracle.com
Thu Jan 21 12:47:44 PST 2010


Hello -

I am working on an application that requires knowledge of the precise
ranges of Unicode characters supported by a font, specifically a
TrueType font.  This information is stored in the OS/2 table of the
TrueType font.  Is there any way, through X, to get access to this
information?  For our Windows product, I simply call GetFontData to
return me the OS/2 table, which I can then parse to get the required
information.  It looks like the min_char_or_byte2 and max_char_or_byte2
fields tell me the first and last character of a range, but what if I
have, for example, an Arabic font which has many characters in a "lower"
range (0x0600-0x06FF) and several in a much "higher" range (the Arabic
Presentation Forms, 0xFB50-0xFDFF); this font doesn't, of course, have
all the characters between 0x0600 and 0xFDFF, so the min and max fields
won't help.

Thanks for any tips.  In lieu of help from X, if such help doesn't
exist, can anybody suggest ideas for gaining access to the physical font
that X is using so that I can parse the font myself?  That is, if I have
an XLFD returned from XListFonts, is there a call I can make to tell me
exactly where the font described by the XLFD exists on the system?

Thanks again,

Shaun
shaun.lippy at oracle.com


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg/attachments/20100121/639fa6f0/attachment.html>


More information about the xorg mailing list