aboutsummaryrefslogtreecommitdiffstats
path: root/XMonad/Actions/GridSelect.hs
diff options
context:
space:
mode:
authorAdam Vogt <vogt.adam@gmail.com>2009-07-05 22:12:05 +0200
committerAdam Vogt <vogt.adam@gmail.com>2009-07-05 22:12:05 +0200
commit595021f9a0b70483a7e26337bab8b2da68cd4757 (patch)
tree3800d5ee909f007a77205f5484a732d12a988675 /XMonad/Actions/GridSelect.hs
parent29c6f55759fc8a080c7dddf7094ec0e3a896df39 (diff)
downloadXMonadContrib-595021f9a0b70483a7e26337bab8b2da68cd4757.tar.gz
XMonadContrib-595021f9a0b70483a7e26337bab8b2da68cd4757.tar.xz
XMonadContrib-595021f9a0b70483a7e26337bab8b2da68cd4757.zip
Remove trailing whitespace from many modules
Ignore-this: 1e28ff0974578d329bd3d593c1a5125e darcs-hash:20090705201205-1499c-581bd0bb43ab6096eccded6edbd54a7a2007b0d9.gz
Diffstat (limited to '')
-rw-r--r--XMonad/Actions/GridSelect.hs10
1 files changed, 5 insertions, 5 deletions
diff --git a/XMonad/Actions/GridSelect.hs b/XMonad/Actions/GridSelect.hs
index 064d041..ffde014 100644
--- a/XMonad/Actions/GridSelect.hs
+++ b/XMonad/Actions/GridSelect.hs
@@ -230,7 +230,7 @@ hsv2rgb (h,s,v) =
-- | Default colorizer for Strings
defaultColorizer :: String -> Bool -> X (String, String)
-defaultColorizer s active =
+defaultColorizer s active =
let seed x = toInteger (sum $ map ((*x).fromEnum) s) :: Integer
(r,g,b) = hsv2rgb ((seed 83) `mod` 360,
(fromInteger ((seed 191) `mod` 1000))/2500+0.4,
@@ -254,17 +254,17 @@ colorRangeFromClassName :: (Word8, Word8, Word8) -- ^ Beginning of the color ran
-> (Word8, Word8, Word8) -- ^ Inactive text color
-> (Word8, Word8, Word8) -- ^ Active text color
-> Window -> Bool -> X (String, String)
-colorRangeFromClassName startC endC activeC inactiveT activeT w active =
+colorRangeFromClassName startC endC activeC inactiveT activeT w active =
do classname <- runQuery className w
- if active
+ if active
then return (rgbToHex activeC, rgbToHex activeT)
- else return (rgbToHex $ mix startC endC
+ else return (rgbToHex $ mix startC endC
$ stringToRatio classname, rgbToHex inactiveT)
where rgbToHex :: (Word8, Word8, Word8) -> String
rgbToHex (r, g, b) = '#':twodigitHex r
++twodigitHex g++twodigitHex b
--- | Creates a mix of two colors according to a ratio
+-- | Creates a mix of two colors according to a ratio
-- (1 -> first color, 0 -> second color).
mix :: (Word8, Word8, Word8) -> (Word8, Word8, Word8)
-> Double -> (Word8, Word8, Word8)