User Guide

FontLab 4
506
T r u eT y pe In s t r u c t i o n s
In TrueType fonts, the hinting process is very different from the one used
in Type 1 fonts. As we said before, in TrueType font format almost all
characters have special programs that directly control the movement of
outline points at different PPM sizes.
The native TrueType instruction language consists of several dozen
commands. All the commands deal with the data stack, a temporary
storage place, and the constant definitions that come with a font.
There are 3 different kinds of instructions in each TrueType font file. One
global program (called the Font Program) is executed one time when the
font is used for the first time. Another global program (called the PPM
Program) is executed one time when the font’s PPM is changed. Local
programs (Glyph Programs) are executed for each glyph when it is scaled.
Programs can deal with points, distances, arithmetic values, constants and
graphics state parameters. Graphics state parameters set rules that are
used as settings for various commands.
Every character outline is scaled according to the selected PPM value.
Point coordinates are stored as fixed-point numbers (they are not integers,
but have a fixed precision). Then the glyph program is interpreted. The
glyph program measures the distances between outline points, uses font-
level constants and resets the position of some outline points. These points
are called touched points.