Skip to content
Tutorials Center
My learning

Topics

Lesson 32 of 38 ยท Beamer, Tooling and Workflows

Beamer Overlays, Themes and Animation

Reveal slide content step by step with \pause, <1-> overlay specifications and \only, \uncover and \onslide, then choose and customise Beamer themes and colours.

A slide full of text appears all at once and the audience reads ahead of you. Overlays let one frame show several steps: each step is a separate PDF page with the same frame but with different parts visible. Beamer's themes control layout, colours and fonts for the whole talk. This lesson covers both.

\pause: the quick way

LATEX
\begin{frame}{Three claims}
  First claim.
  \pause
  Second claim appears after a click.
  \pause
  Third claim.
\end{frame}

Each \pause hides everything after it until the next page. Inside lists, put \pause after an \item, or give the frame an [<+->] option so that every item appears one after another:

LATEX
\begin{itemize}[<+->]
  \item Appears on step 1
  \item Appears on step 2
  \item Appears on step 3
\end{itemize}

Overlay specifications

For more control, add a specification in angle brackets after a command or an \item:

Spec Meaning
<2> Only on step 2
<2-> From step 2 on
<-3> Up to step 3
<2-4> Steps 2 to 4
<1,3> Steps 1 and 3
<+-> Automatic: next step each time
<.-> Same as the current step, then onward
LATEX
\begin{itemize}
  \item<1-> Always from the start
  \item<2-> Appears second
  \item<3> Only on step 3
\end{itemize}

\textbf<2>{Bold only on step 2}
\alert<3->{Highlighted from step 3}
\includegraphics<2->[width=5cm]{result.pdf}

Many commands accept the overlay argument directly: \textbf, \textcolor, \alert, \item, \includegraphics, \only, \uncover, \visible, \invisible, \onslide.

\only, \uncover, \visible, \onslide

They differ in how they treat space:

  • \only<2>{text}: the text exists only on step 2 and takes no space otherwise. The layout can jump.
  • \uncover<2>{text}: the text is invisible but occupies space on other steps, so nothing moves.
  • \visible<2>{text}: like uncover but without transparency effects.
  • \onslide<2->{ ... }: switches visibility for everything until the end of the group.

To swap one formula for another in the same place, use \only for each, or \alt<2>{new}{old}. For tables, use \rowcolor<2>[yellow]{...} with the colortbl package.

The stand-in below shows what Beamer does with the overlay list: it expands a frame into pages and reports what is visible on each. Try changing the specifications.

JS Expand overlays into pages

Press Run (or Ctrl + Enter) to see the console output here.

No output.

Themes

A Beamer theme has four parts, which you can mix:

LATEX
\usetheme{Madrid}          % overall layout: Berlin, Boadilla, CambridgeUS, Copenhagen, Frankfurt, metropolis ...
\usecolortheme{beaver}     % colours: default, beaver, dolphin, seahorse, whale, crane ...
\usefonttheme{professionalfonts}  % or serif, structurebold
\useinnertheme{rectangles} % bullets and blocks: circles, rectangles, rounded
\useoutertheme{infolines}  % headers and footers

Popular simple themes:

  • default, Boadilla, Madrid - classic with footer information.
  • Copenhagen, Berlin - navigation bars.
  • metropolis - clean modern look (\usetheme{metropolis}; may need the mtheme package installed).
  • CambridgeUS, Warsaw - blocky structure.

Compare themes in the Beamer gallery in the Beamer theme matrix before you commit. A talk with a minimal theme usually looks better than one with heavy navigation bars.

Customising

LATEX
\definecolor{brand}{HTML}{1A73E8}
\setbeamercolor{structure}{fg=brand}                 % titles, bullets
\setbeamercolor{block title}{bg=brand, fg=white}
\setbeamercolor{alerted text}{fg=red!80!black}
\setbeamerfont{frametitle}{size=\Large, series=\bfseries}
\setbeamertemplate{itemize items}[circle]            % bullet style
\setbeamertemplate{navigation symbols}{}             % hide icons
\setbeamertemplate{footline}[frame number]
\setbeamertemplate{background canvas}[vertical shading][bottom=white, top=brand!10]

For a logo on every slide: \logo{\includegraphics[height=0.8cm]{logo.pdf}}. For a custom title slide, redefine \setbeamertemplate{title page}.

Animation beyond \pause

  • Animated graphics: the animate package embeds frame sequences (works in Adobe Reader and some viewers).
  • TikZ steps: add overlay specs to TikZ commands: \draw<2->[red] (0,0) -- (3,2); and \node<3>{Result}; for diagram build-ups.
  • Transitions: \transfade, \transwipe, \transsplit apply between pages in viewers that support them.
  • Videos: the media9 or multimedia packages embed video, although support depends on the PDF viewer; a link to the file is safer.

Section dividers and navigation

LATEX
\AtBeginSection[]{
  \begin{frame}{Outline}
    \tableofcontents[currentsection, hideallsubsections]
  \end{frame}
}

This inserts an outline frame at each section start, highlighting the current one, which is a polite signpost in long talks.

Handout and slide variants from one source

Use a class option switch:

LATEX
\documentclass[handout]{beamer}   % one page per frame, overlays flattened

or conditional content with \mode<presentation>{...} and \mode<handout>{...}. Prepare notes with \note.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. Which command hides the following content until the next click?

    \pause splits the frame into pages and reveals the following content one step later.
  2. 2. What is the difference between \only<2>{X} and \uncover<2>{X}?

    With \only the layout can shift between steps, \uncover keeps the space so nothing jumps.
  3. 3. What does \item<2-> mean?

    The trailing dash means from that step to the end.
  4. 4. How do you remove the navigation icons at the bottom right?

    Setting the navigation symbols template to empty removes them.

Summary

  • \pause and [<+->] give simple step-by-step reveals; overlay specs such as <2-> give exact control.
  • \only, \uncover, \visible and \onslide differ in space handling.
  • Choose among outer, inner, colour and font themes; \setbeamercolor, \setbeamerfont and \setbeamertemplate customise them.
  • TikZ and section dividers add structure; handout mode flattens overlays.

Next: Engines, latexmk and Errors