From: Chris Hanson Date: Fri, 11 Aug 1989 11:28:59 +0000 (+0000) Subject: Use new procedure `integer-round' when computing the buffer position X-Git-Tag: 20090517-FFI~11843 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=9d1fa0a0d1167e43e56af5bc93b6f663fe095214;p=mit-scheme.git Use new procedure `integer-round' when computing the buffer position percentage for the modeline. --- diff --git a/v7/src/edwin/modlin.scm b/v7/src/edwin/modlin.scm index e9acfe76e..54ce2eb95 100644 --- a/v7/src/edwin/modlin.scm +++ b/v7/src/edwin/modlin.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/modlin.scm,v 1.1 1989/08/09 13:40:30 cph Exp $ +;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/modlin.scm,v 1.2 1989/08/11 11:28:59 cph Exp $ ;;; ;;; Copyright (c) 1989 Massachusetts Institute of Technology ;;; @@ -272,11 +272,11 @@ If #F, the normal method is used." (string-pad-left (number->string (min - (round - (* 100 - (let ((start (mark-index (buffer-start buffer)))) - (/ (- (mark-index (window-start-mark window)) start) - (- (mark-index (buffer-end buffer)) start))))) 99)) + (let ((start (mark-index (buffer-start buffer)))) + (integer-round + (* 100 (- (window-start-index window) start)) + (- (mark-index (buffer-end buffer)) start))) + 99)) 2) "%")))) ((#\[ #\])