From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: `inhibit-mark-movement' Date: Fri, 17 Dec 2004 18:11:38 +0200 Organization: JURTA Message-ID: <871xdosy4l.fsf@jurta.org> References: <200412080256.30114.pogonyshev@gmx.net> <871xe1trnq.fsf-monnier+emacs@gnu.org> <200412081740.48280.pogonyshev@gmx.net> <871xe0y8lg.fsf@jurta.org> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1103301913 14394 80.91.229.6 (17 Dec 2004 16:45:13 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 17 Dec 2004 16:45:13 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 17 17:45:06 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1CfLE1-00057W-00 for ; Fri, 17 Dec 2004 17:45:06 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CfLOK-0004VM-Oy for ged-emacs-devel@m.gmane.org; Fri, 17 Dec 2004 11:55:44 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CfLNC-0003wZ-41 for emacs-devel@gnu.org; Fri, 17 Dec 2004 11:54:34 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CfLNA-0003vo-B1 for emacs-devel@gnu.org; Fri, 17 Dec 2004 11:54:32 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CfLNA-0003v7-8g for emacs-devel@gnu.org; Fri, 17 Dec 2004 11:54:32 -0500 Original-Received: from [194.126.101.98] (helo=MXR-3.estpak.ee) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CfL7p-000399-N2 for emacs-devel@gnu.org; Fri, 17 Dec 2004 11:38:41 -0500 Original-Received: from mail.neti.ee (80-235-32-111-dsl.mus.estpak.ee [80.235.32.111]) by MXR-3.estpak.ee (Postfix) with ESMTP id 4CE11EB11A for ; Fri, 17 Dec 2004 18:38:38 +0200 (EET) Original-To: emacs-devel@gnu.org In-Reply-To: (Stefan Monnier's message of "Wed, 08 Dec 2004 14:22:56 -0500") User-Agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux) X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at neti.ee 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: main.gmane.org gmane.emacs.devel:31244 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:31244 There is another issue related to active marks in Transient Mark mode, which I believe is a bug: C-u C-SPC behaves differently when the mark ring is empty and when it is not. With the non-empty mark ring C-u C-SPC deactivates the mark when the mark is active. This is good. But when the mark ring is empty C-u C-SPC doesn't deactivate the mark. Such behaviour is unexpected since the state of the mark ring is irrelevant to that operation. I propose the following fix for `pop-mark' which deactivates the active mark regardless of the state of the mark ring: Index: lisp/simple.el =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/simple.el,v retrieving revision 1.672 diff -u -r1.672 simple.el --- lisp/simple.el 14 Dec 2004 12:17:43 -0000 1.672 +++ lisp/simple.el 17 Dec 2004 15:50:29 -0000 @@ -2945,10 +3013,10 @@ (when mark-ring (setq mark-ring (nconc mark-ring (list (copy-marker (mark-marker))))) (set-marker (mark-marker) (+ 0 (car mark-ring)) (current-buffer)) - (deactivate-mark) (move-marker (car mark-ring) nil) (if (null (mark t)) (ding)) - (setq mark-ring (cdr mark-ring)))) + (setq mark-ring (cdr mark-ring))) + (deactivate-mark)) (defalias 'exchange-dot-and-mark 'exchange-point-and-mark) (defun exchange-point-and-mark (&optional arg) -- Juri Linkov http://www.jurta.org/emacs/