]> git.lyx.org Git - features.git/commitdiff
Fix bug 5172: Toolbar names are not translated
authorEnrico Forestieri <forenr@lyx.org>
Fri, 15 Aug 2008 10:56:53 +0000 (10:56 +0000)
committerEnrico Forestieri <forenr@lyx.org>
Fri, 15 Aug 2008 10:56:53 +0000 (10:56 +0000)
http://bugzilla.lyx.org/show_bug.cgi?id=5172

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@26171 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/Toolbars.cpp

index 3a335fe4958eb4ecd213c30f6a58256a91df4e40..72fc4a7c8837e2a8627ac1e8df2ab427660fd07d 100644 (file)
 #include "FuncRequest.h"
 #include "Lexer.h"
 #include "LyXAction.h"
-#include "support/lstrings.h"
+#include "qt_helpers.h"
 
 #include "support/debug.h"
 #include "support/gettext.h"
+#include "support/lstrings.h"
 
 #include <boost/bind.hpp>
 
@@ -94,7 +95,7 @@ ToolbarInfo & ToolbarInfo::read(Lexer & lex)
        name = lex.getString();
 
        lex.next(true);
-       gui_name = lex.getString();
+       gui_name = fromqstr(qt_(lex.getString()));
 
        // FIXME what to do here?
        if (!lex) {
@@ -304,7 +305,8 @@ void Toolbars::readToolbarSettings(Lexer & lex)
 
                if (visibility >= MATH) {
                        if (ToolbarInfo const * ti = info(name))
-                               const_cast<ToolbarInfo *>(ti)->gui_name += " (auto)";
+                               const_cast<ToolbarInfo *>(ti)->gui_name +=
+                                       fromqstr(" (" + qt_("auto") + ")");
                }
        }
 }