]> git.lyx.org Git - features.git/blobdiff - src/LaTeXFeatures.cpp
Replace hardcoded hack with InsetLayout tag
[features.git] / src / LaTeXFeatures.cpp
index dca1b6cf66704c5d934da66b223a751c3b39988a..48c416dc0e778f96c7a564743d89497797299fb3 100644 (file)
@@ -1569,11 +1569,7 @@ docstring const LaTeXFeatures::getTClassI18nPreamble(bool use_babel, bool use_po
                // need to force a fixed width encoding for
                // \lstlistlistingname and \lstlistingname (bug 9382).
                // This needs to be consistent with InsetListings::latex().
-               docstring const ilname = it->second.name();
-               bool const need_fixedwidth = !runparams_.isFullUnicode() &&
-                               (ilname == "Listings" ||
-                                ilname == "Include:Listings" ||
-                                ilname == "TOC:Listings");
+               bool const need_fixedwidth = it->second.fixedwidthpreambleencoding();
                // language dependent commands (once per document)
                snippets.insert(i18npreamble(it->second.langpreamble(),
                                                buffer().language(),