5

I want an enumeration list. The list should however be fixed at its position. Furthermore at all time only 1 item should shown. So what I want is sort of this

\documentclass{beamer}
\begin{document}
\begin{frame}{Test}
\only<1>{%
  \begin{enumerate}
    \item[1.]<1> Item 1
   \end{enumerate}
}
\only<2>{%
  \begin{enumerate}
    \item[2.]<2> Item 2
  \end{enumerate}
}
\only<3>{%
  \begin{enumerate}
    \item[3.]<3> Item 3
  \end{enumerate}
}
\end{frame}
\end{document}

Can this be achieved in an easy manner? For example, is there an option? Such that you could just use

\documentclass{beamer}
\begin{document}
\begin{frame}{Test}
\begin{enumerate}
\item<1> Item 1
\item<2> Item 2
\item<3> Item 3
\end{frame}
\end{document}
8

An easier way would be to use

enter image description here

\documentclass{beamer}
\usepackage{lmodern}% http://tex.stackexchange.com/q/58087/5764
\begin{document}
\begin{frame}{Test}
  \begin{enumerate}
    \only<1>{\item[1.] Item 1}
    \only<2>{\item[2.] Item 2}
    \only<3>{\item[3.] Item 3}
  \end{enumerate}
\end{frame}
\end{document}
8

Buiding on Werner's answer, but without hard-coding the item numbers:

enter image description here

The code:

\documentclass{beamer}
\usepackage{etoolbox}

\makeatletter
\def\c@slideinframe{\beamer@slideinframe}
\def\beamerslideinframe{\beamer@slideinframe}
\makeatother
\def\AdvCnt{\setcounter{enumi}{\numexpr\arabic{slideinframe}-1\relax}}
\pretocmd{\item}{\AdvCnt}{}{}

\begin{document}
\begin{frame}{Test}
  \begin{enumerate}
    \only<+>{\item Item 1}
    \only<+>{\item Item 2}
    \only<+>{\item Item 3}
  \end{enumerate}
\end{frame}
\end{document}

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.