From cae6f2bc049d4b7ed57a7a18a828bc4ea35df4aa Mon Sep 17 00:00:00 2001 From: Arnout Date: Wed, 29 Aug 2012 00:18:46 +0200 Subject: Add '-d' for dockapp mode This makes xmobar work in windowmanagers that support _NET_WM_WINDOW_TYPE_DOCK but not _NET_WM_STRUT, such as Notion --- src/Main.hs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/Main.hs') diff --git a/src/Main.hs b/src/Main.hs index 5ef5db6..aa6ac1d 100644 --- a/src/Main.hs +++ b/src/Main.hs @@ -100,6 +100,7 @@ data Opts = Help | FgColor String | T | B + | D | AlignSep String | Commands String | AddCommand String @@ -117,6 +118,7 @@ options = , Option ['F' ] ["fgcolor" ] (ReqArg FgColor "fg color" ) "The foreground color. Default grey" , Option ['o' ] ["top" ] (NoArg T ) "Place xmobar at the top of the screen" , Option ['b' ] ["bottom" ] (NoArg B ) "Place xmobar at the bottom of the screen" + , Option ['d' ] ["dock" ] (NoArg D ) "Place xmobar in the dock" , Option ['a' ] ["alignsep" ] (ReqArg AlignSep "alignsep" ) "Separators for left, center and right text\nalignment. Default: '}{'" , Option ['s' ] ["sepchar" ] (ReqArg SepChar "char" ) "The character used to separate commands in\nthe output template. Default '%'" , Option ['t' ] ["template" ] (ReqArg Template "template" ) "The output template" @@ -162,6 +164,7 @@ doOpts conf (o:oo) = FgColor s -> doOpts (conf {fgColor = s }) oo T -> doOpts (conf {position = Top }) oo B -> doOpts (conf {position = Bottom}) oo + D -> doOpts (conf {position = Docked}) oo AlignSep s -> doOpts (conf {alignSep = s }) oo SepChar s -> doOpts (conf {sepChar = s }) oo Template s -> doOpts (conf {template = s }) oo -- cgit v1.2.3