HDS ViewStation System Administrator's Guide

A Hypertext Document


Font File Formats

This page describes various font file formats and how to manipulate them.

Font File Formats - .bdf and .snf
Font files contained in the MIT X distribution are in .bdf format (Bitmap Distribution Format, a generic, human-readable format). Other systems, such as DECwindows or Open Look, provide fonts in other formats, such as .dwf (DEC Windows Format) which are pre-compiled for the particular machine architecture they use. These fonts must be recompiled into a special .snf format (Server Natural Format) specifically for the HDS ViewStation (or the .snf format for the machine they are running on). Each server type has different .snf format requirements, based on its memory configuration and processor type, bit and byte order, etc. Other servers will use different .snf files, and you must create specific ones for the HDS View Station, as shown below.

The first step is to create a special directory for these font files. Then the .bdf fonts you need should be copied into the directory and converted to the .snf format for the ViewStation.

Handling .bdf Fonts and Fonts in other Formats
There are large directories of .bdf font files supplied with the standard MIT X distribution. You may not want to use all of these fonts or create .snf files for all of them. This choice depends on the X clients and applications you want to use.

All of these fonts must be compiled into .snf format to be used on the ViewStation (or use the pre-compiled HDS .snf fonts from the HDSware tape).

Font Sizes
Other important font considerations include choosing the correct 75dpi (dpi = dots per inch) or 100dpi files for your HDS ViewStation. These sets of files are provided for monitors with different screen resolutions. ViewStation Monitors gives you information about the screen resolutions of particular monitors.

The appearance of a font on the screen is best when the dots per inch resolution on the screen is as closely matched as possible to the number of dots provided for each character in the font file. (This can become a rather complicated question for users concerned about exact character size. For instance, a 24 point font from the 75dpi directory displayed on a monitor whose resolution is actually 85 dpi will be slightly smaller than 24 points. [The calculation goes like this: Since a point is about 1/72nd of an inch, a 24 point character from the 75dpi directory is about 24 dots high. This means that 24 dots displayed on 85 dpi results in a smaller character - 24/85ths compared with 24/75ths of an inch.] On the other hand, the same 24 point font from the 100dpi directory will be larger than 24 points when displayed on the same monitor [24/85ths compared to 24/100ths of an inch].

Since most applications where this is important, such as WYSIWYG publishing programs, take these factors into consideration with internal mechanisms for their screen displays and printing, most users won't need to be concerned about it. If this is an important consideration, put the preferred font directory, 75dpi or 100dpi, first in your search path. This will insure that when a particular font is requested [if it is available in both directories] it will be loaded from that directory.)

The HDS ViewStation uses either 75dpi or 100dpi font files, depending on the monitor used. Some application programs specify specific dpi values in their font requests and may require loading both 100dpi and 75dpi font directories. The correct font size is calculated by measuring the horizontal display width in inches, then dividing it into the horizontal resolution of the screen to give pixels/inch. Then choose the font resolution closest to that value, 75 or 100 dpi.

This information is also provided by the X command xdpyinfo. If your .bdf fonts appear as files with a .Z extension, they are compressed files (all files from the MIT distribution are compressed). You can convert these files easily with the uncompress command:

uncompress filename.bdf.Z
Or, using a wildcard character:
uncompress *.bdf.Z

The new files appear with the .bdf extension only. They then may be compiled into .snf font files.

Other systems, such as OPEN LOOK (usually .ff or .f3b font format), Hewlett Packard (in .scf format), or DECwindows (in .dwf format), have their own sets of precompiled fonts and font directories necessary for their operation. Some of these fonts may be in a scalable format (which means that they are general formulas for fonts and individual font files, in the desired sizes, must be created before they can be used); scalable fonts often have the .f3b extension on their file name, and their extended font name has 0-0's in the size and spacing fields.

Other common font formats include .afb and .afm, which are Adobe formats, bitmap and metric. On SUN systems, scalable fonts are converted to various size font files with the makeafb utility program, and these .afb files are converted to .bdf files with the convertfont utility. Other systems may use different formats and/or different utility conversion programs.

All of these font format types may be converted to HDS .snf format by using the HDS font utility programs, specifically, the hdsfc960 font compiler. This compiler takes font files of any format (even if they can be read only by the particular server they belong to), reads them with general X routines, and creates HDS format .snf files.

Return to Section Heading Page


Return to the Home Page

If you need more information than is available here, you can reach HDS via email at info@hds.com, or call us at 1.800.HDS.1551 in the USA, or at +610.277.8300 from outside the US. For questions or problems regarding the HDS WWW page, contact webmaster@hds.com.
© 1996 by HDS Network Systems Inc.