[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ion
Subject:    Re: Ion3, keycodes and binding lookup on OS X
From:       tuomov () modeemi ! cs ! tut ! fi (Tuomo Valkonen)
Date:       2004-07-22 15:02:06
Message-ID: 20040722150205.GA7992 () jolt ! modeemi ! cs ! tut ! fi
[Download RAW message or body]

On Thu, Jul 22, 2004 at 03:18:07PM +1000, Nicholas FitzRoy-Dale wrote:
> I tried a slightly different approach. In do_action in 
> ioncore/conf-bindings.c, we iterate through all possible keycodes and 
> add them whenever XKeycodeToKeysym() matches. This seems to be the 
> approach used by at least fvwm:

This won't work over modmap changes. ioncore.getbindings (Ion3) would
also then list multiple entries for the same binding and we don't want
that. Instead 'kcb' in WBinding should be a table of N entries and we 
should enter the binding in the bindmap's r-b tree once for each keycode.
But then we also need to add a reference counter and things get way too 
complicated.

> It's not an elegant solution, but I'm not sure if there is such a thing 
> for this problem. :) Thoughts?

Could there be standard modmaps that don't have the same symbols in
the "no modifier" map as most do? For example, maybe some modmap 
produces special symbols when no modifier is set, and numbers only
when shift is pressed? (Of course, one could have a special modmap
where even numbers and letters overlap, but we must assume something
or else no default bindings can be provided.)

But of course we can always fall back to XKeysymToKeycode if the ugly
scan fails. So, it could work, but I think modmaps with multiple keycodes
for a single symbol are broken.

-- 
Tuomo
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic