From a63feb2e2a4d995ff6fe23c02bfb2fe7bc581bb5 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Tue, 22 Jul 2003 14:32:14 +0000 Subject: [PATCH] fixed quotient on non-integer original commit: a50482571e1d9ce54aa4c6a7bc07c908a87f1ae4 --- collects/mrlib/private/aligned-pasteboard/alignment.ss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/collects/mrlib/private/aligned-pasteboard/alignment.ss b/collects/mrlib/private/aligned-pasteboard/alignment.ss index 0c09bc92..99843422 100644 --- a/collects/mrlib/private/aligned-pasteboard/alignment.ss +++ b/collects/mrlib/private/aligned-pasteboard/alignment.ss @@ -111,11 +111,11 @@ (cond [(empty? sizes) (values 0 0)] [else - (let ([extra/rect (quotient extra count)] + (let ([extra/rect (quotient (floor extra) count)] [onsize (first sizes)]) (if (> onsize extra/rect) (loop (rest sizes) (- extra onsize) (sub1 count)) - (values extra/rect (modulo extra count))))]))) + (values extra/rect (modulo (floor extra) count))))]))) ;; allocate-evenly/position ((cons/p nonnegative? nonnegative?) positive? (listof abs-rect?) . -> . ;; (listof abs->rect?))