]> git.lyx.org Git - lyx.git/blobdiff - src/LaTeXFeatures.cpp
- UI support for the LaTeX-package undertilde, fileformat change, fixed the remaining...
[lyx.git] / src / LaTeXFeatures.cpp
index a714df386e63b5a7916b9dac3a5ef2df6abc6bdc..41f39bd26fee8631ca4a7d8d7b150020b7a29b25 100644 (file)
@@ -744,6 +744,10 @@ string const LaTeXFeatures::getPackages() const
        if (mustProvide("yhmath"))
                packages << "\\usepackage{yhmath}\n";
 
+       if (mustProvide("undertilde") &&
+               params_.use_undertilde != BufferParams::package_off)
+               packages << "\\usepackage{undertilde}\n";
+
        // [x]color and pdfcolmk are handled in getColorOptions() above
        
        // makeidx.sty
@@ -1215,7 +1219,7 @@ docstring const LaTeXFeatures::getTClassI18nPreamble(bool use_babel, bool use_po
                                        from_ascii(buffer().language()->babel())));
                        for (lang_it lit = lbeg; lit != lend; ++lit) {
                                string const code = (*lit)->code();
-                               name = translateIfPossible(flname, code);
+                               name = (*lit)->translateLayout(fl.name());
                                // we assume we have a suitable translation if
                                // either the language is English (we need to
                                // translate into English if English is a secondary
@@ -1347,9 +1351,8 @@ void LaTeXFeatures::getFloatDefinitions(odocstream & os) const
                        docstring const ext = from_ascii(fl.ext());
                        docstring const within = from_ascii(fl.within());
                        docstring const style = from_ascii(fl.style());
-                       docstring const name = translateIfPossible(
-                                       from_utf8(fl.name()),
-                                       buffer().language()->code());
+                       docstring const name =
+                               buffer().language()->translateLayout(fl.name());
                        os << "\\floatstyle{" << style << "}\n"
                           << "\\newfloat{" << type << "}{" << placement
                           << "}{" << ext << '}';