You are not logged in.
I'm learning about setting up key bindings for actions in Openbox. One of things that I wanted to do is to have the root-menu and client-list-combined-menu set to keyboard shortcuts. This part I borrowed from a post in the forums and it does exactly what it's supposed to do:
<!-- Keybindings for root menus -->
<keybind key="W-z">
<action name="ShowMenu">
<menu>client-list-combined-menu</menu>
</action>
</keybind>
<keybind key="W-x">
<action name="ShowMenu">
<menu>root-menu</menu>
</action>
</keybind>
The issue comes when I don't want to select something in the menu. Esc will clear it just like it should. But, The Caps Lock key on my system which is remapped to Esc won't. It works like an escape key everywhere except here. Any ideas on why?
Offline
This is also true for me, but I've never investigated the issue. It hasn't bothered me, since I can still just reach up and hit Esc.
So, confirmed issue is all I can say
Offline
This is also true for me, but I've never investigated the issue. It hasn't bothered me, since I can still just reach up and hit Esc.
So, confirmed issue is all I can say
It's not a huge issue, but the deeper I get into Vim, the less everything else works properly anymore. I'm curious more than anything now.
Offline
Square wrote:This is also true for me, but I've never investigated the issue. It hasn't bothered me, since I can still just reach up and hit Esc.
So, confirmed issue is all I can sayIt's not a huge issue, but the deeper I get into Vim, the less everything else works properly anymore. I'm curious more than anything now.
Does this happen only in the vim window ?
Like you say its probably because the Esc key is used in vi to get out of insert mode which is interfering with the Esc for getting rid of the menu(openbox shortcut).
Last edited by Inxsible (2009-02-06 21:16:14)
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Does this happen only in the vim window ? ...
No, it happens all the time. It can be the first thing that I do when the computer boots, and it still doesn't work the way that I'd expect.
If it helps, this is what xev is reporting for Escape:
KeyPress event, serial 35, synthetic NO, window 0x1200001,
root 0x13b, subw 0x0, time 23124448, (89,89), root:(1163,782),
state 0x10, keycode 9 (keysym 0xff1b, Escape), same_screen YES,
XLookupString gives 1 bytes: (1b) "
XmbLookupString gives 1 bytes: (1b) "
XFilterEvent returns: False
KeyRelease event, serial 35, synthetic NO, window 0x1200001,
root 0x13b, subw 0x0, time 23124600, (89,89), root:(1163,782),
state 0x10, keycode 9 (keysym 0xff1b, Escape), same_screen YES,
XLookupString gives 1 bytes: (1b) "
XFilterEvent returns: False
And for Caps_Lock:
KeyPress event, serial 35, synthetic NO, window 0x1200001,
root 0x13b, subw 0x0, time 23132024, (89,89), root:(1163,782),
state 0x10, keycode 66 (keysym 0xff1b, Escape), same_screen YES,
XKeysymToKeycode returns keycode: 9
XLookupString gives 1 bytes: (1b) "
XmbLookupString gives 1 bytes: (1b) "
XFilterEvent returns: False
KeyRelease event, serial 35, synthetic NO, window 0x1200001,
root 0x13b, subw 0x0, time 23132144, (89,89), root:(1163,782),
state 0x10, keycode 66 (keysym 0xff1b, Escape), same_screen YES,
XKeysymToKeycode returns keycode: 9
XLookupString gives 1 bytes: (1b) "
XFilterEvent returns: False
Offline
Inxsible wrote:Does this happen only in the vim window ? ...
No, it happens all the time. It can be the first thing that I do when the computer boots, and it still doesn't work the way that I'd expect.
Oh ok... when you mentioned vim in your earlier post....I associated the two (wrongly) ...
Your mappings look fine to me. sorry couldn't be more help. Quick question...your Esc key works the way you want, but the caps (which is remapped to Esc doesn't correct?)
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Your mappings look fine to me. sorry couldn't be more help. Quick question...your Esc key works the way you want, but the caps (which is remapped to Esc doesn't correct?)
Yes, and the only place I haven't seen it work properly is in this instance. On the other hand, I don't use escape a whole lot outside of Vim, so maybe it really isn't working the way that I think it is.
--EDIT--
I can confirm that the mapping works properly in GTK2 apps, as well as in ncurses based apps. This pretty much covers everything. It's only openbox that's not getting this.
Offline
Perhaps it has to do with the way openbox handles keypresses?
The only lines that seem to differ in the xev outputs is the fact that caps_lock still returns keycode 66 with a symlink to keycode 9, while escape returns the actual keycode 9.
Consider taking your question upstream, and then report back if you do
Offline
Perhaps it has to do with the way openbox handles keypresses?
The only lines that seem to differ in the xev outputs is the fact that caps_lock still returns keycode 66 with a symlink to keycode 9, while escape returns the actual keycode 9.
Consider taking your question upstream, and then report back if you do
Since this community couldn't see the problem, and it's a good idea:
Offline
The answer:
If you were to make your escape key not have the Escape keysym, then the
rebound caps lock would work in openbox. On the one hand, it shouldn't be too
hard to make openbox bind all keys with a given keysym, on the other hand it is
very unusual to have the same key in two places.
Offline