5

I have a frame with the two columns, one for an image, and one for itemized text. For example,

\frame{\frametitle{hello} 

\begin{columns}[onlytextwidth]
    \begin{column}{0.4\textwidth}
      \centering
      \includegraphics[width=40mm]{pic1.png}
    \end{column}

    \begin{column}{0.6\textwidth}
    \begin{itemize}
      \item statement 1
      \item statement 2
    \end{itemize}
    \end{itemize}
    \end{column}
​  \end{columns}


}

I want to specify an overlay, such that pic1 appears along with statement 1 and pic2 appears with statement 2. How do could I do this?

1
  • I think you can have a look to this question. The difference is that you should add an overlay to includegraphics. Jul 27, 2012 at 13:39

1 Answer 1

5

Using the fact that both \includegraphics and \item are overlay-aware, you can do somthing like this:

\documentclass{beamer}

\begin{document}

\frame{\frametitle{hello} 
\begin{columns}[onlytextwidth]
    \begin{column}{0.4\textwidth}
      \centering
      \includegraphics<1>[width=40mm]{cat}
      \includegraphics<2>[width=40mm]{ctanlion}
    \end{column}

    \begin{column}{0.6\textwidth}
    \begin{itemize}
      \item<1> statement 1
      \item<2> statement 2
    \end{itemize}
    \end{column}
​  \end{columns}
}
\end{document}

enter image description here

CTAN lion drawing by Duane Bibby.

2
  • Excellent minimum working example. All I had to do was save the cat and ctanlion as actual graphic files and it got me over the rut I was stuck in for minutes. Thanks Apr 24 at 19:24
  • Hey @Gonzalo, I am trying to do something similar where the text is already present and I am adding the picture in the \onslide<2-> {}. But this changes the vertical alignment of the text. I can share an MWE but I am not sure if a similar question exists. Can you point me in the right direction? May 30 at 18:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.