Behaviour of \latinfamily

Sebastian Rahtz s.rahtz@elsevier.co.uk
Tue, 26 May 1998 14:02:30 +0100


Rebecca and Rowland writes:
 > Ah!  Information.  How can you tell that fontinst is looking for an
 >mtx file?
   \if_file_exists{ 
      \font_family\font_weight\raw_shape
         \raw_variant\raw_encoding\font_width.mtx 
   }\then 
     \immediate\write16{INFO>~found~\font_family\font_weight
           \raw_shape\raw_variant\raw_encoding\font_width.mtx}
      \latin_encodings 
   \fi 

 > Does a list exist of which transformations and re-encodings fontinst will
 > do on its own?  I'm trying to document the process, you see, and I can't
 > work out any of these points from the source code or log files.
well, you can, you know. 

you just need to apply some judious editing to make it readable. for
instance, here is fake_shape in a rational form, with ptmr hard-wired
in. i leave fake_width as an example for the reader....


IF file exists{ptmr8a.afm} THEN
 IF file exists{ptmr8r.mtx} THEN
 ELSE
    \transformfont{ptmr8r}{\reencodefont{8r}{\fromafm{ptmr8a}}
 FI
 IF file exists{8r.mtx} THEN
   \installrawfont{ptmr8r}{ptmr8r,8r}{8r}{8r}{\latex family}{\latex weight\latex width}{\latex shape}{}
 FI
ELSe
 IF file exists{ptmr8r.afm} THEN
   IF file exists{ptmr8r.mtx} THEN
   ELSE
    IF file exists{8r.mtx} THEN
      \installrawfont{ptmr8r}{ptmr8r,8r}{8r}{8r}{\latex family}{\latex weight\latex width}{\latex shape}{}
    FI
   FI

 > You said above that fontinst was looking for an mtx file, and here you say
 > it's looking for an afm file.  Can you explain what's going on?  I gather
 > fontinst can work with pl, afm, or mtx files.  Which sort is it looking for
 > here, and if it looks for more than one, what's the search order?
it must have .mtx for the \installfont. so if that exists, it uses
it. else it calls \transformfont to build one  from the .afm file

 > you're talking about.  fontinst just sits there until you start executing
 > commands.  Which commands cause it to exhibit this behaviour?
\latinfamily

as Uklrik says

\latinfamily calls\latin_weights which executes \latin_widths which
executes \latin_shapes which executes \latin_encodings

 > But I've never seen fontinst place any entries in a 8r.fd file, even though
 > it's created 8r.fd files for me quite happily.  I've also not worked out
does it any more?

 > seems that I'm supposed to be able to work out all sorts of things that
 > aren't stated explicitly.  Well, I've tried, and got no-where.
 > 
they *are* explicit. the TeX code is umambiguous. its just not
English...

sebastian