aboutsummaryrefslogtreecommitdiffstats
path: root/XMonad/Layout
diff options
context:
space:
mode:
authordaniel <daniel@wagner-home.com>2009-02-21 23:52:29 +0100
committerdaniel <daniel@wagner-home.com>2009-02-21 23:52:29 +0100
commitff9449a55e44962320aed5462b8d3a7a5e84c564 (patch)
tree9b380595b80b874e89a8ec862e4b9ec998e9b887 /XMonad/Layout
parente3afcccee9f7708d6248f435095a628310d6919d (diff)
downloadXMonadContrib-ff9449a55e44962320aed5462b8d3a7a5e84c564.tar.gz
XMonadContrib-ff9449a55e44962320aed5462b8d3a7a5e84c564.tar.xz
XMonadContrib-ff9449a55e44962320aed5462b8d3a7a5e84c564.zip
IndependentScreens, v0.0
darcs-hash:20090221225229-c98ca-e70f998908ef8106af4c6abf62761750f0118eaa.gz
Diffstat (limited to 'XMonad/Layout')
-rw-r--r--XMonad/Layout/IndependentScreens.hs8
1 files changed, 8 insertions, 0 deletions
diff --git a/XMonad/Layout/IndependentScreens.hs b/XMonad/Layout/IndependentScreens.hs
new file mode 100644
index 0000000..fe86a40
--- /dev/null
+++ b/XMonad/Layout/IndependentScreens.hs
@@ -0,0 +1,8 @@
+module IndependentScreens where
+
+marshall (S sc) ws = show sc ++ '_':ws
+unmarshall = ((S . read) *** drop 1) . break (=='_')
+workspaces' = nub . map (snd . unmarshall) . workspaces
+withScreens n workspaces = [marshall sc ws | ws <- workspaces, sc <- [0..n-1]]
+onScreen f workspace = screen . current >>= f . flip marshall workspace
+countScreens = fmap genericLength $ openDisplay "" >>= getScreenInfo