Re: ttf font installation

<[email protected]> Thu, 1 Sep 2005 11:15:16 +0100
Newsgroups gmane.comp.tex.tetex.general
Message-ID <4E28CEA517A795438B120F62D182A8C923CDF8@I2KM11-UKBR.domain1.systemhost.net>
Thomas: I appreciate very much your reply and advice.   I already had looked at the tetex manual, but part of
my confusion comes from other webpages which offer only out-of-date advice on this question.    On my system
(Fedora core 4), "texdoc <anything>" says "Can't find documentation for 'anything'".   Is this a bug with Fedora?

However, even after following the tetex pdf manual, I have no success.   Here is exactly what I have done:

font=gara

ttf2afm -e T1-WGL4.enc ${font}.ttf -o rec${font}.afm
afm2tfm rec${font}.afm -T T1-WGL4.enc rec${font}.tfm

cat >| t1${font}.fd <<End-of-fdfile
\ProvidesFile{t1${font}.fd}[${font}]
\DeclareFontFamily{T1}{${font}}{}
\DeclareFontShape{T1}{${font}}{m}{n}{<-> rec${font}}{}
\DeclareFontShape{T1}{${font}}{bx}{n}{<->ssub * ptm/m/n}{}
\DeclareFontShape{T1}{${font}}{m}{it}{<->ssub * ptm/m/it}{}
\DeclareFontShape{T1}{${font}}{m}{sl}{<->ssub * ptm/m/sl}{}
\DeclareFontShape{T1}{${font}}{m}{sc}{<->ssub * ptm/m/sc}{}
\DeclareFontShape{T1}{${font}}{bx}{it}{<->ssub * ptm/b/it}{}
\DeclareFontShape{T1}{${font}}{bx}{sl}{<->ssub * ptm/b/sl}{}
\pdfmapline{+rec${font}\space <${font}.ttf\space <T1-WGL4.enc}
End-of-fdfile

cat >| ${font}.tex <<End-of-texfile
\documentclass{article}
\DeclareTextFontCommand{\text${font}}{\fontencoding{T1}\fontfamily{${font}}\selectfont}
\begin{document}
Hello.
\end{document}
End-of-texfile

pdflatex ${font}.tex

This works.  Now I try to install everything:

font=gara

texmf=/usr/local/share/texmf

mkdir -p ${texmf}/fonts/afm/kbriggs
mv rec${font}.afm ${texmf}/fonts/afm/kbriggs

mkdir -p ${texmf}/fonts/tfm/kbriggs
mv rec${font}.tfm ${texmf}/fonts/tfm/kbriggs

mkdir -p ${texmf}/fonts/truetype/kbriggs
cp ${font}.ttf ${texmf}/fonts/truetype/kbriggs

mkdir -p ${texmf}/tex/latex/kbriggs
mv t1${font}.fd ${texmf}/tex/latex/kbriggs

mkdir -p ${texmf}/fonts/map/pdftex/unknown/
cp gara.map ${texmf}/fonts/map/pdftex/unknown/
updmap --enable Map gara.map

(gara.map is "recgara Garamond  T1Encoding ReEncodeFont  <T1-WGL4.enc < gara.ttf")

Now "pdflatex ${font}.tex" does not work any more: "Font gara .. not found".

Any more hints gratefully received!

Keith