From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.bugs Subject: bug#19272: 25.0.50; electric-indent-mode: Appears to do the opposite Date: 4 Dec 2014 22:11:39 -0000 Organization: muc.de e.V. Message-ID: <20141204221139.86993.qmail@mail.muc.de> References: NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1417731146 22082 80.91.229.3 (4 Dec 2014 22:12:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 4 Dec 2014 22:12:26 +0000 (UTC) Cc: 19272@debbugs.gnu.org To: raman Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Dec 04 23:12:18 2014 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XwedE-0002pl-RX for geb-bug-gnu-emacs@m.gmane.org; Thu, 04 Dec 2014 23:12:16 +0100 Original-Received: from localhost ([::1]:47949 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XwedD-000689-UI for geb-bug-gnu-emacs@m.gmane.org; Thu, 04 Dec 2014 17:12:15 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xwed5-00067r-JA for bug-gnu-emacs@gnu.org; Thu, 04 Dec 2014 17:12:12 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xwed0-0000YN-Oh for bug-gnu-emacs@gnu.org; Thu, 04 Dec 2014 17:12:07 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:56864) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xwed0-0000YG-L7 for bug-gnu-emacs@gnu.org; Thu, 04 Dec 2014 17:12:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Xwed0-0003yz-ET for bug-gnu-emacs@gnu.org; Thu, 04 Dec 2014 17:12:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Alan Mackenzie Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 04 Dec 2014 22:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19272 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 19272-submit@debbugs.gnu.org id=B19272.141773110315283 (code B ref 19272); Thu, 04 Dec 2014 22:12:02 +0000 Original-Received: (at 19272) by debbugs.gnu.org; 4 Dec 2014 22:11:43 +0000 Original-Received: from localhost ([127.0.0.1]:54077 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Xwecg-0003yR-Tv for submit@debbugs.gnu.org; Thu, 04 Dec 2014 17:11:43 -0500 Original-Received: from colin.muc.de ([193.149.48.1]:13756 helo=mail.muc.de) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Xwece-0003yH-RU for 19272@debbugs.gnu.org; Thu, 04 Dec 2014 17:11:41 -0500 Original-Received: (qmail 86994 invoked by uid 3782); 4 Dec 2014 22:11:39 -0000 In-Reply-To: X-Newsgroups: gnu.emacs.bug User-Agent: tin/2.2.0-20131224 ("Lochindaal") (UNIX) (FreeBSD/8.4-RELEASE (amd64)) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:96872 Archived-At: In article you wrote: > In both Emacs 24.4 -- as well as Emacs 25 built from head: > In lisp buffers electric-indent-mode is on by default. electric-indent-mode is now enabled everywhere, by default. > But if it is on, then hitting C-j does not indent -- it ends up leaving > point on the first column in the newly inserted line. This is deliberate - the swapping of the actions of C-j and RET. Most people on the developers' mailing list agreed it was time to do this, for the benefit of new users who expect auto indentation of the new line, but who aren't used to typing C-j for it. However, this change in key actions has been conflated with electric-indent-mode. En/dis-able that minor mode, and the action of your keys is swapped. > I do have 10 in the list electric-indent-chars. 10 is , aka C-j. When you type a character which is in electric-indent-chars, that causes electric indentation of the current line (not the new one you may create). I think that 10 causes indentation of that line regardless of whether you type C-j or RET. > Even stranger, turning off electric-indent-mode results in the behavior > I want, ie C-j inserts a newline then inserts. This is indeed strange, but is deliberate. The two behaviours (electric-indent-mode and the transpositions of the key actions) were linked together "for simplicity". If you want to have electric-indent-mode enabled at the same time as having C-j and RET behave traditionally, you're going to have to swap the key bindings or start hacking the Emacs lisp code. This situation is a big part of why I personally haven't upgraded to Emacs 24.4. > In GNU Emacs 25.0.50.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw scroll bars) > of 2014-12-02 on raman-glaptop > Repository revision: cb2257edc4a4b74ce9b566edc2d15a54e1ce2f22 > System Description: Ubuntu 14.04 LTS -- Alan Mackenzie (Nuremberg, Germany).