add 20 number workspaces
This commit is contained in:
parent
00df00f750
commit
ca6600710f
4 changed files with 25 additions and 1 deletions
|
@ -13,6 +13,6 @@ myTertiaryModMask = controlMask -- control
|
|||
|
||||
-- | For XMonad.Util.EZConfig, these can be used
|
||||
myMainModifier, mySecondaryModifier, myTertiaryModifier :: String
|
||||
myMainModifier = "M"
|
||||
myMainModifier = "M4"
|
||||
mySecondaryModifier = "M1"
|
||||
myTertiaryModifier = "C"
|
||||
|
|
20
src/XMonad/Custom/NumberWorkspaces.hs
Normal file
20
src/XMonad/Custom/NumberWorkspaces.hs
Normal file
|
@ -0,0 +1,20 @@
|
|||
module XMonad.Custom.NumberWorkspaces (myNumberWorkspaces, myNumberWorkspacesKeyBindings) where
|
||||
|
||||
import XMonad
|
||||
import XMonad.Custom.Workspaces
|
||||
import XMonad.Custom.Modifiers
|
||||
|
||||
|
||||
myNumberWorkspacesKeyBindings :: [(String, X())]
|
||||
myNumberWorkspacesKeyBindings = concat [
|
||||
makeWorkspacesCombined myMainModifier $ zip digits first10
|
||||
, makeWorkspacesCombined mySecondaryModifier $ zip digits second10
|
||||
]
|
||||
|
||||
myNumberWorkspaces :: [String]
|
||||
myNumberWorkspaces = first10 ++ second10
|
||||
|
||||
digits, first10, second10 :: [String]
|
||||
digits = map show $ [1 .. 9 :: Int] ++ [0 :: Int]
|
||||
first10 = map show $ [1 .. 10 :: Int]
|
||||
second10 = map show $ [11 .. 20 :: Int]
|
|
@ -4,6 +4,9 @@ import XMonad
|
|||
|
||||
import XMonad.Custom.BindingUtils
|
||||
|
||||
makeWorkspacesCombined :: String -> [(String, String)] -> [(String, X())]
|
||||
makeWorkspacesCombined m ws = (\(a,b) -> a ++ b) $ makeWorkspaces m ws
|
||||
|
||||
makeWorkspaces :: String -> [(String, String)] -> ([(String, X ())], [(String, X ())])
|
||||
makeWorkspaces m ws= (makeFocusBindings m ws, makeShiftBindings m ws)
|
||||
|
||||
|
|
|
@ -17,6 +17,7 @@ library
|
|||
XMonad.Custom.Layout
|
||||
XMonad.Custom.Workspaces
|
||||
XMonad.Custom.Modifiers
|
||||
XMonad.Custom.NumberWorkspaces
|
||||
hs-source-dirs: src
|
||||
ghc-options: -funbox-strict-fields -Wall -Wno-unused-do-bind
|
||||
build-depends: base
|
||||
|
|
Loading…
Reference in a new issue