From 7c108afd140c002613bd33f2b00e29b447a537cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Tue, 27 Nov 2007 22:19:36 +0000 Subject: [PATCH] cosmetics git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21837 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/frontends/qt4/GuiAlert.cpp | 2 ++ src/frontends/qt4/GuiClipboard.cpp | 1 - src/frontends/qt4/GuiDialog.cpp | 9 ++++----- src/frontends/qt4/GuiErrorList.cpp | 3 +-- src/frontends/qt4/GuiFontLoader.cpp | 1 - src/frontends/qt4/GuiKeySymbol.cpp | 14 ++++---------- src/frontends/qt4/GuiMenubar.cpp | 4 ---- src/frontends/qt4/GuiPopupMenu.cpp | 6 ------ src/frontends/qt4/GuiSelection.cpp | 2 -- src/frontends/qt4/GuiSpellchecker.cpp | 11 ----------- src/frontends/qt4/GuiToc.cpp | 1 - src/frontends/qt4/GuiToolbars.cpp | 1 - src/frontends/qt4/TocModel.cpp | 2 -- src/frontends/qt4/TocWidget.cpp | 7 +------ 14 files changed, 12 insertions(+), 52 deletions(-) diff --git a/src/frontends/qt4/GuiAlert.cpp b/src/frontends/qt4/GuiAlert.cpp index 88bdce1630..f52070fd11 100644 --- a/src/frontends/qt4/GuiAlert.cpp +++ b/src/frontends/qt4/GuiAlert.cpp @@ -29,6 +29,8 @@ #include #include +#include + using std::endl; diff --git a/src/frontends/qt4/GuiClipboard.cpp b/src/frontends/qt4/GuiClipboard.cpp index 7798228a21..0bad26412d 100644 --- a/src/frontends/qt4/GuiClipboard.cpp +++ b/src/frontends/qt4/GuiClipboard.cpp @@ -27,7 +27,6 @@ using lyx::support::internalLineEnding; using lyx::support::externalLineEnding; -using std::endl; using std::string; static char const * const mime_type = "application/x-lyx"; diff --git a/src/frontends/qt4/GuiDialog.cpp b/src/frontends/qt4/GuiDialog.cpp index 5034373cce..9729464c86 100644 --- a/src/frontends/qt4/GuiDialog.cpp +++ b/src/frontends/qt4/GuiDialog.cpp @@ -169,9 +169,8 @@ void GuiDialog::showData(string const & data) return; if (!initialiseParams(data)) { - lyxerr << "Dialog \"" << name() - << "\" failed to translate the data " - "string passed to show()" << std::endl; + LYXERR(Debug::ANY, "Dialog \"" << name() + << "\" failed to translate the data string passed to show()"); return; } @@ -188,8 +187,8 @@ void GuiDialog::updateData(string const & data) return; if (!initialiseParams(data)) { - lyxerr << "Dialog \"" << name() - << "\" could not be initialized" << std::endl; + LYXERR(Debug::ANY, "Dialog \"" << name() + << "\" could not be initialized"); return; } diff --git a/src/frontends/qt4/GuiErrorList.cpp b/src/frontends/qt4/GuiErrorList.cpp index 968e11e4e4..627374f3e2 100644 --- a/src/frontends/qt4/GuiErrorList.cpp +++ b/src/frontends/qt4/GuiErrorList.cpp @@ -28,7 +28,6 @@ #include #include -using std::endl; using std::string; @@ -115,7 +114,7 @@ void GuiErrorList::goTo(int item) ParIterator pit = buf.getParFromID(err.par_id); if (pit == buf.par_iterator_end()) { - lyxerr << "par id " << err.par_id << " not found" << endl; + LYXERR(Debug::ANY, "par id " << err.par_id << " not found"); return; } diff --git a/src/frontends/qt4/GuiFontLoader.cpp b/src/frontends/qt4/GuiFontLoader.cpp index b6b03be610..d0c8eb4cc9 100644 --- a/src/frontends/qt4/GuiFontLoader.cpp +++ b/src/frontends/qt4/GuiFontLoader.cpp @@ -29,7 +29,6 @@ #include #include -using std::endl; using std::make_pair; using std::pair; diff --git a/src/frontends/qt4/GuiKeySymbol.cpp b/src/frontends/qt4/GuiKeySymbol.cpp index 8a69a44308..c961d38fdf 100644 --- a/src/frontends/qt4/GuiKeySymbol.cpp +++ b/src/frontends/qt4/GuiKeySymbol.cpp @@ -1,5 +1,5 @@ /** - * \file qt4/KeySymbolFactory.cpp + * \file qt4/GuiKeySymbol.cpp * This file is part of LyX, the document processor. * Licence details can be found in the file COPYING. * @@ -17,10 +17,6 @@ #include "debug.h" -#include "support/lstrings.h" -#include "support/environment.h" -#include "support/unicode.h" - #include "Encoding.h" #include "Language.h" @@ -29,17 +25,15 @@ #include #include +#include "boost/assert.hpp" + #include -namespace lyx { - -using std::endl; using std::string; using std::map; -using lyx::support::contains; -using lyx::support::getEnv; +namespace lyx { #if 0 static char encode(string const & encoding, QString const & str) diff --git a/src/frontends/qt4/GuiMenubar.cpp b/src/frontends/qt4/GuiMenubar.cpp index 2574c9ed33..4e56213707 100644 --- a/src/frontends/qt4/GuiMenubar.cpp +++ b/src/frontends/qt4/GuiMenubar.cpp @@ -19,7 +19,6 @@ #include "GuiPopupMenu.h" #include "qt_helpers.h" -#include "support/lstrings.h" #include "MenuBackend.h" @@ -28,9 +27,6 @@ #include #include -using std::pair; -using std::string; -using std::endl; namespace lyx { namespace frontend { diff --git a/src/frontends/qt4/GuiPopupMenu.cpp b/src/frontends/qt4/GuiPopupMenu.cpp index 7c383d6adc..8528f72bdf 100644 --- a/src/frontends/qt4/GuiPopupMenu.cpp +++ b/src/frontends/qt4/GuiPopupMenu.cpp @@ -24,12 +24,6 @@ #include "debug.h" -using std::make_pair; -using std::string; -using std::pair; -using std::endl; - - namespace lyx { namespace frontend { diff --git a/src/frontends/qt4/GuiSelection.cpp b/src/frontends/qt4/GuiSelection.cpp index 241d9422b9..e53c8b6cc8 100644 --- a/src/frontends/qt4/GuiSelection.cpp +++ b/src/frontends/qt4/GuiSelection.cpp @@ -24,8 +24,6 @@ #include -using std::endl; - namespace lyx { namespace frontend { diff --git a/src/frontends/qt4/GuiSpellchecker.cpp b/src/frontends/qt4/GuiSpellchecker.cpp index daff427e85..0ca45a6fc1 100644 --- a/src/frontends/qt4/GuiSpellchecker.cpp +++ b/src/frontends/qt4/GuiSpellchecker.cpp @@ -30,15 +30,7 @@ #include "support/docstring.h" #include "support/lstrings.h" -#include -#include -#include -#include #include -#include -#include -#include -#include #if defined(USE_ASPELL) # include "ASpell_local.h" @@ -54,9 +46,6 @@ #include "frontends/alert.h" -using std::advance; -using std::distance; -using std::endl; using std::string; diff --git a/src/frontends/qt4/GuiToc.cpp b/src/frontends/qt4/GuiToc.cpp index f366a1ffcc..526584e6a3 100644 --- a/src/frontends/qt4/GuiToc.cpp +++ b/src/frontends/qt4/GuiToc.cpp @@ -35,7 +35,6 @@ #include -using std::endl; using std::string; diff --git a/src/frontends/qt4/GuiToolbars.cpp b/src/frontends/qt4/GuiToolbars.cpp index 20fc1fcbd6..9d8a3acd8b 100644 --- a/src/frontends/qt4/GuiToolbars.cpp +++ b/src/frontends/qt4/GuiToolbars.cpp @@ -31,7 +31,6 @@ #include "ToolbarBackend.h" -using std::endl; using std::string; namespace lyx { diff --git a/src/frontends/qt4/TocModel.cpp b/src/frontends/qt4/TocModel.cpp index adc580bc99..6ee11a3105 100644 --- a/src/frontends/qt4/TocModel.cpp +++ b/src/frontends/qt4/TocModel.cpp @@ -17,8 +17,6 @@ #include -using std::endl; -using std::map; using std::max; using std::min; diff --git a/src/frontends/qt4/TocWidget.cpp b/src/frontends/qt4/TocWidget.cpp index ec1fa42eec..10d0efe493 100644 --- a/src/frontends/qt4/TocWidget.cpp +++ b/src/frontends/qt4/TocWidget.cpp @@ -19,14 +19,9 @@ #include "debug.h" #include -#include -#include #include -using std::endl; -using std::vector; - namespace lyx { namespace frontend { @@ -219,7 +214,7 @@ void TocWidget::updateView() void TocWidget::updateGui() { - vector const & type_names = form_.typeNames(); + std::vector const & type_names = form_.typeNames(); if (type_names.empty()) { enableControls(false); typeCO->clear();