[Top][All Lists]

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

Re: [Emacs-diffs] trunk r116461: Connect electric-indent-mode up with CC

From: Stephen J. Turnbull
Subject: Re: [Emacs-diffs] trunk r116461: Connect electric-indent-mode up with CC Mode. Bug #15478.
Date: Wed, 26 Mar 2014 01:49:28 +0900

Steinar Bang writes:
 > >>>>> "Stephen J. Turnbull" <address@hidden>:
 > >> You might get used to "RET reindents" and stop hitting TAB that often ;-)
 > > I'm very unlikely to get used to it.  Specifically, in the very
 > > annoying case where unconventional indentation gets blown away by it
 > > (TAB won't fix that!)
 > I've been C-j'ing to get return and indent, since I first startet using
 > emacs, back in 1987 or 1988 or thereabouts.
 > Works for me.

*sigh* That is simply not the point, it has worked forever (I started
using Emacs in 1979, don't remember if `newline-and-indent' was
implemented in pre-GNU Emacsen) and I don't expect it to stop working.

There are two problems with binding `reindent-then-newline-and-indent'
(RTNAT) and `newline-and-indent' (NAT) but not `newline'.  The first
is that the simple, reliable "newline" behavior is not easily available
in macros and the like.

The second is that for many users RTNAT is going to be identical to
NAT 95% of the time, or perhaps more, depending on how often they edit
code such that the changed syntax requires changed indentation.  This
makes one simply an unreliable version of the other, ISTM.  If a user
likes RTNAT behavior, they probably are willing to put up with the
occasional spurious indentation change -- and won't use the NAT
binding.  If they don't like that behavior, they won't use the RTNAT
binding anyway.

I don't think this is good UI.  Keystrokes are scarce in Emacs.  They
shouldn't be spent on keeping users of different preferences happy,
that's the job of minor modes.

reply via email to

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