View on
Johan Vromans > PostScript-Font > fontsampler


Annotate this POD


Open  2
View/Report Bugs


fontsampler - make sample pages from PostScript fonts


fontsampler [options] [PostScript font files ...]

   -details             show font details instead of samples
   -[no]align           align to even page (default with -duplex)
   -manualfeed          manual feed paper
   -[no]duplex          duplex printing
   -[no]tumble          tumble (default with -duplex)
   -title XXX           descriptive title
   -[no]include         include the font definition (default)
   -[no]famskip         add extra space between different families
   -ident               show identification
   -help                brief help message
   -man                 full documentation
   -verbose             verbose information


fontsampler writes a PostScript document to standard output to make sample pages of PostScript and True Type fonts.

The program takes, as command line arguments, font files. For PostScript files, these should contain an ASCII encoded font (a so called .pfa file), or a binary encoded font (a so called .pfb file).

The resultant PostScript document conforms to Adobe's Document Structuring Conventions (DSC), version 3.0.

The program can run in one of two modes, depending on the -details option. Without this option, from every font the name and a small sample of characters is printed, up to 38 font samples per page.

With the -details option, every font gets at least one page of output. These pages contain detailed information about all the glyphs that are present in the font, starting with the glyphs as defined in the ISO Latin1 encoding, and followed by the glyphs are not part of this encoding. Each page can take up to 256 glyphs.

fontsampler depends on the capabilities of the PostScript::Font module. If your version supports True Type fonts, fontsampler will happily process True Type fonts as well.



Enable detailed output.


With -details, start every new font on an even page. Useful for n-up processing and duplex printing.

This option is automatically enabled with duplex printing.


Insert PostScript code to enable or disable duplex printing. This need to be supported by the printer.

This options will also enable -align and -tumble.


Insert PostScript code to enable or disable tumble. Only relevant with duplex printing.


Manual feed is requested when the job is printed. Requires a printer that can handle PostScript Level 2 of above.

-title XXX

A descriptive title that is printed on top of each page.


When enabled, the font definitions are inserted in the PostScript output. This results in a self-contained PostScript document that can be printed directly.

When disabled, DSC comments are inserted in the output that need to be processed by a suitable print manager (unless all fonts are resident in the printer).

-include is enabled by default.


Add some extra space between entries of different families. This is on by default. In the worst case, when all the fonts are of different families (or unsorted!) this reduces the number of samples per page to about 25.


Print a brief help message and exits.


Prints program identification.


More verbose information.


This program uses the PostScript::Font package to get at the fonts info. The cababilities of this program, especially when dealing with weird fonts or True Type fonts, depend on this package. See PostScript::Font for details.

If a font is shown in a one-page detail page, and it gets substituted by a multi-page font, the PostScript engine will crash. This usually happens if the font cannot be found, and the PostScript engine substitutes the (multi-page) Courier font.

Contrary to popular belief, lots of buggy and erroneous fonts exist. Caveat emptor!


Johan Vromans, Squirrel Consultancy <>


This program is Copyright 2000,1998 by Squirrel Consultancy. All rights reserved.

This program is free software; you can redistribute it and/or modify it under the terms of either: a) the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version, or b) the "Artistic License" which comes with Perl.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See either the GNU General Public License or the Artistic License for more details.

syntax highlighting: