# Installing new fonts for use with PDFlatex [duplicate]

I have been looking around the web for guides on how to install a new font for LaTeX with PDFlatex. There are plenty of guides, but I have a hard time trying to follow them.

At the moment I have the following files and file structure:

``````-pwb(walbaum)
-fonts
-afm
-abobe
-walbaum
<18x .afm files>
-enc
<empty>
-map
<1x .map file>
-tfm
-abobe
-walbaum
<60x .tfm files>
-type1
-abobe
-walbaum
<18x .pfb files>
-vf
-abobe
-walbaum
<30x .vf files>
-tex
-latex
-abobe
-walbaum
<4x .fd files>
<1x .sty file>
``````

So what is the next steps to be able to use the font? Where should I put the files, etc? And will I be able to use it for math equations?

If you can explain it in a simple way, I would be glad.

Bonus info: I am using TexMaker and PDFLatex on a Mac.

-

## marked as duplicate by Martin Schröder, Jubobs, Christian Hupfer, Guido, moeweAug 6 '14 at 10:46

You find instructions in appendix B of this paper: tug.org/TUGboat/tb32-1/tb100gregorio.pdf –  egreg Aug 6 '14 at 9:19
Since you are using TeXLive, you will have to refresh your file database (`texhash`) and run `updmap`. But really: Use XeTeX or LuaTeX. Both do microtype, LuaTeX more so. –  Martin Schröder Aug 6 '14 at 10:02
@MartinSchröder, wouldn't it be better to use `updmap-sys` if it is a single user system? –  daleif Aug 6 '14 at 10:06
@daleif: Probably. :-) –  Martin Schröder Aug 6 '14 at 10:09
@daleif Better to use it if it is a single user system; essential if it is a multi user system. (Unless installing the font in your personal tree but that is not recommended unless you don't have permission to do anything else. In which case no need to update the database either.) –  cfr Aug 6 '14 at 21:48

Do you know of the fontspec package? According to the documentation it "allows users of either XeTeX or LuaTeX to load OpenType fonts in a LaTeX document. No font installation is necessary, and font features can be selected and used as desired throughout the document."

I use it with documents typeset using pdflatex on Mac, simply putting

``````\usepackage{fontspec}
\setmainsfont{Georgia}
``````

to use Georgia, which is installed as a system font.

-
The reason why I don't want to use the fontspec package, is that is not is compatible with the microtype package, which I use. –  Christoffer Aug 6 '14 at 9:20
@GeertF that doesn't work with PDFLaTeX, only with LuaLaTeX or XeLaTeX. –  Juri Robl Aug 6 '14 at 9:21
@Christoffer `microtype` supports most of it functionality with LuaLaTeX. –  Juri Robl Aug 6 '14 at 9:23

Essentielly you're missing a `pwb.map` file which describes the correspondence between the virtual fonts and the actual, type 1 fonts, so that pdflatex or dvips can use them. You install it in `your_local_texmf\ fonts\map`\adobe` (not abobe!). That done:

1. Add to your `local` `updmap.cfg` this line: `Map pwb.map`
2. Run `texhash` (TeXLive or MacTeX) or `Refresh FNBD` (MiKTeX)
3. Run `initexmf --mkmaps` to refresh the databases of type 1 fonts

You can see more details in the excellent `Font Installation Guide`

-
I have a problem with no.3 in your procedure. When I run the command `initexmf --mkmaps` I get the following error: `-bash: initexmf: command not found`. –  Christoffer Aug 6 '14 at 10:39
Oh! I gave the procedure for MiKTeX. For TeX Live and MacTeX, run (+ sudo if you're not under Windows) `updmap-sys --enable Map=pwb.map, then run `texhash``. –  Bernard Aug 6 '14 at 11:15
It seems like the terminal commands worked. However, when I try to use the font, I end up with this warning: `Font shape `T1/pwb/m/n' undefined`. I am trying to load the font with `\usefont{T1}{pwb}{m}{n}\selectfont` Any ideas of what is wrong? –  Christoffer Aug 6 '14 at 12:23
Mac OS X - Mavericks –  Christoffer Aug 6 '14 at 12:35
Sudo? Do you have a t1pwb.fd file, and the relevant .vf files? –  Bernard Aug 6 '14 at 12:38