1

I've been using the [pausesection] option on my table of contents and that is working well. However I'd like to be able to print, on the same page different images syncronized with the table of contents pauses on the other side of the slide.

I don't want to have the images start once the toc has finished, but right when the subsection shows

Minimum working example:

\documentclass[30pt]{beamer}

\setbeamertemplate{navigation symbols}{}
\usetheme{Luebeck}
\useoutertheme{miniframes}
\AtBeginSection[]{\subsection{}}

\begin{document}

\begin{frame}
\frametitle{Index}
\begin{columns}
\column{0.50\textwidth}
\tableofcontents[pausesections]
\column{0.50\textwidth}
space for sync images
\end{columns}
\end{frame}

\section{test1}
\subsection{test11}
\frame{}

\section{test2}
\subsection{test21}
\frame

\end{document}

On the right column I want to print images with respect to the different sections

1 Answer 1

0

No idea how this could be done automatically, would require a bit of patching of beamer's internals. The following does it manually, using minipages, which is not adviced by beamer, but for some reasons we have to use \only before \tableofcontents, or else the \only macros for the images wouldn't work correctly.

\documentclass[30pt]{beamer}

\setbeamertemplate{navigation symbols}{}
\usetheme{Luebeck}
\useoutertheme{miniframes}
\AtBeginSection[]{\subsection{}}

\usepackage{duckuments} % only to get random duck images for example-image-duck

\makeatletter
\newcounter{tocimage}
\newcommand*\tocimage[2][]
  {%
    \only<+>
      {%
        \if\relax\detokenize{#2}\relax
        \else
          \begingroup
            \includegraphics[{#1}]{#2}%
          \endgroup
        \fi
      }%
  }
\makeatother

\begin{document}

\begin{frame}
\frametitle{Index}
  \leavevmode
  \rlap
    {%
      \hskip.5\textwidth
      \begin{minipage}[c]{.5\textwidth}
        \tocimage[width=\linewidth]{example-image-duck}%
        \tocimage{}% no image for section 2
        \tocimage[width=\linewidth]{example-image-duck}%
      \end{minipage}%
    }%
  \begin{minipage}[c]{.5\textwidth}
    \tableofcontents[pausesections]
  \end{minipage}%
\end{frame}

\section{test1}
\subsection{test11}
\frame{}

\section{test2}
\subsection{test21}
\frame

\section{test3}
\subsection{test31}
\frame

\end{document}
4
  • I was afraid it was quite difficult to achieve, anyhow I have only a few subsections ad sections, I believe I'll go and do it manually :( Thank you for your kind reply!
    – suxdavide
    Commented Oct 6, 2019 at 8:01
  • Could you elaborate more on the fact beamer doen't like minipages? I've been using them quite a lot
    – suxdavide
    Commented Oct 6, 2019 at 8:02
  • 1
    @suxdavide well that was formulated a bit of unlucky. beamer doesn't dislike minipages per se, but it does advocate for using its own columns mechanism like you did in your MWE to separate contents into columns, which I didn't use and instead built manually with minipages.
    – Skillmon
    Commented Oct 6, 2019 at 8:10
  • Thank you for your quick reply!
    – suxdavide
    Commented Oct 6, 2019 at 8:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .