Add keybindings for numpad

This commit is contained in:
Martin Potier 2023-08-04 10:57:48 +03:00
parent 6070398070
commit 8b162c7c31
No known key found for this signature in database
GPG key ID: D4DD957DBA4AD89E

View file

@ -31,6 +31,9 @@ import qualified XMonad.StackSet as W
-- Custom (in libs) -- Custom (in libs)
import Password (passPrompt) import Password (passPrompt)
lockScreenCmd =
spawn "/etc/profiles/per-user/e/bin/mpc pause; /run/current-system/sw/bin/xset s activate"
modify :: XConfig l -> XConfig l modify :: XConfig l -> XConfig l
modify conf = conf modify conf = conf
{ modMask = mod4Mask -- Use the "Win" key for the mod key { modMask = mod4Mask -- Use the "Win" key for the mod key
@ -43,6 +46,15 @@ modify conf = conf
, ("<XF86AudioPlay>", spawn "/etc/profiles/per-user/e/bin/mpc toggle") , ("<XF86AudioPlay>", spawn "/etc/profiles/per-user/e/bin/mpc toggle")
, ("<XF86AudioNext>", spawn "/etc/profiles/per-user/e/bin/mpc next") , ("<XF86AudioNext>", spawn "/etc/profiles/per-user/e/bin/mpc next")
, ("<XF86AudioPrev>", spawn "/etc/profiles/per-user/e/bin/mpc prev") , ("<XF86AudioPrev>", spawn "/etc/profiles/per-user/e/bin/mpc prev")
-- KP_1 -> KP_6 macros
, ("<XF86Tools>", viewProject "sound")
, ("<XF86Launch5>", viewProject "frs")
, ("<XF86Launch6>", viewProject "chat")
, ("<XF86Launch7>", viewProject "isengard")
, ("<XF86Launch8>", viewProject "moria")
, ("<XF86Launch9>", viewProject "fre")
-- KP_Delete
, ("Cancel", lockScreenCmd)
, ("M-<Down>", windows W.focusDown) , ("M-<Down>", windows W.focusDown)
, ("M-<Esc>", sendMessage (Toggle "Full")) , ("M-<Esc>", sendMessage (Toggle "Full"))
, ("M-$", sendMessage (Toggle "Full")) , ("M-$", sendMessage (Toggle "Full"))
@ -52,7 +64,7 @@ modify conf = conf
, ("M-<Right>", nextWS) , ("M-<Right>", nextWS)
, ("M-<Tab>", toggleWS' ["NSP"]) , ("M-<Tab>", toggleWS' ["NSP"])
, ("M-<Up>", windows W.focusUp) , ("M-<Up>", windows W.focusUp)
, ("M-S-<Delete>", spawn "/etc/profiles/per-user/e/bin/mpc pause; /run/current-system/sw/bin/xset s activate") , ("M-S-<Delete>", lockScreenCmd)
, ("M-S-<Left>", shiftToPrev >> prevWS) , ("M-S-<Left>", shiftToPrev >> prevWS)
, ("M-S-<Right>", shiftToNext >> nextWS) , ("M-S-<Right>", shiftToNext >> nextWS)
, ("M-s s", spawn "/etc/profiles/per-user/e/bin/flameshot gui") , ("M-s s", spawn "/etc/profiles/per-user/e/bin/flameshot gui")