Notes on setup of PostScript fonts for L^{A}TEX 2ε

Sebastian Rahtz

                 s.rahtz@elsevier.co.uk

1997/02/23

Contents

1 Introduction 1

2 Finding font metrics 2

3 Standard installation 3

4 Testing 3

5 User interface 4 5.1 Variant OT1 font encoding . . . . . . . . . . . . . . . . . . . . . 4

6 Font family names 5

1 Introduction

This set of files^{1} offers a sample working setup for L^{A}TEX 2ε’s NFSS and PostScript fonts; it is based on the system I created between 1989 and 1991 for Southampton Computer Science department, checked and updated for NFSS2, and subsequently L^{A}TEX 2ε. You should be familiar with the standard L^{A}TEX 2ε files and their use to follow this document. It is assumed that Karl Berry’s naming scheme is followed.

Packages are offered to set documents in the common PostScript fonts, plus common free fonts (Charter, Utopia etc). All Lucida fonts are supported. The MathTime fonts are not supported fully because I do not understand them and do not have them; a package by Aloysius Helminck is provided as-is in the ‘unsupported/mathtim’ subdirectory, about which enquiries should be addressed to him.

1Thanks are due to many, many, people for correcting errors and helping, including Michel Goossens, Alois Steindl, Peter Dyballa, Aloysius Helminck, Constantin Kahn, Berthold Horn, Alan Jeffrey, Howard Marvel, Frank Poppe, Andrew Trevorrow, Piet Tutelaars…

2 Finding font metrics

IMPORTANT NOTE: .fd files and .tfm files for the common setup are not included in this package. They can be found in the CTAN archives in the companion collection (fonts/psfonts) for each font family separately. That collection also includes simpler L^{A}TEX 2ε package files for each font family. To install a font family, take the following steps:

1. Locate the font family in the fonts/psfonts directory, which is divided up by foundry (eg adobe, monotype etc). If, for instance, you want the ‘normal’ Times Roman, this is in adobe/times. The family names for the directories are listed in Karl Berry’s font-naming documentation.

2. Each family directory has subdirectories containing .tfm, .vf and .fd files. You need to install these where L^{A}TEX 2ε and your driver will find them. L^{A}TEX 2ε will need the .tfm and .fd files, and the driver needs the .vf files (and possibly the .tfm ones too).

3. You now need to tell your driver that you are going to use these new PostScript fonts (to stop it looking for Metafont sources and .pk files). Using dvips this is accomplished by taking the .map file in the family directory and appending it to the standard psfonts.map file of dvips. Alternatively you can install the .map and the config file (named config.short family name (eg Times’ short name is ptm, so the config file is config.ptm) where dvips’ support files live, and use eg dvips -Pptm to load the extra .map file on the fly. Refer to the dvips manual for full details of map and config files.

If you don’t use dvips, refer to your driver’s manual for how to tell it about new PostScript fonts.

4. If the font is not resident in the printer, you’ll have to download it. You can use software supplied with the font to do this, or have it done on the fly by some drivers. However, note that the names in the .map files supplied on CTAN assume strict conformancy with the Berry scheme — you may have to rename your .pfb or .pfa font file.

5. If you just want to load one font family, and have it replace the default roman, sans or typewriter family in your document, each of the font family directories has a simple L^{A}TEX2e .sty package file.

It is also Very Important to understand the naming system and generation of the fonts! This setup follows the latest version of the scheme by Karl Berry (on CTAN in info/fontname) religiously. The metric and .fd files are named differently from the AFM files distributed by all font suppliers at this time (January 1997). Thus, for Times Roman, the OT1-encoded font is called ptmr7t, the T1-encoded font is ptmr8t and the raw font is ptmr8r. This system will be followed exactly in all PostScript font support in L^{A}TEX 2ε.

The font metric files whose use we assume are those generated using Alan Jeffrey’s fontinst package. These used to generate quite tight setting compared to other systems, which produced a lot of hyphenation or overfull boxes if you were not careful. However, since February 1995, the metrics have changed, so the advice to reset various TEX tolerance parameters etc no longer applies.

3 Standard installation

This distribution is provided as a set of .dtx files which need to be unpacked using docstrip to create user files. The resulting .sty files change the font defaults to use some new group of fonts (sometimes just one default is changed).

Scripts are provided for docstrip in the form of .ins files, which simply need to be run through TEX; when that has been done, install all the .sty files that result in a directory where L^{A}TEX will find them.

You have an important decision to make at some point — are you going to use fonts encoded in the ‘Cork’ layout, or the old ones which look like the CM fonts described in the TEX book? This manual will not attempt to explain why you should or should not use Cork fonts… Font description (.fd) files are available for both T1 and OT1 encoding in the CTAN fonts/psfonts directories.

If you follow the Cork-encoding route, you need different TEX font metric files and virtual font files. To activate this, use the package t1enc.

Important. If you use the Cork (T1 in L^{A}TEX 2ε scheme) encoding, you will probably also need the EC fonts to go with them, for maths and so on.

The standard ‘35’ PostScript fonts built into most PostScript printers are known by their ‘Berry’ names:

Family name Full name
pag  Adobe AvantGarde
pbk  Adobe Bookman
pcr  Adobe Courier
phv  Adobe Helvetica
pnc  Adobe NewCenturySchoolbook
ppl  Adobe Palatino
ptm  Adobe TimesRoman
pzc  Adobe ZapfChancery
psy  Adobe Symbol font
pzd  Adobe ZapfDingbats

To create font and package files for Lucida and Lucida Bright (including Lucida Bright maths), run TEX on lucida.ins.

4 Testing

All installers should run test0.tex through L^{A}TEX and print the result, after installing their chosen setup, to ensure that things are more or less working.

Package  Sans font  Roman font  Typewriter font
times.sty  Helvetica  Times  Courier
palatino.sty Helvetica  Palatino  Courier
helvet.sty  Helvetica
avant.sty  AvantGarde
newcent.sty AvantGarde NewCenturySchoolbook Courier
bookman.sty AvantGarde Bookman  Courier

Table 1: Effect of package files

The OT1 encoding demonstration will not have a proper set of pounds signs! They will all be italic. test1.tex will exercise your supply of PostScript fonts.

Do not worry if nothing but test0.tex works!. test0.ps is a prebuilt version of test0.tex for you to compare.

5 User interface

The daily user will simply use one of the packages times, newcent, helvet, palatino etc to change the default text fonts for one or more of the roman, sans-serif and typewriter faces. Table 1 lists the effects of the package files created in the installation procedure.

The special package pifont gives access to the Dingbat and Symbol fonts. This is described in The L^{A}TEX Companion. Note that maths fonts will stay the same unless you have suitable fonts to load. If the Adobe Lucida Maths fonts have been purchased, and appropriate metrics obtained, loading lucmath will remove all reference to CMR fonts in the document. Alternatively, purchase the Lucida Bright font set and use the lucbr package.

5.1 Variant OT1 font encoding

The package files assume that you have already made the choice of which text font encoding scheme you prefer (T1 or OT1), and that it is the default when the L^{A}TEX job starts. If you end up using older OT1 tfm files distributed with dvips before mid 1995, you’ll find some characters are not in the expected places. Similarly, older Textures users will find things not quite right. Y&Y users may be loading reencoding packages which moves things around. Prior to 1995, PSNFSS provided a package ot1var to cope with this sort of situation. It is now not supported or maintained. The remnants are in the obsolete subdirectory for the curious.

Package  Sans font  Roman font  Typewriter font
basker.sty  Monotype Baskerville
bembo.sty  Bembo
charter  Bitstream Charter
garamond.sty  Adobe Garamond
mtimes  Monotype Times
nimbus  URW NimbusSans-Regular URW NimbusRoman-Regular
utopia  Utopia
lucid.sty  LucidaSans  Lucida  Courier
lucbr.sty  LucidaSans  LucidaBright  LucidaTypewriter

Table 2: Effect of extra package files

Notes: a) lucbr.sty uses the font names for Lucida Bright which conform to Karl Berry’s scheme. Use package option ‘yy’ to use the font names supplied by Y&Y. b) If you want to use just standard PostScript fonts for math, Alan Jeffrey’s mathptm package does as good a job as possible (though it still needs access to some CMR math fonts). The extra metric and virtual font files that this needs are supplied with Adobe Times Roman in the CTAN

fonts/psfonts/adobe/times directory.

6 Font family names

Family name Full name
bch  Bitstream Charter
hlc  B&H Lucida Bright
hlcs  B&H Lucida Sans
hlct  B&H Lucida Bright Typewriter
pgm  Adobe Garamond
mim  Monotype Imprint
mnt  Monotype Times New Roman
pgm  Adobe ITC Garamond
pgs  Adobe MGillSans
pgs  Adobe MGillSans
plc  Adobe Lucida
plcs  Adobe Lucida Sans
pnb  NewBaskerville
pop  Adobe Optima
pun  Adobe Univers
put  Adobe Utopia-Regular
unmr  URW NimbusRoman-Regular
unmrs  URW NimbusSans-Regular