unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: "Drew Adams" <drew.adams@oracle.com>
To: "'Juri Linkov'" <juri@jurta.org>,
	"'Stefan Monnier'" <monnier@iro.umontreal.ca>
Cc: "'Per Starbäck'" <per@starback.se>,
	emacs-devel@gnu.org, "'Deniz Dogan'" <deniz.a.m.dogan@gmail.com>
Subject: RE: C-j considered harmful (not really)
Date: Mon, 23 Nov 2009 07:05:47 -0800	[thread overview]
Message-ID: <F531921AB3E74524B20637B314693C6B@us.oracle.com> (raw)
In-Reply-To: <87zl6dk2pz.fsf@mail.jurta.org>

> 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.





  parent reply	other threads:[~2009-11-23 15:05 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-16 22:37 C-j considered harmful (not really) Per Starbäck
2009-11-16 22:51 ` Deniz Dogan
2009-11-17 10:09   ` Juri Linkov
2009-11-17 23:17     ` Xavier Maillard
2009-11-18  9:54       ` Juri Linkov
2009-11-22 20:36     ` Per Starbäck
2009-11-22 20:53       ` Deniz Dogan
2009-11-23  2:57       ` Stefan Monnier
2009-11-23  9:54         ` Juri Linkov
2009-11-23 11:11           ` Per Starbäck
2009-11-23 15:05             ` Drew Adams
2009-11-23 15:05           ` Drew Adams [this message]
2009-11-23 16:09             ` Per Starbäck
2009-11-24 17:12             ` Juri Linkov
2009-11-24 17:51               ` Drew Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=F531921AB3E74524B20637B314693C6B@us.oracle.com \
    --to=drew.adams@oracle.com \
    --cc=deniz.a.m.dogan@gmail.com \
    --cc=emacs-devel@gnu.org \
    --cc=juri@jurta.org \
    --cc=monnier@iro.umontreal.ca \
    --cc=per@starback.se \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).