module XMonad.Util.Minimize
( RectMap
, Minimized(..)
) where
import XMonad
import qualified XMonad.StackSet as W
import qualified Data.Map as M
type RectMap = M.Map Window (Maybe W.RationalRect)
data Minimized = Minimized
{ Minimized -> RectMap
rectMap :: RectMap
, Minimized -> [Window]
minimizedStack :: [Window]
}
deriving (Minimized -> Minimized -> Bool
(Minimized -> Minimized -> Bool)
-> (Minimized -> Minimized -> Bool) -> Eq Minimized
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Minimized -> Minimized -> Bool
$c/= :: Minimized -> Minimized -> Bool
== :: Minimized -> Minimized -> Bool
$c== :: Minimized -> Minimized -> Bool
Eq, ReadPrec [Minimized]
ReadPrec Minimized
Int -> ReadS Minimized
ReadS [Minimized]
(Int -> ReadS Minimized)
-> ReadS [Minimized]
-> ReadPrec Minimized
-> ReadPrec [Minimized]
-> Read Minimized
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Minimized]
$creadListPrec :: ReadPrec [Minimized]
readPrec :: ReadPrec Minimized
$creadPrec :: ReadPrec Minimized
readList :: ReadS [Minimized]
$creadList :: ReadS [Minimized]
readsPrec :: Int -> ReadS Minimized
$creadsPrec :: Int -> ReadS Minimized
Read, Int -> Minimized -> ShowS
[Minimized] -> ShowS
Minimized -> String
(Int -> Minimized -> ShowS)
-> (Minimized -> String)
-> ([Minimized] -> ShowS)
-> Show Minimized
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Minimized] -> ShowS
$cshowList :: [Minimized] -> ShowS
show :: Minimized -> String
$cshow :: Minimized -> String
showsPrec :: Int -> Minimized -> ShowS
$cshowsPrec :: Int -> Minimized -> ShowS
Show)
instance ExtensionClass Minimized where
initialValue :: Minimized
initialValue = Minimized :: RectMap -> [Window] -> Minimized
Minimized { rectMap :: RectMap
rectMap = RectMap
forall k a. Map k a
M.empty
, minimizedStack :: [Window]
minimizedStack = []
}
extensionType :: Minimized -> StateExtension
extensionType = Minimized -> StateExtension
forall a. (Read a, Show a, ExtensionClass a) => a -> StateExtension
PersistentExtension