From: Georg Baum Date: Thu, 7 Apr 2011 19:17:30 +0000 (+0000) Subject: fix another bug spotted by Pavel X-Git-Tag: 2.0.0~193 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=15c274fbc8ee26e08f90fc42253db9df68d2c243;p=lyx.git fix another bug spotted by Pavel git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@38300 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/LaTeXFeatures.cpp b/src/LaTeXFeatures.cpp index a714df386e..61bd0a7a03 100644 --- a/src/LaTeXFeatures.cpp +++ b/src/LaTeXFeatures.cpp @@ -1215,7 +1215,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 +1347,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 << '}';