2

Processing the following input with csplain prints "ec-lmr10":

\input t1code \input utf8lat1 \frlang \input lmfonts
\message{\fontname\tenrm}
\end

Is it possible to change this example so that "rm-lmr10" will be printed instead?

1
  • You're asking for T1 encoded fonts, so ec-lmr10 is the choice; \fontname returns the name of the TFM file. – egreg Aug 28 '19 at 7:10
2

In lmfonts.tex we find

\ismacro\fotenc{8t}\iftrue \def\ffnamepre{ec-}\fi      % T1 aka Cork

In cs-heros.tex we find

Encodings
---------

You can declare more cases for various text font encondings. User can define
font encoding by \def\fotenc{something}. Note \fotenc, no \fontenc. The
sequence \fotenc means "FOnt Text ENCoding".

The ff-mac.tex keeps the \fotenc macro unchanged, but if it is not defined then it does:

- \def\fotenc{8z} if CSplain is used without \input t1code nor \input ucode
- \def\fotenc{8t} if \input t1code or pdfTeX without CSplain is used
- \def\fotenc{U}  if \input ucode or XeTeX or LuaTeX is used

So when t1code.tex is loaded, the ec-lm??? fonts will be used: accents (and not only them) would print wrong if the rm-lm??? fonts are used.

Since \fontname<font> returns the name of the TFM file corresponding to the <font> selector, you get ec-lmr10 as expected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.