diff options
author | Spencer Janssen <sjanssen@cse.unl.edu> | 2007-06-29 23:39:17 +0200 |
---|---|---|
committer | Spencer Janssen <sjanssen@cse.unl.edu> | 2007-06-29 23:39:17 +0200 |
commit | ccc8377b43ca258b30d37402bdcf881e9acab7d9 (patch) | |
tree | d938fa4d290b5d324229fdf915b36ae6b86d6d45 /XMonad.hs | |
parent | 2ea97e792f3584981ea565ec960d75a0568665f5 (diff) | |
download | metatile-ccc8377b43ca258b30d37402bdcf881e9acab7d9.tar metatile-ccc8377b43ca258b30d37402bdcf881e9acab7d9.zip |
Move screen details into StackSet
darcs-hash:20070629213917-a5988-3ad31d8f028efcec41c9c4805c01c2d42c0009b2
Diffstat (limited to 'XMonad.hs')
-rw-r--r-- | XMonad.hs | 12 |
1 files changed, 8 insertions, 4 deletions
@@ -15,7 +15,7 @@ ----------------------------------------------------------------------------- module XMonad ( - X, WindowSet, WorkspaceId(..), ScreenId(..), XState(..), XConf(..), Layout(..), + X, WindowSet, WorkspaceId(..), ScreenId(..), ScreenDetail(..), XState(..), XConf(..), Layout(..), Typeable, Message, SomeMessage(..), fromMessage, runLayout, runX, catchX, io, catchIO, withDisplay, withWindowSet, isRoot, spawn, restart, trace, whenJust, whenX, atom_WM_STATE, atom_WM_PROTOCOLS, atom_WM_DELETE_WINDOW @@ -30,6 +30,8 @@ import System.Posix.Process (executeFile, forkProcess, getProcessStatus, createS import System.Exit import System.Environment import Graphics.X11.Xlib +-- for Read instance +import Graphics.X11.Xlib.Extras () import Data.Typeable import qualified Data.Map as M @@ -39,8 +41,6 @@ import qualified Data.Set as S -- Just the display, width, height and a window list data XState = XState { windowset :: !WindowSet -- ^ workspace list - , xineScreens :: ![Rectangle] -- ^ dimensions of each screen - , statusGaps :: ![(Int,Int,Int,Int)] -- ^ width of status bar on each screen , mapped :: !(S.Set Window) -- ^ the Set of mapped windows , waitingUnmap :: !(M.Map Window Int) -- ^ the number of expected UnmapEvents , layouts :: !(M.Map WorkspaceId (Layout Window, [Layout Window])) } @@ -51,7 +51,7 @@ data XConf = XConf , normalBorder :: !Pixel -- ^ border color of unfocused windows , focusedBorder :: !Pixel } -- ^ border color of the focused window -type WindowSet = StackSet WorkspaceId Window ScreenId +type WindowSet = StackSet WorkspaceId Window ScreenId ScreenDetail -- | Virtual workspace indicies newtype WorkspaceId = W Int deriving (Eq,Ord,Show,Read,Enum,Num,Integral,Real) @@ -59,6 +59,10 @@ newtype WorkspaceId = W Int deriving (Eq,Ord,Show,Read,Enum,Num,Integral,Real) -- | Physical screen indicies newtype ScreenId = S Int deriving (Eq,Ord,Show,Read,Enum,Num,Integral,Real) +data ScreenDetail = SD { screenRect :: !Rectangle + , statusGap :: !(Int,Int,Int,Int) -- ^ width of status bar on the screen + } deriving (Eq,Show, Read) + ------------------------------------------------------------------------ -- | The X monad, a StateT transformer over IO encapsulating the window |