The problem is as follows:
On a slide, I have several figures. I would like to zoom into whole figures or parts of them susequently. I tried to do so using tikz
spy
library with the spy using overlays
-option for the tikzpicture. In principle, this works. The desired area of the figure is zoomed to the desired position on the slide, only it is drawn beneath the other content of the frame, meaning in the background. How can I get the zoomed content to the front? The following MWE illustrates the problem (graphics are included in the mwe
-package).
\documentclass[]{beamer}
\usepackage{mwe}
\usepackage{tikz}
\usetikzlibrary{spy}
\begin{document}
\begin{frame}
\begin{minipage}[l]{0.6\textwidth}
\centering
\begin{tikzpicture}[
spy using overlays
]
\node[inner sep=0pt]{\pgfimage[width=0.98\textwidth]{example-image-16x10}};
\only<2>{\spy[overlay,width=7cm,height=2cm,magnification=2] on (0,0) in node[] at (2,-3);}
\end{tikzpicture}
some description
\includegraphics[width=0.98\textwidth]{example-image-16x10}
some description
\end{minipage}%
\hfill%
\begin{minipage}[r]{0.35\textwidth}
\centering
\includegraphics[width=0.98\textwidth]{example-image-10x16}
some description
\end{minipage}%
\end{frame}
\end{document}
Best Answer
For example, you could do something like this (needs a bit of polishing but I'm assuming these are not your actual images anyway):