在Markdown上使用Pandoc时,如何从YAML标头中更改PDF输出字体? [英] How can I change PDF output font from within the YAML header when using Pandoc on Markdown?

查看:42
本文介绍了在Markdown上使用Pandoc时,如何从YAML标头中更改PDF输出字体?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有一种(内置)方法来设置要在Pandoc YAML标头中使用的其他字体?理想情况下,我会在Markdown文件的YAML标头中执行以下操作:

Is there a (built-in) way to set a different font (or fonts) to use in the Pandoc YAML header? Ideally, I would do something like this in the YAML header of my Markdown file:

---
font: MySansSerifFontName  
...

我正在Linux(Ubuntu)上使用TexLive,当然还有 pandoc .

I'm using TexLive on Linux (Ubuntu), with pandoc, of course.

推荐答案

这应该可以解决问题:

---
fontfamily: arev
---

从Pandoc的自述文件:

fontfamily :用于LaTeX文档的字体包(带有pdflatex):TeXLive具有 bookman (Bookman), utopia Fourier (乌托邦), fouriernc (新世纪教科书), txfonts (次), mathpazo pxfonts mathpple (Palatino), libertine (Linux Libertine), arev (Arev Sans),以及默认的 lmodern 等.

fontfamily: font package to use for LaTeX documents (with pdflatex): TeXLive has bookman (Bookman), utopia or fourier (Utopia), fouriernc (New Century Schoolbook), times or txfonts (Times), mathpazo or pxfonts or mathpple (Palatino), libertine (Linux Libertine), arev (Arev Sans), and the default lmodern, among others.

这篇关于在Markdown上使用Pandoc时,如何从YAML标头中更改PDF输出字体?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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