我在演示文稿中使用华沙主题,我想删除导航栏中与目录有关的项目符号。
例如,在动态模型部分中,前两个项目符号涉及我想要删除的部分和小节的目录(因为我有很多幻灯片,而且项目符号会粘在一起,所以我想减少项目符号的数量)
这是代码:
\documentclass[serif,12pt,aspectratio=169,compress,xcolor={dvipsnames}]{beamer}
\mode<presentation>
\usetheme{Warsaw}
\setbeamertemplate{navigation symbols}{}
\useoutertheme[subsection= false]{miniframes}
\AtBeginSection[ ]
{
\begin{frame}[plain]{Outline}
\tableofcontents[currentsection,hideallsubsections]
\addtocounter{framenumber}{-1}
\end{frame}
}
\AtBeginSubsection[ ]
{
\begin{frame}[plain]{Outline}
\tableofcontents[sectionstyle=show/hide,subsectionstyle=show/shaded/hide,subsubsectionstyle=hide]%hideallsubsections]
\addtocounter{framenumber}{-1}
\end{frame}
}
\AtBeginSubsubsection[ ]
{
\begin{frame}[plain]{Outline}
\usebeamercolor{subsection in toc shaded}%
\tableofcontents[sectionstyle=show/hide%
,subsectionstyle=show/shaded/hide,subsubsectionstyle=show/shaded/hide]
\addtocounter{framenumber}{-1}
\end{frame}
}
\begin{document}
\section{Dynamic Model}
\subsection{Assumptions}
\begin{frame}
\end{frame}
\subsection{Coordinate systems}
\begin{frame}
\end{frame}
\end{document}
请问我该如何修复它
答案1
您可以暂时关闭迷你框架,如下所示:
\documentclass[12pt,aspectratio=169,compress,xcolor={dvipsnames}]{beamer}
\mode<presentation>
\usefonttheme{serif}
\usetheme{Warsaw}
\setbeamertemplate{navigation symbols}{}
\useoutertheme[subsection= false]{miniframes}
\makeatletter
\let\beamer@writeslidentry@miniframeson=\beamer@writeslidentry%
\def\beamer@writeslidentry@miniframesoff{%
\expandafter\beamer@ifempty\expandafter{\beamer@framestartpage}{}% does not happen normally
{%else
% removed \addtocontents commands
\clearpage\beamer@notesactions%
}
}
\newcommand*{\miniframeson}{\let\beamer@writeslidentry=\beamer@writeslidentry@miniframeson}
\newcommand*{\miniframesoff}{\let\beamer@writeslidentry=\beamer@writeslidentry@miniframesoff}
\makeatother
\AtBeginSection[ ]
{
\miniframesoff
\begin{frame}[plain]{Outline}
\tableofcontents[currentsection,hideallsubsections]
\addtocounter{framenumber}{-1}
\end{frame}
\miniframeson
}
\AtBeginSubsection[ ]
{
\miniframesoff
\begin{frame}[plain]{Outline}
\tableofcontents[sectionstyle=show/hide,subsectionstyle=show/shaded/hide,subsubsectionstyle=hide]%hideallsubsections]
\addtocounter{framenumber}{-1}
\end{frame}
\miniframeson
}
\AtBeginSubsubsection[ ]
{
\miniframesoff
\begin{frame}[plain]{Outline}
\usebeamercolor{subsection in toc shaded}%
\tableofcontents[sectionstyle=show/hide%
,subsectionstyle=show/shaded/hide,subsubsectionstyle=show/shaded/hide]
\addtocounter{framenumber}{-1}
\end{frame}
\miniframeson
}
\begin{document}
\section{Dynamic Model}
\subsection{Assumptions}
\begin{frame}
one frame
\end{frame}
\subsection{Coordinate systems}
\begin{frame}
another frame
\end{frame}
\end{document}
(请注意,serif
类选项已过时,您应该使用\usefonttheme{serif}
它来代替)