[PyQt] Programmatically changing the input method, and a missing
qinputcontextfactory
Damien Elmes
resolve at ichi2.net
Sat Jan 24 08:25:18 GMT 2009
Hi folks,
In my application (http://ichi2.net/anki/) I'd like text input fields
to remember the last input method, so that if a user is inputting
Japanese into one field and English in another, they don't have to
switch between input methods every time. This works out of the box for
me on Linux, as apparently Qt uses a separate XIM context for each
widget. But on Windows and OSX, the input context seems to be
application-wide.
I was looking at the docs to QInputContextFactory. The keys() and
languages() methods look like they might be useful here, but I see
that this class is not available in PyQt. Am I barking up the wrong
tree? If inclusion of this class in unlikely in the future, is there
an easy way to add it to a binary install of PyQt (such as dropping an
extra sip into a directory)?
Cheers,
Damien
More information about the PyQt
mailing list