[Top][All Lists]

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

RE: C-j considered harmful (not really)

From: Drew Adams
Subject: RE: C-j considered harmful (not really)
Date: Mon, 23 Nov 2009 07:05:47 -0800

> I guess the initial suggestion was rather:
>   (define-key minibuffer-local-map [S-return] 'newline)

1. I hope you won't do that. It's best to reserve modifiers for similar meanings
as the base key they modify, other things being equal. IOW, S-RET, M-RET,
C-M-RET, C-S-RET, etc. should be reserved for things akin to what RET does.

(In Icicles, for instance, S-RET in the minibuffer overrides the REQUIRE-MATCH
arg to completing-read, so it acts like RET + confirmation. Just an example.)

I wasn't going to speak to the general question about `S-RET' as a binding for
newline, but since I've started...

2. I don't like the idea of binding `S-RET' to newline. The argument is
apparently that some users will be used to that and thus expect it. So what?
There are so many more things to learn about Emacs that might not be what
someone is used to. This is truly not a big deal, and it doesn't warrant
sacrificing a good key such as `S-RET'. That key is naturally associated with
RET, which is used often and has specific meanings in different contexts, so
`S-RET' can be used for a variant of what RET does in any given context (see #1
wrt the minibuffer's RET).

`C-j' _IS_ newline. OK, some people don't know that. But most programmers of
UNIX, Linux, C, etc. do know it, and others can surely learn it - no biggee. It
is elegant to use the key to self-insert, the same way it is elegant to use the
key `a' to insert an `a' character.

Just one opinion.

reply via email to

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