holtzermann17 / key-mon

Automatically exported from code.google.com/p/key-mon
Apache License 2.0
0 stars 0 forks source link

Implement new keymap system #94

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
After dealing with some issues, I began to fell kbdfile is hard to please every 
keyboard layout other than us.

So, I am thinking to rewrite the mod_mapper.py and use xmodmap data only, which 
reflects the current system keymap. I don't really see any reason to use 
scancode. Using X keycode + keysym should be enough.

I think we can directly get keymap via XGetKeyboardMapping via xlib if there is 
a binding already. According the manpage, the returned keysyms per keycode are 
the generated keysym for the key uses with modifier keys, and I believe that's 
enough.

By using this way, it doesn't need to have a default or any kbd file and to 
worry it might not match to current system's keymap. Everything is already in 
results of XGetKeyboardMapping.

Furthermore, since the returned keysyms for a keycode contains the key with 
shift, we can then use it to display something like

 +-----+
 |  $  |
 |  4  |
 +-----+

It kills two birds with one stone.

This will block Issue 90, which will not get fixed anytime soon. After some 
thinking, I will create a new branch instead of developing in a clone, also the 
discussion will still be here in this issue.

The first step, I will create a test script or edit xlib.py/mod_mapper.py, so 
it will list all keysyms just as `xmodmap -pk` does.

Any feedback is welcome, especially the flaws I didn't see.

Original issue reported on code.google.com by livibet...@gmail.com on 21 Aug 2011 at 5:57

GoogleCodeExporter commented 9 years ago

Original comment by livibet...@gmail.com on 21 Aug 2011 at 6:01

GoogleCodeExporter commented 9 years ago

Original comment by livibet...@gmail.com on 21 Aug 2011 at 10:01

GoogleCodeExporter commented 9 years ago
Way more than a year and I haven't actually started *the* branch and probably 
won't be.

I am sorry that I brought up the idea and couldn't deliver it. However, I still 
think this might be a good idea, so I will remove myself as the owner of the 
issue and set priority to low. Keep this as a record, but feel free to change 
status to WONTFIX, when this stalls too long. Or the better, taking over the 
issue and lead the way, I will follow.

Original comment by livibet...@gmail.com on 31 Dec 2012 at 5:25

GoogleCodeExporter commented 9 years ago

Original comment by livibet...@gmail.com on 31 Dec 2012 at 5:25