From 4fde26fb2c8478176bdd77be19e091695b744ae8 Mon Sep 17 00:00:00 2001 From: "Lubomir I. Ivanov" Date: Fri, 10 Nov 2017 16:56:54 +0200 Subject: preferences: re-use a tr() string in _language.cpp Also, tell "in date format" instead of "in time format" for dates. Signed-off-by: Lubomir I. Ivanov --- desktop-widgets/preferences/preferences_language.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'desktop-widgets') diff --git a/desktop-widgets/preferences/preferences_language.cpp b/desktop-widgets/preferences/preferences_language.cpp index 4d200d82f..0cb36dc2c 100644 --- a/desktop-widgets/preferences/preferences_language.cpp +++ b/desktop-widgets/preferences/preferences_language.cpp @@ -89,14 +89,15 @@ void PreferencesLanguage::syncSettings() lang->setDateFormatShort(ui->shortDateFormatEntry->text()); uiLanguage(NULL); + QString qDateTimeWeb = tr("These will be used as is. This might not be what you intended.\nSee http://doc.qt.io/qt-5/qdatetime.html#toString"); QRegExp tfillegalchars("[^hHmszaApPt\\s:;\\.,]"); if (tfillegalchars.indexIn(ui->timeFormatEntry->text()) >= 0) QMessageBox::warning(this, tr("Literal characters"), - tr("Non-special character(s) in time format.\nThese will be used as is. This might not be what you intended.\nSee http://doc.qt.io/qt-5/qdatetime.html#toString")); + tr("Non-special character(s) in time format.\n") + qDateTimeWeb); QRegExp dfillegalchars("[^dMy/\\s:;\\.,\\-]"); if (dfillegalchars.indexIn(ui->dateFormatEntry->currentText()) >= 0 || dfillegalchars.indexIn(ui->shortDateFormatEntry->text()) >= 0) QMessageBox::warning(this, tr("Literal characters"), - tr("Non-special character(s) in time format.\nThese will be used as is. This might not be what you intended.\nSee http://doc.qt.io/qt-5/qdatetime.html#toString")); + tr("Non-special character(s) in date format.\n") + qDateTimeWeb); } -- cgit v1.2.3-70-g09d2