0

I have three parts in my beamer presentation. Each part has its own table of contents (see below). Currently, the numbering of each section is connected i.e. while the sections in the TOC of part 1 are 1, 2, 3 etc. the numbering in part 3 continues with the numbering of the previous part e.g. 6, 7, 8 etc.

How can I change the code such that the numbering in each section's TOC always start from 1?

\documentclass{Bredelebeamer}
\usepackage[english]{babel}
\setbeamertemplate{caption}{\raggedright\insertcaption\par}

\begin{document}

\part{part 1}

\begin{frame} \partpage \end{frame}

\section[Intro]{Intro} \begin{frame}{Outline} \tableofcontents[currentsection] \end{frame}

\begin{frame}{frame1} xxx \end{frame}

\section[Main]{Main} \begin{frame}{Outline} \tableofcontents[currentsection] \end{frame}

\begin{frame}{frame2} xxx \end{frame}

\part{part 2}

\begin{frame} \partpage \end{frame}

\section[Intro]{Intro2} \begin{frame}{Outline} \tableofcontents[currentsection] \end{frame}

\begin{frame}{frame3} xxx \end{frame}

\section[Main]{Main2} \begin{frame}{Outline} \tableofcontents[currentsection] \end{frame}

\begin{frame}{frame4} xxx \end{frame}

\end{document}

Neicooo
  • 33
  • 3
  • Can you please complete your code fragment so that it is self contained, i. e. compilable without modifications? – Dr. Manuel Kuehner Apr 13 '22 at 15:57
  • 1
    Please also test your code before posting. You have part{Part3} without the backslash, \end{footnotesize} in two places but no corresponding \begins, and no beamer theme specified (without which there aren't even any numbers for sections in tocs at all). – frabjous Apr 13 '22 at 17:39
  • Thanks, I added a MWE. Basically, the issue is that the numbering in the TOC in part 2 continues, as opposed to starting from 1 again. – Neicooo Apr 13 '22 at 17:50
  • 1
    Looks like this is more or less a duplicate of this question. I think \makeatletter\AtBeginPart{\beamer@tocsectionnumber=0\relax\setcounter{section}{0}}\makeatother in the preamble will work. – frabjous Apr 13 '22 at 19:30

0 Answers0