From 9f29fb33d1d9d4b42420e4ee950d4b36145fbb28 Mon Sep 17 00:00:00 2001 From: Udi Fogiel Date: Fri, 7 Jul 2023 00:47:20 +0300 Subject: [PATCH] prioretize-user-font-options --- src/BufferParams.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/BufferParams.cpp b/src/BufferParams.cpp index ec4d290609..875b8d0ca8 100644 --- a/src/BufferParams.cpp +++ b/src/BufferParams.cpp @@ -3527,11 +3527,11 @@ string const BufferParams::loadFonts(LaTeXFeatures & features) const os << "\\babelfont{rm}["; else os << "\\setmainfont["; - if (!font_roman_opts.empty()) - os << font_roman_opts << ','; os << texmapping; if (fonts_roman_osf) os << ",Numbers=OldStyle"; + if (!font_roman_opts.empty()) + os << ',' << font_roman_opts; os << "]{" << parseFontName(fontsRoman()) << "}\n"; } if (fontsSans() != "default") { @@ -3545,10 +3545,10 @@ string const BufferParams::loadFonts(LaTeXFeatures & features) const << float(fontsSansScale()) / 100 << ','; if (fonts_sans_osf) os << "Numbers=OldStyle,"; + os << texmapping; if (!font_sans_opts.empty()) - os << font_sans_opts << ','; - os << texmapping << "]{" - << sans << "}\n"; + os << ',' << font_sans_opts; + os << "]{" << sans << "}\n"; } else { if (babelfonts) os << "\\babelfont{sf}["; @@ -3556,10 +3556,10 @@ string const BufferParams::loadFonts(LaTeXFeatures & features) const os << "\\setsansfont["; if (fonts_sans_osf) os << "Numbers=OldStyle,"; + os << texmapping; if (!font_sans_opts.empty()) - os << font_sans_opts << ','; - os << texmapping << "]{" - << sans << "}\n"; + os << ',' << font_sans_opts; + os << "]{" << sans << "}\n"; } } if (fontsTypewriter() != "default") { -- 2.39.5