I'm currently setting up gestures using Touchegg. Most of them are fairly easy, but I want to bind Fn+F11 which is causing me some trouble.
As far as I understand it FN is not an actual key, but more of a physical switch for my laptop, so it doesn't have an actual "Key" I can use as a modifier in my settings.
Using xev
I managed to print out the output of my keypresses, but I'm unsure how to use it in my configuration:
Pressing and releasing F11
FocusOut event, serial 38, synthetic NO, window 0x3e00001,
mode NotifyGrab, detail NotifyAncestor
FocusIn event, serial 38, synthetic NO, window 0x3e00001,
mode NotifyUngrab, detail NotifyAncestor
Pressing and releasing Fn+F11
KeyPress event, serial 38, synthetic NO, window 0x3e00001,
root 0x1c9, subw 0x0, time 17878429, (-72,69), root:(799,536),
state 0x0, keycode 95 (keysym 0xffc8, F11), same_screen YES,
XLookupString gives 0 bytes:
XmbLookupString gives 0 bytes:
XFilterEvent returns: False
KeyRelease event, serial 38, synthetic NO, window 0x3e00001,
root 0x1c9, subw 0x0, time 17878519, (-72,69), root:(799,536),
state 0x0, keycode 95 (keysym 0xffc8, F11), same_screen YES,
XLookupString gives 0 bytes:
XFilterEvent returns: False
Any idea what key combination I should use?
In your case you could create a file named
.Xmodmap
in your home directory. (Note the "dot" in the beginning).So I tested with xev the combination of Fn+F11 and got this info:
You can see that the keycode of this combination is 128 on my device (yours may be a different one)
Next I want to change that combination to -say XF86AudioMute (or whatever you want) and test it:
xmodmap -e "keycode 128 = XF86AudioMute NoSymbol XF86AudioMute"
If I press the combination
Fn+F11
my audio toggles. To persist this behaviour add it to the.Xmodmap
file in you home directory. Create it if is doesn't exist:Instead of using XF86AudioMute you could also use XF86Launch1 or anything else that you can find in this list:
xmodmap -pke
Last not least use your chosen value to connect this event with an executable.
More infos on Xmodmap
An alternative would be Xbindkeys which might also work to tackle your problem. A more elaborate documentation can be found here