Can no longer type underscore using Shift+<hyphen> once GTK_IM_MODULE is set to gtk-im-context-simple

For the past years I have used GTK_IM_MODULE=xim, mostly for the compose key functionality and ~/.XCompose. Unfortunately the latest stable Eclipse release does not work at all using xim: It will run out of SWT handles (see [1, 2]; as it turns out, xim was unsupported by Eclipse for a while before).

It appears that people have been recommending setting GTK_IM_METHOD to xim for compose key functionally in the past, because otherwise GTK would not respect ~/.XCompose. But I assume that this has changed in recent GTK versions as

GTK_IM_MODULE=gtk-im-context-simple evince

allows be to use my compose key. But unfortunately once I set GTK_IM_MODULE to gtk-im-context-simple I can no longer type an underscore using shift+<hypen>.

I have tried to debug the issue by starting evince with --gtk-debug keybindings, which yields the following output:

On keypress ‘hypen’:

Gtk-Message: 00:38:01.808: Looking up keycode = 20, modifiers = 0x0001,
    keyval = 95, group = 0, level = 1, consumed_modifiers = 0x6003

On keypress ‘underscore’ (shift+<hypen>):

Gtk-Message: 00:38:01.862: Looking up keycode = 50, modifiers = 0x0001,
    keyval = 65505, group = 0, level = 0, consumed_modifiers = 0x6002

Note the “keyval = 65505”. I assume that means that some mapping is off. Unfortunately I do not know how to debug further from here.

Why can I no longer write underscores (and potentially other keysyms) once I use gtk-im-context-simple?


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.