commit 0e75a749d0c5dd29718353159cce925a0499ce61
Author: Juergen Spitzmueller <[email protected]>
Date:   Mon Apr 23 16:19:41 2018 +0200

    Move definition out of loop
---
 src/Language.cpp |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/Language.cpp b/src/Language.cpp
index d6a8fa3..4f69a61 100644
--- a/src/Language.cpp
+++ b/src/Language.cpp
@@ -76,11 +76,12 @@ string Language::fontenc(BufferParams const & params) const
 {
        // Determine optimal font encoding
        // We check whether the used rm font supports an encoding our language 
supports
+       LaTeXFont const & lf =
+               theLaTeXFonts().getLaTeXFont(from_ascii(params.fontsRoman()));
+       vector<string> const lfe = lf.fontencs();
        for (auto & fe : fontenc_) {
-               LaTeXFont const & lf = 
theLaTeXFonts().getLaTeXFont(from_ascii(params.fontsRoman()));
                // ASCII means: support all T* encodings plus OT1
                if (fe == "ASCII") {
-                       vector<string> const lfe = lf.fontencs();
                        for (auto & afe : lfe) {
                                if (afe == "OT1" || prefixIs(afe, "T"))
                                        // we found a suitable one; return that.

Reply via email to