From 43d1dc71f9900986168458d3af281453f41df966 Mon Sep 17 00:00:00 2001 From: Unoqwy Date: Fri, 24 Jul 2020 01:53:15 +0200 Subject: Allow font bg to be taller (or smaller) Implemented only for XFT fonts. Adds a new "part" in the fc tag. > Example: foo bar will make the font background as tall as the bar (absolute offset, here set to 0 for both top & bottom) Changes ColorString to ColorInfo, containing both top and bottom offsets. The "colors string" is still in only one string. --- src/Xmobar/X11/Bitmap.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Xmobar/X11/Bitmap.hs') diff --git a/src/Xmobar/X11/Bitmap.hs b/src/Xmobar/X11/Bitmap.hs index e323606..e764384 100644 --- a/src/Xmobar/X11/Bitmap.hs +++ b/src/Xmobar/X11/Bitmap.hs @@ -24,7 +24,7 @@ import System.Directory (doesFileExist) import System.FilePath (()) import System.Mem.Weak ( addFinalizer ) import Xmobar.X11.ColorCache -import Xmobar.X11.Parsers (Widget(..)) +import Xmobar.X11.Parsers (ColorInfo(..), Widget(..)) import Xmobar.X11.Actions (Action) #ifdef XPM @@ -54,7 +54,7 @@ data Bitmap = Bitmap { width :: Dimension } updateCache :: Display -> Window -> Map FilePath Bitmap -> FilePath -> - [[(Widget, String, Int, Maybe [Action])]] -> IO (Map FilePath Bitmap) + [[(Widget, ColorInfo, Int, Maybe [Action])]] -> IO (Map FilePath Bitmap) updateCache dpy win cache iconRoot ps = do let paths = map (\(Icon p, _, _, _) -> p) . concatMap (filter icons) $ ps icons (Icon _, _, _, _) = True -- cgit v1.2.3