summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuigi Toscano <luigi.toscano@tiscali.it>2014-04-01 00:11:42 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-04-09 15:20:33 +0200
commit49a8b33482396224e48b5741ee4ba68c46bab150 (patch)
tree03aa07cae23c7d93862d0a3db8a4652170786a04
parent8e55ee3f610315f8fc346020f40211e0030bcebd (diff)
Remove exclamation marks from messages
Exclamation marks should usually be avoided in message strings (even in error messages). See also: http://qt-project.org/wiki/UI_Text_Conventions and other HIG guidelines. Change-Id: I0a4cc7c03cf64b130a2b32c1d77143e80e3e4024 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Karsten Heimrich <karsten.heimrich@digia.com>
-rw-r--r--src/assistant/help/qhelpcollectionhandler.cpp24
-rw-r--r--src/assistant/help/qhelpenginecore.cpp4
-rw-r--r--src/assistant/help/qhelpgenerator.cpp24
-rw-r--r--src/assistant/help/qhelpprojectdata.cpp4
-rw-r--r--src/assistant/help/qhelpsearchresultwidget.cpp2
5 files changed, 29 insertions, 29 deletions
diff --git a/src/assistant/help/qhelpcollectionhandler.cpp b/src/assistant/help/qhelpcollectionhandler.cpp
index 548f2b8af..511e4967f 100644
--- a/src/assistant/help/qhelpcollectionhandler.cpp
+++ b/src/assistant/help/qhelpcollectionhandler.cpp
@@ -76,7 +76,7 @@ bool QHelpCollectionHandler::isDBOpened()
{
if (m_dbOpened)
return true;
- emit error(tr("The collection file '%1' is not set up yet!").
+ emit error(tr("The collection file '%1' is not set up yet.").
arg(m_collectionFile));
return false;
}
@@ -99,7 +99,7 @@ bool QHelpCollectionHandler::openCollectionFile()
m_connectionName);
if (db.driver()
&& db.driver()->lastError().type() == QSqlError::ConnectionError) {
- emit error(tr("Cannot load sqlite database driver!"));
+ emit error(tr("Cannot load sqlite database driver."));
return false;
}
@@ -122,7 +122,7 @@ bool QHelpCollectionHandler::openCollectionFile()
m_query.next();
if (m_query.value(0).toInt() < 1) {
if (!createTables(&m_query)) {
- emit error(tr("Cannot create tables in file %1!").arg(collectionFile()));
+ emit error(tr("Cannot create tables in file %1.").arg(collectionFile()));
return false;
}
}
@@ -138,7 +138,7 @@ bool QHelpCollectionHandler::copyCollectionFile(const QString &fileName)
QFileInfo fi(fileName);
if (fi.exists()) {
- emit error(tr("The collection file '%1' already exists!").
+ emit error(tr("The collection file '%1' already exists.").
arg(fileName));
return false;
}
@@ -289,7 +289,7 @@ bool QHelpCollectionHandler::removeCustomFilter(const QString &filterName)
filterNameId = m_query.value(0).toInt();
if (filterNameId < 0) {
- emit error(tr("Unknown filter '%1'!").arg(filterName));
+ emit error(tr("Unknown filter '%1'.").arg(filterName));
return false;
}
@@ -342,7 +342,7 @@ bool QHelpCollectionHandler::addCustomFilter(const QString &filterName,
}
if (nameId < 0) {
- emit error(tr("Cannot register filter %1!").arg(filterName));
+ emit error(tr("Cannot register filter %1.").arg(filterName));
return false;
}
@@ -386,13 +386,13 @@ bool QHelpCollectionHandler::registerDocumentation(const QString &fileName)
QHelpDBReader reader(fileName, QHelpGlobal::uniquifyConnectionName(
QLatin1String("QHelpCollectionHandler"), this), 0);
if (!reader.init()) {
- emit error(tr("Cannot open documentation file %1!").arg(fileName));
+ emit error(tr("Cannot open documentation file %1.").arg(fileName));
return false;
}
QString ns = reader.namespaceName();
if (ns.isEmpty()) {
- emit error(tr("Invalid documentation file '%1'!").arg(fileName));
+ emit error(tr("Invalid documentation file '%1'.").arg(fileName));
return false;
}
@@ -426,7 +426,7 @@ bool QHelpCollectionHandler::unregisterDocumentation(const QString &namespaceNam
nsId = m_query.value(0).toInt();
if (nsId < 0) {
- emit error(tr("The namespace %1 was not registered!").arg(namespaceName));
+ emit error(tr("The namespace %1 was not registered.").arg(namespaceName));
return false;
}
@@ -546,7 +546,7 @@ int QHelpCollectionHandler::registerNamespace(const QString &nspace, const QStri
m_query.exec();
while (m_query.next()) {
if (m_query.value(0).toInt() > 0) {
- emit error(tr("Namespace %1 already exists!").arg(nspace));
+ emit error(tr("Namespace %1 already exists.").arg(nspace));
return -1;
}
}
@@ -559,7 +559,7 @@ int QHelpCollectionHandler::registerNamespace(const QString &nspace, const QStri
if (m_query.exec())
namespaceId = m_query.lastInsertId().toInt();
if (namespaceId < 1) {
- emit error(tr("Cannot register namespace '%1'!").arg(nspace));
+ emit error(tr("Cannot register namespace '%1'.").arg(nspace));
return -1;
}
return namespaceId;
@@ -583,7 +583,7 @@ void QHelpCollectionHandler::optimizeDatabase(const QString &fileName)
db.setDatabaseName(fileName);
if (!db.open()) {
QSqlDatabase::removeDatabase(QLatin1String("optimize"));
- emit error(tr("Cannot open database '%1' to optimize!").arg(fileName));
+ emit error(tr("Cannot open database '%1' to optimize.").arg(fileName));
return;
}
diff --git a/src/assistant/help/qhelpenginecore.cpp b/src/assistant/help/qhelpenginecore.cpp
index 15ce07620..a2aeb73ed 100644
--- a/src/assistant/help/qhelpenginecore.cpp
+++ b/src/assistant/help/qhelpenginecore.cpp
@@ -119,7 +119,7 @@ bool QHelpEngineCorePrivate::setup()
QHelpDBReader *reader = new QHelpDBReader(absFileName,
QHelpGlobal::uniquifyConnectionName(info.fileName, this), this);
if (!reader->init()) {
- emit q->warning(QHelpEngineCore::tr("Cannot open documentation file %1: %2!")
+ emit q->warning(QHelpEngineCore::tr("Cannot open documentation file %1: %2.")
.arg(absFileName, reader->errorMessage()));
continue;
}
@@ -523,7 +523,7 @@ QList<QUrl> QHelpEngineCore::files(const QString namespaceName,
return res;
QHelpDBReader *reader = d->readerMap.value(namespaceName);
if (!reader) {
- d->error = tr("The specified namespace does not exist!");
+ d->error = tr("The specified namespace does not exist.");
return res;
}
diff --git a/src/assistant/help/qhelpgenerator.cpp b/src/assistant/help/qhelpgenerator.cpp
index c496c3eff..ef893d166 100644
--- a/src/assistant/help/qhelpgenerator.cpp
+++ b/src/assistant/help/qhelpgenerator.cpp
@@ -155,20 +155,20 @@ bool QHelpGenerator::generate(QHelpDataInterface *helpData,
emit progressChanged(0);
d->error.clear();
if (!helpData || helpData->namespaceName().isEmpty()) {
- d->error = tr("Invalid help data!");
+ d->error = tr("Invalid help data.");
return false;
}
QString outFileName = outputFileName;
if (outFileName.isEmpty()) {
- d->error = tr("No output file name specified!");
+ d->error = tr("No output file name specified.");
return false;
}
QFileInfo fi(outFileName);
if (fi.exists()) {
if (!fi.dir().remove(fi.fileName())) {
- d->error = tr("The file %1 cannot be overwritten!").arg(outFileName);
+ d->error = tr("The file %1 cannot be overwritten.").arg(outFileName);
return false;
}
}
@@ -186,7 +186,7 @@ bool QHelpGenerator::generate(QHelpDataInterface *helpData,
}
if (!openingOk) {
- d->error = tr("Cannot open data base file %1!").arg(outFileName);
+ d->error = tr("Cannot open data base file %1.").arg(outFileName);
cleanupDB();
return false;
}
@@ -200,7 +200,7 @@ bool QHelpGenerator::generate(QHelpDataInterface *helpData,
insertMetaData(helpData->metaData());
if (!registerVirtualFolder(helpData->virtualFolder(), helpData->namespaceName())) {
- d->error = tr("Cannot register namespace %1!").arg(helpData->namespaceName());
+ d->error = tr("Cannot register namespace %1.").arg(helpData->namespaceName());
cleanupDB();
return false;
}
@@ -308,7 +308,7 @@ bool QHelpGenerator::createTables()
"AND Name=\'NamespaceTable\'"));
d->query->next();
if (d->query->value(0).toInt() > 0) {
- d->error = tr("Some tables already exist!");
+ d->error = tr("Some tables already exist.");
return false;
}
@@ -369,7 +369,7 @@ bool QHelpGenerator::createTables()
foreach (const QString &q, tables) {
if (!d->query->exec(q)) {
- d->error = tr("Cannot create tables!");
+ d->error = tr("Cannot create tables.");
return false;
}
}
@@ -455,7 +455,7 @@ bool QHelpGenerator::registerVirtualFolder(const QString &folderName, const QStr
return d->virtualFolderId > 0;
}
}
- d->error = tr("Cannot register virtual folder!");
+ d->error = tr("Cannot register virtual folder.");
return false;
}
@@ -648,12 +648,12 @@ bool QHelpGenerator::registerCustomFilter(const QString &filterName,
if (d->query->exec())
nameId = d->query->lastInsertId().toInt();
} else if (!forceUpdate) {
- d->error = tr("The filter %1 is already registered!").arg(filterName);
+ d->error = tr("The filter %1 is already registered.").arg(filterName);
return false;
}
if (nameId < 0) {
- d->error = tr("Cannot register filter %1!").arg(filterName);
+ d->error = tr("Cannot register filter %1.").arg(filterName);
return false;
}
@@ -777,7 +777,7 @@ bool QHelpGenerator::insertContents(const QByteArray &ba,
d->query->exec();
int contentId = d->query->lastInsertId().toInt();
if (contentId < 1) {
- d->error = tr("Cannot insert contents!");
+ d->error = tr("Cannot insert contents.");
return false;
}
@@ -789,7 +789,7 @@ bool QHelpGenerator::insertContents(const QByteArray &ba,
d->query->bindValue(1, filterAtt);
d->query->exec();
if (!d->query->isActive()) {
- d->error = tr("Cannot register contents!");
+ d->error = tr("Cannot register contents.");
return false;
}
}
diff --git a/src/assistant/help/qhelpprojectdata.cpp b/src/assistant/help/qhelpprojectdata.cpp
index feb42ab85..0dd264490 100644
--- a/src/assistant/help/qhelpprojectdata.cpp
+++ b/src/assistant/help/qhelpprojectdata.cpp
@@ -99,7 +99,7 @@ void QHelpProjectDataPrivate::readData(const QByteArray &contents)
readProject();
else
raiseError(QCoreApplication::translate("QHelpProject",
- "Unknown token. Expected \"QtHelpProject\"!"));
+ "Unknown token. Expected \"QtHelpProject\"."));
}
}
@@ -379,7 +379,7 @@ bool QHelpProjectData::readData(const QString &fileName)
QFile file(fileName);
if (!file.open(QIODevice::ReadOnly)) {
d->errorMsg = QCoreApplication::translate("QHelpProject",
- "The input file %1 could not be opened!").arg(fileName);
+ "The input file %1 could not be opened.").arg(fileName);
return false;
}
diff --git a/src/assistant/help/qhelpsearchresultwidget.cpp b/src/assistant/help/qhelpsearchresultwidget.cpp
index d038d9852..e06d1d514 100644
--- a/src/assistant/help/qhelpsearchresultwidget.cpp
+++ b/src/assistant/help/qhelpsearchresultwidget.cpp
@@ -116,7 +116,7 @@ public:
"%1&nbsp;<span style=\"font-weight:normal; color:black\">"
"%2</span></div></div><br>")).arg(tr("Note:"))
.arg(tr("The search results may not be complete since the "
- "documentation is still being indexed!"));
+ "documentation is still being indexed."));
foreach (const QHelpSearchEngine::SearchHit &hit, hits) {
htmlFile += QString(QLatin1String("<div style=\"text-align:left; font-weight:bold\""