emacs-devel
[Top][All Lists]
Advanced

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

Re: delete-selection-mode


From: Stefan Monnier
Subject: Re: delete-selection-mode
Date: Thu, 25 Mar 2010 22:48:49 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

>>> What do you think about marking commands that should delete the active
>>> region with a new interactive character (like "^" is used to call
>>> `handle-shift-selection'), so e.g. a new function `handle-delete-region'
>>> could delete the active region before running a command?
>> Sounds very good, indeed,
> Isn't this redundant with the idea of replacing mouse-region-delete-keys
> with a more general variable that affects all active regions?  That
> sounds more appealing than assigning more interactive codes.

No, what I want is to replace the code that implements the feature
linked to mouse-region-delete-keys by new code which implements
a similar feature that covers more cases (not linked to
mouse-selection).

Whether that new code uses a variable like foo-region-delete-keys is
an "implementation detail".
And I think relying on keys (as is done currently by
mouse-region-delete-keys), or on symbol names (as is done currently by
d-s-m) is wrong: the behavior should depend on the actual command, so it
needs to be part of the command's definition, which basically means part
of its interactive spec.  Again, the reasoning is exactly the same as
the one that lead to the "^" for shift-select.


        Stefan




reply via email to

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