A simple solution could be
\documentclass{beamer}
\begin{document}
\frame{\frametitle{testing cols}
\begin{columns}[t]
\column{.4\textwidth}
\begin{itemize}[<+->]
\item On the next column you see a pic
\item Pic is getting bigger!
\item And it got even more big!
\end{itemize}
\column[T]{.6\textwidth}
\only<1>{\rule{100pt}{100pt}}
\only<2>{\rule{150pt}{150pt}}
\only<3>{\rule{200pt}{200pt}}
\end{columns}
}
\end{document}
With the optinal itemize
parameter <+->
you can uncover the items one after another. I did not have you pictures so I had to work with \only<>{}
and \rule{x width}{y width}
you can just continue using \includegraphics<1>...
.
By following the method shown in Background coloring with overlay specification in algorithm2e + beamer package, it is possible to build this MWE:
\documentclass{beamer}
\usepackage{amsmath,amssymb}
\usepackage{tikz}
\usetikzlibrary{fit,calc}
\newcommand{\tikzmark}[1]{%
\tikz[overlay,remember picture,baseline] \node [anchor=base] (#1) {};}
\definecolor{mybrown}{RGB}{255,218,195}
\definecolor{myframe}{RGB}{197,122,195}
\usetheme{Copenhagen}
\begin{document}
\section{Mysection}
\subsection{A subsection}
\begin{frame}{The equations}
\begin{block}{}
\begin{align}
\tikzmark{a}a_i\tikzmark{b} + b_j = 10 & \forall i\in I, j\in J \\
\tikzmark{e}c_j + d_j + \tikzmark{c}a_i\tikzmark{d} >= 30 & \forall i\in I, j\in J\tikzmark{f}
\end{align}
\begin{tikzpicture}[remember picture,overlay]
\coordinate (aa) at ($(a)+(0,0.25)$);
\coordinate (bb) at ($(b)+(0,0)$);
\node<1>[draw=myframe,line width=1pt,fill=mybrown,opacity=0.4,rectangle,rounded corners,fit=(aa) (bb)] {};
\coordinate (cc) at ($(c)+(0,0.25)$);
\coordinate (dd) at ($(d)+(0,0)$);
\node<1>[draw=myframe,line width=1pt,fill=mybrown,opacity=0.4,rectangle,rounded corners,fit=(cc) (dd)] {};
\coordinate (ee) at ($(e)+(0,0.25)$);
\coordinate (ff) at ($(f)+(0,-0.25)$);
\node<2>[draw=myframe,line width=1pt,fill=mybrown,opacity=0.4,rectangle,rounded corners,fit=(ee) (ff)] {};
\end{tikzpicture}
\end{block}
\end{frame}
\end{document}
that allows to get those two frames:
Thus you can select the zone you want to highlight thanks to \tikzmark
, an entire equation or just a part displaying it as "alert"
.
A TikZ-free solution
\documentclass{beamer}
\usepackage{amsmath,amssymb}
\usepackage{xparse}
\usepackage{xcolor}
% Code by Gonzalo Medina
% https://tex.stackexchange.com/questions/35319/a-boxed-alternative-with-minimal-spacing/35346#35346
\newbox\FBox
\NewDocumentCommand\Highlight{O{black}O{white}mO{0.5pt}O{0pt}O{0pt}}{%
\setlength\fboxsep{#4}\sbox\FBox{\fcolorbox{#1}{#2}{#3\rule[-#5]{0pt}{#6}}}\usebox\FBox}
\usetheme{Copenhagen}
\begin{document}
\begin{frame}{The equations}
\only<1>{
\begin{align}
&\Highlight[blue][blue!20]{$a_i$}[3pt] + b_j = 10 \qquad\forall i\in I, j\in J \\
&c_j + d_j +\Highlight[blue][blue!20]{$a_i$}[3pt] >= 30 \qquad \forall i\in I, j\in J
\end{align}
}
\only<2>{
\begin{align}
&a_i + b_j = 10 \qquad \forall i\in I, j\in J \\
&\Highlight[orange][orange!20]{$c_j + d_j +a_i >= 30 \qquad\forall i\in I, j\in J$}[3pt]
\end{align}
}
\end{frame}
\end{document}
Beware that with the latter method, one can not place tabs (with &
) inside the \Highlight
command.
Solution with the hf-tikz
package
\documentclass{beamer}
\usepackage{lmodern,amsmath,amssymb}
\usepackage[beamer]{hf-tikz}
\usetheme{Copenhagen}
\begin{document}
\section{Mysection}
\subsection{A subsection}
\begin{frame}{The equations}
\begin{block}{}
\begin{align}
\tikzmarkin<1>{a}a_i\tikzmarkend{a} + b_j = 10 & \forall i\in I, j\in J \\
\tikzmarkin<2>{c}c_j + d_j + \tikzmarkin<1>{b}a_i\tikzmarkend{b} >= 30 & \forall i\in I, j\in J\tikzmarkend{c}
\end{align}
\end{block}
\end{frame}
\end{document}
Notice that it also avoids the so called "jumping effect" visible in the TikZ-free solution:
Best Answer
One option using the
alert@
specification for overlays to highlight text on desired slides; for example,shows the item text from the third slide on and highlights it on the third slide only. The color used to highlight the text can be changed using
The code:
An animation of the result: