D14779: Fix 'kformattest fails with installed kcoreaddons language package'
Ralf Habacker
noreply at phabricator.kde.org
Tue Aug 21 08:51:27 BST 2018
habacker added a comment.
In D14779#311871 <https://phabricator.kde.org/D14779#311871>, @habacker wrote:
> Thanks for this pointer - with this setting the german translation is not fetched anymore.
A further look into the windows implementation of the qm loader part (https://cgit.kde.org/extra-cmake-modules.git/tree/modules/ECMQmLoader.cpp.in#n65) shows that the language is fetched from `QLocale::system() `
QLocale::system() is initiated on unix os from LC_ALL and friends (http://code.qt.io/cgit/qt/qtbase.git/tree/src/corelib/tools/qlocale_unix.cpp#n75), which could be changed with the qputenv call.
But on Windows the system locale is fetched from the current user locale (http://code.qt.io/cgit/qt/qtbase.git/tree/src/corelib/tools/qlocale_win.cpp#n172), which could not be changed temporary by the test app.
To have a cross platform solution I think it is really required to disable loading translations in this test. If QLocale::C could not be used for that (Albert mentioned that) an auxiliary function provided by the qmloader is required for that.
I'm going to file a related review request.
REPOSITORY
R244 KCoreAddons
REVISION DETAIL
https://phabricator.kde.org/D14779
To: habacker, #frameworks
Cc: dfaure, aacid, kde-frameworks-devel, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180821/830b4418/attachment-0001.html>
More information about the Kde-frameworks-devel
mailing list