我正在尝试在我正在使用的主题上添加进度条,但非常不确定 sty 文件是如何工作的,所以我不知道在哪里调整。有人能帮我理解这个主题是如何工作的吗?
幻灯片 tex 文件:
\documentclass[
11pt,notheorems,hyperref={pdfauthor=whatever}
]{beamer}
\input{loadslides.tex} % Loads packages and some defined commands
加载幻灯片.tex:
\RequirePackage{palatino}
\RequirePackage[utf8]{inputenc}
\RequirePackage[T1]{fontenc}
\usefonttheme{serif}
\usepackage{styles/elegantmacros}
\usefolder{styles}
\usetheme[style=blue]{elegant}
\usepackage{subcaption}
外部主题 sty 文件\usepackage{styles/elegantmacros}
指的是
\mode<presentation>
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
% Set Margins around frame title
\setbeamertemplate{frametitle}{\vspace{1cm} \color{primary}\insertframetitle \par\vskip1pt \color{secondary}{\small\insertframesubtitle} \vspace*{0.5cm}}
% Automatic Frame Titles
\makeatletter
\CheckCommand*\beamer@checkframetitle{%
\@ifnextchar\bgroup\beamer@inlineframetitle{}}
\renewcommand*\beamer@checkframetitle{%
\global\let\beamer@frametitle\relax\@ifnextchar%
\bgroup\beamer@inlineframetitle{}}
\makeatother
\addtobeamertemplate{frametitle}{
\ifx\insertframetitle\empty
\ifx\insertframesubtitle\empty
\ifx\insertsubsection\empty
\frametitle{\insertsectionhead}
\else
\frametitle{\insertsectionhead}\framesubtitle{\insertsubsectionhead}
\fi
\else
\frametitle{\insertsectionhead} %If frame title is empty but subtitle is specified by user, insert section as frametitle
\fi
\else
\fi
}{}
%\setbeamertemplate{framesubtitle}{\color{primary}\insertframesubtitle\par\vskip6pt \vspace*{0.5cm}}
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
% Footer
% Set Margins around footer
\setbeamertemplate{footline}{
\hspace*{10mm}
{\scshape \insertshortauthor \hfill \insertshorttitle \hfill \insertframenumber{} / \inserttotalframenumber}
\hspace*{10mm}
\vspace*{0.6cm}
}
\mode<all>
宏
\mode<presentation>
\mode<presentation>
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
% Define folder tree
\def\beamer@calltheme#1#2#3{%
\def\beamer@themelist{#2}
\@for\beamer@themename:=\beamer@themelist\do
{\usepackage[{#1}]{\beamer@themelocation/#3\beamer@themename}}}
\def\usefolder#1{
\def\beamer@themelocation{#1}
}
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
\mode<all>
答案1
您实际上并不需要了解主题的所有细节,重要的是您的主题并没有定义标题。
这意味着您可以smoothbars
在自定义主题之前加载外部主题:
\documentclass[
11pt,notheorems,hyperref={pdfauthor=whatever}
]{beamer}
\usecolortheme{whale}
\useoutertheme{smoothbars}
\input{loadslides.tex} % Loads packages and some defined commands
\begin{document}
\section{title}
\begin{frame}
content...
\end{frame}
\end{document}