]> git.lyx.org Git - features.git/commitdiff
* src/frontend/qt4/QLToolbar.C: fix translation of toolbar
authorMichael Schmitt <michael.schmitt@teststep.org>
Sun, 22 Apr 2007 10:05:17 +0000 (10:05 +0000)
committerMichael Schmitt <michael.schmitt@teststep.org>
Sun, 22 Apr 2007 10:05:17 +0000 (10:05 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17907 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/QLToolbar.C

index dea075ca17fbfe0b53c4488da690098d20d03197..dc539912f56e0126e2b28a7e637d6a6b22ad3496 100644 (file)
@@ -195,8 +195,8 @@ void QLToolbar::add(ToolbarItem const & item)
                QToolButton * tb = new QToolButton;
                tb->setCheckable(true);
                tb->setIcon(QPixmap(toqstr(getIcon(FuncRequest(LFUN_TABULAR_INSERT)))));
-               tb->setToolTip(toqstr(item.label_));
-               tb->setStatusTip(toqstr(item.label_));
+               tb->setToolTip(qt_(to_ascii(item.label_)));
+               tb->setStatusTip(qt_(to_ascii(item.label_)));
                InsertTableWidget * iv = new InsertTableWidget(owner_, tb);
                connect(tb, SIGNAL(clicked(bool)), iv, SLOT(show(bool)));
                connect(iv, SIGNAL(visible(bool)), tb, SLOT(setChecked(bool)));
@@ -207,9 +207,9 @@ void QLToolbar::add(ToolbarItem const & item)
        case ToolbarItem::ICONPALETTE: {
                QToolButton * tb = new QToolButton(this);
                tb->setCheckable(true);
-               tb->setToolTip(toqstr(item.label_));
-               tb->setStatusTip(toqstr(item.label_));
-               tb->setText(toqstr(item.label_));
+               tb->setToolTip(qt_(to_ascii(item.label_)));
+               tb->setStatusTip(qt_(to_ascii(item.label_)));
+               tb->setText(qt_(to_ascii(item.label_)));
                connect(this, SIGNAL(iconSizeChanged(const QSize &)),
                        tb, SLOT(setIconSize(const QSize &)));
 
@@ -239,15 +239,15 @@ void QLToolbar::add(ToolbarItem const & item)
        case ToolbarItem::POPUPMENU: {
                QToolButton * tb = new QToolButton;
                tb->setPopupMode(QToolButton::InstantPopup);
-               tb->setToolTip(toqstr(item.label_));
-               tb->setStatusTip(toqstr(item.label_));
-               tb->setText(toqstr(item.label_));
+               tb->setToolTip(qt_(to_ascii(item.label_)));
+               tb->setStatusTip(qt_(to_ascii(item.label_)));
+               tb->setText(qt_(to_ascii(item.label_)));
                FileName icon_path = libFileSearch("images/math", item.name_, "xpm");
                tb->setIcon(QIcon(toqstr(icon_path.absFilename())));
                connect(this, SIGNAL(iconSizeChanged(const QSize &)),
                        tb, SLOT(setIconSize(const QSize &)));
 
-               ButtonMenu * m = new ButtonMenu(toqstr(item.label_), tb);
+               ButtonMenu * m = new ButtonMenu(qt_(to_ascii(item.label_)), tb);
                connect(this, SIGNAL(updated()), m, SLOT(updateParent()));
                ToolbarInfo const & tbinfo = toolbarbackend.getToolbar(item.name_);
                ToolbarInfo::item_iterator it = tbinfo.items.begin();