aboutsummaryrefslogtreecommitdiffstats
path: root/XMonad/Layout/SimpleDecoration.hs
diff options
context:
space:
mode:
Diffstat (limited to 'XMonad/Layout/SimpleDecoration.hs')
-rw-r--r--XMonad/Layout/SimpleDecoration.hs19
1 files changed, 8 insertions, 11 deletions
diff --git a/XMonad/Layout/SimpleDecoration.hs b/XMonad/Layout/SimpleDecoration.hs
index d47d9be..fbff81e 100644
--- a/XMonad/Layout/SimpleDecoration.hs
+++ b/XMonad/Layout/SimpleDecoration.hs
@@ -17,8 +17,8 @@ module XMonad.Layout.SimpleDecoration
( -- * Usage:
-- $usage
simpleDeco
- , DeConfig (..)
- , SimpleDecoration (..), defaultSimpleConfig
+ , Theme (..)
+ , SimpleDecoration (..)
, shrinkText, CustomShrink(CustomShrink)
, Shrinker(..)
) where
@@ -35,7 +35,7 @@ import XMonad.Layout.Decoration
-- Then edit your @layoutHook@ by adding the SimpleDecoration decoration to
-- your layout:
--
--- > myL = simpleDeco shrinkText defaultSimpleConfig (layoutHook defaultConfig)
+-- > myL = simpleDeco shrinkText defaultTheme (layoutHook defaultConfig)
-- > main = xmonad defaultConfig { layoutHook = myL }
--
-- For more detailed instructions on editing the layoutHook see:
@@ -44,20 +44,17 @@ import XMonad.Layout.Decoration
--
-- You can also edit the default configuration options.
--
--- > mySDConfig = defaultSimpleConfig { inactiveBorderColor = "red"
+-- > mySDConfig = defaultTheme { inactiveBorderColor = "red"
-- > , inactiveTextColor = "red"}
--
-- and
--
--- > myL = dwmStyle shrinkText mySDConfig (layoutHook defaultConfig)
+-- > myL = dwmStyle shrinkText mySDConfig (layoutHook defaultTheme)
-- | Add simple decorations to windows of a layout.
-simpleDeco :: Shrinker s => s -> DeConfig SimpleDecoration a
+simpleDeco :: Shrinker s => s -> Theme
-> l a -> ModifiedLayout (Decoration SimpleDecoration s) l a
-simpleDeco s c = decoration s c
-
-defaultSimpleConfig :: DeConfig SimpleDecoration a
-defaultSimpleConfig = mkDefaultDeConfig $ Simple True
+simpleDeco s c = decoration s c $ Simple True
data SimpleDecoration a = Simple Bool deriving (Show, Read)
@@ -67,4 +64,4 @@ instance DecorationStyle SimpleDecoration a where
if b then Rectangle x (y + fi dh) w (h - dh) else r
pureDecoration (Simple b) wh ht _ _ _ (_,Rectangle x y wid _) =
if b then Just $ Rectangle x y nwh ht else Just $ Rectangle x (y - fi ht) nwh ht
- where nwh = min wid wh \ No newline at end of file
+ where nwh = min wid wh