3

Suppose I have the following code:

\documentclass{beamer}

\usepackage[utf8]{inputenc}

%Information to be included in the title page:
\title{Sample title}
\author{Anonymous}
\institute{ShareLaTeX}
\date{2014}

\begin{document}
\frame{\titlepage}
\begin{frame}
\frametitle{Sample frame title}
\begin{itemize}
\item<1-> Hello
\item<2-> World
\item<3-> !
\end{itemize}
\pause
\begin{figure}
    \centering
    \includegraphics[scale=0.5]{smallcat.jpg}
    \caption{Smallcat}
    \label{fig:my_label}
\end{figure}

\end{frame}

\end{document}

The code is suppose to show: hello -> world -> exclamation mark, then show a picture of a small cat.

However, for reason unknown, the picture of the cat shows up on the second pause in the itemize block.

enter image description here

How do I make the cat show up after the exclamation mark?

CarLaTeX
  • 62,716
Norman
  • 527
  • 3
  • 13

1 Answers1

4

The \pause command works independently from the items, so it shows the figure starting from the second slide. To show it starting from the fourth one you could add another two \pauses. But I'd suggest to use something like \uncover to make the code more readable:

\documentclass{beamer}

\usepackage[utf8]{inputenc}

%Information to be included in the title page:
\title{Sample title}
\author{Anonymous}
\institute{ShareLaTeX}
\date{2014}

\begin{document}
\frame{\titlepage}
\begin{frame}
\frametitle{Sample frame title}
\begin{itemize}
\item<1-> Hello
\item<2-> World
\item<3-> !
\end{itemize}
\uncover<4->{%
\begin{figure}
    \centering
    \includegraphics[scale=0.5]{smallcat.jpg}
    \caption{Smallcat}
    \label{fig:my_label}
\end{figure}
}
\end{frame}

\end{document}