3

I have a slide with three blocks, say 1, 2, 3a, and 3b, where 3a and 3b have exactly the same height (they are the same equation with some change of variable). I want to use \pause and \only to obtain the following:

  • only 1
  • (click) -> only 1 and 2
  • (click) -> 1, 2, and 3a
  • (click) -> 1, 2, and 3b

while maintaining the exact same positioning of each block as in the last two slides. Here is my tentative example: what happens is that Block 1 and Block 2 appear in the center of the slide as no third block is going to appear.

\begin{frame}[c]{Title}
    Block 1
        \pause
    Block 2
        \pause
    \only<3>{
        Block 3a
    }
    \only<4>{
        Block 3b
    }
\end{frame}
Stefan Pinnow
  • 29,535
TheDon
  • 755

2 Answers2

2

The overlayarea-environment might do the trick

\documentclass{beamer}

\begin{document}
\begin{frame}

    \onslide<1->{1}

    \onslide<2->{2}

    \begin{overlayarea}{\textwidth}{0.2\textheight}

        \only<3>{3a} 

        \only<4>{3b}

    \end{overlayarea}


\end{frame}
\end{document}
1

use

\only<3>{Block 3a}% no following empty line!  
\onslide<4>{Block 3b}

instead of \only. Then the vertical space of the invisible overlays is taken into account. An alternative is

Block 2 \pause

Block 3\only<3>{a}\only<4>{b}