From a9ff90233d9376a466f0788117fe86ccf7596e59 Mon Sep 17 00:00:00 2001 From: azahi Date: Thu, 16 Aug 2018 17:12:34 +0300 Subject: Release 0.2.1.1 --- src/XMonad/Custom/Bindings.hs | 39 +++++++++++++++++++-------------------- 1 file changed, 19 insertions(+), 20 deletions(-) (limited to 'src/XMonad/Custom/Bindings.hs') diff --git a/src/XMonad/Custom/Bindings.hs b/src/XMonad/Custom/Bindings.hs index 9192f7e..19eaa2a 100644 --- a/src/XMonad/Custom/Bindings.hs +++ b/src/XMonad/Custom/Bindings.hs @@ -64,7 +64,7 @@ import XMonad.Util.XSelection showKeyBindings :: [((KeyMask, KeySym), NamedAction)] -> NamedAction showKeyBindings a = addName "Show Keybindings" $ io $ do - p <- spawnPipe "/usr/bin/zenity --text-info" -- TOOD Find an application that doesn't rely on any toolkits + p <- spawnPipe "zenity --text-info" -- TOOD Find an application that doesn't rely on any toolkits hPutStr p $ unlines $ showKm a hClose p return () @@ -114,8 +114,7 @@ keyBindings c = let subKeys s ks = subtitle s:mkNamedKeymap c ks in subKeys "System" - [ ("M-q" , addName "Restart XMonad" $ spawn "/usr/bin/xmonad --restart") - , ("M-C-q" , addName "Recompile & restart XMonad" $ spawn "/usr/bin/xmonad --recompile && /usr/bin/xmonad --restart") + [ ("M-q" , addName "Restart XMonad" $ spawn "xmonad-ng --restart") , ("M-S-q" , addName "Quit XMonad" $ confirmPrompt hotPromptTheme "Quit XMonad?" $ io exitSuccess) , ("M-x" , addName "Shell prompt" $ shellPrompt promptTheme) , ("M-o" , addName "Goto W prompt" $ windowPrompt promptTheme Goto allWindows) @@ -137,7 +136,7 @@ keyBindings c = \xcast.sh --webm") , ("M-S-" , addName "Start recording screen as gif" $ spawn "~/.xmonad/bin/\ \xcast.sh --gif") - , ("M-C-" , addName "Stop recording" $ spawn "/usr/bin/pkill ffmpeg") + , ("M-C-" , addName "Stop recording" $ spawn "pkill ffmpeg") , ("M-C-c" , addName "Toggle compton on/off" $ spawn "~/.xmonad/bin/\ \toggle-compton.sh") , ("M-C-r" , addName "Toggle redshift on/off" $ spawn "~/.xmonad/bin/\ @@ -153,11 +152,24 @@ keyBindings c = , ("" , addName "ALSA: Lower volume" $ void $ lowerVolume 5) , ("" , addName "ALSA: Raise volume" $ void $ raiseVolume 5) , ("" , addName "MPD: Play/pause" $ spawn "~/.xmonad/bin/mpc-play-pause.sh") - , ("" , addName "MPD: Stop" $ spawn "/usr/bin/mpc --no-status stop") - , ("" , addName "MPD: Previos track" $ spawn "/usr/bin/mpc --no-status prev") - , ("" , addName "MPD: Next track" $ spawn "/usr/bin/mpc --no-status next") + , ("" , addName "MPD: Stop" $ spawn "mpc --no-status stop") + , ("" , addName "MPD: Previos track" $ spawn "mpc --no-status prev") + , ("" , addName "MPD: Next track" $ spawn "mpc --no-status next") ] ^++^ + subKeys "Workspaces & Projects" + ( [ ("M-w" , addName "Switch to project" $ switchProjectPrompt promptTheme) + , ("M-S-w" , addName "Shift to project" $ shiftToProjectPrompt promptTheme) + , ("M-," , addName "Next non-empty WS" nextNonEmptyWS) + , ("M-." , addName "Previous non-empty WS" prevNonEmptyWS) + , ("M-i" , addName "Toggle last WS" $ toggleWS' ["NSP"]) + , ("M-`" , addName "WS prompt" $ workspacePrompt promptTheme $ windows . S.shift) + ] + ++ zipM "M-" "View WS" wsKeys [0 ..] (withNthWorkspace S.greedyView) + ++ zipM "M-S-" "Move W to WS" wsKeys [0 ..] (withNthWorkspace S.shift) + ++ zipM "M-C-S-" "Copy W to WS" wsKeys [0 ..] (withNthWorkspace copy) + ) + ^++^ subKeys "Spawnables" [ ("M-" , addName "Terminal" $ spawn (CM.term CM.customApplications)) , ("M-b" , addName "Browser" $ spawn (CM.browser CM.customApplications)) @@ -196,19 +208,6 @@ keyBindings c = ++ zipM' "M-C-" "Swap W to screen" arrowKeys directions screenSwap True ) ^++^ - subKeys "Workspaces & Projects" - ( [ ("M-w" , addName "Switch to project" $ switchProjectPrompt promptTheme) - , ("M-S-w" , addName "Shift to project" $ shiftToProjectPrompt promptTheme) - , ("M-," , addName "Next non-empty WS" nextNonEmptyWS) - , ("M-." , addName "Previous non-empty WS" prevNonEmptyWS) - , ("M-i" , addName "Toggle last WS" $ toggleWS' ["NSP"]) - , ("M-`" , addName "WS prompt" $ workspacePrompt promptTheme $ windows . S.shift) - ] - ++ zipM "M-" "View WS" wsKeys [0 ..] (withNthWorkspace S.greedyView) - ++ zipM "M-S-" "Move W to WS" wsKeys [0 ..] (withNthWorkspace S.shift) - ++ zipM "M-C-S-" "Copy W to WS" wsKeys [0 ..] (withNthWorkspace copy) - ) - ^++^ subKeys "Layout Management" [ ("M-" , addName "Cycle layouts" $ sendMessage NextLayout) , ("M-C-" , addName "Cycle sublayouts" $ toSubl NextLayout) -- cgit 1.4.1