TeX Fonts (III): postscript

In TeX, a font requires two definition/description files: a metric definition file (.tfm) as introduced in the previous post, and a glyph shape description file (.gf from METAFONT, .pfa/.pfb for printer fonts, etc). The TeX font metric file *.tfm only specifies the dimensions of each character in the font, as well as a list of kerning and ligature pairs. It does not tell how actually a character looks like. The shapes of the characters are only described in the glyph file. The output of a TeX file, *.dvi, merely contains information about a large number of bounding boxes and their relative positions. Hence, in order to print the document to paper or to screen, a dvi file has to be interpreted using a dvi driver with glyph definition in mind. dvips is one such driver. It converts a dvi file to a PostScript file. Yap, or xdvi, or other dvi previewers, are essentially dvi drivers. They assume glyph information, otherwise they have no way of rendering the fonts stored in *.dvi.

Indeed, a large part of fonts talked about in this post are no longer TeX fonts. TeX only recognizes fonts from .tfm files—bounding boxes and kerning informations. METAFONT can produce glyph files (.gf), but fonts we commonly used today are Adobe fonts (.afm), TrueType fonts (.ttf), etc. Corresponding tools are designed to convert these fonts into TeX font metrics, such as afm2tfm, ttf2tfm, recognized by the latex program, as well as into glyph files (ttf2pk, etc) used by the dvi drivers (dvips, Yap, xdvi, etc). The relationships are illustrated in the following figure. (I slightly cheat in the figure in that the Adobe font metric .afm will only be converted to TeX font metric .tfm, but no information is deduced for glyph file.)


[To be finished..]

0 Responses to “TeX Fonts (III): postscript”

  1. Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


Blog Stats

  • 242,375 hits

%d bloggers like this: