summaryrefslogtreecommitdiffstats
path: root/Operations.hs
diff options
context:
space:
mode:
authorDon Stewart <dons@cse.unsw.edu.au>2007-04-05 02:01:00 +0200
committerDon Stewart <dons@cse.unsw.edu.au>2007-04-05 02:01:00 +0200
commitb4f358f9339d77b83a0faceb7892f27f49382e4b (patch)
tree14a9eb375823e501dca3436a8796e3dd622cd11c /Operations.hs
parent533b5fea6d46fefea441c86d54d8adbfb99dd039 (diff)
downloadmetatile-b4f358f9339d77b83a0faceb7892f27f49382e4b.tar
metatile-b4f358f9339d77b83a0faceb7892f27f49382e4b.zip
-Wall police
darcs-hash:20070405000100-9c5c1-aab51f7bfb20248e9a601b7af5107591db48af8c
Diffstat (limited to 'Operations.hs')
-rw-r--r--Operations.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/Operations.hs b/Operations.hs
index 994843b..41a4616 100644
--- a/Operations.hs
+++ b/Operations.hs
@@ -44,7 +44,7 @@ refresh = do
tile :: Rational -> Rectangle -> [Window] -> [(Window, Rectangle)]
tile _ _ [] = []
tile _ d [w] = [(w, d)]
-tile r (Rectangle sx sy sw sh) (w:s)
+tile r (Rectangle sx sy sw sh) (w:s)
= (w, Rectangle sx sy (fromIntegral lw) sh) : zipWith f [sy, sy + rh ..] s
where
lw = floor $ fromIntegral sw * r
@@ -57,8 +57,8 @@ vtile :: Rational -> Rectangle -> [Window] -> [(Window, Rectangle)]
vtile r rect ws = map (\(w, wr) -> (w, flipRect wr)) $ tile r (flipRect rect) ws
flipRect :: Rectangle -> Rectangle
-flipRect (Rectangle { rect_x = x, rect_y = y, rect_width = w, rect_height = h })
- = Rectangle { rect_x = y, rect_y = x, rect_width = h, rect_height = w }
+flipRect (Rectangle { rect_x = rx, rect_y = ry, rect_width = rw, rect_height = rh })
+ = Rectangle { rect_x = ry, rect_y = rx, rect_width = rh, rect_height = rw }
-- | switchLayout. Switch to another layout scheme. Switches the
-- current workspace.