如何在常規 LaTeX 中使用“The New Yorker”字體

如何在常規 LaTeX 中使用“The New Yorker”字體

如何使用 Allen R. Walden 的“The New Yorker”字體(請參閱字體空間)在常規 LaTeX 中(不在 LuLaTeX 或 XeLaTeX 中)。

答案1

有兩種方法可以做到這一點:

新學校

使用autoinstNEWYORKR.TTF.它創建了在 (pdf)LaTeX 中使用該字體所需的所有文件。您可以像這樣調用它:

autoinst -encoding=T1      \
         -ts1              \
         -noupdmap         \
         -nooldstyle       \
         -noproportional   \
         -nosmallcaps      \
         -noswash          \
         -notitling        \
         -nosuperior       \
         -noinferiors      \
         -nofractions      \
         -noornaments      \
         -target=./Install \
         -verbose          \
         NEWYORKR.TTF

正確安裝後,可以得到以下結果:

\documentclass{article}
\usepackage{fonttable,textcomp}
\usepackage[T1]{fontenc}
\usepackage{NewYorker}

\begin{document}

\xfonttable{T1}{NewYorker-TLF}{m}{n}
\clearpage
\xfonttable{TS1}{NewYorker-TLF}{m}{n}

\end{document}

在此輸入影像描述

老套

從-file建立afm和文件並使用,這稍微複雜一些。你必須寫一個像這樣的文件:pfbttffontinstdrv

\input fontinst.sty
\needsfontinstversion{1.926}
\recordtransforms{fny-rec.tex}

\substitutesilent{bx}{m}
\substitutesilent{b}{m}

\transformfont{fnyr8r}{\reencodefont{8r}{\fromafm{NewYorker}}}

\installfonts
\installfamily{T1}{fny}{}
\installfont{fnyr8t}{fnyr8r,newlatin}{t1}{T1}{fny}{m}{n}{}
\endinstallfonts

\installfonts
\installfamily{TS1}{fny}{}
\installfont{fnyr8c}{fnyr8r,textcomp}{ts1}{TS1}{fny}{m}{n}{}
\endinstallfonts

\endrecordtransforms
\bye

和一個map生成器文件,例如:

\input finstmsc.sty
\resetstr{PSfontsuffix}{.pfb}
\adddriver{dvips}{fny.map}
\input fny-rec.tex
\donedrivers
\bye

然後你必須在和文件tex上運行加上:drvmap

for filename in *.pl; do pltotf $filename; done
for filename in *.vpl; do vptovf $filename; done

正確安裝後,您將得到:

\documentclass{article}
\usepackage{fonttable,textcomp}
\usepackage[T1]{fontenc}

\renewcommand*{\rmdefault}{fny}
\renewcommand*{\familydefault}{\rmdefault}

\begin{document}
\xfonttable{T1}{fny}{m}{n}
\clearpage
\xfonttable{TS1}{fny}{m}{n}
\end{document}

在此輸入影像描述

接下來的事情是教導fontinst從名稱與預期afm不符的字體中取得書寫字形fontinst

相關內容