You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

RMarkdown采用Metropolis主题时Beamer章节起始页添加页脚失效求助

失效原因

Metropolis主题默认的章节起始页使用了plain帧属性,该属性会直接清空页脚(footline)区域,你自定义的页脚设置会被强制覆盖,因此无法正常显示。

修复方案

把你YAML头部#show footer on section's start/title pages注释下的原有代码替换为以下内容即可:

\makeatletter
% 自定义章节页的页脚样式,和普通页保持一致
\def\ps@sectionpage{%
  \setbeamertemplate{footline}{%
    \tiny{\textcolor{beaublue}{Conference 56. Jahrestagung der DGSMP, 2021 | SIMON RESS}}%
    \hfill%
    \usebeamertemplate*{frame numbering}%
  }
}
\addtobeamertemplate{section page}{\thispagestyle{sectionpage}}{}
% 覆盖Metropolis默认设置,移除章节页的plain属性
\defbeamertemplate*{section page}{metropolis}[1][]
{
  \begin{frame}[c]
    \centering
    \usebeamerfont{section title}\usebeamercolor[fg]{section title}\insertsection\par
  \end{frame}
}
\makeatother

替换后重新编译RMarkdown文件,章节起始页就会正常显示自定义页脚,你已经实现的标题页隐藏页脚、带编号目录功能不会受影响。

内容的提问来源于stack exchange,提问作者Simon Ress

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.09.30 20:18:01