3

Consider this minimal example:

\documentclass[aspectratio=169, 16pt]{beamer}
\usetheme[titleformat=smallcaps]{metropolis} % Usemetropolistheme

\usepackage[english]{babel}

\begin{document}
\begin{frame}[standout]
\only<+>{H}
\only<+>{He}
\only<+>{Hel}
\only<+>{Hell}
\only<+>{Hello}
\only<+>{Hello w}
\only<+>{Hello wo}
\only<+>{Hello wor}
\only<+>{Hello worl}
\only<+>{Hello world}
\only<+>{Hello world!}
\end{frame}
\end{document}

Basically, it's animated text using beamer's overlay. However, as far as I know, I have to manually go to the next slide to make it works. There is a way to temporize the process? I know that a solution could be to export the image, make a gif and use the animate package. However there are two downsides in this solution: gifs are not vectorial, I have to make a new gif each time I change something in the layout (like fonts or anything like that).

Note It's not mandatory to use beamer overlays. However, the solution must work with beamer class and xelatex compiler.

3

You can specify the time each overlay should be shown with \transduration{<time in seconds>}:

\documentclass[aspectratio=169, 16pt]{beamer}
\usetheme[titleformat=smallcaps]{metropolis} % Usemetropolistheme

\usepackage[english]{babel}

\begin{document}
\begin{frame}[standout]
\transduration{0.1}
\only<+>{H}
\only<+>{He}
\only<+>{Hel}
\only<+>{Hell}
\only<+>{Hello}
\only<+>{Hello w}
\only<+>{Hello wo}
\only<+>{Hello wor}
\only<+>{Hello worl}
\only<+>{Hello world}
\only<+>{Hello world!}
\end{frame}
\end{document}

enter image description here

Note: the automatic slide transitions only work with pdf viewers that support java script and they need to be in presentation mode.

  • It works. and the result is the same as using \animate<>. However, with both of them slides changes each second. There is a problem in my pdf viewer? – gvgramazio Dec 9 '18 at 21:50
  • @gvgramazio Which pdfviewer do you use? With the example above they should change ten times a second. (if the slides are complex and/or the computer is slow, rendering can take longer) – user36296 Dec 9 '18 at 21:52
  • The default document viewer of Ubuntu 18.04: Evince 3.28.4 – gvgramazio Dec 9 '18 at 21:56
  • 1
    I confirm that the problem doesn't exist with okular. – gvgramazio Dec 9 '18 at 22:20
  • 1
    @gvgramazio If you are really desperate, produce an animated gif as in this answer or an mp4 as in this answer, and embed them. Needless to say that will reduce the quality, and whether there is a way to synchronize the resolution with the one of the projector I don't know. – marmot Dec 9 '18 at 22:33
1

Just to clear up the misunderstanding that an animate-based solution would require a pre-fabricated set of bitmapped (gif, png, whatever) animation frames. Of course Acrobat Reader is still required, but on Linux, AR-DC runs fairly well using Wine.

\documentclass[aspectratio=169,16pt]{beamer}
\usetheme[titleformat=smallcaps]{metropolis} % Use metropolis theme

\usepackage{animate}
\usepackage[english]{babel}

\begin{document}
\begin{frame}[standout]

  \begin{animateinline}[autoplay,loop]{2}
    \makebox[\widthof{\strut Hello world!}][l]{\strut} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut H} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut He} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hel} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hell} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello w} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello wo} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello wor} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello worl} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello world} \newframe  
    \makebox[\widthof{\strut Hello world!}][l]{\strut Hello world!}
  \end{animateinline}

\end{frame}
\end{document}

Click on the image to see the animated version (vectorial [SVG]):

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.