Closed weiweihuanghuang closed 9 years ago
The Unicode values are assigned at build time though makeotf
, which reads that data from the GlyphOrderAndAliasDB file.
Not a bug then! But how does it know which unicode to assign each glyph, is it in the 2nd column (standardised naming)?
And what's the best way to get the unicode values into the .UFO if we wanted to use a .UFO editor…?
There is a list of standardized glyph names, commonly know as the agl
(Adobe Glyph List).
Within the FDK, this data is called via the agd
module.
You can search the FDK repo for agl
for more information.
The AGL even has a Wikipedia entry.
Additionally, here is a listing of the AL1 – AL5 character sets we use: https://github.com/adobe-type-tools/adobe-latin-charsets
If you want to get Unicode values in a UFO I suggest the Robofab method glyph.autoUnicodes()
; which also relies on the info given in the agl
list.
But how does it know which unicode to assign each glyph, is it in the 2nd column (standardised naming)?
By processing the names in the 1st column. The Unicode values for standard names are assigned according to the AGLFN. Names that follow the format uniXXXX
will be Unicode-encoded as XXXX
. GlyphOrderAndAliasDB entries that have a value in the 3rd column (e.g. glyph f_f
), will get that Unicode value.
Glyphs with names that don't follow any of the rules above, will get no Unicode value.
Thanks for the clear explanation. Why are the unicode values not encoded into the .UFO though?
Because they aren't needed. The OTFs are built with makeotf
and this tool gets all the Unicode information it needs from the GlyphOrderAndAliasDB file.
Are the unicode values assigned by another file or process? Or is this a bug?