[kmscon-devel] About keyboard shortcuts and consumed modifiers

David Herrmann dh.herrmann at gmail.com
Sun Mar 10 08:27:07 PDT 2013


Hi Ran

On Sun, Mar 10, 2013 at 11:21 AM, Ran Benita <ran234 at gmail.com> wrote:
> I noticed the last commit added a nice feature for dynamically
> increasing/decreasing the font size with a shortcut. The default is
> <Ctrl><+> and <Ctrl><->.
>
> When I tried it I noticed that you need to use <Ctrl><Shift><=> to get
> the effect of <Ctrl><+>, because on this keymap the <+> is shifted. I
> think though that the expected behavior is that you don't actually need
> to use Shift there.. I wrote some explanation on this a while back, I
> thought it might intrest you:
> http://cgit.freedesktop.org/libxkbcommon/tree/xkbcommon/xkbcommon.h?id=bb620df7aa98c129#n1323

I am aware of the problem, but didn't have the time to fix it. Thanks
for pointing me to the xkb_*_consumed_*() helpers.

So to fix this bug, I basically want to call
xkb_state_mod_mask_remove_consumed() on the keycode+modifiers for each
key-event and pass this as "effective_mods" or something like this
along, right? And I should call this _after_ xkb_state_update_key(),
right?

I think that's the easiest way. Any comments?
Thanks
David


More information about the kmscon-devel mailing list