In `maybe-scroll', if the lines are being scrolled off the window,
authorChris Hanson <org/chris-hanson/cph>
Mon, 1 Apr 1991 19:47:25 +0000 (19:47 +0000)
committerChris Hanson <org/chris-hanson/cph>
Mon, 1 Apr 1991 19:47:25 +0000 (19:47 +0000)
don't forget to deallocate the structures used to describe them.

v7/src/edwin/bufwiu.scm

index 6c0df769d39cb3aa8fac666f7ca568d3cd99b142..3c7150e2ae241d3df7b7d5c578d00c86a424d466 100644 (file)
@@ -1,6 +1,6 @@
 ;;; -*-Scheme-*-
 ;;;
-;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/bufwiu.scm,v 1.17 1991/04/01 10:06:42 cph Exp $
+;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/bufwiu.scm,v 1.18 1991/04/01 19:47:25 cph Exp $
 ;;;
 ;;;    Copyright (c) 1986, 1989-91 Massachusetts Institute of Technology
 ;;;
                            (o3-index start)
                            (fix:- 1 (fix:- (o3-y end) (o3-y start)))
                            (window-y-size window))))
-    (cond ((not y) false)
-         ((fix:= (o3-y start) y) true)
-         ((fix:< (o3-y start) y) (scroll-lines-down window start end y))
-         (else (scroll-lines-up window start end y)))))
+    (cond ((not y)
+          (deallocate-outlines! window (o3-outline start) (o3-outline end))
+          (deallocate-o3! window start)
+          (deallocate-o3! window end)
+          false)
+         ((fix:= (o3-y start) y)
+          true)
+         ((fix:< (o3-y start) y)
+          (scroll-lines-down window start end y))
+         (else
+          (scroll-lines-up window start end y)))))
 \f
 ;;;; Direct Output