# Beamer automatic ordering of overlays

I would like to order automatically some alerts (or other things) in some uncoverenv's. uncoverenv's should be continuously added but alerts should be just on the numbered slide. A minimal example is below. How to get the same result without manual numbering?

\documentclass{beamer}

\begin{document}
\begin{frame}{Frame}
First

\begin{uncoverenv}<4->
Second

\end{uncoverenv}

\begin{uncoverenv}<7->
Third

\end{uncoverenv}

\end{frame}

\end{document}

• Welcome to TeX.SX! What do you mean with order automatically? Something like the + overlay specification (instead of the number)? Oct 12 '17 at 11:56

Like this?

\documentclass{beamer}

\begin{document}
\begin{frame}{Frame}
First

\begin{uncoverenv}<+(1)->
Second

\end{uncoverenv}

\begin{uncoverenv}<+(1)->
Third

\end{uncoverenv}

\end{frame}

\end{document}

• Do you need the (1)? I always thought + would suffice. Oct 12 '17 at 12:05
• @TeXnician That's what I tried first :) Oct 12 '17 at 12:09
• I also tried this for nested overlays. But I could not make it. For example \uncover<+(1)>{U1\alert<+(1)>{U1}} did not worked. Any suggestion? Oct 12 '17 at 12:37
• @mert Should the same text be uncovered and alerted? Oct 12 '17 at 13:17
• No. It is just for an example. The point: first uncover complete sentence on a slide and alert part of the sentence on another slide. The overlays should be only on those two slides. The text should become normal after that. Oct 12 '17 at 13:21