help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: C-Ret: cua and icicles


From: Lennart Borgman
Subject: Re: C-Ret: cua and icicles
Date: Mon, 24 May 2010 23:46:51 +0200

On Mon, May 24, 2010 at 11:22 PM, Drew Adams <drew.adams@oracle.com> wrote:
>> > So the desired behaviour is when cua mode and icy mode are
>> > active at the same time: When you press C-RET in minibuffer
>> > then use `icicle-candidate-action', otherwise use
>> > `cua-set-rectangle-mark'.
>> >
>> > The solution is in the EmacsWiki:
>> > http://www.emacswiki.org/emacs/IciclesIssuesClosed  (search
>> > this emacswiki page for the function `my-c-return').
>>
>> That is good, but Icicles should of course try to do this, not you.
>
> CUA is a minor mode. Its key bindings therefore override all local bindings,
> including minibuffer bindings.


It overrides more. It is an emulation minor mode. It therefore has a
special status and overrides also minor mode bindings.

If it did not do this it would be quite useless.


> Unlike CUA mode, Icicles uses the standard
> minibuffer keymaps to affect keys in the minibuffer, and there are reasons for
> that.


Icicles is a normal minor mode, yes.


> Icicles should not be worrying about each mode that might bind some key in its
> minor-mode map and thus override a binding in a minibuffer keymap.  I know you
> feel that CUA mode is extremely important, and everything in Emacs should bend
> over backwards to cater to CUA mode.  To me, it is just one mode among a
> multitude of possible modes.


See above. It is not another (normal) minor mode. It is an emulating
minor mode. (Which just happens to be a minor mode because non-major
modes are called minor modes.)


> (since CUA-mode lays hold C-RET ubiquitously).


I think that is a problem. It is used to start rectangle editing which
surely is a nice feature for those who needs it, but it is IMO not
important enough to steel the C-RET key. You can customize it in cua,
but I think the default should be some less important key.

And this is part of cua-mode just because Kim wrote it ;-)

It is nice but not included in what I talk about when I mention
cua-mode. I think it should be moved to a global minor mode on its own
(not an emulation minor mode).


> The only way to take back C-RET for the minibuffer is to remap the CUA-imposed
> command to a command that DTRT, distinguishing the minibuffer.  Fortunately, 
> it
> is trivial for an Icicles user to do that using Customize.


You can customize the binding in cua-mode too. That is what I have done.


> If CUA mode did not fail itself to distinguish the minibuffer case, it would 
> be
> even more trivial.


cua-mode should NOT do that but the key and command we are talking
about should not be in cua-mode.

I think all who knows about cua-mode on the devel list are aware of
this. It is just a matter of time, someone must have time to fix it. I
have included Kim in the receivers here if he has a different opinion.



reply via email to

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