all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: RE: Why was `transient-mark-mode' turned off for `delete-selection-mode'?
Date: Thu, 4 Sep 2014 20:01:41 -0700 (PDT)	[thread overview]
Message-ID: <53f0f206-96ae-423b-a237-294a26f60270@default> (raw)
In-Reply-To: <3b045884-0f98-49f3-addd-227a3c1403d1@default>

1. It seems that the description of this feature is misleading.

It apparently does not do what I feared from reading its
description: give you delete-selection (type-to-replace)
behavior without the region being active and highlighted.

That was what I understood from the NEWS description:

** Delete Selection mode can now be used without Transient
   Mark mode.

That would not have been an improvement.  Users of
type-to-replace behavior should see what they are replacing
or deleting.

The feature that was implemented is in fact a good one.
It is better described, IMO, like this (or similarly):

  You can now get Delete-Selection mode behavior (type to
  replace the active region) also when Transient Mark mode
  is activated temporarily.

That is, you cannot use delete-selection without the region
being active and highlighted.  You can use delete-selection
even when region activation and highlighting are temporary.

What is important is the behavior, regardless of what modes
happen to be turned on.  This feature brings d-s behavior
to all situations where the region is active.  Good.

I think it would have been good to raise this possibility
for discussion.  But I am glad that this is now available.
I hope the doc will make clear what this amounts to,
starting with the NEWS description.


2. There are now 4 possible behaviors that a user can
choose:

a. d-s mode on  and t-m mode on
b. d-s mode off and t-m mode on
c. d-s mode off and t-m mode off
d. d-s mode on  and t-m mode off
 
This is a good time to again consider the question of
what the default behavior should be.  It is currently (b).
I think it should be (a).

(a) is the behavior most new users are used to.  It is the
behavior I have preferred for Emacs, ever since it was first
available, 20 or so years ago.

(b) is the behavior we have now.

(c) is the behavior that Emacs had until a few years ago.
It was quite a battle to get Emacs to move from (c) to (b).

(d) might make sense for someone who generally likes the
behavior of (c) but occasionally wants the behavior of (a)
temporarily.  It is possible only now, because of the
new feature described in (1).

I think (a) is the best choice for the default behavior,
and (d) is arguably the second best choice.

It is true that some programmers develop code on platforms
that generally have the behavior of (c) (perhaps also with
some mouse-selection highlighting).

But even then many of them interact with programs (e.g.
web browsers) that have the behavior of (a).  And both
programmers on other platforms and non-programmers are
generally used to the behavior of (a).


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.

At the time this mouse-selection feature was introduced
I argued that mouse-selection should be just another form
of region selection; it should not behave differently in
any way. I would still argue that.



  parent reply	other threads:[~2014-09-05  3:01 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 [this message]
2014-09-05  7:03           ` David Kastrup
2014-09-05 16:01             ` Drew Adams
2014-09-05 16:14               ` David Kastrup
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=53f0f206-96ae-423b-a237-294a26f60270@default \
    --to=drew.adams@oracle.com \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /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.