summaryrefslogtreecommitdiffstats
path: root/src/corelib/time/qdatetime.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2020-03-04 09:54:35 +0100
committerShawn Rutledge <shawn.rutledge@qt.io>2020-03-04 14:39:18 +0000
commit2a4b95778993b00499eb94f61a87330fdbadf947 (patch)
tree168147adcc2854cb6723335b5abffe9d7585c7f4 /src/corelib/time/qdatetime.cpp
parentb4e17a48646a1d2156b7d56ab6003db46af79cec (diff)
parent048f0a00fa7b46f531fbe3ed6d1babae9858e8c2 (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Diffstat (limited to 'src/corelib/time/qdatetime.cpp')
-rw-r--r--src/corelib/time/qdatetime.cpp24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/corelib/time/qdatetime.cpp b/src/corelib/time/qdatetime.cpp
index e9fe34110a..47539141bd 100644
--- a/src/corelib/time/qdatetime.cpp
+++ b/src/corelib/time/qdatetime.cpp
@@ -1383,6 +1383,10 @@ QT_WARNING_POP
If the datetime is invalid, an empty string will be returned.
+ \note If localized month and day names are desired, please switch to using
+ QLocale::system().toString() as QDate methods shall change to use English (C
+ locale) names at Qt 6.
+
\sa fromString(), QDateTime::toString(), QTime::toString(), QLocale::toString()
*/
@@ -1884,6 +1888,10 @@ QT_WARNING_POP
\snippet code/src_corelib_tools_qdatetime.cpp 3
+ \note If localized month and day names are used, please switch to using
+ QLocale::system().toDate() as QDate methods shall change to only recognize
+ English (C locale) names at Qt 6.
+
\sa toString(), QDateTime::fromString(), QTime::fromString(),
QLocale::toDate()
*/
@@ -2244,6 +2252,10 @@ QT_WARNING_POP
If the time is invalid, an empty string will be returned.
If \a format is empty, the default format "hh:mm:ss" is used.
+ \note If localized forms of am or pm (the AP, ap, A or a formats) are
+ desired, please switch to using QLocale::system().toString() as QTime
+ methods shall change to use English (C locale) at Qt 6.
+
\sa fromString(), QDate::toString(), QDateTime::toString(), QLocale::toString()
*/
QString QTime::toString(QStringView format) const
@@ -2641,6 +2653,10 @@ QT_WARNING_POP
\snippet code/src_corelib_tools_qdatetime.cpp 8
+ \note If localized forms of am or pm (the AP, ap, A or a formats) are used,
+ please switch to using QLocale::system().toTime() as QTime methods shall
+ change to only recognize English (C locale) at Qt 6.
+
\sa toString(), QDateTime::fromString(), QDate::fromString(),
QLocale::toTime()
*/
@@ -4541,6 +4557,10 @@ QT_WARNING_POP
If the datetime is invalid, an empty string will be returned.
+ \note If localized month and day names are desired, please switch to using
+ QLocale::system().toString() as QDateTime methods shall change to use
+ English (C locale) names at Qt 6.
+
\sa fromString(), QDate::toString(), QTime::toString(), QLocale::toString()
*/
QString QDateTime::toString(QStringView format) const
@@ -5580,6 +5600,10 @@ QT_WARNING_POP
\snippet code/src_corelib_tools_qdatetime.cpp 14
+ \note If localized month and day names are used, please switch to using
+ QLocale::system().toDateTime() as QDateTime methods shall change to only
+ recognize English (C locale) names at Qt 6.
+
\sa toString(), QDate::fromString(), QTime::fromString(),
QLocale::toDateTime()
*/