![降低投影机页脚的高度](https://linux22.com/image/383036/%E9%99%8D%E4%BD%8E%E6%8A%95%E5%BD%B1%E6%9C%BA%E9%A1%B5%E8%84%9A%E7%9A%84%E9%AB%98%E5%BA%A6.png)
我想降低 Beamer 中页脚的高度。我试过,\setbeamerfont{footline}{size=\fontsize{0}{0}\selectfont}
但有一次,这不再能降低高度了。另外,如果页脚中的文本能与幻灯片标题垂直对齐就更好了。这是我的代码。
\documentclass{beamer}
\usetheme{metropolis}
\setbeamertemplate{frame numbering}[fraction]
\title{My Title}
\subtitle{My Subtitle}
\author{My Name}
\date{}
\institute{Reference}
\setbeamertemplate{frame footer}{\insertauthor\hfill\insertsubtitle}
\setbeamerfont{footline}{size=\fontsize{0}{0}\selectfont}
\setbeamerfont{page number in head/foot}{size=\tiny}
\setbeamercolor{footline}{fg=white,bg=black}
\setbeamercolor{frametitle}{fg=white,bg=black}
\begin{document}
\begin{frame}
\titlepage\thispagestyle{empty}
\end{frame}
\begin{frame}[t]{Contents}\vspace{3pt}
\begin{enumerate}
\item First Point
\item Second Point
\item ...
\end{enumerate}
\end{frame}
\end{document}
答案1
将字体大小减小到 0 没有帮助,因为该尺寸的字体不可用,并且将被替换为下一个更大的尺寸,即 3pt。
要降低脚注线的高度,您可以调整投影仪盒的填充:
\documentclass{beamer}
\usetheme{moloch}% modern fork of the metropolis theme
\setbeamertemplate{page number in head/foot}[totalframenumber]
\title{My Title}
\subtitle{My Subtitle}
\author{My Name}
\date{}
\institute{Reference}
\setbeamertemplate{frame footer}{\insertauthor\hfill\insertsubtitle}
\setbeamerfont{footline}{size=\fontsize{0}{0}\selectfont}
\setbeamerfont{page number in head/foot}{size=\tiny}
\setbeamercolor{footline}{fg=white,bg=black}
\setbeamercolor{frametitle}{fg=white,bg=black}
\setbeamertemplate{footline}{%
\begin{beamercolorbox}[wd=\textwidth, sep=1ex]{footline}%
\hspace{0.3cm}
\usebeamerfont{page number in head/foot}%
\usebeamertemplate*{frame footer}
\hfill%
\usebeamertemplate*{page number in head/foot}
\end{beamercolorbox}%
}
\begin{document}
\begin{frame}
\titlepage\thispagestyle{empty}
\end{frame}
\begin{frame}[t]{Contents}\vspace{3pt}
\begin{enumerate}
\item First Point
\item Second Point
\item ...
\end{enumerate}
\end{frame}
\end{document}