From fd4ba42666314d851da89619b5d05924c093046e Mon Sep 17 00:00:00 2001 From: Vladislav Turbanov Date: Wed, 18 May 2016 22:02:09 +0400 Subject: [PATCH] Custom font families Adding ability to define custom font families. Needed for correct polyglossia operation with Cyrillic fonts and perhaps can find some other usages. Example usage in YAML metadata: ``` fontfamilies: - name: \cyrillicfont font: Liberation Serif - name: \cyrillicfonttt options: Scale=MatchLowercase font: Liberation Mono ``` --- default.latex | 3 +++ 1 file changed, 3 insertions(+) diff --git a/default.latex b/default.latex index 0a1c47391..bc84520a3 100644 --- a/default.latex +++ b/default.latex @@ -24,6 +24,9 @@ $endif$ \usepackage{fontspec} \fi \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase} +$for(fontfamilies)$ + \newfontfamily{$fontfamilies.name$}[$fontfamilies.options$]{$fontfamilies.font$} +$endfor$ $if(euro)$ \newcommand{\euro}{€} $endif$