#!/bin/sh # This script prepares Czech and Slovak TeX font using a2ac and afm2tfm # The name of output virtual font is prefixed by c and font encoding # is chosen by ISO 8859-2 (more precisely by CS-encoding defined in files # xl2.enc or xt2.enc). if test $# -lt 2 ; then echo usage: echo ' ' mkfnt Full-PostScript-Name texname echo for example: echo ' ' mkfnt Times-Roman ptmr echo more advanced usage: echo ' ' mkfnt Full-PostScript-Name texname nextletters [afm2tfm options] echo where [afm2tfm options] have to end by -v or -V . For example: echo ' ' mkfnt Times-Roman ptmr c -V echo makes the cptmrc.vf: the Caps and Small Caps variant of Times-Roman. exit fi # You can edit the following paths in order to match with your system strategy. # The currentdir variants of output can be used by any user. # corrtabfile=/usr/lib/a2ac/cscorr.tab corrtabfile=cscorr.tab texfontpath=/usr/lib/texfm/fonts # encfilepath=$texfontpath/enc encfilepath=. afminput=/usr/openwin/lib/fonts/afm # vfoutput=$texfontpath/vf/dvips vfoutput=. # tfmoutput=$texfontpath/tfm tfmoutput=. # rtfmoutput=$texfontpath/tfm/dvips rtfmoutput=. a2ac $afminput/$1.afm $corrtabfile c$2.afm if grep 'IsFixedPitch true' c$2.afm ; then encfile=$encfilepath/xt2.enc else encfile=$encfilepath/xl2.enc fi if test $# -gt 2 ; then afmparam=$4 $5 $6 $7 $8 $9 else afmparam=-v fi echo afm2tfm c$2.afm -t $encfile $afmparam c$2$3.vpl $rtfmoutput/r$2.tfm afm2tfm c$2.afm -t $encfile $afmparam c$2$3.vpl $rtfmoutput/r$2.tfm vptovf c$2$3.vpl $vfoutput/c$2$3.vf $tfmoutput/c$2$3.tfm rm c$2.afm c$2$3.vpl