Add pavucontrol scratchpad to emacs on Mod4+C+5

Signed-off-by: Collin J. Doering <rekahsoft@gmail.com>
This commit is contained in:
Collin J. Doering 2014-11-28 01:22:53 -05:00 committed by Collin J. Doering
parent ca0ffdc4d5
commit 9e9410bb4e

View File

@ -273,6 +273,9 @@ myGenericKeys =
-- Launch ncmpcpp scratchpad
, ((modm .|. controlMask, xK_4), namedScratchpadAction scratchpads "ncmpcpp-scratch")
-- Launch pavucontrol scratchpad
, ((modm .|. controlMask, xK_5), namedScratchpadAction scratchpads "pavucontrol-scratch")
-- Enable movement and resizing of floating windows
, ((modm, xK_d), withFocused (keysMoveWindow (10,0))) -- move floating window right
, ((modm, xK_a), withFocused (keysMoveWindow (-10,0))) -- move floating window left
@ -413,25 +416,29 @@ scratchpads = [ NS "emacs-scratch" spawnEmacsScratch findEmacsScratch manageEmac
, NS "maintenance-terminal" spawnMaintenanceTerminal findMaintenanceTerminal manageMaintenanceTerminal
, NS "screen-terminal" spawnScreenTerminal findScreenTerminal manageScreenTerminal
, NS "mc-scratch" spawnMcScratch findMcScratch manageMcScratch
, NS "ncmpcpp-scratch" spawnNcmpcppScratch findNcmpcppScratch manageNcmpcppScratch]
, NS "ncmpcpp-scratch" spawnNcmpcppScratch findNcmpcppScratch manageNcmpcppScratch
, NS "pavucontrol-scratch" spawnPavucontrolScratch findPavucontrolScratch managePavucontrolScratch ]
where
findEmacsScratch = title =? "emacs-scratch"
findMaintenanceTerminal = resource =? "scratchpad"
findScreenTerminal = title =? "screen-scratch"
findMcScratch = resource =? "mc-scratch"
findNcmpcppScratch = resource =? "ncmpcpp-scratch"
findPavucontrolScratch = resource =? "pavucontrol"
spawnEmacsScratch = "emacsclient --eval '(make-frame-with-static-name \"emacs-scratch\")'"
spawnMaintenanceTerminal = myTerminal ++ " -name scratchpad -bg black"
spawnScreenTerminal = "emacsclient --eval '(make-frame-with-static-name \"screen-scratch\")'"
spawnMcScratch = myTerminal ++ " -name mc-scratch -pe -tabbedex -e mc"
spawnNcmpcppScratch = myTerminal ++ " -name ncmpcpp-scratch -pe -tabbedex -e ncmpcpp"
spawnPavucontrolScratch = "pavucontrol"
manageEmacsScratch = customFloating $ W.RationalRect 0.10 0.10 0.80 0.80
manageEmacsScratch = doMaxFloat
manageMaintenanceTerminal = customFloating $ W.RationalRect 0 0.66 1 0.34
manageScreenTerminal = customFloating $ W.RationalRect 0 0.01 1 0.99
manageScreenTerminal = doFullFloat
manageMcScratch = customFloating $ W.RationalRect 0.125 0.125 0.75 0.75
manageNcmpcppScratch = customFloating $ W.RationalRect 0.225 0.10 0.55 0.80
managePavucontrolScratch = doMaxFloat
-- manageScreenTerminal = customFloating $ W.RationalRect l t w h
-- where