summaryrefslogtreecommitdiffhomepage
path: root/src/Xmobar/X11/Draw.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Xmobar/X11/Draw.hs')
-rw-r--r--src/Xmobar/X11/Draw.hs10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/Xmobar/X11/Draw.hs b/src/Xmobar/X11/Draw.hs
index 853ed03..5139aa9 100644
--- a/src/Xmobar/X11/Draw.hs
+++ b/src/Xmobar/X11/Draw.hs
@@ -27,12 +27,9 @@ import Graphics.X11.Xlib hiding (Segment)
import Xmobar.Run.Parsers (Segment)
import Xmobar.X11.Types
-#if defined(XFT) || defined(CAIRO)
+#ifdef CAIRO
import Xmobar.Config.Types
import Xmobar.X11.XRender (drawBackground)
-#endif
-
-#ifdef CAIRO
import Xmobar.X11.CairoDraw
#else
import Xmobar.X11.XlibDraw
@@ -50,14 +47,11 @@ drawInWin segments = do
gc <- liftIO $ createGC d w
liftIO $ setGraphicsExposures d gc False
-#if defined(XFT) || defined(CAIRO)
+#ifdef CAIRO
let cconf = config xconf
alph = alpha cconf
when (alph < 255)
(liftIO $ drawBackground d p (bgColor cconf) alph (Rectangle 0 0 wid ht))
-#endif
-
-#ifdef CAIRO
res <- drawInPixmap gc p segments
#else
res <- updateActions (rect xconf) segments