Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 480724 - Localization broken in kde-native dialogs used in Qt-based applications
Summary: Localization broken in kde-native dialogs used in Qt-based applications
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] KDE (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo KDE team
URL: https://bugs.kde.org/show_bug.cgi?id=...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-12 12:58 UTC by Egor Y. Egorov
Modified: 2014-07-28 03:16 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Egor Y. Egorov 2013-08-12 12:58:06 UTC
Build test Qt-application:
#include <QtGui>
int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    bool ok;
    QFileDialog::getExistingDirectory();
    QColorDialog::getColor ();
    QFontDialog::getFont(&ok);
    QTimer::singleShot(1000, QApplication::instance(), SLOT(quit()));
    return a.exec();
}

and run in KDE environment.


Reproducible: Always

Steps to Reproduce:
Build test Qt-application:
#include <QtGui>
int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    bool ok;
    QFileDialog::getExistingDirectory();
    QColorDialog::getColor ();
    QFontDialog::getFont(&ok);
    QTimer::singleShot(1000, QApplication::instance(), SLOT(quit()));
    return a.exec();
}

and run in KDE environment with not default locale (ru_RU.UTF-8 in my case)
Actual Results:  
Dialogs are not localized.

Expected Results:  
Dialogs are localized.


In strace log we can see:
access("/home/eegorov/.kde4/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/home/eegorov/.kde4/share/locale/ru_RU/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/locale/ru_RU/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/home/eegorov/.kde4/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/home/eegorov/.kde4/share/locale/ru_RU/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/locale/ru_RU/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/home/eegorov/.kde4/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/locale/ru/LC_MESSAGES/kfilemodule.mo", R_OK) = -1 ENOENT (No such file or directory)
access("/home/eegorov/.kde4/share/locale/en_US/LC_MESSAGES/kdelibs4.mo", R_OK) = -1 ENOENT (No such file or directory)

=> workaround:

mkdir -p ~/.kde4/share/locale/ru/LC_MESSAGES/
cd ~/.kde4/share/locale/ru/LC_MESSAGES/
ln -s /usr/share/locale/ru/LC_MESSAGES/kdialog.mo kfilemodule.mo

After this all localized fine.
Comment 1 Egor Y. Egorov 2013-08-12 15:57:28 UTC
I do not know, this is gentoo bug or upstream bug. But maybe it makes sense to install links kfilemodule.mo -> kdialog.mo in /usr/share/locale/<lang>/LC_MESSAGES/ by kde-base/kde-l10n ebuld?
Comment 2 Johannes Huber gentoo-dev 2013-11-03 12:59:33 UTC
Is this still valid with testing qt (4.8.5) and kde (4.11.2) version?
Comment 3 Egor Y. Egorov 2013-11-03 13:38:14 UTC
Yes. Bug is still with qt-4.8.5 on kde-4.11.2
Comment 4 Egor Y. Egorov 2014-04-30 06:04:52 UTC
Bug is still with qt-4.8.5 on kde-4.13.0
Comment 5 Michael Palimaka (kensington) gentoo-dev 2014-05-01 11:24:07 UTC
This should probably go upstream I guess.
Comment 6 Johannes Huber gentoo-dev 2014-07-25 19:45:32 UTC
Please report this upstream. This looks not like an packaging issue. If it turns out that this is a Gentoo specific problem, please re-open this bug.