diff options
| author | Jose A Ortega Ruiz <jao@gnu.org> | 2010-03-20 03:08:48 +0100 | 
|---|---|---|
| committer | Jose A Ortega Ruiz <jao@gnu.org> | 2010-03-20 03:08:48 +0100 | 
| commit | 384659364b78a5b763aa07e29e767073d303c6e7 (patch) | |
| tree | c79c9caa7dbe93603a4fd409adc7ae11103d50ee /Plugins/Monitors/Common.hs | |
| parent | 01931fdc886896e1700da4a37103e4df0d69e344 (diff) | |
| download | xmobar-384659364b78a5b763aa07e29e767073d303c6e7.tar.gz xmobar-384659364b78a5b763aa07e29e767073d303c6e7.tar.bz2 | |
Bars for DiskIO
Ignore-this: 50ae0b5d07377a8563acdede4dba31cf
darcs-hash:20100320020848-748be-4c1b8f64b056f026328348a3eb8ca6f367544285.gz
Diffstat (limited to 'Plugins/Monitors/Common.hs')
| -rw-r--r-- | Plugins/Monitors/Common.hs | 7 | 
1 files changed, 7 insertions, 0 deletions
| diff --git a/Plugins/Monitors/Common.hs b/Plugins/Monitors/Common.hs index 13f6323..9362fd8 100644 --- a/Plugins/Monitors/Common.hs +++ b/Plugins/Monitors/Common.hs @@ -41,6 +41,7 @@ module Plugins.Monitors.Common (                         , showWithColors'                         , showPercentsWithColors                         , showPercentBar +                       , showLogBar                         , showWithUnits                         , takeDigits                         , showDigits @@ -394,6 +395,12 @@ showPercentBar v x = do    s <- colorizeString v (take len $ cycle bf)    return $ s ++ (take (bw - len) $ cycle bb) +showLogBar :: Float -> Float -> Monitor String +showLogBar f v = do +  h <- fromIntegral `fmap` getConfigValue high +  bw <- fromIntegral `fmap` getConfigValue barWidth +  showPercentBar v $ f + (logBase 10 (v / h)) / bw +  -- $threads  doActionTwiceWithDelay :: Int -> IO [a] -> IO ([a], [a]) | 
