0

So far I've tried:

awful.key({ modkey }, "",    function () awful.screen.focused().mypromptbox:run() end)
awful.key({ modkey, modekey }, "",    function () awful.screen.focused().mypromptbox:run() end)
-- 133 is the modkey identifier for my keyboard
awful.key({ modkey }, "#133",    function () awful.screen.focused().mypromptbox:run() end)
awful.key({ }, "#133",    function () awful.screen.focused().mypromptbox:run() end)

None of them worked as intended(running the prompt).

3 Answers3

1

For me this worked

wm.key({          }, "#133",      cheat_sheet_popup.show_help,
                    {description="Cheat-sheet (this page)", group="Global"}),
Peter
  • 748
  • 6
  • 20
0

modkey is a modifier and not a key. Other keys activate modifiers.

Try running xev in a terminal and pressing some keys. It shows, among other things, the name of the key. When I use this and press the left windows key, I get:

KeyPress event, serial 34, synthetic NO, window 0x2a00001,
    root 0x761, subw 0x0, time 65120999, (601,803), root:(2523,842),
    state 0x0, keycode 133 (keysym 0xffeb, Super_L), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

This shows that the key is called Super_L.

However, I am not sure that binding a key binding to this key does what you want it to do. I think (but am not sure) that it will no longer act as a modifier if you use it in a key binding.

Edit:

-- 133 is the modkey identifier for my keyboard

Hm. This should work. Now I doubt that using Super_L would work and I don't know what is going on...

Uli Schlachter
  • 9,337
  • 1
  • 23
  • 39
0

check out ksuperkey or xcape. Both these programs do the same thing and let you simulate one key press with another. As such, you can bind Super_L t sumulate Alt_L+F1, and then set awesomewm to bind Alt_L+F1 to anything you want. I use this to pull up rofi with super

caleb
  • 1