Details
-
Bug
-
Resolution: Invalid
-
P3: Somewhat important
-
5.6.1, 5.7.0
-
None
-
Windows 10, msc_2015_64
Description
With this code:
QDateTime date = QDateTime::fromString("14:13:09.042", "hh:mm:ss.zzz");
qDebug() << date << " " << date.toString("H:m:s a");
Date would be "14:13:9 pm" instead i have "14:13:9 "
Same result using QTime.
Also
QDateTime date = QDateTime::fromString("14:13:09.042", "hh:mm:ss.zzz");
qDebug() << date << " " << date.toString("h:m:s ap"); has wrong result: "2:13:9 " instead of "2:13:9 pm" (the correct)
Attachments
Issue Links
- relates to
-
QTBUG-49234 QTime::toString() does not work correctly
- Closed
For Gerrit Dashboard: QTBUG-55632 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
169876,4 | Document that am/pm in QDateTime::toString are locale-specific | 5.6 | qt/qtbase | Status: MERGED | +2 | 0 |
170591,2 | Q(Date|Time)+::(to|from)String(): mention relevant QLocale methods | 5.6 | qt/qtbase | Status: MERGED | +2 | 0 |
170592,2 | Q(Date|Time)+::(to|from)String(): use C locale from Qt 6 | dev | qt/qtbase | Status: MERGED | +2 | 0 |