AMS/CM fonts in OpenType/CFF format

Marcel Fabian Krüger tex at 2krueger.de
Wed Nov 17 10:48:28 CET 2021


On Tue, Nov 16, 2021 at 11:54:23AM +0000, Philip Taylor (Hellenic Institute) wrote:
> > % !TeX Program=XeTeX
> > 
> > 
> > \font \cmr = "cmr9"
> > 
> > \cmr
> > 
> > The quick brown fox jumps right over the laxy dog's back.
> > 
> > \end
> > 
> and found, to my complete surprise, that the text in cmr9 also scaled
> perfectly.  So my question is, "where is XeTeX finding a scaleable version
> of cmr9, when the only OTF file that I have installed from your suite is
> cmr10 ?".  "Start / Control Panel / Fonts" reveals that only "CMR 10
> Regular" (of your font set) is installed, and a search under
> "C:\TeX\Live\2021" finds only :
> 
> > cmr9.afm
> > cmr9.mf
> > cmr9.pfb
> > cmr9.pfm
> > cmr9.t3
> > cmr9.tfm
> 
> Is it possible that XeTeX is using the PFB version and ignoring the string
> quotes around "cmr9" that should force it to use a system font, and if so,
> must I write (/e.g.,/) \font \cmr = "[cmr10.otf]" to force XeTeX to use
> /only/ your OTF versions and to report "Font not found" if the relevant
> font(s) is/are not installed ?  TeX Live and XeTeX lists cc'd for comment.

The string quotes don't have any special meaning in XeTeX. The font name
is read using TeX's normal file scanning routine which (at least for TeX
Live) uses string quotes to allow embedding spaces in the name and then
discards them. Therefore they never reach the parts of XeTeX where the
decision between system fonts and classical fonts is made.

If you want to load the font by fontname, you can try to add a colon
instead to add an empy feature string. Then the TFM file isn't found. So
you would have e.g. `\font \cmr = "cmr10:"` (I haven't checked if the
font is actually found by that name, but if you have an OpenType font
with fontname cmr10 installed than this would work)

Marcel


More information about the tex-live mailing list.