]> git.lyx.org Git - lyx.git/commitdiff
cosmetics
authorAbdelrazak Younes <younes@lyx.org>
Fri, 2 May 2008 22:07:51 +0000 (22:07 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Fri, 2 May 2008 22:07:51 +0000 (22:07 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@24590 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/Dialog.cpp
src/frontends/qt4/GuiFontLoader.cpp
src/frontends/qt4/GuiWorkArea.cpp
src/frontends/qt4/Menus.cpp
src/frontends/qt4/PanelStack.cpp
src/frontends/qt4/qt_helpers.cpp

index d4bd227e127b849575555ec0bb4294781d2ddafc..f2e29bfd8c50858c6a31ceebc00926d99304cc4a 100644 (file)
@@ -135,7 +135,7 @@ void Dialog::showData(string const & data)
                return;
 
        if (!initialiseParams(data)) {
-               LYXERR0("Dialog \"" << fromqstr(name())
+               LYXERR0("Dialog \"" << name()
                        << "\" failed to translate the data string passed to show()");
                return;
        }
index 2bf371acc14be3c37156a57a4e9e5b1feb6ea1c9..dac59a6ad2f2a8cbe5b9063400693dd7001efd1f 100644 (file)
@@ -140,7 +140,7 @@ static bool isChosenFont(QFont & font, QString const & family)
        // positions.
        QFontInfo fi(font);
 
-       LYXERR(Debug::FONT, "got: " << fromqstr(fi.family()));
+       LYXERR(Debug::FONT, "got: " << fi.family());
 
        if (fi.family().contains(family)) {
                LYXERR(Debug::FONT, " got it ");
@@ -313,7 +313,7 @@ GuiFontInfo::GuiFontInfo(FontInfo const & f)
        else
                LYXERR(Debug::FONT, "This font is NOT an exact match");
 
-       LYXERR(Debug::FONT, "XFLD: " << fromqstr(font.rawName()));
+       LYXERR(Debug::FONT, "XFLD: " << font.rawName());
 
        font.setPointSizeF(convert<double>(lyxrc.font_sizes[f.size()])
                               * lyxrc.zoom / 100.0);
index c116bbb599494a6bd54e04505b4ea06bd5498ee5..e4ca81fc1687c8724eb92e8741a742d43edd7ca8 100644 (file)
@@ -1526,8 +1526,8 @@ void TabWorkArea::updateTabTexts()
                        // final?
                        allFinal = allFinal && it->final();
                        
-                       LYXERR(Debug::GUI, "it = " << fromqstr(it->abs())
-                              << " => " << fromqstr(it->displayString()));
+                       LYXERR(Debug::GUI, "it = " << it->abs()
+                              << " => " << it->displayString());
                        
                        // still the same segment?
                        QString nextString;
@@ -1551,23 +1551,18 @@ void TabWorkArea::updateTabTexts()
                        It sit = segStart;
                        QString dspString = sit->forecastPathString();
                        LYXERR(Debug::GUI, "first forecast found for "
-                              << fromqstr(sit->abs())
-                              << " => " << fromqstr(dspString));
+                              << sit->abs() << " => " << dspString);
                        ++sit;
                        bool moreUnique = false;
                        for (; sit != next; ++sit) {
                                if (sit->forecastPathString() != dspString) {
                                        LYXERR(Debug::GUI, "different forecast found for "
-                                              << fromqstr(sit->abs())
-                                              << " => "
-                                              << fromqstr(sit->forecastPathString()));
+                                               << sit->abs() << " => " << sit->forecastPathString());
                                        moreUnique = true;
                                        break;
                                }
                                LYXERR(Debug::GUI, "same forecast found for "
-                                       << fromqstr(sit->abs())
-                                       << " => "
-                                       << fromqstr(dspString));
+                                       << sit->abs() << " => " << dspString);
                        }
                        
                        // if the path segment helped, add it. Otherwise add dots
@@ -1575,9 +1570,8 @@ void TabWorkArea::updateTabTexts()
                        LYXERR(Debug::GUI, "using dots = " << dots);
                        for (sit = segStart; sit != next; ++sit) {
                                sit->shiftPathSegment(dots);
-                               LYXERR(Debug::GUI, "shifting " << fromqstr(sit->abs())
-                                      << " => "
-                                      << fromqstr(sit->displayString()));
+                               LYXERR(Debug::GUI, "shifting "
+                                       << sit->abs() << " => " << sit->displayString());
                        }
 
                        // start new segment
index a6be3cfb76118c431eba2b5b5aab6b1469465f6f..9a36095df2eb863f6123ba44de81a79907fab250 100644 (file)
@@ -565,17 +565,17 @@ void MenuDefinition::checkShortcuts() const
                if (shortcut.isEmpty())
                        continue;
                if (!it1->label().contains(shortcut))
-                       lyxerr << "Menu warning: menu entry \""
-                              << fromqstr(it1->label())
+                       LYXERR0("Menu warning: menu entry \""
+                              << it1->label()
                               << "\" does not contain shortcut `"
-                              << fromqstr(shortcut) << "'." << endl;
+                              << shortcut << "'." << endl);
                for (const_iterator it2 = begin(); it2 != it1 ; ++it2) {
                        if (!it2->shortcut().compare(shortcut, Qt::CaseInsensitive)) {
-                               lyxerr << "Menu warning: menu entries "
-                                      << '"' << fromqstr(it1->fulllabel())
-                                      << "\" and \"" << fromqstr(it2->fulllabel())
+                               LYXERR0("Menu warning: menu entries "
+                                      << '"' << it1->fulllabel()
+                                      << "\" and \"" << it2->fulllabel()
                                       << "\" share the same shortcut."
-                                      << endl;
+                                      << endl);
                        }
                }
        }
@@ -595,8 +595,7 @@ bool MenuDefinition::searchMenu(FuncRequest const & func, vector<docstring> & na
                        names.push_back(qstring_to_ucs4(m->label()));
                        if (!m->hasSubmenu()) {
                                LYXERR(Debug::GUI, "Warning: non existing sub menu label="
-                                       << fromqstr(m->label())
-                                       << " name=" << fromqstr(m->submenuname()));
+                                       << m->label() << " name=" << m->submenuname());
                                names.pop_back();
                                continue;
                        }
@@ -1159,9 +1158,9 @@ static QString label(MenuItem const & mi)
 
 void Menu::Impl::populate(QMenu & qMenu, MenuDefinition const & menu)
 {
-       LYXERR(Debug::GUI, "populating menu " << fromqstr(menu.name()));
+       LYXERR(Debug::GUI, "populating menu " << menu.name());
        if (menu.size() == 0) {
-               LYXERR(Debug::GUI, "\tERROR: empty menu " << fromqstr(menu.name()));
+               LYXERR(Debug::GUI, "\tERROR: empty menu " << menu.name());
                return;
        }
        LYXERR(Debug::GUI, " *****  menu entries " << menu.size());
@@ -1438,7 +1437,7 @@ MenuDefinition const & Menus::Impl::getMenu(QString const & name) const
        const_iterator cit = find_if(menulist_.begin(), menulist_.end(),
                MenuNamesEqual(name));
        if (cit == menulist_.end())
-               lyxerr << "No submenu named " << fromqstr(name) << endl;
+               lyxerr << "No submenu named " << name << endl;
        LASSERT(cit != menulist_.end(), /**/);
        return (*cit);
 }
@@ -1449,7 +1448,7 @@ MenuDefinition & Menus::Impl::getMenu(QString const & name)
        iterator it = find_if(menulist_.begin(), menulist_.end(),
                MenuNamesEqual(name));
        if (it == menulist_.end())
-               lyxerr << "No submenu named " << fromqstr(name) << endl;
+               lyxerr << "No submenu named " << name << endl;
        LASSERT(it != menulist_.end(), /**/);
        return (*it);
 }
@@ -1541,11 +1540,11 @@ void Menus::fillMenuBar(QMenuBar * qmb, GuiView * view, bool initial)
                qmb->clear();
        }
 
-       LYXERR(Debug::GUI, "populating menu bar" << fromqstr(d->menubar_.name()));
+       LYXERR(Debug::GUI, "populating menu bar" << d->menubar_.name());
 
        if (d->menubar_.size() == 0) {
                LYXERR(Debug::GUI, "\tERROR: empty menu bar"
-                       << fromqstr(d->menubar_.name()));
+                       << d->menubar_.name());
                return;
        }
        LYXERR(Debug::GUI, "menu bar entries " << d->menubar_.size());
@@ -1562,16 +1561,16 @@ void Menus::fillMenuBar(QMenuBar * qmb, GuiView * view, bool initial)
        for (; m != end; ++m) {
 
                if (m->kind() != MenuItem::Submenu) {
-                       LYXERR(Debug::GUI, "\tERROR: not a submenu " << fromqstr(m->label()));
+                       LYXERR(Debug::GUI, "\tERROR: not a submenu " << m->label());
                        continue;
                }
 
-               LYXERR(Debug::GUI, "menu bar item " << fromqstr(m->label())
-                       << " is a submenu named " << fromqstr(m->submenuname()));
+               LYXERR(Debug::GUI, "menu bar item " << m->label()
+                       << " is a submenu named " << m->submenuname());
 
                QString name = m->submenuname();
                if (!d->hasMenu(name)) {
-                       LYXERR(Debug::GUI, "\tERROR: " << fromqstr(name)
+                       LYXERR(Debug::GUI, "\tERROR: " << name
                                << " submenu has no menu!");
                        continue;
                }
@@ -1587,7 +1586,7 @@ void Menus::fillMenuBar(QMenuBar * qmb, GuiView * view, bool initial)
 
 void Menus::updateMenu(Menu * qmenu)
 {
-       LYXERR(Debug::GUI, "Triggered menu: " << fromqstr(qmenu->d->name));
+       LYXERR(Debug::GUI, "Triggered menu: " << qmenu->d->name);
        qmenu->clear();
 
        if (qmenu->d->name.isEmpty())
@@ -1599,7 +1598,7 @@ void Menus::updateMenu(Menu * qmenu)
        if (!d->hasMenu(qmenu->d->name)) {
                qmenu->addAction(qt_("No action defined!"));
                LYXERR(Debug::GUI, "\tWARNING: non existing menu: "
-                       << fromqstr(qmenu->d->name));
+                       << qmenu->d->name);
                return;
        }
 
@@ -1614,10 +1613,10 @@ void Menus::updateMenu(Menu * qmenu)
 
 Menu * Menus::menu(QString const & name, GuiView & view)
 {
-       LYXERR(Debug::GUI, "Context menu requested: " << fromqstr(name));
+       LYXERR(Debug::GUI, "Context menu requested: " << name);
        Menu * menu = d->name_map_[&view].value(name, 0);
        if (!menu && !name.startsWith("context-")) {
-               LYXERR0("requested context menu not found: " << fromqstr(name));
+               LYXERR0("requested context menu not found: " << name);
                return 0;
        }
 
index f0726b38c46e50db47e49b6424f41014d25905b1..69158e1a8e98e9c2caffff3b0aa8fe30f4de9999 100644 (file)
@@ -61,7 +61,7 @@ void PanelStack::addCategory(QString const & name, QString const & parent)
 {
        QTreeWidgetItem * item = 0;
 
-       LYXERR(Debug::GUI, "addCategory n= " << fromqstr(name) << "   parent= ");
+       LYXERR(Debug::GUI, "addCategory n= " << name << "   parent= ");
 
        int depth = 1;
 
index b1e2b140bb02b537182dcdd1d5896be854ee30d5..08b979d34dd7e902435a295c4b94209ffe10aed9 100644 (file)
@@ -530,11 +530,11 @@ QStringList fileFilters(QString const & desc)
        // we have: "*.{gif,png,jpg,bmp,pbm,ppm,tga,tif,xpm,xbm}"
        // but need:  "*.cpp;*.cc;*.C;*.cxx;*.c++"
        FileFilterList filters(qstring_to_ucs4(desc));
-       LYXERR0("DESC: " << fromqstr(desc));
+       LYXERR0("DESC: " << desc);
        QStringList list;
        for (size_t i = 0; i != filters.filters_.size(); ++i) {
                QString f = filters.filters_[i].toString();
-               LYXERR0("FILTER: " << fromqstr(f));
+               LYXERR0("FILTER: " << f);
                list.append(f);
        }
        return list;