After adding about 1000 'characters' to PUA codepoints, UnBatang
font available at http://www.i18nl10n.com/fonts/UnBatang.ttf
does not get recognized as supporting Korean although it has
the full set of characters in KS X 1001 as well as the full
set of precomposed Hangul syllables. In addition, it has ~1400
extra characters not in ko.orth. (I wrote a simple program
with Freetype2 APIs to get the list of Unicode characters
in the Unicode cmap of a font and compared the output with
the list in ko.orth)
I've just downloaded fontconfig 2.2 only to get the same result.
I tried to get the CVS snapshot, but the cvs access doesn't
seem to work.
Setting FC_DEBUG=3,5,10 and running 'fc-cache -f -v' didn't let me
glimpse into what's going on.
BTW, bugzilla doesn't let me choose version 2.2 for fontconfig
so I'm filing this under 2.1
$ FC_DEBUG=384 fc-cache -f -v
to discover that UnBatang is missing a glyph for character U+4E00 which is
included in the KSC 5601-1992 encoding. Is this glyph not a part of KS X 1001?
Created attachment 42 [details]
a simple freetype char check program
Thank you for testing.
U+4E00 is CJK Ideograph Number One and it's a part of KS X 1001:1998 repertoire
(KS C 5601-1992 repertoire + EURO Sign + Registered Sign = KS X 1001:1998
The font has it with GID = 0x4356 according to my program I've just attached.
When I filed a bug, I used another program that lists all the characters in
a given font in all the CMaps present in the font. That's the way I compared
the list of characters in UnBatang with characters in ko.orth.
To my surprise, both fc-cache and pfaedit think UnBatang doesn't have
The following is a part of the output I obtained from my first test program
As you can see, there's a jump in GID around U+4E00, but does it matter?
Anyway, it seems like there's something wrong with the font and I'll examine
Unicode CMap directly.
I'm sorry that this bug is invalid.
It turned out that in the font U+4E00 had been accidentally
assigned a blank glyph(gid=0x4356 that's supposed to be assigned to U+115f) and
fontconfig rejcted it as invalid because U+4E00 is not supposed to be blank.
Fixing the cmap of the font (assigning gid=0x5a6 to U+4E00) solved the problem.
BTW, the tolerance limit of fontconfig appears to be zero when determining
whether a font is suitable for a language. For 'orthographies' with a large
this might be too severe. Well, if it had been more generous, I'd not have
discovered the glitch in the font. So, I must be grateful to it :-)