Question

For example:

awful.key({"Shift", }, "Left", volwidget.down)

How to find out what to write instead of "Shift" to use "Fn" key?

Was it helpful?

Solution

I've found the solution: the program xev.
If it runs, it doesn't show a Fn code. Actually it doesn't have to: X can't see that key.

Anyhow, it shows you the codes for "hot" keys, like Fn+LeftArrow (for volume down). In my case the name for that is XF86AudioLowerVolume and I can use it as such in configuration files.

OTHER TIPS

you can use xmodmap -pke to show the keycode, then you will get something like this :

...
keycode 121 = XF86AudioMute NoSymbol XF86AudioMute
keycode 122 = XF86AudioLowerVolume NoSymbol XF86AudioLowerVolume
keycode 123 = XF86AudioRaiseVolume NoSymbol XF86AudioRaiseVolume
keycode 124 = XF86PowerOff NoSymbol XF86PowerOff
keycode 125 = KP_Equal NoSymbol KP_Equal
keycode 126 = plusminus NoSymbol plusminus
keycode 127 = Pause Break Pause Break
keycode 128 = XF86LaunchA NoSymbol XF86LaunchA
keycode 129 = KP_Decimal KP_Decimal KP_Decimal KP_Decimal
...

You can see that the keycode of XF86AudioLowerVolume is 122, so you can write your code like this :

awful.key({ }, "#122", volwidget.down)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top