I am making some simple drawings with TikZ
, and would like to spread the drawings over several slides (ie. on each slide something additional is drawn on the frame). I have succeeded doing it with \pause
as I would normally do, and, when it doesn't work (when drawing on layers), I use the visible on=
drawing option which serves the purpose. My only issue is that page numbering is only rendered in the very last page of a given frame, that is, when the drawing is fully complete, just before I pass to the next frame. The paging is actually correct (in the sense that if, the previous frame ended on, say, page 8, and the frame has four steps, then the last slide correctly shows page 12; it's just that, in between, nothing is shown at all).
To do the paging, I have \setbeamertempate{footline}[page number]
at the top of my latex code.
Besides that, I also have this issue with footnotes, that is, if I have a \footnotetext{...}
at the end of my frame, it will only show in the very last slide of my frame, no matter what I tried with things like \pause[...]
or \onslide<...>{\footnotetext{...}}
.
Here is a minimal reproducible example:
\documentclass{beamer}
\usepackage{tikz}
\setbeamertemplate{footline}[page number]
\begin{document}
\begin{frame}
\begin{tikzpicture}
\draw (0,0) rectangle (1,1);
\pause
\draw (2,0) rectangle (3,1);
\end{tikzpicture}
\end{frame}
\end{document}
This will produce a pdf with two pages. The first page will have a single square, without any pagination. The second page will have two squares, with 2/2
written at the bottom right of the page.
\pause
. For example,\uncover
doesn't cause such problem:\documentclass{beamer} \setbeamertemplate{footline}[page number] \usepackage{tikz} \begin{document} \begin{frame} \begin{tikzpicture} \draw (0,0) rectangle (1,1); \uncover<2->{ \draw (2,0) rectangle (3,1); } \end{tikzpicture} \end{frame} \end{document}
works fine.\onslide<1->
last in yourtikzpicture
and it works with\pause
.