emacs-devel
[Top][All Lists]
Advanced

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

Re: Shift-movement selection


From: Kim F. Storm
Subject: Re: Shift-movement selection
Date: Mon, 10 Mar 2008 16:06:54 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1.91 (gnu/linux)

Stefan Monnier <address@hidden> writes:

>>>> So to make it work "correctly", you need to modify all commands in
>>>> emacs!  [yikes!]
>>> Most commands already deactivate the mark.  So which ones would be left?
>
>> Anything that doesn't modify the buffer -- e.g. all movement commands.
>
> Supposedly these will be changed to use the new function, so they will
> explicitly deactivate the mark if the mark was activated with shift and
> the movement is then performed without the shift.


One problem is that basic movement commands are in C, not in Lisp.

Another problem may be advise on functions - the "shift" handling
may then be performed too late.

Personally, I like my proposal of just setting a "shift" property
on the relevant commands, and do it by running a shifted-key-hook
in the command loop.  

That method has proven to work excellent with CUA mode!

For one thing, it is trivial for a user to add shift-region support
for new movement commands in an external package - without modifying
the code of that package.

-- 
Kim F. Storm <address@hidden> http://www.cua.dk





reply via email to

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