Reputation: 1534
I am new to pandoc and using it to convert set of markdown files into pdf. I would like to change the default fonts for the pdf.
The documentation gives an example to set the fonts
pandoc -N --template=mytemplate.tex --variable mainfont=Georgia --variable
sansfont=Arial --variable monofont="Bitstream Vera Sans Mono" --variable
fontsize=12pt --variable version=1.10 README --latex-engine=xelatex --toc
-o example14.pdf
however this uses xelatex
and it is recommended to use MiKTeX
.
I have tried the above with MiKTeX
, but without any success.
Is there a way to set the font, I am using Windows 8 with MiKTeX
Upvotes: 8
Views: 8063
Reputation: 1534
I have tried the above with MiKTeX, but without any success.
At a closer look I found that MiKTex is indeed supported, the issue was with fontspec. Once I ran the update fontspec for updated and it started working.
Upvotes: 0
Reputation: 39209
MiKTeX is a TeX distribution that includes the LaTeX macro package (including the pdflatex and xelatex engines). (Its support for the ConTeXt macro package is apparently not so good though.) If you need unicode support, pdflatex
is not such a great choice, so you might want to use xelatex
instead.
Use pandoc -D latex
to look at the template, save that as myTemplate.tex
, modify the file and use for example:
pandoc --template myTemplate.tex --latex-engine xelatex -o output.pdf input.md
Upvotes: 2