aboutsummaryrefslogtreecommitdiff
path: root/src/Internal/LayoutDraw.hs
diff options
context:
space:
mode:
authorJosh Rahm <rahm@google.com>2021-11-02 00:41:08 -0600
committerJosh Rahm <joshuarahm@gmail.com>2022-10-09 12:19:45 -0600
commit17fe2b579f096ab4b3daacaca2db2d5443fd5e92 (patch)
tree7d8eb4f25a8d53f2f33508e29e918ecf4f416156 /src/Internal/LayoutDraw.hs
parent8475c103767344bd9c6a47052794cc14675d24cd (diff)
downloadrde-17fe2b579f096ab4b3daacaca2db2d5443fd5e92.tar.gz
rde-17fe2b579f096ab4b3daacaca2db2d5443fd5e92.tar.bz2
rde-17fe2b579f096ab4b3daacaca2db2d5443fd5e92.zip
Big powerpill added to my XMonad and XMobar.
Diffstat (limited to 'src/Internal/LayoutDraw.hs')
-rw-r--r--src/Internal/LayoutDraw.hs19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/Internal/LayoutDraw.hs b/src/Internal/LayoutDraw.hs
index 7dc2087..4bb069a 100644
--- a/src/Internal/LayoutDraw.hs
+++ b/src/Internal/LayoutDraw.hs
@@ -54,13 +54,13 @@ drawPng l = do
-- (0.9, 0.9, 1.0),
-- (0.8, 0.8, 1.0),
-- (0.7, 0.7, 1.0),
- (0.6, 0.6, 0.8),
- (0.5, 0.5, 0.8),
- (0.4, 0.4, 0.8),
- (0.3, 0.3, 0.8),
- (0.2, 0.2, 0.8),
- (0.1, 0.1, 0.8),
- (0.0, 0.0, 0.8)
+ (0.8, 0.6, 0.6),
+ (0.8, 0.5, 0.5),
+ (0.8, 0.4, 0.4),
+ (0.8, 0.3, 0.3),
+ (0.8, 0.2, 0.2),
+ (0.8, 0.1, 0.1),
+ (0.8, 0.0, 0.0)
]
exists <- liftIO $ doesFileExist filepathXpm
@@ -71,7 +71,7 @@ drawPng l = do
setLineCap LineCapButt
setLineJoin LineJoinMiter
- forM_ (reverse $ zip (map (second padR) rects) colors) $
+ forM_ (reverse $ zip (map (second extraPad) rects) colors) $
\((wind, Rectangle x y w h), (r, g, b)) -> do
setSourceRGBA r g b 1
@@ -93,7 +93,8 @@ drawPng l = do
return filepathXpm
where
- padR = id
+ extraPad (Rectangle x y w h) =
+ Rectangle (x + 100) (y + 100) (w - 100) (h - 100)
-- padR (Rectangle x y w h) =
-- Rectangle x y (max 1 $ w - 120) (max 1 $ h - 120)