reworded glyph name section
git-svn-id: svn://svn.code.sf.net/p/fonttools/code/trunk@217 4cde692c-a291-49d1-8350-778aa11640f8
This commit is contained in:
parent
b4bdd0f235
commit
7de32f2fb4
@ -99,23 +99,24 @@ than the command line programs described below.
|
|||||||
makes the two above tools available under the Right Mouse Button. I haven't tested
|
makes the two above tools available under the Right Mouse Button. I haven't tested
|
||||||
these myself, but I'm very interested in hearing about the results!
|
these myself, but I'm very interested in hearing about the results!
|
||||||
|
|
||||||
<H3>Note about glyph names and TrueType GlyphID's</H3>
|
<H3>A note about glyph names and TrueType GlyphID's</H3>
|
||||||
|
|
||||||
TrueType fonts use glyph indices (GlyphID's) to refer to glyphs in most places.
|
TrueType fonts use glyph indices (GlyphID's) to refer to glyphs in most places.
|
||||||
While this is fine in binary form, it is really hard to work with for
|
While this is fine in binary form, it is really hard to work with for
|
||||||
humans. Therefore we use names instead.
|
humans. Therefore we use names instead.
|
||||||
|
|
||||||
<P>The names are derived from what is found in the 'post' table. It is
|
<P>The glyph names are either extracted from the 'CFF ' table or the 'post' table,
|
||||||
possible that different glyphs use the same PS name. If this happens, we
|
or are derived from a Unicode 'cmap' table. In the latter case the Adobe Glyph List
|
||||||
force the names to be unique by appending "#n" to the name (n being an
|
is used to calculate names based on Unicode values. If all of these mthods fail,
|
||||||
integer number). The original PS names will still be maintained by the
|
names are invented based on GlyphID (eg. "glyph00142").
|
||||||
'post' table, so even though we use a different name internally, we are
|
|
||||||
still able to write the 'post' table back in original form. If there is
|
<P>It is possible that different glyphs use the same name. If this happens,
|
||||||
no proper 'post' table available, names will be derived from a Unicode
|
we force the names to be unique by appending "#n" to the name (n being an
|
||||||
cmap (if available) in conjuction with the Adobe Glyph List (see fontTools/agl.py).
|
integer number). The original names are being kept, so this has no influence
|
||||||
|
on a "round tripped" font.
|
||||||
|
|
||||||
<P>Because the order in which glyphs are stored inside the TT font is
|
<P>Because the order in which glyphs are stored inside the TT font is
|
||||||
important, ttLib maintains an ordered list of glyph names in the font.
|
important, we maintain an ordered list of glyph names in the font.
|
||||||
|
|
||||||
<H3>Feedback</H3>
|
<H3>Feedback</H3>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user