【问题标题】:How to add page numbers on rmarkdown beamer slide under theme: "boxes"?如何在主题下的 rmarkdown beamer 幻灯片上添加页码:“框”?
【发布时间】:2021-02-13 11:49:07
【问题描述】:

使用 rmarkdown beamer,我尝试在每张幻灯片的底部添加幻灯片编号,但一直失败。无论如何我可以在名为“boxes”的投影仪主题下的每个页面上添加幻灯片编号吗?

---
title: "Big Business" 
author: |
| Mr. Bean
| Sunny College
output: 
beamer_presentation:
    theme: "boxes"
    citation_package: natbib
biblio-style: apalike 
incremental: TRUE
header-includes:
- \usepackage{makecell}
- \usepackage{booktabs}
- \usepackage{adjustbox}
---
# Motivation
Big business

# Motivation 2
Small business 

【问题讨论】:

  • 请创建一个minimal reproducible example,我们可以编译而无需访问您的文件,例如header_pagenrs.tex
  • @samcarter_is_at_topanswers.xyz:根据您的要求,我完全更改了上面的代码,以便您可以复制它们。我只希望每个页面的底部都有页码。
  • 您可以在标题中包含 \addfootbox{normal text}{\hfill\insertframenumber\quad} 的框主题添加脚线

标签: r latex r-markdown beamer


【解决方案1】:

boxes 主题有一个特殊的语法来添加东西到脚注:

 \addfootbox{normal text}{\hfill\insertframenumber\quad}

(将<normal text>替换为您喜欢的任何其他投影仪颜色)

MWE:

---
title: "Big Business" 
author: |
  | Mr. Bean
  | Sunny College
output: 
  beamer_presentation:
    theme: "boxes"
    citation_package: natbib
biblio-style: apalike 
incremental: TRUE
header-includes:
  - \usepackage{makecell}
  - \usepackage{booktabs}
  - \usepackage{adjustbox}
  - \addfootbox{normal text}{\hfill\insertframenumber\quad}
---

# Motivation
Big business

# Motivation 2
Small business 

【讨论】:

  • 我也可以用- \addfootbox{normal text}{\hfill\insertframenumber/\inserttotalframenumber\quad}添加总帧数。
猜你喜欢
  • 1970-01-01
  • 2021-10-08
  • 2017-12-26
  • 1970-01-01
  • 2017-07-15
  • 2016-08-15
  • 2017-05-31
  • 2023-02-23
  • 1970-01-01
相关资源
最近更新 更多