emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/simple.el


From: Kim F . Storm
Subject: [Emacs-diffs] Changes to emacs/lisp/simple.el
Date: Fri, 21 Jan 2005 20:44:57 -0500

Index: emacs/lisp/simple.el
diff -c emacs/lisp/simple.el:1.683 emacs/lisp/simple.el:1.684
*** emacs/lisp/simple.el:1.683  Tue Jan 18 20:50:43 2005
--- emacs/lisp/simple.el        Sat Jan 22 01:44:56 2005
***************
*** 3179,3188 ****
        (or (memq prop buffer-invisibility-spec)
          (assq prop buffer-invisibility-spec)))))
  
  ;; This is the guts of next-line and previous-line.
  ;; Arg says how many lines to move.
  ;; The value is t if we can move the specified number of lines.
! (defun line-move (arg &optional noerror to-end)
    ;; Don't run any point-motion hooks, and disregard intangibility,
    ;; for intermediate positions.
    (let ((inhibit-point-motion-hooks t)
--- 3179,3209 ----
        (or (memq prop buffer-invisibility-spec)
          (assq prop buffer-invisibility-spec)))))
  
+ ;; Perform vertical scrolling of tall images if necessary.
+ (defun line-move (arg &optional noerror to-end)
+   (if auto-window-vscroll
+       (let ((forward (> arg 0))
+           (pvis (pos-visible-in-window-p (window-start) nil t)))
+       (if (and pvis (null (nth 2 pvis))
+                (> (nth (if forward 4 3) pvis) 0))
+           (set-window-vscroll nil
+                               (if forward
+                                   (+ (window-vscroll nil t)
+                                      (min (nth 4 pvis)
+                                           (* (frame-char-height) arg)))
+                                 (max 0
+                                      (- (window-vscroll nil t)
+                                         (min (nth 3 pvis)
+                                              (* (frame-char-height) (- 
arg))))))
+                               t)
+         (set-window-vscroll nil 0)
+         (line-move-1 arg noerror to-end)))
+     (line-move-1 arg noerror to-end)))
+ 
  ;; This is the guts of next-line and previous-line.
  ;; Arg says how many lines to move.
  ;; The value is t if we can move the specified number of lines.
! (defun line-move-1 (arg &optional noerror to-end)
    ;; Don't run any point-motion hooks, and disregard intangibility,
    ;; for intermediate positions.
    (let ((inhibit-point-motion-hooks t)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]