[Tex/LaTex] How to change the \texttt font


This question is the most similar to my own, but it was closed before anyone could answer it. Looking here there are quite a few "Typewrite" fonts built into LaTeX. I was wondering what the default font is for \texttt, and how I would go about changing the font to one of the others on this list.

Best Answer

It looks like you can just use the package, for example:


You can also use (assuming the font is available):

\renewcommand*{\ttdefault}{(font name)}

With fontspec, you can also use:

\setmonofont{⟨font name⟩}[⟨font features⟩]