My attempts to test this yield errors looking like this: ``` $ pandoc --defaults `pwd`/defaults --latex-engine=lualatex --template=my_client.latex my_source_file.pdc -o my_result_file.pdf pandoc: unrecognized option `--defaults' Try pandoc --help for more information. ``` looking at the --help output yields this: ``` $ pandoc --help | grep default -D FORMAT --print-default-template=FORMAT --print-default-data-file=FILE --default-image-extension=extension ``` but no `--defaults` switch. What am I missing here, please? -- Hugh On Monday, August 16, 2021 at 4:32:15 AM UTC-4 BPJ wrote: > > > Den mån 16 aug. 2021 10:25BPJ skrev: > >> You use the `mainfont`, `sansfont`, `monofont`, `mathfont`, `CJKmainfont` >> variables for the font names and the corresponding `mainfontoptions` etc. >> variables. The latter are lists of strings with raw fontspec[^1] options >> in the format `'Option=Value'` or `'Option={Multi-word value}'`. The >> easiest way is to specify them is in a defaults file[^2] like this: >> >> from: markdown >> to: latex >> pdf-engine: xelatex >> variables: >> mainfont: Noto Serif >> sansfont: Noto Sans >> monofont: Noto Mono >> monofontoptions: >> - 'Scale=MatchLowercase' >> >> For some reason the default latex template[^3] does not contain any >> variable for `defaultfontfeatures` but >> `\defaultfontfeatures{Scale=MatchLowercase}` is hard coded. In my custom >> template I have added that variable[^4]: >> >> $if(defaultfontfeatures)$ >> >> \mainfontfeatures{$for(mainfontfeatures)$$mainfontfeatures$$sep$,$endfor$} >> $else$ >> > \defaultfontfeatures{Scale=MatchLowercase} >> $endif$ >> > > Sorry, a typo: it should be `defaultfontfeatures` rather than > `mainfontfeatures`. That's what happens when you copy the wrong line and > use search/replace to make up for it! :-/ > > >> Font embedding depends on your XeTeX/LuaTeX settings. Usually it Just >> Works. >> >> >> [^1]: https://ctan.org/pkg/fontspec >> >> [^2]: https://pandoc.org/MANUAL.html#default-files >> >> [^3]: https://pandoc.org/MANUAL.html#templates >> >> [^4]: https://git.io/J0UJS >> >> >> Den mån 16 aug. 2021 06:56Hugh Esco skrev: >> >>> My tests seem to indicate that the fonts which are available to me are a >>> function of the value of the `--latex-engine=` switch. >>> >>> If I set that switch to pdflatex (which seems to be the default), I can >>> choose any font installed as a .sty file at this path: >>> `/usr/share/texlive/texmf-dist/tex/latex/psnfss/`, by setting a value to >>> the fontenc key at the top of my markdown source file. >>> >>> But I have not been able to sort out how to access other fonts installed >>> at `/usr/share`, by setting the `--latex-engine` to `lualatext` or >>> `xelatex`. >>> >>> All my tests seem to look alike, and changing my fonts has no impact on >>> how the resulting pdf looks. >>> >>> Can someone please point me to some documentation which would help me >>> understand how to use the full range of fonts available on this system, >>> suitable for which ever value I set to the `--latext-engine` switch? >>> >>> Thanks, >>> -- Hugh Esco >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "pandoc-discuss" group. >>> To unsubscribe from this group and stop receiving emails from it, send >>> an email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/pandoc-discuss/543536ca-7ced-4033-ad1a-ecdd3fedaf44n%40googlegroups.com >>> >>> . >>> >> -- You received this message because you are subscribed to the Google Groups "pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/512edc0d-8cbb-4e97-92b9-5cd1a1bdfffen%40googlegroups.com.