summaryrefslogtreecommitdiffstats
path: root/src/corelib
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@qt.io>2016-09-01 13:29:46 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2016-10-13 15:16:23 +0000
commitd023b300b26a9db3cf4dbbe31c1cc5726fe277d7 (patch)
tree6e859e1b7294cf97eba5b00d3cd8a0efa099f282 /src/corelib
parent8796c69480a6e5e331d19edf24d4dabb180bc4d2 (diff)
Document that am/pm in QDateTime::toString are locale-specific
Change-Id: I28382b25ac94cbfbad4acff1308ddd8baf5ca693 Task-number: QTBUG-55632 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Diffstat (limited to 'src/corelib')
-rw-r--r--src/corelib/tools/qdatetime.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/corelib/tools/qdatetime.cpp b/src/corelib/tools/qdatetime.cpp
index 6b09b4107c..3e29b55666 100644
--- a/src/corelib/tools/qdatetime.cpp
+++ b/src/corelib/tools/qdatetime.cpp
@@ -1623,9 +1623,11 @@ QString QTime::toString(Qt::DateFormat format) const
\row \li z \li the milliseconds without leading zeroes (0 to 999)
\row \li zzz \li the milliseconds with leading zeroes (000 to 999)
\row \li AP or A
- \li use AM/PM display. \e A/AP will be replaced by either "AM" or "PM".
+ \li use AM/PM display. \e A/AP will be replaced by either
+ QLocale::amText() or QLocale::pmText().
\row \li ap or a
- \li use am/pm display. \e a/ap will be replaced by either "am" or "pm".
+ \li use am/pm display. \e a/ap will be replaced by a lower-case version of
+ QLocale::amText() or QLocale::pmText().
\row \li t \li the timezone (for example "CEST")
\endtable
@@ -1634,7 +1636,8 @@ QString QTime::toString(Qt::DateFormat format) const
expression. Two consecutive single quotes ("''") are replaced by a singlequote
in the output. Formats without separators (e.g. "HHmm") are currently not supported.
- Example format strings (assuming that the QTime is 14:13:09.042)
+ Example format strings (assuming that the QTime is 14:13:09.042 and the system
+ locale is \c{en_US})
\table
\header \li Format \li Result