1

I have some itemize items that I want to present sequentially. I also want to discuss each item, using for that subitems. The subitems should disappear after that item is discussed.

I can achieve this using \only commands for each batch of subitems, see the example below:

\documentclass{beamer}

\begin{document}
\begin{frame}[t]
    \begin{itemize}
        \item<1-> Item 1
        \only<2>{\begin{itemize}
            \item Subitem 1
            \item Subitem 2
        \end{itemize}}
        \item<3-> Item 2
        \only<4>{\begin{itemize}
            \item Subitem 1
            \item Subitem 2
        \end{itemize}}
        \item<5-> Item 3
        \only<6>{\begin{itemize}
            \item Subitem 1
            \item Subitem 2
        \end{itemize}}
    \end{itemize}
\end{frame}

I want the main Items (Item 1, Item 2, etc.) to have a fixed position, rather than shifting vertically as I transition from one slide to the other (this is the reason why I used the [t] specifier for the frame environment). However, whenever I transition into a slide that has a subitem (say, in slide 4), the vertical spacing between the main items gets messed up.

Is there a way of achieving what I want? I have tried using overlayarea and overprint for this, but I was not able to do it.

1 Answer 1

1
\documentclass{beamer}

\begin{document}
\begin{frame}[t]
    \begin{itemize}
        \item<1-> Item 1
        \begin{itemize}[<only@2>]
            \item Subitem 1
            \item Subitem 2
        \end{itemize}
        \item<3-> Item 2
        \begin{itemize}[<only@4>]
            \item Subitem 1
            \item Subitem 2
        \end{itemize}
        \item<5-> Item 3
        \begin{itemize}[<only@6>]
            \item Subitem 1
            \item Subitem 2
        \end{itemize}
    \end{itemize}
\end{frame}
\end{document}

enter image description here

3
  • I would like the main items to be right below one another, as they are in my example. In your solution, there are blank vertical spaces where the subitems were Commented Apr 15 at 19:01
  • @GuilhermeFraga Is this what you are looking for? Commented Apr 15 at 19:13
  • Yes, exactly this. I wonder why it works like this, but it does not if I enclose the itemize environment with \only<>, as I tried in my example. Anyway, thanks! Commented Apr 16 at 9:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .