将标题拆分为多行? [英] Split the title onto multiple lines?

查看:26
本文介绍了将标题拆分为多行?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在 R markdown 文档(html 和演示文稿)中,是否可以手动将标题拆分为多行?我尝试使用产生可怕输出的管道.

In an R markdown document (html and presentations), is it possible to manually split the title onto multiple lines? I tried playing with pipes which produces orrendous output.

---
title:  'A title I want to split on two lines'
author: 
date: 
output:
  ioslides_presentation
---

推荐答案

对于 HTML 输出,只需使用 <br> 标签,而如果您的输出是 PDF 或 PDF 演示标准 LaTeX 代码\ 给出的换行符应该可以工作.

For an HTML output just us the <br> tag while if your output is a PDF or PDF presentation standard LaTeX code to break line given by \ should work.

---
title:  'A title I want to <br> split on two lines'
author: 
date: 
output:
  ioslides_presentation
---

对于 PDF

只是为了排除可能,我试过把 \ ewline 都放不分割,所以对于 PDF 来说似乎有点棘手.linebreak 停止 knitr 解析.也许其他用户可以为 knitr PDF 解决这个问题.

For PDF

Just to rule out possibilities, I've tried to put \ or ewline, both do not split, so for PDF seems to be a little bit tricky. linebreak stop knitr parsing. Maybe another user can solve this question for knitr PDFs.

这篇关于将标题拆分为多行?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆