Skip to content

Commit

Permalink
Merge pull request #536 from TheMC47/add-loggers-reference
Browse files Browse the repository at this point in the history
Documentation tweaks for `X.H.StatusBar(.PP)`
  • Loading branch information
TheMC47 authored May 12, 2021
2 parents a622c08 + 644f993 commit 02d0b79
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
3 changes: 3 additions & 0 deletions XMonad/Hooks/StatusBar.hs
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,9 @@ statusBarPipe cmd xpp = do
-- property, their content will be the same. If you want to use property-based
-- logging with multiple bars, they should read from different properties.
--
-- "XMonad.Util.Loggers" includes loggers that can be bound to specific screens,
-- like 'logCurrentOnScreen', that might be useful with multiple screens.
--
-- Long-time xmonad users will note that the above config is equivalent to
-- the following less robust and more verbose configuration that they might
-- find in their old configs:
Expand Down
9 changes: 5 additions & 4 deletions XMonad/Hooks/StatusBar/PP.hs
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,8 @@ import XMonad.Hooks.UrgencyHook
-- > import XMonad.Hooks.StatusBar.PP
-- >
-- > myPP = def { ppCurrent = xmobarColor "black" "white" }
-- > main = do
-- > mySB <- statusBarProp "xmobar" (pure myPP)
-- > xmonad =<< withEasySB mySB defToggleStrutsKey myConfig
-- > mySB = statusBarProp "xmobar" (pure myPP)
-- > main = xmonad . withEasySB mySB defToggleStrutsKey $ myConfig
--
-- Check "XMonad.Hooks.StatusBar" for more examples and an in depth
-- explanation.
Expand Down Expand Up @@ -101,7 +100,9 @@ data PP = PP { ppCurrent :: WorkspaceId -> String
, ppWsSep :: String
-- ^ separator to use between workspace tags
, ppTitle :: String -> String
-- ^ window title format for the focused window
-- ^ window title format for the focused window. To display
-- the titles of all windows—even unfocused ones—check
-- 'XMonad.Util.Loggers.logTitles'.
, ppTitleSanitize :: String -> String
-- ^ escape / sanitizes input to 'ppTitle'
, ppLayout :: String -> String
Expand Down

0 comments on commit 02d0b79

Please sign in to comment.