为 knitr beamer 幻灯片丢掉部分和小节标题的帧 [英] Dropping frames of sections and subsections titles for knitr beamer slides
本文介绍了为 knitr beamer 幻灯片丢掉部分和小节标题的帧的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
使用法兰克福主题使用 knitr
制作投影仪幻灯片时,PDF 输出包括带有部分和小节名称的幻灯片.
When making beamer slides with knitr
using the Frankfurt theme the PDF output includes slides with the section and subsection names.
---
title: Movies
author: Chewy
output:
beamer_presentation:
slide_level: 3
theme: "Frankfurt"
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = FALSE)
```
#Introduction
##Background
###History
A long time ago ...
###History
... in a galaxy far far away
#The End
##This the end
### My only friend, the end
给出这个输出...
幻灯片 1-4:
幻灯片 5-8:
如何去掉带有节和小节标题的幻灯片(2、3、6 和 7),同时保持幻灯片顶部显示的文档结构?
How do I get rid of the slides (2,3,6 and 7) with the section and subsection titles whilst maintaining the document structure displayed at the top of the slides?
推荐答案
那些帧由命令 \AtBeginSubsection{}
和 \AtBeginSection{}
生成,你可以在你的 YAML 前端重新定义什么都不做:
Those frames are produced by the commands \AtBeginSubsection{}
and \AtBeginSection{}
, which you can redefine in your YAML front matter to do nothing instead:
---
header-includes:
- \AtBeginSubsection{}
- \AtBeginSection{}
---
这篇关于为 knitr beamer 幻灯片丢掉部分和小节标题的帧的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文