From 5edbb125958df0adadd354fae48877d36086abd5 Mon Sep 17 00:00:00 2001 From: David Roundy Date: Mon, 20 Aug 2007 13:38:13 +0200 Subject: make Contrib use WorkspaceId darcs-hash:20070820113813-72aca-30984283cb9c04185fde9c89253af00e16912c10.gz --- DynamicLog.hs | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'DynamicLog.hs') diff --git a/DynamicLog.hs b/DynamicLog.hs index 7447f43..4bcfec8 100644 --- a/DynamicLog.hs +++ b/DynamicLog.hs @@ -65,9 +65,9 @@ pprWindowSet s = concatMap fmt $ sortBy (comparing S.tag) where this = S.tag (S.workspace (S.current s)) visibles = map (S.tag . S.workspace) (S.visible s) - fmt w | S.tag w == this = "[" ++ pprTag w ++ "]" - | S.tag w `elem` visibles = "<" ++ pprTag w ++ ">" - | isJust (S.stack w) = " " ++ pprTag w ++ " " + fmt w | S.tag w == this = "[" ++ S.tag w ++ "]" + | S.tag w `elem` visibles = "<" ++ S.tag w ++ ">" + | isJust (S.stack w) = " " ++ S.tag w ++ " " | otherwise = "" -- | @@ -83,11 +83,7 @@ dynamicLogXinerama = withWindowSet $ io . putStrLn . pprWindowSetXinerama pprWindowSetXinerama :: WindowSet -> String pprWindowSetXinerama ws = "[" ++ unwords onscreen ++ "] " ++ unwords offscreen - where onscreen = map (pprTag . S.workspace) + where onscreen = map (S.tag . S.workspace) . sortBy (comparing S.screen) $ S.current ws : S.visible ws - offscreen = map pprTag . filter (isJust . S.stack) + offscreen = map S.tag . filter (isJust . S.stack) . sortBy (comparing S.tag) $ S.hidden ws - --- util functions -pprTag :: Integral i => S.Workspace i a -> String -pprTag = show . (+(1::Int)) . fromIntegral . S.tag -- cgit v1.2.3