emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: delete-selection-mode as default (WAS: Some developement questions)


From: Eli Zaretskii
Subject: Re: delete-selection-mode as default (WAS: Some developement questions)
Date: Fri, 07 Sep 2018 09:47:52 +0300

> From: Noam Postavsky <address@hidden>
> Date: Thu, 6 Sep 2018 20:32:54 -0400
> Cc: Eli Zaretskii <address@hidden>, hw <address@hidden>, address@hidden, 
>       Emacs developers <address@hidden>, Phillip Lord <address@hidden>
> 
> >> Type "C-x C-x", then some letter: puff! the whole region is gone.
> >> This could be okay in text modes, but in code buffers users generally
> >> don't replace regions with single letters.
> 
> I don't understand why a user who is okay with replacing the region
> with a single letter in text mode, would all of sudden dislike the
> idea in a code buffer.

Because in text editing, it is a frequent use case that you want to
replace a region of text with some other long text; and also I find
myself in the need of doing "C-x C-x" much less frequently when I'm
editing text.  By contrast, in coding, most changes are of a much
smaller size, and "C-x C-x" is a very frequent command, due to the
need to look at other portions of the code.

> Maybe. My feeling from using non-Emacs editors (gasp!), is that the
> main use of this sort of thing is rather for replacing the selection
> by pasting, not so about much typing. Or, for when some feature
> inserts some default text, it highlights that text, indicating to the
> user that they may replace it by typing (i.e., it's rare that a
> user-created selection is deleted by typing).

It is exactly these features that get in the way when I write code.
It means I must click the mouse or do some cursor motion or C-g after
yanking, otherwise typing something will nuke the text just yanked.

Feel free to start a user poll, though: if it turns out I'm the only
one who thinks delete-selection-mode is inappropriate in programming
modes, we can make it the default; I can easily turn it off in my
configuration.  Though I would urge people to actually try this in
programming modes before responding, and in any case the poll should
request to provide the major modes used with the responses.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]