summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSpencer Janssen <sjanssen@cse.unl.edu>2007-09-24 11:04:25 +0200
committerSpencer Janssen <sjanssen@cse.unl.edu>2007-09-24 11:04:25 +0200
commit2c74264ba0367a5a1554e517821e63f2c474032d (patch)
tree8f56781819a596a15aee031e2b54eb7ab3e6c608
parent620ea3900da9415e53be43ac842cbec8bb3768cd (diff)
downloadmetatile-2c74264ba0367a5a1554e517821e63f2c474032d.tar
metatile-2c74264ba0367a5a1554e517821e63f2c474032d.zip
Add StackSet.screens
darcs-hash:20070924090425-a5988-8e3e485fa505e61a1ad6bfa6d9c818de74657440
-rw-r--r--StackSet.hs5
1 files changed, 5 insertions, 0 deletions
diff --git a/StackSet.hs b/StackSet.hs
index 9a62bb5..7a4c392 100644
--- a/StackSet.hs
+++ b/StackSet.hs
@@ -19,6 +19,7 @@ module StackSet (
-- * Xinerama operations
-- $xinerama
lookupWorkspace,
+ screens, workspaces,
-- * Operations on the current stack
-- $stackOperations
peek, index, integrate, integrate', differentiate,
@@ -386,6 +387,10 @@ focusWindow w s | Just w == peek s = s
+-- | Get a list of all screens in the StackSet.
+screens :: StackSet i a s sd -> [Screen i a s sd]
+screens s = current s : visible s
+
-- | Get a list of all workspaces in the StackSet.
workspaces :: StackSet i a s sd -> [Workspace i a]
workspaces s = workspace (current s) : map workspace (visible s) ++ hidden s