Here a simple solution:
\documentclass{beamer}
\setbeamercovered{transparent}
\begin{document}
\begin{frame}
\begin{itemize}[<+-+>]
\item item-1
\item item-2
\item item-3
\end{itemize}
\end{frame}
\end{document}
You can use the optional argument of the itemize
environment which is defined by beamer
itself.
I don't really understand exactly what you are trying to do, but the basic idea is to arrange your items as you'd like them if everything were shown. So if a
is a sub-item of b
, it needs to be an \item
in a list nested as part of the specification of b
e.g. a nested list, if b
is itself an \item
. Once you have that, add the overlay specifications you need. If you want alerted text separate from overlays, use \alert{}
as you have been. Otherwise, you can add it to the \item
overlay specification.
Since you want something pretty bespoke, just specify the slide numbers for each \item
. I wouldn't bother trying to define a default for the list in this kind of case, or try to use relative overlay specifications. It will just be too confusing, I think. If you stick to the numbers, it should be relatively straightforward, if a bit fiddly, to get the result you want.
This is an example. Since I don't completely understand your question and have no idea what to do with the fourth item and its sub-items, it will surely need modification. However, hopefully, it should be pretty straightforward to do that, even if you need a bit of trial-and-error.
\documentclass{beamer}
\begin{document}
\begin{frame}{Test}
Animation with beamer: learn
\begin{itemize}
\item<2,5-> \alert<5,8>{First item}% show on slide 2 and 5 onwards, alert only on 5 and 8
\begin{itemize}% these are sub-items - need a nested list
\item<6-| alert@6> sub-first item% show on slide 6 and later, alert on 6 only
\item<6-| alert@6> sub-second item
\end{itemize}
\item<4> Extra item% only on slide 4, never alert
\item<3,5-> \alert<5,8>{Second item}% show on slide 3 and 5 onwards, alert only on 5 and 8
\begin{itemize}% these are sub-items - need a nested list
\item<7-| alert@7> sub-first item% show on slide 7 and later, alert on 7 only
\item<7-| alert@7> sub-second item
\end{itemize}
\onslide<9->% no idea what to do here - let's just put it on the next slide with everything bar the extra item
\item \alert{Fourth item}
\begin{itemize}% sub-items follow parent by default, so this is all on slide 9 onwards (which is just slide 9 in this case)
\item sub-first item
\item sub-second item
\end{itemize}
\end{itemize}
\end{frame}
\end{document}
Best Answer
If you just want to sequentially list all items in the list (including subitems), you don't have to manually specify each item. You can use the default overlay specification for the environment:
Here is an example:
The
<default overlay specification>
is inherited by subenvironments. See thebeamer
documentation (section 12.1 Itemizations, Enumerations, and Description, p 111).