--- Config.hs-orig 2007-09-06 03:40:47.000000000 +0000
+++ Config.hs 2007-09-06 03:51:19.000000000 +0000
@@ -29,6 +29,88 @@
import System.Exit
import Graphics.X11.Xlib
+-- Extension-provided imports
+-- For extension Accordion:
+--import XMonadContrib.Accordion
+-- For extension Anneal:
+--import XMonadContrib.Anneal
+-- For extension Circle:
+--import XMonadContrib.Circle
+-- For extension Combo:
+--import XMonadContrib.Combo
+--import XMonadContrib.SimpleStacking
+-- For extension Commands:
+--import XMonadContrib.Commands
+-- For extension CopyWindow:
+--import XMonadContrib.CopyWindow
+-- For extension DeManage:
+--import XMonadContrib.DeManage
+-- For extension Dmenu:
+--import XMonadContrib.Dmenu
+-- For extension DragPane:
+--import XMonadContrib.DragPane
+-- For extension DwmPromote:
+--import XMonadContrib.DwmPromote
+-- For extension DynamicLog:
+--import XMonadContrib.DynamicLog
+-- For extension FindEmptyWorkspace:
+--import XMonadContrib.FindEmptyWorkspace
+-- For extension FlexibleManipulate:
+--import qualified XMonadContrib.FlexibleManipulate as Flex
+-- For extension FlexibleResize:
+--import qualified XMonadContrib.FlexibleResize as Flex
+-- For extension FocusNth:
+--import XMonadContrib.FocusNth
+-- For extension HintedTile:
+--import qualified XMonadContrib.HintedTile
+-- For extension LayoutHints:
+--import XMonadContrib.LayoutHints
+-- For extension LayoutScreens:
+--import XMonadContrib.LayoutScreens
+-- For extension MagicFocus:
+--import XMonadContrib.MagicFocus
+-- For extension Magnifier:
+--import XMonadContrib.Magnifier
+-- For extension Mosaic:
+--import XMonadContrib.Mosaic
+-- For extension NoBorders:
+--import XMonadContrib.NoBorders
+-- For extension Roledex:
+--import XMonadContrib.Roledex
+-- For extension RotSlaves:
+--import XMonadContrib.RotSlaves
+-- For extension RotView:
+--import XMonadContrib.RotView
+-- For extension ShellPrompt:
+--import XMonadContrib.XPrompt
+--import XMonadContrib.ShellPrompt
+-- For extension SimpleDate:
+--import XMonadContrib.SimpleDate
+-- For extension SinkAll:
+--import XMonadContrib.SinkAll
+-- For extension Spiral:
+--import XMonadContrib.Spiral
+-- For extension Square:
+--import XMonadContrib.Square
+-- For extension SshPrompt:
+--import XMonadContrib.XPrompt
+--import XMonadContrib.SshPrompt
+-- For extension Submap:
+--import XMonadContrib.Submap
+-- For extension Tabbed:
+--import XMonadContrib.Tabbed
+-- For extension ThreeColumns:
+--import XMonadContrib.ThreeColumns
+-- For extension TwoPane:
+--import XMonadContrib.TwoPane
+-- For extension Warp:
+--import XMonadContrib.Warp
+-- For extension WorkspaceDir:
+--import XMonadContrib.WorkspaceDir
+-- For extension XMonadPrompt:
+--import XMonadContrib.XPrompt
+--import XMonadContrib.XMonadPrompt
+
--
-- The number of workspaces (virtual screens, or window groups)
--
@@ -91,7 +173,48 @@
-- The default set of tiling algorithms
--
defaultLayouts :: [Layout Window]
-defaultLayouts = [ tiled , mirror tiled , full ]
+defaultLayouts = [ tiled
+ , mirror tiled
+ , full
+
+ -- Extension-provided layouts
+ -- For extension Accordion:
+ -- , accordion
+ -- For extension Combo:
+ -- , simpleStacking $ combo (twoPane 0.03 0.5) [(full,1),(tabbed shrinkText defaultTConf,1)]
+ -- For extension DragPane:
+ -- , dragPane "" (fromRational delta) (fromRational delta)
+ -- For extension HintedTile:
+ -- , XMonadContrib.HintedTile.tall nmaster delta ratio
+ -- For extension LayoutHints:
+ -- , layoutHints tiled
+ -- , layoutHints $ mirror tiled
+ -- For extension MagicFocus:
+ -- , magicFocus tiled
+ -- , magicFocus $ mirror tiled
+ -- For extension Magnifier:
+ -- , magnifier tiled
+ -- , magnifier $ mirror tiled
+ -- For extension Mosaic:
+ -- , mosaic 0.25 0.5 M.empty
+ -- For extension NoBorders:
+ -- -- prepend noBorders to default layouts above to remove their borders, like so:
+ -- , noBorders full
+ -- For extension Roledex:
+ -- , roledex
+ -- For extension Spiral:
+ -- , spiral (1 % 1)
+ -- For extension Tabbed:
+ -- , tabbed shrinkText defaultTConf
+ -- For extension ThreeColumns:
+ -- , threeCol nmaster delta ratio
+ -- For extension TwoPane:
+ -- , twoPane delta (1%2)
+ -- For extension WorkspaceDir:
+ -- -- prepend 'map (workspaceDir "~")' to defaultLayouts definition above,
+ -- -- just before the list, like the following (don't uncomment next line):
+ -- -- defaultLayouts = map (workspaceDir "~") [ tiled, ... ]
+ ]
where
-- default tiling algorithm partitions the screen into two panes
tiled = tall nmaster delta ratio
@@ -159,19 +282,83 @@
, ((modMask .|. shiftMask, xK_q ), io (exitWith ExitSuccess)) -- @@ Quit xmonad
, ((modMask , xK_q ), restart Nothing True) -- @@ Restart xmonad
- ] ++
+ -- Extension-provided key bindings
+ -- For extension Commands:
+ -- , ((modMask .|. controlMask, xK_y), runCommand commands)
+ -- For extension CopyWindow:
+ -- -- comment out default close window binding above if you uncomment this:
+ -- , ((modMask .|. shiftMask, xK_c ), kill1) -- @@ Close the focused window
+ -- For extension DeManage:
+ -- , ((modMask, xK_d ), withFocused demanage)
+ -- For extension DwmPromote:
+ -- , ((modMask, xK_Return), dwmpromote)
+ -- For extension FindEmptyWorkspace:
+ -- , ((modMask, xK_m ), viewEmptyWorkspace)
+ -- , ((modMask .|. shiftMask, xK_m ), tagToEmptyWorkspace)
+ -- For extension LayoutScreens:
+ -- , ((modMask .|. shiftMask, xK_space), layoutScreens 2 (twoPane 0.5 0.5))
+ -- , ((controlMask .|. modMask .|. shiftMask, xK_space), rescreen)
+ -- For extension Mosaic:
+ -- , ((controlMask .|. modMask .|. shiftMask, xK_h), withNamedWindow (sendMessage . tallWindow))
+ -- , ((controlMask .|. modMask .|. shiftMask, xK_l), withNamedWindow (sendMessage . wideWindow))
+ -- , ((modMask .|. shiftMask, xK_h ), withNamedWindow (sendMessage . shrinkWindow))
+ -- , ((modMask .|. shiftMask, xK_l ), withNamedWindow (sendMessage . expandWindow))
+ -- , ((modMask .|. shiftMask, xK_s ), withNamedWindow (sendMessage . squareWindow))
+ -- , ((modMask .|. shiftMask, xK_o ), withNamedWindow (sendMessage . myclearWindow))
+ -- , ((controlMask .|. modMask .|. shiftMask, xK_o ), withNamedWindow (sendMessage . flexibleWindow))
+ -- For extension RotSlaves:
+ -- , ((modMask .|. shiftMask, xK_Tab ), rotSlavesUp)
+ -- For extension RotView:
+ -- , ((modMask .|. shiftMask, xK_Right), rotView True)
+ -- , ((modMask .|. shiftMask, xK_Left), rotView False)
+ -- For extension ShellPrompt:
+ -- , ((modMask .|. controlMask, xK_x), shellPrompt defaultXPConfig)
+ -- For extension SimpleDate:
+ -- , ((modMask, xK_d ), date)
+ -- For extension SinkAll:
+ -- , ((modMask .|. shiftMask, xK_t), sinkAll)
+ -- For extension SshPrompt:
+ -- , ((modMask .|. controlMask, xK_x), xmonadPrompt defaultXPConfig)
+ -- For extension Submap:
+ -- , ((modMask, xK_a), submap . M.fromList $
+ -- [ ((0, xK_n), spawn "mpc next")
+ -- , ((0, xK_p), spawn "mpc prev")
+ -- , ((0, xK_z), spawn "mpc random")
+ -- , ((0, xK_space), spawn "mpc toggle")
+ -- ])
+ -- For extension Warp:
+ -- , ((modMask, xK_z ), warpToWindow (1%2) (1%2)) -- @@ Move pointer to currently focused window
+ -- For extension WorkspaceDir:
+ -- , ((modMask .|. shiftMask, xK_x ), changeDir defaultXPConfig)
+ -- For extension XMonadPrompt:
+ -- , ((modMask .|. controlMask, xK_x), xmonadPrompt defaultXPConfig)
+ ]
+ ++
-- mod-[1..9] @@ Switch to workspace N
-- mod-shift-[1..9] @@ Move client to workspace N
[((m .|. modMask, k), f i)
| (i, k) <- zip workspaces [xK_1 ..]
, (f, m) <- [(view, 0), (shift, shiftMask)]]
-
+ ++
-- mod-{w,e,r} @@ Switch to physical/Xinerama screens 1, 2, or 3
-- mod-shift-{w,e,r} @@ Move client to screen 1, 2, or 3
- ++
[((m .|. modMask, key), screenWorkspace sc >>= flip whenJust f)
| (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]
, (f, m) <- [(windows . W.view, 0), (shift, shiftMask)]]
+ -- Extension-provided key bindings lists
+ -- For extension CopyWindow:
+ -- ++
+ -- -- mod-[1..9] @@ Switch to workspace N
+ -- -- mod-shift-[1..9] @@ Move client to workspace N
+ -- -- mod-control-shift-[1..9] @@ Copy client to workspace N
+ -- [((m .|. modMask, k), f i)
+ -- | (i, k) <- zip workspaces [xK_1 ..]
+ -- , (f, m) <- [(view, 0), (shift, shiftMask), (copy, shiftMask .|. controlMask)]]
+ -- For extension Warp:
+ -- ++
+ -- -- mod-ctrl-{w,e,r} @@ Move mouse pointer to screen 1, 2, or 3
+ -- [((modMask .|. controlMask, key), warpToScreen sc (1%2) (1%2))
+ -- | (key, sc) <- zip [xK_w, xK_e, xK_r] [0..]]
-- |
-- default actions bound to mouse events
@@ -183,4 +370,19 @@
-- mod-button2 @@ Raise the window to the top of the stack
, ((modMask, button2), (\w -> focus w >> swapMaster))
-- mod-button3 @@ Set the window to floating mode and resize by dragging
- , ((modMask, button3), (\w -> focus w >> mouseResizeWindow w)) ]
+ , ((modMask, button3), (\w -> focus w >> mouseResizeWindow w))
+
+ -- Extension-provided mouse bindings
+ -- For extension FlexibleManipulate:
+ -- , ((modMask, button1), (\w -> focus w >> Flex.mouseWindow Flex.linear w))
+ -- For extension FlexibleResize:
+ -- , ((modMask, button3), (\w -> focus w >> Flex.mouseResizeWindow w))
+ ]
+
+-- Extension-provided definitions
+-- For extension Commands:
+-- commands :: [(String, X ())]
+-- commands = defaultCommands
+-- For extension DynamicLog:
+-- -- comment out default logHook definition above if you uncomment this:
+-- logHook = dynamicLog