From d64969c3fa6dba85430ba38ae48513ec2424004f Mon Sep 17 00:00:00 2001 From: jao Date: Tue, 13 Sep 2022 06:17:17 +0100 Subject: cairo: honouring iconOffset --- src/Xmobar/X11/CairoDraw.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/Xmobar/X11') diff --git a/src/Xmobar/X11/CairoDraw.hs b/src/Xmobar/X11/CairoDraw.hs index c258509..fa11bf4 100644 --- a/src/Xmobar/X11/CairoDraw.hs +++ b/src/Xmobar/X11/CairoDraw.hs @@ -97,11 +97,11 @@ withRenderinfo ctx dctx seg@(Text _, inf, idx, a) = do withRenderinfo _ _ seg@(Hspace w, _, _, _) = do return (seg, \_ _ -> return (), fromIntegral w) -withRenderinfo _ dctx seg@(Icon p, _, idx, _) = do +withRenderinfo _ dctx seg@(Icon p, _, _, _) = do let bm = dcBitmapLookup dctx p wd = maybe 0 (fromIntegral . B.width) bm - ioff = indexedOffset (dcConfig dctx) idx - vpos = dcHeight dctx / 2 - fromIntegral ioff + ioff = iconOffset (dcConfig dctx) + vpos = dcHeight dctx / 2 + fromIntegral ioff draw _ off = dcBitmapDrawer dctx off vpos p return (seg, draw, wd) -- cgit v1.2.3