# Beamer: use glyphs from smaller font size, but enlarge

Like most full-featured typefaces, Computer Modern has different versions for different display sizes. Smaller sizes have a wider aspect ratio, heavier serifs, and less variation between horizontal and vertical strokes. These features make text more legible at small sizes.

Beamer defaults to an 11-point font. In my opinion, this is too big. I want those legibility features from smaller sizes. However, I think the overall size of Beamer's fonts is good. Selecting \documentclass[8pt]{beamer} results in too many characters per line.

How can I tell Beamer to use the glyphs of a smaller size of Computer Modern, but enlarge them to (roughly) the same size as default?

• The typical suggestion here would be to choose the smaller font and then also reduce your slide size, so you're technically scaling everything up. – Werner Mar 10 at 23:26
• Ah, for some reason I thought Beamer allowed you to control aspect ratio but not size. Thanks. – japreiss Mar 10 at 23:29
• It's suggested to use the aspect ratio options, but you can set the paper size, if you wish, via \setbeamersize. – Werner Mar 10 at 23:34

Consider this minimal example that uses the default of 11pt font and a 43 (or 4:3 aspect ratio, or 12.8cm x 9.6cm page dimension):

\documentclass{beamer}

\usetheme{Warsaw}

\begin{document}

\begin{frame}
\frametitle{There Is No Largest Prime Number - 11pt}
\framesubtitle{The proof uses \textit{reductio ad absurdum}.}
\begin{theorem}
There is no largest prime number.
\end{theorem}
\begin{proof}
\begin{enumerate}
\item<1-| alert@1> Suppose $p$ were the largest prime number.
\item<2-> Let $q$ be the product of the first $p$ numbers.
\item<3-> Then $q+1$ is not divisible by any of them.
\item<1-> But $q + 1$ is greater than $1$, thus divisible by some prime number not in the first $p$ numbers.\qedhere
\end{enumerate}
\end{proof}
\end{frame}

\end{document}


You can choose the 8pt font option, and resize the page to have a similar aspect ratio, but slightly smaller (by a scaling factor of 8/11 thanks to xfp):

\documentclass[8pt]{beamer}

\usepackage{xfp}
\makeatletter
% Taken from beamer.cls' default geometry settings
% http://mirrors.ctan.org/macros/latex/contrib/beamer/base/beamer.cls
\geometry{%
papersize={\fpeval{\beamer@paperwidth*8/11}pt,\fpeval{\beamer@paperheight*8/11}pt},
hmargin=\fpeval{8/11}cm,% 1cm
vmargin=0cm,%
foot=\fpeval{0.5*8/11}cm% 0.5cm
}
\makeatother

\usetheme{Warsaw}

\begin{document}

\begin{frame}
\frametitle{There Is No Largest Prime Number - 8pt}
\framesubtitle{The proof uses \textit{reductio ad absurdum}.}
\begin{theorem}
There is no largest prime number.
\end{theorem}
\begin{proof}
\begin{enumerate}
\item<1-| alert@1> Suppose $p$ were the largest prime number.
\item<2-> Let $q$ be the product of the first $p$ numbers.
\item<3-> Then $q+1$ is not divisible by any of them.
\item<1-> But $q + 1$ is greater than $1$, thus divisible by some prime number not in the first $p$ numbers.\qedhere
\end{enumerate}
\end{proof}
\end{frame}

\end{document}


Here's a rough visual of the difference:

You may have to change other lengths as well just because the scaling doesn't translate unilaterally to font-related concepts. Visually, however, it suffices to be very similar in display.

The simplest way to do this is to use the OpticalSize= font feature, from fontspec, and a font that supports it, such as Latin Modern or the TeX Gyre series. This has none of the side-effects of shrinking the document size.

There is really no reason not to use modern software with beamer, since you aren’t submitting a beamer presentation to a publisher who requires you to use PDFTeX.

\documentclass{beamer}
\tracinglostchars=2
\usetheme{Warsaw}
\usefonttheme{professionalfonts}
\usepackage{unicode-math}

\defaultfontfeatures{ Ligatures=TeX, OpticalSize=20 }

\setmainfont{Latin Modern Roman}
\setsansfont{Latin Modern Sans}
\setmathfont{Latin Modern Math}
\setmathfont{XITS Math}[range=\QED, Scale=MatchUppercase]

\renewcommand\qedsymbol{\ensuremath{\QED}}

\begin{document}

\begin{frame}
\frametitle{There Is No Largest Prime Number - 20pt}
\framesubtitle{The proof uses \textit{reductio ad absurdum}.}
\begin{theorem}
There is no largest prime number.
\end{theorem}
\begin{proof}
\begin{enumerate}
\item<1-| alert@1> Suppose $p$ were the largest prime number.
\item<2-> Let $q$ be the product of the first $p$ numbers.
\item<3-> Then $q+1$ is not divisible by any of them.
\item<1-> But $q + 1$ is greater than $1$, thus divisible by some prime number not in the first $p$ numbers.\qedhere
\end{enumerate}
\end{proof}
\end{frame}

\end{document}


And mutatis mutandis:

Additional use of \setmathfont[range=... can get you sans-serif math letters, too.