diff options
author | Don Stewart <dons@cse.unsw.edu.au> | 2007-05-27 17:08:05 +0200 |
---|---|---|
committer | Don Stewart <dons@cse.unsw.edu.au> | 2007-05-27 17:08:05 +0200 |
commit | 659411687c04f6e07a39a92717ec6dc0895b9918 (patch) | |
tree | 88d093da471c321d8cf9bf31bd9d9448858eb302 | |
parent | d3fd8432032209ca581886cc225524b02474d14d (diff) | |
download | metatile-659411687c04f6e07a39a92717ec6dc0895b9918.tar metatile-659411687c04f6e07a39a92717ec6dc0895b9918.zip |
only set gap on current physical screen
darcs-hash:20070527150805-9c5c1-6774cc60f8f39b8ac16c465d7ab0d2884a984fc1
-rw-r--r-- | Operations.hs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/Operations.hs b/Operations.hs index ef17095..741866a 100644 --- a/Operations.hs +++ b/Operations.hs @@ -137,10 +137,13 @@ refresh = do let n = W.tag (W.workspace w) this = W.view n ws Just l = fmap fst $ M.lookup n fls - Rectangle sx sy sw sh = genericIndex xinesc (W.screen w) - -- now tile the windows on this workspace - rs <- doLayout l (Rectangle sx (sy + fromIntegral gap) - sw (sh - fromIntegral gap)) (W.index this) + r@(Rectangle sx sy sw sh) = genericIndex xinesc (W.screen w) + + -- now tile the windows on this workspace, and set gap maybe on current + rs <- doLayout l (if w == W.current ws + then Rectangle sx (sy + fromIntegral gap) + sw (sh - fromIntegral gap) + else r) (W.index this) mapM_ (\(win,rect) -> io (tileWindow d win rect)) rs -- and raise the focused window if there is one. |