From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: auto indenting code blocks Date: Sun, 14 Jun 2015 15:59:21 -0400 Organization: A noiseless patient Spider Message-ID: References: <43ca5eee-94a4-47f3-8b69-3af8a38227cd@googlegroups.com> <87616rlt63.fsf@web.de> <871thfi3uo.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1434312024 5116 80.91.229.3 (14 Jun 2015 20:00:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 14 Jun 2015 20:00:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Jun 14 22:00:20 2015 Return-path: Envelope-to: geh-help-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 1Z4E4p-00041H-Dg for geh-help-gnu-emacs@m.gmane.org; Sun, 14 Jun 2015 22:00:19 +0200 Original-Received: from localhost ([::1]:59461 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z4E4o-0001Fh-Gj for geh-help-gnu-emacs@m.gmane.org; Sun, 14 Jun 2015 16:00:18 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!us.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!newsfeed.straub-nv.de!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 17 Injection-Info: mx02.eternal-september.org; posting-host="ee16984cdf13bddf8bde6a442d903709"; logging-data="25128"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18eX+/fvL2u0SYHu/ug4Qfw" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:aHrJ6IVeer/KfCr+TuV7+uQqZAg= sha1:a2Uxm394Fd2PHS9YXYM9lRWw438= Original-Xref: usenet.stanford.edu gnu.emacs.help:212643 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:104927 Archived-At: > I do not believe it’s a smartparens bug. Its job in this context is to > add a matching closing brace as soon as an opening brace is inserted. > It’s not an electric-indent-mode bug, either. When a line break is > inserted immediately before a closing brace, it reindents the closing > brace according to the mode and style. > What Sam and I want, however, is, with a single Enter keypress, to > insert *two* line breaks, position the point between them, and indent > everything nicely. Indeed. IIRC electric-pair-mode offers such a feature, and during its implementation we considered other alternatives, including adding it via electric-layout-mode which is arguably conceptually closer. Stefan