[Pkg-ime-devel] Bug#664201: ibus: wrong environment variable
Osamu Aoki
osamu at debian.org
Fri Mar 16 17:17:02 UTC 2012
Hi Awashiro-san,
I did some check on QT4 source code. (qt4-x11-4.7.4)
$ grep -r QT.*_IM_MODULE *
inputmethods/imsw-multi/qmultiinputcontext.cpp: QString def = QLatin1String(getenv("QT4_IM_MODULE"));
inputmethods/imsw-multi/qmultiinputcontext.cpp: def = QLatin1String(getenv("QT_IM_MODULE"));
OK so there is no other place in this source mentioning QT_IM_MODULE or
QT4_IM_MODULE in the source.
src/plugins/inputmethods/imsw-multi/qmultiinputcontext.cpp has:
QMultiInputContext::QMultiInputContext()
: QInputContext(), current(-1)
{
keys = QInputContextFactory::keys();
for (int i = keys.size()-1; i >= 0; --i)
if (keys.at(i).contains(QLatin1String("imsw")))
keys.removeAt(i);
QString def = QLatin1String(getenv("QT4_IM_MODULE"));
if (def.isEmpty())
def = QLatin1String(getenv("QT_IM_MODULE"));
if (def.isEmpty()) {
QSettings settings(QSettings::UserScope, QLatin1String("Trolltech"));
settings.beginGroup(QLatin1String("Qt"));
def = settings.value(QLatin1String("DefaultInputMethod"), QLatin1String("xim")).toString();
}
...
So only when QT4_IM_MODULE is not defined, QT_IM_MODULE value is used.
If both are undefined, "xim" used as its default value.
So there is no need to set both values. Use of QT4_IM_MODULE seems good
choice for me. Am I wrong?
Osamu
More information about the Pkg-ime-devel
mailing list