beamer

beamer is the LaTeX document class for making presentation slides (as a PDF). You divide your source into units called frames, and each one becomes a slide. It comes with the polished themes familiar from academic talks, overlays that reveal a list one line at a time, side-by-side columns, and highlighted boxes — everything a presentation needs. This page walks through it from the first line to stepwise reveals.

Choosing the class — \documentclass{beamer}

A beamer document begins with \documentclass{beamer}. That single line turns each page into one screenful in landscape rather than a sheet of paper, and sets up presentation styling — headings, navigation, and colour — all at once. Instead of flowing chapters and sections like article, beamer lays content out one screen at a time.

Slides default to 4:3 (about 126 mm × 96 mm). To match a modern widescreen display, change the aspect ratio with a class option: \documentclass[aspectratio=169]{beamer} gives you 16:9. The values aspectratio accepts are 1610, 169, 149, 54, 43, and 32, standing for 16:10, 16:9, 14:9, 5:4, 4:3, and 3:2. You can also set the body font size, as in \documentclass[11pt]{beamer}; the default is 11pt.

The frame environment — one slide

The heart of beamer is the **frame environment**. Everything between \begin{frame} and \end{frame} is, in principle, one slide, and inside it you put your bullets, figures, and equations. Give the slide a heading with \frametitle{...}, or pass it as an argument to the environment: \begin{frame}{Title}.

latex
\begin{frame}{はじめに}
  \begin{itemize}
    \item 背景
    \item 目的
  \end{itemize}
\end{frame}

The key idea here is that **one frame is not necessarily one page**. With the overlays (stepwise reveals) we will see shortly, a single frame can produce several PDF pages, which play back like an animation. Even so, the unit stays “one frame = one logical screen,” counted by frame number rather than by page.

Title slide and table of contents

Title metadata is declared in the preamble, just as in article. Write \title{...}, \author{...}, \institute{...}, and \date{...}, then in the body place **\titlepage** inside one frame to typeset the title slide (\maketitle gives the same result). For talks, \date{\today} is a common way to fill in the date automatically.

For a longer talk, dividing the content with \section{...} feeds that structure into the navigation along the top of each slide. Once you have declared the divisions, placing \tableofcontents inside one frame produces a contents slide. Writing \tableofcontents[currentsection] highlights only the current section, and to insert such a frame automatically at the start of each section you use \AtBeginSection[]{...} in the preamble.

Themes — set the whole look at once

A big part of beamer’s appeal is that selecting a theme in a single line sets the colours, layout, and navigation for you. In the preamble you pick a presentation theme with, say, \usetheme{Madrid}. Besides Madrid, many themes exist — Berlin, Warsaw, Singapore, metropolis (needs a separate install), and more. To change just the palette, use \usecolortheme{...} (for example beaver, seahorse, dolphin); for typefaces, \usefonttheme{...} (for example serif, professionalfonts).

CommandWhat it setsExample
\usethemeOverall layout, navigation, and colours\usetheme{Madrid}
\usecolorthemeSwaps only the colour palette\usecolortheme{seahorse}
\usefontthemeTypeface for headings and body\usefonttheme{serif}
\useinnertheme / \useouterthemeInner (bullets, etc.) / outer (headline, etc.) styling\useoutertheme{infolines}

Overlays — reveal step by step

To reveal content gradually during a talk, you use overlays. The simplest is **\pause**: placed partway through a frame, everything after it is pushed onto the next slide (the next page). The single frame then expands into several PDF pages, which play back as a stepwise reveal.

latex
\begin{frame}{結果}
  \begin{itemize}
    \item 第一の点
    \pause
    \item 第二の点
    \pause
    \item 第三の点
  \end{itemize}
\end{frame}

For finer control, attach an overlay specification in angle brackets <...> right after a command. For instance \item<1-> means “shown from slide 1 onward,” \item<2> means “shown only on slide 2,” and \item<2-> means “from slide 2 on.” You can also write ranges and gaps, as in <-2,4-5,7>. The main commands for toggling visibility are these.

CommandBehaviourSpace it occupies
\pausePush what follows to the next slideRevealed content is added in turn
\onslide<2->{...}Show on the given slides, hide otherwiseAlways reserves the space (no shifting)
\uncover<2->{...}Uncover on the given slidesAlways reserves the space
\only<2>{...}Output only on the given slidesTakes no space (content reflows)
\alert<2>{...}Emphasise (alert colour) on the given slidesAlways visible; reserves space

\onslide and \uncover reserve space even while content is hidden, so the layout does not jump as items appear. \only, by contrast, inserts and removes the output itself, so the hidden space is reclaimed and the content reflows. As with \alert<2>{...}, you can attach overlay specs to \textbf or \textcolor too, to “emphasise only on a given slide.”

Blocks, columns, and fragile

To set content off in a framed box, use the **block environment**: \begin{block}{Title}…\end{block} gives a titled box styled to match the theme. There are also an attention-grabbing **alertblock and an exampleblock** for examples, while theorem and definition environments work directly for theorems and definitions.

To split a slide left and right, place **\column{width}** entries (or column environments) inside the **columns environment**. It is handy for putting a figure beside its explanation.

latex
\begin{frame}{比較}
  \begin{columns}
    \column{0.5\textwidth}
      左の内容
    \column{0.5\textwidth}
      右の内容
  \end{columns}
\end{frame}

One caution: when you use a verbatim environment or listings (to show source code) inside a frame, that frame needs the **[fragile] option** — write \begin{frame}[fragile]. beamer internally redefines the meaning of characters like < and > for overlays, which clashes with verbatim, where characters must be printed as-is. The [fragile] option switches to a special mode that writes the frame’s contents out to an external file and reads them back, so the two can coexist.

A minimal example

Here is the smallest beamer document that compiles, with a theme, a title slide, and a bulleted frame using \pause. The preamble declares the theme and title metadata; the body puts \titlepage in the first frame and a stepwise bulleted list in the next.

document.tex
\documentclass[aspectratio=169]{beamer}
\usetheme{Madrid}

\title{My Talk}
\author{Ada Lovelace}
\institute{Analytical Engine Lab}
\date{\today}

\begin{document}

\begin{frame}
  \titlepage
\end{frame}

\begin{frame}{Overview}
  \begin{itemize}
    \item Background
    \pause
    \item Method
    \pause
    \item Results
  \end{itemize}
\end{frame}

\end{document}

Compiling this first shows the Madrid title slide (title, author, institute, date); then on the “Overview” slide each item is added one at a time as you advance. There are two frames, but \pause expands the PDF into several pages. For Japanese slides, on LuaLaTeX you enable Japanese with something like luatexja and add the setup that matches your engine.