[Tex/LaTex] Show a frame step by step

beameroverlays

I have seen people showing one slide progressively by pressing Enter. Could anyone tell me how to realize that in Beamer?

Best Answer

beamer provides \pause that provides this functionality. You can add that anywhere in the slide and it will "pause" the output there, produce an additional slide for post-pause display.

Additionally, many commands typical to LaTeX have been modified in beamer to provide a so-called overlay specification. As an example, the following list show each item only on the specified slides:

\begin{enumerate}
  \item<1-> First item
  \item<2> Second item
  \item<3> Last item
\end{enumerate}

Here, the overlay specification is contained within < >. Slide 1 will contain only the "First item". Slide 2 will contain "First item" and "Second item". Slide 3 will contain "First item" and "Last item". This example, taken from the front page of the package documentation provides another view on overlay specifications:

\begin{frame}
  \frametitle{There Is No Largest Prime Number}
  \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-> Thus $q+1$ is also prime and greater than $p$.\qedhere
    \end{enumerate}
  \end{proof}
\end{frame}

The display depends on the theme used. Below is the first slide of the above frame code from two different themes (left: default; right Frankfurt):

Same frame, different themes in beamer

There are many slide overlay specifications possible. Review the package documentation to see the format provided with each command/environment.