在Markdown上使用Pandoc时,如何从YAML标头中更改PDF输出字体? [英] How can I change PDF output font from within the YAML header when using Pandoc on Markdown?
问题描述
是否有一种(内置)方法来设置要在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
orfourier
(Utopia),fouriernc
(New Century Schoolbook),times
ortxfonts
(Times),mathpazo
orpxfonts
ormathpple
(Palatino),libertine
(Linux Libertine),arev
(Arev Sans), and the defaultlmodern
, among others.
这篇关于在Markdown上使用Pandoc时,如何从YAML标头中更改PDF输出字体?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!