From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stephen Berman Newsgroups: gmane.emacs.bugs,gmane.emacs.pretest.bugs Subject: bug#4854: 23.1.50; before-string overlay and show-paren-mode Date: Mon, 02 Nov 2009 15:49:55 +0100 Message-ID: <87fx8x0yng.fsf@escher.local.home> Reply-To: Stephen Berman , 4854@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1257176947 23571 80.91.229.12 (2 Nov 2009 15:49:07 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 2 Nov 2009 15:49:07 +0000 (UTC) To: emacs-pretest-bug@gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 02 16:49:00 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1N4z9P-0003Lt-7g for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Nov 2009 16:48:59 +0100 Original-Received: from localhost ([127.0.0.1]:59276 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N4z9O-00036N-QP for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Nov 2009 10:48:58 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N4z7s-0001cl-88 for bug-gnu-emacs@gnu.org; Mon, 02 Nov 2009 10:47:24 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N4z7n-0001XE-6r for bug-gnu-emacs@gnu.org; Mon, 02 Nov 2009 10:47:23 -0500 Original-Received: from [199.232.76.173] (port=53707 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N4z7m-0001WL-DF for bug-gnu-emacs@gnu.org; Mon, 02 Nov 2009 10:47:18 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:50368) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1N4z7l-0007Ug-PG for bug-gnu-emacs@gnu.org; Mon, 02 Nov 2009 10:47:18 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA2FlFgO000550; Mon, 2 Nov 2009 07:47:15 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id nA2FZ41L031662; Mon, 2 Nov 2009 07:35:04 -0800 Resent-Date: Mon, 2 Nov 2009 07:35:04 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Stephen Berman Original-Sender: steve@escher.local.home Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Mon, 02 Nov 2009 15:35:04 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: report 4854 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.125717573231098 (code B ref -1); Mon, 02 Nov 2009 15:35:04 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 2 Nov 2009 15:28:52 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nA2FSoZn031085 for ; Mon, 2 Nov 2009 07:28:51 -0800 Original-Received: from mail.gnu.org ([199.232.76.166]:43968 helo=mx10.gnu.org) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1N4ypt-00071B-N1 for emacs-pretest-bug@gnu.org; Mon, 02 Nov 2009 10:28:49 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1N4ypr-0004oN-UY for emacs-pretest-bug@gnu.org; Mon, 02 Nov 2009 10:28:49 -0500 Original-Received: from mail.gmx.net ([213.165.64.20]:43997) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1N4ypq-0004o8-Th for emacs-pretest-bug@gnu.org; Mon, 02 Nov 2009 10:28:47 -0500 Original-Received: (qmail invoked by alias); 02 Nov 2009 15:28:45 -0000 Original-Received: from i59F56ABD.versanet.de (EHLO escher.local.home) [89.245.106.189] by mail.gmx.net (mp008) with SMTP; 02 Nov 2009 16:28:45 +0100 X-Authenticated: #20778731 X-Provags-ID: V01U2FsdGVkX1+LmPhuMHCLCNKM3Gjm33KcnXcB/JPtaBj2zw73Ct 04lUF5FHzW432b Original-Received: by escher.local.home (Postfix, from userid 1000) id B167F1D0B79; Mon, 2 Nov 2009 15:49:55 +0100 (CET) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) X-Y-GMX-Trusted: 0 X-FuHaFi: 0.47 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Mon, 02 Nov 2009 10:47:23 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:32374 gmane.emacs.pretest.bugs:25159 Archived-At: Start Emacs with -Q, insert the following text into a buffer: begin (test) end then eval the following: (defun my-test () "" (interactive) (widen) (goto-char (point-min)) (let ((begin (search-forward "begin"))) (search-forward "end") (narrow-to-region (1+ begin) (line-beginning-position)) (goto-char (point-min))) (unless (let ((ovlist (overlays-in (1- (point)) (1+ (point))))) (when ovlist (overlay-get (car ovlist) 'before-string))) (let ((ov (make-overlay (point) (point) nil t t))) (overlay-put ov 'before-string "* ")))) (global-set-key "\C-cy" 'my-test) and now type `C-c y' in the buffer with the inserted text. The buffer nows displays this: * (test) As expected, now repeating `C-c y' does not alter the display, i.e. does not add more overlays. Now enable show-paren-mode (e.g. by checking "Paren Match Highlighting" in the Options menu). Now repeating `C-c y' display one additional "* " for each repetition (provided point remains on `('). Surprisingly, however, typing `M-x my-test' repeatedly does not add any "* ". In addition, typing a self-inserting character and then deleting it has the effect that typing `C-c y' no longer adds "* "; except after widening and removing the overlays: then repeating `C-c y' adds "* " once only, as when show-paren-mode is disabled. If the described behavior after enabling show-paren-mode is not a bug, can anyone explain it? In GNU Emacs 23.1.50.1 (i686-pc-linux-gnu, GTK+ Version 2.14.4) of 2009-10-27 on escher Windowing system distributor `The X.Org Foundation', version 11.0.10502000 Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=local locale-coding-system: utf-8-unix default enable-multibyte-characters: t