PDA

View Full Version : KGlobal::locale::Warning error...



glafauci
19th August 2011, 19:26
Hi to all.
I work with Linux (Kubuntu 11.04) with italian localization, using QtSDK, ver. 4.7.4, and QtCreator ver. 2.2.0.
I'm developing an application that use some QFileDialog objects. When I attempt to use one of that functions (getSaveFileName or getOpenFileName) I obtain the following warning:


KGlobal::locale::Warning your global KLocale is being recreated with a valid main component instead of a fake component, this usually means you tried to call i18n related functions before your main component was created. You should not do that since it most likely will not work

Catching that entry on the web, I found that this problem arise with a problem in the kde-qt integration, but I can't solve it.

I have some mistake on my configuration. There is anyone that can address me on the right solution?

antoyo
18th September 2011, 23:11
Hello,
did somebody know why this happen?

I am using ArchLinux with KDE in french and my QFileDialog is in english because of a similar message:

KGlobal::locale::Warning your global KLocale is being recreated with a valid main component instead of a fake component, this usually means you tried to call i18n related functions before your main component was created. You should not do that since it most likely will not work
kfilemodule(20742) KSambaSharePrivate::findSmbConf: KSambaShare: Could not find smb.conf!

This problem happens with other Qt non-KDE applications like Opera.

Does somebody know a solution?

Thanks for your help.

glafauci
19th September 2011, 08:56
Dear buddy,
I think that the problem is due to a global variable (type KGlobale) that isn't inizialized from the system. This problem is one KDE bug, that isn't fixed. This fact is reported from various Linux newsgroups in no-programming tasks, so the problem isn't caused from a programming error.

I verify that this warning occurs when I use, for the 1st time, one object of type QDialog, during programming with QtCreator. While I working in no-programming environment, it doesn't occur.

If anyone have other information on this problem, I pray him to share his information.