As with macros, fonts need to be stored in a hierarchical structure in order to make maintenance feasible. The TDS specifies the following (except for PK and GF files, which need additional structure, as detailed in the next sextion):
texmf/fonts/type/supplier/typeface/
is the type of font file:
font sources (METAFONT files, property lists, etc.).
TFM files.
virtual fonts.
Adobe font metrics.
PK files.
GF files.
Type 1 fonts in PFA or PFB format or both.
is the name of the font supplier or public. adobe, monotype, and ams are examples of supplier.
The public directory serves a practical purpose: it designates fonts which can be freely redistributed.
The name ams is precisely defined: the ams typeface directory contains only the fonts distributed by the AMS in the ``amsfonts'' collection.
is the name of the typeface family. cm, latex, euler, concrete, bookman, and courier are examples of typeface.
The names cm and latex are precisely defined, as follows. The cm typeface directory contains only the 75 fonts defined in Computers and Typesetting, Volume E. The latex typeface directory contains only the fonts distributed with LaTeX in the base distribution.
For example:
texmf/fonts/tfm/public/cm/cmr10.tfm texmf/fonts/type1/adobe/utopia/putr.pfa
For more information about font filenames, consult Filenames for TeX fonts (see Section C, Related References for a complete reference).
The bitmaps for each font require special attention. In addition to the name of the font, two more characteristics are required to uniquely identify a bitmap font: the type of device (i.e., mode) for which the font was created and the resolution of the bitmap.
Following common practice, the TDS segregates fonts with different device types (modes) into separate directories. Consult modes.mf for recommended mode names. (See Section C, Related References for a complete reference.)
Two naming strategies are commonly used to identify the resolution of bitmap font files. On systems that allow long filenames, the convention is to include the resolution in the filename (in fact, this is how METAFONT itself names its output). For example, the 300dpi bitmap of cmr10 is named cmr10.300pk. On other systems, such as MS-DOS, the fonts are generally segregated into directories by resolution. For example, the same 300dpi bitmap would be named cmr10.pk in a directory named dpi300.
Because the TDS cannot assume long filenames (see Section 2.2, Constraints) it must use the latter scheme for naming fonts. Therefore, under the pk directory, the TDS specifies two more subdirectory levels:
texmf/fonts/pk/mode/supplier/typeface/dpi/
is the mode name which identifies the device type. This is usually the name of the METAFONT mode used to build the PK file. ljfour, cx, and linotype are examples of mode.
For fonts rendered as bitmaps by a program that does not distinguish between different output devices, the mode name shall be that of the program (e.g., ps2pk, gsftopk).
specifies the resolution of the font. The directory name shall consist of the string dpi followed by the numeric value of the resolution in decimal. dpi300, dpi329, and dpi1404 are examples of dpi.
GF files are stored in a parallel structure:
texmf/fonts/gf/mode/supplier/typeface/dpi/
The TWG recognizes that the use of short filenames has many disadvantages. The most vexing is that it results in the creation of dozens of different files with exactly the same name. At a typical site, cmr10.pk will be the filename for Computer Modern Roman 10pt at 5--10 magnifications for 2--3 modes.
There was considerable discussion about how to minimize the disadvantages of this scheme. One result of that discussion was the decision to allow extensions to the basic naming scheme (such as cmr10.300pk or font library files), provided that the basic scheme is also supported. The following statement is the other result:
In a TDS-conformant installation, all PK files must contain enough information to identify precisely how they were created; this includes mode, base resolution, and magnification used to create the font.
This information is easy to supply: a simple addition to the local modes used for building the fonts with METAFONT will automatically provide the required information. If you have been using a local modes file derived from (or that is, in fact) the complete modes.mf distribution from CTAN, the required information is already in your PK files. If not, a simple addition based on the code found in modes.mf (see Section C, Related References for a complete reference) can be made to your local modes file and the PK files rebuilt.