Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
5.5.0, 5.5.1, 5.6.2, 5.12.3
-
Windows
-
a90869861cbc9927af2bbab5a94630e47b33fd5c 4c3ec0caa839260c2252115535847b9277be32d7 bf2b794a9af7b0ed9ca2dbf48e12fb221523c645 (qt/qtbase/5.15)
Description
Set a RTL locale in Windows. Get a system locale by QLocale::system(). Get textDirection value - it will be Qt::LeftToRight, no matter of actual direction.
QLocale::textDirection implementation uses a switch on QLocale::Script. QLocale::system().script() returns QLocale::AnyScript.
Checked on Windows only, but looks like it will be the same for other platforms.
Workaround: create another QLocale object using language and country of system locale. It will set script to proper value and return correct text direction.
Attachments
Issue Links
- resulted in
-
QTBUG-53110 QLineEdit: Placeholder text is aligned to the right
- Closed
For Gerrit Dashboard: QTBUG-49031 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
139147,2 | QLocale: Actually get the language script for the system locale | 5.6 | qt/qtbase | Status: MERGED | +2 | 0 |
297609,2 | Revert "Revert "QLocale: Actually get the language script for the system locale"" | dev | qt/qtbase | Status: MERGED | +2 | 0 |
300951,2 | Revert "Revert "QLocale: Actually get the language script for the system locale"" | 5.15 | qt/qtbase | Status: MERGED | +2 | 0 |