From cbfa2c0191a8ba3586a0125e2fb7dfb051b1c7ca Mon Sep 17 00:00:00 2001 From: Friedemann Kleint <Friedemann.Kleint@nokia.com> Date: Fri, 31 Jul 2009 16:41:12 +0200 Subject: [PATCH] Fixed translation glitches. --- .../cmakeopenprojectwizard.cpp | 2 +- src/plugins/cvs/checkoutwizard.cpp | 2 +- src/plugins/fakevim/fakevimplugin.cpp | 4 +- src/plugins/help/xbelsupport.cpp | 6 +- .../customwidgetwizard/classdefinition.ui | 2 +- .../gettingstartedwelcomepagewidget.cpp | 2 +- src/plugins/subversion/checkoutwizard.cpp | 2 +- src/plugins/subversion/checkoutwizardpage.ui | 84 ------------------- src/plugins/subversion/subversion.pro | 3 +- src/plugins/texteditor/colorscheme.cpp | 3 +- src/plugins/texteditor/fontsettings.cpp | 3 +- src/plugins/vcsbase/basecheckoutwizard.cpp | 2 +- 12 files changed, 17 insertions(+), 98 deletions(-) delete mode 100644 src/plugins/subversion/checkoutwizardpage.ui diff --git a/src/plugins/cmakeprojectmanager/cmakeopenprojectwizard.cpp b/src/plugins/cmakeprojectmanager/cmakeopenprojectwizard.cpp index 9d07264c745..bb100c53dc9 100644 --- a/src/plugins/cmakeprojectmanager/cmakeopenprojectwizard.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeopenprojectwizard.cpp @@ -299,7 +299,7 @@ void CMakeRunPage::initializePage() if (m_cmakeWizard->existsUpToDateXmlFile()) { m_descriptionLabel->setText( - tr("The directoyr %1 already contains a cbp file, which is recent enough. " + tr("The directory %1 already contains a cbp file, which is recent enough. " "You can pass special arguments or change the used toolchain here and rerun cmake. " "Or simply finish the wizard directly").arg(m_buildDirectory)); } else { diff --git a/src/plugins/cvs/checkoutwizard.cpp b/src/plugins/cvs/checkoutwizard.cpp index 736cd9e2fc6..9040344fc29 100644 --- a/src/plugins/cvs/checkoutwizard.cpp +++ b/src/plugins/cvs/checkoutwizard.cpp @@ -51,7 +51,7 @@ QIcon CheckoutWizard::icon() const QString CheckoutWizard::description() const { - return tr("Check-out a project from a CVS repository."); + return tr("Checks out a project from a CVS repository."); } QString CheckoutWizard::name() const diff --git a/src/plugins/fakevim/fakevimplugin.cpp b/src/plugins/fakevim/fakevimplugin.cpp index 5703033d5a0..ca7ec800183 100644 --- a/src/plugins/fakevim/fakevimplugin.cpp +++ b/src/plugins/fakevim/fakevimplugin.cpp @@ -533,7 +533,7 @@ void FakeVimPluginPrivate::handleExCommand(const QString &cmd) if (failed.isEmpty()) handler->showBlackMessage(tr("Saving succeeded")); else - handler->showRedMessage(tr("%1 files not saaved").arg(failed.size())); + handler->showRedMessage(tr("%n files not saved", 0, failed.size())); } else if (reQuit.indexIn(cmd) != -1) { // :q bool forced = cmd.contains(QChar('!')); @@ -543,7 +543,7 @@ void FakeVimPluginPrivate::handleExCommand(const QString &cmd) bool forced = cmd.contains(QChar('!')); emit delayedQuitAllRequested(forced); } else { - handler->showRedMessage(tr("Not an editor command: ") + cmd); + handler->showRedMessage(tr("Not an editor command: %1").arg(cmd)); } } diff --git a/src/plugins/help/xbelsupport.cpp b/src/plugins/help/xbelsupport.cpp index 4b75daaaef1..a82b9a3b8e9 100644 --- a/src/plugins/help/xbelsupport.cpp +++ b/src/plugins/help/xbelsupport.cpp @@ -30,6 +30,8 @@ #include "xbelsupport.h" #include "bookmarkmanager.h" +#include <QtCore/QCoreApplication> + using namespace Help::Internal; struct Bookmark { @@ -114,7 +116,7 @@ bool XbelReader::readFromFile(QIODevice *device) == QLatin1String("1.0")) { readXBEL(); } else { - raiseError(QObject::tr("The file is not an XBEL version 1.0 file.")); + raiseError(QCoreApplication::translate("Help::Internal::XbelReader", "The file is not an XBEL version 1.0 file.")); } } } @@ -187,7 +189,7 @@ void XbelReader::readBookmark(QStandardItem *item) { QStandardItem *bookmark = createChildItem(item); bookmark->setIcon(bookmarkIcon); - bookmark->setText(QObject::tr("Unknown title")); + bookmark->setText(QCoreApplication::translate("Help::Internal::XbelReader", "Unknown title")); bookmark->setData(attributes().value(QLatin1String("href")).toString(), Qt::UserRole + 10); diff --git a/src/plugins/qt4projectmanager/customwidgetwizard/classdefinition.ui b/src/plugins/qt4projectmanager/customwidgetwizard/classdefinition.ui index 6d390cffa45..21fc000415e 100644 --- a/src/plugins/qt4projectmanager/customwidgetwizard/classdefinition.ui +++ b/src/plugins/qt4projectmanager/customwidgetwizard/classdefinition.ui @@ -74,7 +74,7 @@ <item row="3" column="1"> <widget class="QLineEdit" name="widgetHeaderEdit"> <property name="whatsThis"> - <string>The header file as to be specified i source code. </string> + <string>The header file has to be specified in source code.</string> </property> </widget> </item> diff --git a/src/plugins/qt4projectmanager/gettingstartedwelcomepagewidget.cpp b/src/plugins/qt4projectmanager/gettingstartedwelcomepagewidget.cpp index 41dd90da34a..a771c194331 100644 --- a/src/plugins/qt4projectmanager/gettingstartedwelcomepagewidget.cpp +++ b/src/plugins/qt4projectmanager/gettingstartedwelcomepagewidget.cpp @@ -248,7 +248,7 @@ QStringList GettingStartedWelcomePageWidget::tipsOfTheDay() "by clicking the <tt>+</tt> button in <tt>Projects -> Run Settings -> Run Configuration</tt> and then select the new " "target in the combo box.")); tips.append(tr("You can use Qt Creator with a number of <a href=\"qthelp://com.nokia.qtcreator/doc/creator-version-control.html\">" - "revision control systems</a> such as Subversion, Perforce and Git.")); + "revision control systems</a> such as Subversion, Perforce, CVS and Git.")); tips.append(tr("In the editor, <tt>F2</tt> toggles declaration and definition while <tt>F4</tt> toggles header file and source file.")); } return tips; diff --git a/src/plugins/subversion/checkoutwizard.cpp b/src/plugins/subversion/checkoutwizard.cpp index 955f34a3b4e..e456cac2059 100644 --- a/src/plugins/subversion/checkoutwizard.cpp +++ b/src/plugins/subversion/checkoutwizard.cpp @@ -51,7 +51,7 @@ QIcon CheckoutWizard::icon() const QString CheckoutWizard::description() const { - return tr("Check-out a project from a Subversion repository."); + return tr("Checks out a project from a Subversion repository."); } QString CheckoutWizard::name() const diff --git a/src/plugins/subversion/checkoutwizardpage.ui b/src/plugins/subversion/checkoutwizardpage.ui deleted file mode 100644 index 74e5ed5069f..00000000000 --- a/src/plugins/subversion/checkoutwizardpage.ui +++ /dev/null @@ -1,84 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<ui version="4.0"> - <class>Subversion::Internal::CheckoutWizardPage</class> - <widget class="QWizardPage" name="Subversion::Internal::CheckoutWizardPage"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>464</width> - <height>302</height> - </rect> - </property> - <property name="windowTitle"> - <string>WizardPage</string> - </property> - <property name="subTitle"> - <string>Specify path and repository URL.</string> - </property> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <layout class="QFormLayout" name="formLayout"> - <item row="0" column="0"> - <widget class="QLabel" name="repositoryLabel"> - <property name="text"> - <string>Clone URL:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QLineEdit" name="repositoryLineEdit"/> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="checkoutDirectoryLabel"> - <property name="text"> - <string>Checkout Directory:</string> - </property> - </widget> - </item> - <item row="2" column="0"> - <widget class="QLabel" name="pathLabel"> - <property name="text"> - <string>Path:</string> - </property> - </widget> - </item> - <item row="2" column="1"> - <widget class="Core::Utils::PathChooser" name="pathChooser"/> - </item> - <item row="1" column="1"> - <widget class="Core::Utils::ProjectNameValidatingLineEdit" name="checkoutDirectoryLineEdit"/> - </item> - </layout> - </item> - <item> - <spacer name="horizontalSpacer"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - </layout> - </widget> - <customwidgets> - <customwidget> - <class>Core::Utils::ProjectNameValidatingLineEdit</class> - <extends>QLineEdit</extends> - <header location="global">utils/projectnamevalidatinglineedit.h</header> - </customwidget> - <customwidget> - <class>Core::Utils::PathChooser</class> - <extends>QWidget</extends> - <header location="global">utils/pathchooser.h</header> - <container>1</container> - </customwidget> - </customwidgets> - <resources/> - <connections/> -</ui> diff --git a/src/plugins/subversion/subversion.pro b/src/plugins/subversion/subversion.pro index b046bec8865..f72f0096bb5 100644 --- a/src/plugins/subversion/subversion.pro +++ b/src/plugins/subversion/subversion.pro @@ -30,8 +30,7 @@ SOURCES += annotationhighlighter.cpp \ checkoutwizard.cpp \ checkoutwizardpage.cpp -FORMS += settingspage.ui \ - checkoutwizardpage.ui +FORMS += settingspage.ui RESOURCES += subversion.qrc diff --git a/src/plugins/texteditor/colorscheme.cpp b/src/plugins/texteditor/colorscheme.cpp index cb298f102c1..a1eedcef050 100644 --- a/src/plugins/texteditor/colorscheme.cpp +++ b/src/plugins/texteditor/colorscheme.cpp @@ -32,6 +32,7 @@ #include "texteditorconstants.h" #include <QtCore/QFile> +#include <QtCore/QCoreApplication> #include <QtXml/QXmlStreamWriter> using namespace TextEditor; @@ -206,7 +207,7 @@ bool ColorSchemeReader::read(const QString &fileName, ColorScheme *scheme) if (readNextStartElement() && name() == QLatin1String("style-scheme")) readStyleScheme(); else - raiseError(QObject::tr("Not a color scheme file.")); + raiseError(QCoreApplication::translate("TextEditor::Internal::ColorScheme", "Not a color scheme file.")); return true; } diff --git a/src/plugins/texteditor/fontsettings.cpp b/src/plugins/texteditor/fontsettings.cpp index cc71afbbbaa..46681d2fe4a 100644 --- a/src/plugins/texteditor/fontsettings.cpp +++ b/src/plugins/texteditor/fontsettings.cpp @@ -34,6 +34,7 @@ #include <coreplugin/icore.h> #include <QtCore/QSettings> +#include <QtCore/QCoreApplication> #include <QtGui/QTextCharFormat> static const char *fontFamilyKey = "FontFamily"; @@ -132,7 +133,7 @@ bool FontSettings::fromSettings(const QString &category, m_scheme.setFormatFor(name, format); } - m_scheme.setName(QObject::tr("Customized")); + m_scheme.setName(QCoreApplication::translate("TextEditor::Internal::FontSettings", "Customized")); } return true; diff --git a/src/plugins/vcsbase/basecheckoutwizard.cpp b/src/plugins/vcsbase/basecheckoutwizard.cpp index e53b90524de..eee11a6d0cd 100644 --- a/src/plugins/vcsbase/basecheckoutwizard.cpp +++ b/src/plugins/vcsbase/basecheckoutwizard.cpp @@ -101,7 +101,7 @@ QStringList BaseCheckoutWizard::runWizard(const QString &path, QWidget *parent) const QString projectFile = openProject(checkoutPath, &errorMessage); if (projectFile.isEmpty()) { QMessageBox msgBox(QMessageBox::Warning, tr("Cannot Open Project"), - tr("Failed to open project in '%1'").arg(checkoutPath)); + tr("Failed to open project in '%1'.").arg(checkoutPath)); msgBox.setDetailedText(errorMessage); msgBox.exec(); return QStringList(); -- GitLab