all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: David Kastrup <dak@gnu.org>
To: Drew Adams <drew.adams@oracle.com>
Cc: emacs-devel@gnu.org
Subject: Re: Why was `transient-mark-mode' turned off for `delete-selection-mode'?
Date: Fri, 05 Sep 2014 18:14:31 +0200	[thread overview]
Message-ID: <87a96e11ug.fsf@fencepost.gnu.org> (raw)
In-Reply-To: <1e534a9c-cc81-4bd6-ab28-8427de9e07bf@default> (Drew Adams's message of "Fri, 5 Sep 2014 09:01:58 -0700 (PDT)")

Drew Adams <drew.adams@oracle.com> 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



  reply	other threads:[~2014-09-05 16:14 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-25 20:07 Why was `transient-mark-mode' turned off for `delete-selection-mode'? Drew Adams
2014-09-04 19:50 ` Drew Adams
2014-09-04 20:48 ` Stefan Monnier
2014-09-04 21:15   ` Drew Adams
2014-09-04 21:31     ` Stefan Monnier
2014-09-04 21:44       ` Drew Adams
2014-09-05  1:00         ` Stefan Monnier
2014-09-05  3:01         ` Drew Adams
2014-09-05  7:03           ` David Kastrup
2014-09-05 16:01             ` Drew Adams
2014-09-05 16:14               ` David Kastrup [this message]
2014-09-05 17:04                 ` Drew Adams
2014-09-05 17:22                   ` David Kastrup

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a96e11ug.fsf@fencepost.gnu.org \
    --to=dak@gnu.org \
    --cc=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.