From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: [ben@redfrontdoor.org: Patch: minor display glitch with show-paren-mode] Date: Fri, 01 Dec 2006 08:37:16 -0500 Message-ID: Reply-To: rms@gnu.org NNTP-Posting-Host: main.gmane.org Content-Type: text/plain; charset=ISO-8859-15 X-Trace: sea.gmane.org 1164980461 12032 80.91.229.2 (1 Dec 2006 13:41:01 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 1 Dec 2006 13:41:01 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 01 14:40:56 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1Gq8d1-0007tv-TQ for ged-emacs-devel@m.gmane.org; Fri, 01 Dec 2006 14:40:36 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gq8d1-0004lq-DY for ged-emacs-devel@m.gmane.org; Fri, 01 Dec 2006 08:40:35 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Gq8Zq-0001Q9-KL for emacs-devel@gnu.org; Fri, 01 Dec 2006 08:37:18 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Gq8Zp-0001Oo-JU for emacs-devel@gnu.org; Fri, 01 Dec 2006 08:37:18 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gq8Zp-0001OY-CL for emacs-devel@gnu.org; Fri, 01 Dec 2006 08:37:17 -0500 Original-Received: from [199.232.76.164] (helo=fencepost.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.52) id 1Gq8Zp-0001HI-CD for emacs-devel@gnu.org; Fri, 01 Dec 2006 08:37:17 -0500 Original-Received: from rms by fencepost.gnu.org with local (Exim 4.52) id 1Gq8Zo-0007n6-9r; Fri, 01 Dec 2006 08:37:16 -0500 Original-To: emacs-devel@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:63192 Archived-At: Would someone please install this, then ack? ------- Start of forwarded message ------- Date: Tue, 28 Nov 2006 11:54:26 +0000 From: Ben North To: emacs-devel@gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Subject: Patch: minor display glitch with show-paren-mode X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=failed version=3.0.4 When using `show-paren-mode', I've noticed a slight problem: suppose you have show-paren-mode turned on, and point is at -!- in the following: (setq a -!-(car b)) Then the opening and closing parens of `(car b)' are both highlighted. Now type a few characters quickly. If you are quick enough, the characters you type are also highlighted, because the overlay which highlights the `(' has not yet had a chance to be moved. The tiny patch below (against CVS HEAD, rev 1.69) makes the two relevant overlays front-advancing, which seems to fix the problem. - --- ORIG/paren.el 2006-11-28 11:14:46.840839000 +0000 +++ NEW/paren.el 2006-11-28 11:16:16.059970000 +0000 @@ -220,7 +220,7 @@ (point)))) (if show-paren-overlay-1 (move-overlay show-paren-overlay-1 from to (current-buffer)) - - (setq show-paren-overlay-1 (make-overlay from to))) + (setq show-paren-overlay-1 (make-overlay from to nil t))) ;; Always set the overlay face, since it varies. (overlay-put show-paren-overlay-1 'priority show-paren-priority) (overlay-put show-paren-overlay-1 'face face))) @@ -243,7 +243,7 @@ (forward-point (- dir)))))) (if show-paren-overlay (move-overlay show-paren-overlay from to (current-buffer)) - - (setq show-paren-overlay (make-overlay from to)))) + (setq show-paren-overlay (make-overlay from to nil t)))) ;; ;; Always set the overlay face, since it varies. (overlay-put show-paren-overlay 'priority show-paren-priority) _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel ------- End of forwarded message -------