10

I'd like to use Times fonts in Plain TeX. What would be the Plain-TeX equivalent of the LaTeX command \renewcommand{\rmdefault}{ptm}?

  • If you can use XeTeX, \font\times="Times" \times (or Times New Roman) or with LuaTeX. – morbusg Feb 19 '14 at 10:42
  • Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. – jub0bs Feb 19 '14 at 10:56
9

Looking at mathptmx.sty, the following should do

\font\tenrm=ptmr7t at 10pt % roman text
\font\sevenrm=ptmr7t at 7pt
\font\fiverm=ptmr7t at 5pt

\font\tenbf=ptmb7t at 10pt % boldface extended
\font\sevenbf=ptmb7t at 7pt
\font\fivebf=ptmb7t at 5pt

\font\tensl=ptmro7t at 10pt % slanted roman

\font\tenit=ptmri7t at 10pt % text italic

% for math family 0 we need a font different from ptmr7t    
\font\tenrmop=zptmcm7t at 10pt
\font\sevenrmop=zptmcm7t at 7pt
\font\fivermop=zptmcm7t at 5pt

\textfont0=\tenrmop
\scriptfont0=\sevenrmop
\scriptscriptfont0=\fivermop

\font\teni=zptmcm7m at 10pt % math italic
\font\seveni=zptmcm7m at 7pt
\font\fivei=zptmcm7m at 5pt

\font\tensy=zptmcm7y at 10pt % math symbols
\font\sevensy=zptmcm7y at 7pt
\font\fivesy=zptmcm7y at 5pt

\font\tenex=zptmcm7v at 10pt % math extension

\tenrm % choose default
  • OK. However \font\tensl=ptmbo7t at 10pt should be substituded with – Luigi Feb 20 '14 at 17:04
  • \font\tensl=ptmro7t at 10pt otherwise you get boldface slanted. – Luigi Feb 20 '14 at 17:06
  • @Luigi Sorry for the typo. – egreg Feb 20 '14 at 17:10
4

If you use opmac (distributed with csplain), simply type \input ctimes. In that case the tx-math.tex is loaded, which activates the TX fonts for math. If you need the T1 encoded fonts, type \input t1code before \input ctimes. You can change all sizes of the loaded fonts simply by stating, for example, \typosize[11.5pt/13.5pt]. If you use xetex or luatex then you can type \input ucode \input cs-termes to load the unicoded variant Termes from TeXGyre. Make sure you have all the required fonts, csfonts in particular, installed.

  • of the files you recommend, none seem to be in a normal plain-tex environment -- the ones i've located are in csplain (plain tex for czechs & slovaks, or something). whatever, they seem not to be present in my installation. are you suggesting that non-slavic people don't use plain tex? – wasteofspace Jun 25 '14 at 10:46
  • @wasteofspace There is only plain.tex and hyphen.tex in normal plain-tex environment. It is our decision to choose only this starting point and nothing more. But if users want to use some additional macros for plain TeX, they can use eplain or csplain. These packages are comparable. The csplain serves multilanguage support today. It is signed as "for czech and slovak" only from historical reason. – wipet Jun 25 '14 at 11:07
  • @wasteofspace I can say that csplain is most definitely NOT just for Czech/Slovak. I have used it with great success the past few weeks now. All the TeXGyre fonts are available out of the box with commands like \input cs-bonum or \input cs-termes. I highly recommend this TUGboat article: tug.org/TUGboat/tb34-1/tb106olsak-csplain.pdf. Also, If you use the OPmac package you get even more font conveniences. I haven't used csplain with pdftex or xetex much, mostly just luatex. csplain is a format so its best to invoke with something like: luatex --fmt=pdfcsplain ... – acarlow Jun 26 '14 at 6:50
1

If you want to load times fonts for text, you may use the plnfss package for plain.

\input plnfss
\usefont{LY1}{ptm}{m}{n}

beware you will switch to the LY1 encoding (LY1 is a superset of Latin1, roughly equivalent to win1252). You may need to install fonts encoded that way.

plnfss also provides with the classic LaTeX calls to switch attributes (\textit, \textbf, etc), but is limited in switching sizes.

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.