diff options
author | Andrea Rossato <andrea.rossato@unibz.it> | 2007-08-30 16:15:24 +0200 |
---|---|---|
committer | Andrea Rossato <andrea.rossato@unibz.it> | 2007-08-30 16:15:24 +0200 |
commit | f91ce26c3c5c2c4ac71d1c531900c8c64f575993 (patch) | |
tree | 131be8d0d1e7f0a828bca12eccec0e1a6239fe65 | |
parent | d80db0d10ed50bd3eec170f1cc24aefde6e4ebde (diff) | |
download | XMonadContrib-f91ce26c3c5c2c4ac71d1c531900c8c64f575993.tar.gz XMonadContrib-f91ce26c3c5c2c4ac71d1c531900c8c64f575993.tar.xz XMonadContrib-f91ce26c3c5c2c4ac71d1c531900c8c64f575993.zip |
XPrompt: a very long string in the completion list can lead to a division by zero
darcs-hash:20070830141524-32816-beeaa150ea23704c1a92f1ac3d533777fcd331e8.gz
Diffstat (limited to '')
-rw-r--r-- | XPrompt.hs | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -463,7 +463,7 @@ getComplWinDim compl = do let compl_number = length compl max_compl_len = (fi ht `div` 2) + (maximum . map (textWidth fontst) $ compl) - columns = wh `div` (fi max_compl_len) + columns = max 1 $ wh `div` (fi max_compl_len) rem_height = rect_height scr - ht (rows,r) = compl_number `divMod` fi columns needed_rows = max 1 (rows + if r == 0 then 0 else 1) |