;;; -*-Scheme-*-
;;;
-;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/bufwfs.scm,v 1.14 1991/04/03 03:59:52 cph Exp $
+;;; $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/bufwfs.scm,v 1.15 1991/07/08 22:34:05 cph Exp $
;;;
;;; Copyright (c) 1986, 1989-91 Massachusetts Institute of Technology
;;;
(%scroll-lines-up window start end new-start-y)
(let ((start-outline (o3-outline start))
(amount (fix:- (o3-y start) new-start-y)))
- (if (or (fix:<= (fix:- (o3-y end) amount) 0)
- (and (fix:> (o3-y end) (window-y-size window))
- (eq? start-outline (o3-outline end))))
+ (if (if (fix:> (o3-y end) (window-y-size window))
+ (let ((outline (o3-outline end)))
+ (or (eq? start-outline outline)
+ (fix:<= (fix:- (o3-y end) (outline-y-size outline))
+ amount)))
+ (fix:<= (o3-y end) amount))
(begin
(deallocate-outlines! window start-outline (o3-outline end))
(deallocate-o3! window start)