# How to select Latin Modern font for small sizes

I want to demonstrate in a presentation different fonts. In the beamer talk the fonts Courier and Bera Sans are used, but for the demonstration I also want to use Latin Modern Roman as well.

This is what I do to print the text:

\usefont{T1}{lmr}{m}{n}
\small Latin Modern Roman \\
\tiny\sampletext


which gives me a comparable HUGE text size. Doing the same for courier font looks correct:

\usefont{T1}{bch}{m}{n}
\small Charter \\
\tiny\sampletext


I assume that the wrong font is scaled to tiny, but how do I select the correct font?

Here's a comparison; the first block is Latin Modern at 5pt size (the specially designed font), the second block is Latin Modern 10 scaled at 5pt, the third block is Charter scaled at 5pt

The artifacts of the conversion to a bitmap image are good to show what's the purpose of specially designed fonts for small sizes (and also for bigger sizes): making the text readable.

Here is the code

\documentclass{standalone}
\usepackage{lmodern,lipsum}\frenchspacing

\begin{document}
\vbox{\hsize=5cm
\small Latin Modern Roman \\
\tiny\lipsum[2]

\small Latin Modern Roman (scaled) \\
{\normalsize\font\x=\fontname\font\space at 5pt \tiny\x
\lipsum[2]\par}

\usefont{T1}{bch}{m}{n}
\small Charter \\
\tiny\lipsum[2]

}
\end{document}

• Actually for this demonstration purpose I want the normal font to be scaled down, since the designed font appears to be much much larger than the scaled version of charter. Can you show the code for your answer? – Matthias Pospiech Sep 30 '11 at 11:14
• does not work for me: \usefont{T1}{lmr}{m}{n} \small Latin Modern Roman \{\normalsize\font\x=\fontname\font\space at 5pt \tiny\x \sampletext} Font is not scaled down. – Matthias Pospiech Sep 30 '11 at 12:09
• @MatthiasPospiech It is. What's in \sampletext? – egreg Sep 30 '11 at 12:22
• only text with several lines. – Matthias Pospiech Sep 30 '11 at 13:15
• Add \par at the end of \sampletext. Actually the font is scaled, but the baselines are too far apart, aren't they? The problem is that the closing brace clears up the \tiny setting (for the baseline), so the paragraph is typeset as the last declaration in force (here \small) tells to. – egreg Sep 30 '11 at 13:19

Are you maybe looking to use the \fontsize command? The following MWE demonstrates its usage.

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\newcommand{\sampletext}{Some randomly chosen words.}
\begin{document}
\fontsize{4}{6}\selectfont\sampletext\par
\fontsize{5}{7}\selectfont\sampletext\par
\fontsize{6}{8}\selectfont\sampletext\par
\fontsize{7}{9}\selectfont\sampletext\par
\fontsize{8}{10}\selectfont\sampletext\par
\fontsize{9}{11}\selectfont\sampletext\par
\fontsize{10}{14}\selectfont\sampletext\par
\fontsize{12}{15}\selectfont\sampletext\par
\fontsize{14}{17}\selectfont\sampletext\par
\fontsize{17}{20}\selectfont\sampletext\par
\fontsize{20}{25}\selectfont\sampletext\par
\fontsize{25}{30}\selectfont\sampletext\par
\fontsize{30}{35}\selectfont\sampletext\par
\end{document}


Note that when you use a font in a relatively tiny size (such as 4, 5, and 6 points), you're better off if the font has a variant that's properly designed for these small sizes. (Latin Modern is such a font.) Without such size-specific adjustments, the text will look skinny and thin when displayed at small sizes (and very heavy and ponderous when displayed at sizes much larger than the "design size").