From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: Why was `transient-mark-mode' turned off for `delete-selection-mode'? Date: Fri, 05 Sep 2014 18:14:31 +0200 Message-ID: <87a96e11ug.fsf@fencepost.gnu.org> References: <60d75d3a-d04c-4394-800b-60b65fafdb11@default> <2ffbe01d-ef46-4467-83a6-4714a192ba8b@default> <3b045884-0f98-49f3-addd-227a3c1403d1@default> <53f0f206-96ae-423b-a237-294a26f60270@default> <87ppfa1rdi.fsf@fencepost.gnu.org> <1e534a9c-cc81-4bd6-ab28-8427de9e07bf@default> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1409934620 4244 80.91.229.3 (5 Sep 2014 16:30:20 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 5 Sep 2014 16:30:20 +0000 (UTC) Cc: emacs-devel@gnu.org To: Drew Adams Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Sep 05 18:30:13 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XPwJr-0004fz-3V for ged-emacs-devel@m.gmane.org; Fri, 05 Sep 2014 18:25:03 +0200 Original-Received: from localhost ([::1]:58904 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPwFY-0006aF-8b for ged-emacs-devel@m.gmane.org; Fri, 05 Sep 2014 12:20:36 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45993) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPw9j-0004FM-2Q for emacs-devel@gnu.org; Fri, 05 Sep 2014 12:14:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XPw9i-0005yY-0H for emacs-devel@gnu.org; Fri, 05 Sep 2014 12:14:34 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:43795) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPw9h-0005yQ-U1 for emacs-devel@gnu.org; Fri, 05 Sep 2014 12:14:33 -0400 Original-Received: from localhost ([127.0.0.1]:50971 helo=lola) by fencepost.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPw9g-00046N-6c; Fri, 05 Sep 2014 12:14:32 -0400 Original-Received: by lola (Postfix, from userid 1000) id BDA63E04A7; Fri, 5 Sep 2014 18:14:31 +0200 (CEST) In-Reply-To: <1e534a9c-cc81-4bd6-ab28-8427de9e07bf@default> (Drew Adams's message of "Fri, 5 Sep 2014 09:01:58 -0700 (PDT)") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:174042 Archived-At: Drew Adams writes: >> I find myself trying to figure out a good way to unhighlight a >> selection half of the time when I am trying to edit a link in a >> browser or something that pops up highlighted for some reason. >> It is total nuisance behavior without a generally available way >> to turn the unasked-for selection off. The other half of the time >> I inadvertantly delete material. Sometimes it can be recovered >> by C-z (depending on the application). Sometimes not. > > Clearly, d-s mode is not for you. Fortunately, anyone can choose > the behavior (a-d) that s?he prefers. > > But I wonder if your surprise and annoyance with such behavior > outside Emacs might have something to do with your not using d-s > mode inside Emacs. My suprise and annoyance with getting punched in the face in a bar might also have something to do with me not being used to being punched in the face at home. That does not make it a better idea to let me get punched in the face at home. Basically you continue arguing that one can get used to getting annoyed. > I use d-s mode, and I am not surprised outside Emacs by a highlighted > selection or its deletion if I hit a deletion key or its replacement > if I type text. And that's a point in favor of turning on d-s mode > by default: it is quite common UI outside Emacs. > >> Your only argument so far has been "others do it". But that's not, >> in itself, a good reason to let Emacs adopt default behavior that >> gets in the way of productive work. > > I agree 100% that how things work outside Emacs should not be the > *only* reason for how they should work inside Emacs. I have opposed > turning on CUA mode by default, for instance. > > Just as you find d-s mode off more natural and less conducive to > mistakes, so I find the opposite. And then you continue to explain how to best deal with the mistakes it causes you to make, and how to anticipate them best. You don't actually point out anything useful about that behavior. >> > 3. Besides having the limitation of not being able to just >> > type to replace the region text, the current situation >> > suffers from treating mouse selection exceptionally. >> > A mouse selection has the deletion behavior of d-s mode, >> > but without its type-to-replace behavior. >> >> Are you sure about that? Like, really sure? > > Well, let's see (I'm on MS Windows; YMMV): > > 1. emacs -Q (any Emacs version you like). > > 2. In *scratch*, select some text with the mouse. Take > your pick how you do this: drag mouse-1 or double-click it, > or click mouse-1 then mouse-3 elsewhere, etc. > > 3. Type some text. > > For me, the typed text is inserted at point, without any of the > selected (and highlighted) text being replaced. > > If I hit a deletion key (e.g. Backspace or Delete) then the > selected text is deleted. And that's the behavior I described. > Do you see something different? That's not the entirety of your claim. The entirety of your claim is "the current situation suffers from treating mouse selection exceptionally." Try marking a region in emacs -Q with _any_ of the mouse, or with shift-cursor, or with C-SPC and some movement. Then type DEL. You'll see that _any_ way of marking a highlighted region will cause DEL to delete that region. Your claim of the mouse selection being treated specially is bogus. -- David Kastrup