感谢 samcarter 的回复这里我可以在每个部分的开头显示目录,突出显示当前部分及其子部分。
\documentclass[hyperref={pdfpagelabels=false}]{beamer}
\usepackage{lmodern}
\usetheme{Antibes}
\title{Beamer Class Usetheme Antibes}
\author{Sascha Frank}
\date{\today}
\AtBeginSection{%
\begin{frame}
\tableofcontents[currentsection, subsectionstyle=show/show/hide]
\end{frame}
}
\begin{document}
%\logo{\includegraphics[scale=0.14]{logo-SF}}
\begin{frame}
\titlepage
\end{frame}
\begin{frame}
\frametitle{Table of contents}
\tableofcontents[hidesubsections]
\end{frame}
\section{Section no.1}
\begin{frame}
\frametitle{frame title}
Each frame should have a title.
\end{frame}
\subsection{Subsection no.1.1 }
\begin{frame}
Without title somethink is missing.
\end{frame}
\section{Section no. 2}
\subsection{Lists I}
\begin{frame}
\frametitle{unnumbered lists}
\begin{itemize}
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{itemize}
\end{frame}
\begin{frame}\frametitle{lists with single pauses}
\begin{itemize}
\item Introduction to \LaTeX{} \pause
\item Course 2 \pause
\item Termpapers and presentations with \LaTeX{} \pause
\item Beamer class
\end{itemize}
\end{frame}
\begin{frame}\frametitle{lists with pause}
\begin{itemize}[<+->]
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{itemize}
\end{frame}
\subsection{Lists II}
\begin{frame}\frametitle{numbered lists}
\begin{enumerate}
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{enumerate}
\end{frame}
\begin{frame}
\frametitle{numbered lists with single pauses}
\begin{enumerate}
\item Introduction to \LaTeX{} \pause
\item Course 2 \pause
\item Termpapers and presentations with \LaTeX{} \pause
\item Beamer class
\end{enumerate}
\end{frame}
\begin{frame}
\frametitle{numbered lists with pause}
\begin{enumerate}[<+->]
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{enumerate}
\end{frame}
\end{document}
我现在想在此 MWE 末尾添加另一个部分,但这次 TOC 不会出现在本节的开头。
\section*{Remerciements}
\begin{frame}
\begin{block}{JE VOUS REMERCIE DE VOTRE ATTENTION.}
\end{block}
\end{frame}
创建一个不出现在目录中的部分,但目录出现在此部分的开头,其余部分未突出显示。我想避免这个额外的框架。
答案1
您可以添加一个布尔变量来切换附加的 toc-frame:
\documentclass[hyperref={pdfpagelabels=false}]{beamer}
\usepackage{lmodern}
\usetheme{Antibes}
\title{Beamer Class Usetheme Antibes}
\author{Sascha Frank}
\date{\today}
\newif\ifshowtoc
\showtoctrue% toggles to show the toc
\AtBeginSection{%
\ifshowtoc
\begin{frame}
\tableofcontents[currentsection, subsectionstyle=show/show/hide]
\end{frame}
\fi
}
\begin{document}
%\logo{\includegraphics[scale=0.14]{logo-SF}}
\begin{frame}
\titlepage
\end{frame}
\begin{frame}
\frametitle{Table of contents}
\tableofcontents[hidesubsections]
\end{frame}
\section{Section no.1}
\begin{frame}
\frametitle{frame title}
Each frame should have a title.
\end{frame}
\subsection{Subsection no.1.1 }
\begin{frame}
Without title somethink is missing.
\end{frame}
\section{Section no. 2}
\subsection{Lists I}
\begin{frame}
\frametitle{unnumbered lists}
\begin{itemize}
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{itemize}
\end{frame}
\begin{frame}\frametitle{lists with single pauses}
\begin{itemize}
\item Introduction to \LaTeX{} \pause
\item Course 2 \pause
\item Termpapers and presentations with \LaTeX{} \pause
\item Beamer class
\end{itemize}
\end{frame}
\begin{frame}\frametitle{lists with pause}
\begin{itemize}[<+->]
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{itemize}
\end{frame}
\subsection{Lists II}
\begin{frame}\frametitle{numbered lists}
\begin{enumerate}
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{enumerate}
\end{frame}
\begin{frame}
\frametitle{numbered lists with single pauses}
\begin{enumerate}
\item Introduction to \LaTeX{} \pause
\item Course 2 \pause
\item Termpapers and presentations with \LaTeX{} \pause
\item Beamer class
\end{enumerate}
\end{frame}
\begin{frame}
\frametitle{numbered lists with pause}
\begin{enumerate}[<+->]
\item Introduction to \LaTeX{}
\item Course 2
\item Termpapers and presentations with \LaTeX{}
\item Beamer class
\end{enumerate}
\end{frame}
\showtocfalse% toggles to not show the toc
\section*{Remerciements}
\begin{frame}
\begin{block}{JE VOUS REMERCIE DE VOTRE ATTENTION.}
\end{block}
\end{frame}
\end{document}
答案2
\AtBeginSection
可以选择单独指定带星号部分的行为:
\AtBeginSection[<starred section>]{<normal section>}
因此,如果您不想对带星号的部分执行任何操作,则可以使用:
\AtBeginSection[]{%
\begin{frame}
\tableofcontents[currentsection, subsectionstyle=show/show/hide]
\end{frame}
}