emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/paren.el,v


From: Chong Yidong
Subject: [Emacs-diffs] Changes to emacs/lisp/paren.el,v
Date: Thu, 19 Apr 2007 17:21:37 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Chong Yidong <cyd>      07/04/19 17:21:37

Index: paren.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/paren.el,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -b -r1.71 -r1.72
--- paren.el    21 Jan 2007 03:53:11 -0000      1.71
+++ paren.el    19 Apr 2007 17:21:37 -0000      1.72
@@ -143,6 +143,7 @@
       (let ((oldpos (point))
            (dir (cond ((eq (syntax-class (syntax-after (1- (point)))) 5) -1)
                        ((eq (syntax-class (syntax-after (point)))      4) 1)))
+           (window-start (window-start))
            pos mismatch face)
        ;;
        ;; Find the other end of the sexp.
@@ -247,7 +248,12 @@
          ;;
          ;; Always set the overlay face, since it varies.
          (overlay-put show-paren-overlay 'priority show-paren-priority)
-         (overlay-put show-paren-overlay 'face face)))
+         (overlay-put show-paren-overlay 'face face))
+       ;; If there are continued lines, the above operations can
+       ;; force redisplay to recenter the window (since there is no
+       ;; way for it to know that the overlay changes to the buffer
+       ;; are harmless).  So reset the window-start.
+       (set-window-start (selected-window) window-start))
     ;; show-paren-mode is nil in this buffer.
     (and show-paren-overlay
         (delete-overlay show-paren-overlay))




reply via email to

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