= Glyph index
A <glyph index> is a numerical identifier for a <glyph> inside a particular <computer font>. It identifies an entry in that font's own <glyph> collection, rather than a <Unicode> <code point>. In an <OpenType> <computer font>, the `cmap` table maps character codes to default <glyph indices>; unavailable characters map to index zero, whose special `.notdef` <glyph> indicates missing coverage.<Character to Glyph Index Mapping Table by Microsoft>[Table overview: default glyph mapping and the required missing-character glyph at index zero]{ref}
For a hypothetical example, one <computer font> might map `U+0041` to index 37 while another maps the same character A to index 9. Both can display the correct letter. Carrying index 37 from the first <computer font> into the second can select an unrelated form. A later <glyph substitution> can also change the selected <glyph index> while leaving the underlying <text characters> unchanged. This distinction matters in rendering caches and when exchanging shaped text between systems.
Back to article page