From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Edward O'Connor Newsgroups: gmane.emacs.devel Subject: Re: Bug in nxml-mode (indentation)? Date: Thu, 20 Dec 2007 18:05:03 -0800 Organization: Church of Emacs Message-ID: References: <8763ywvf4y.fsf@everybody.org> <476794FA.50204@gnu.org> <47679F9E.4080502@gnu.org> <4767AF14.5080704@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1198202764 22014 80.91.229.12 (21 Dec 2007 02:06:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 21 Dec 2007 02:06:04 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Dec 21 03:06:16 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1J5XH1-0004Vb-7P for ged-emacs-devel@m.gmane.org; Fri, 21 Dec 2007 03:06:03 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1J5XGh-0004s8-DK for ged-emacs-devel@m.gmane.org; Thu, 20 Dec 2007 21:05:43 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1J5XGd-0004qa-6t for emacs-devel@gnu.org; Thu, 20 Dec 2007 21:05:39 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1J5XGb-0004oW-Gi for emacs-devel@gnu.org; Thu, 20 Dec 2007 21:05:38 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1J5XGb-0004oR-Df for emacs-devel@gnu.org; Thu, 20 Dec 2007 21:05:37 -0500 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1J5XGa-00025m-VT for emacs-devel@gnu.org; Thu, 20 Dec 2007 21:05:37 -0500 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1J5XGD-0000zt-OK for emacs-devel@gnu.org; Fri, 21 Dec 2007 02:05:13 +0000 Original-Received: from ip68-101-220-172.sd.sd.cox.net ([68.101.220.172]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 21 Dec 2007 02:05:13 +0000 Original-Received: from hober0 by ip68-101-220-172.sd.sd.cox.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 21 Dec 2007 02:05:13 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 31 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: ip68-101-220-172.sd.sd.cox.net Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAHlBMVEX47PoBAAegiLwiH1N IQYI0M4iMeKYBAAYGBBGqm9JF4g0mAAACYElEQVR4nGWTsY/aMBTGLXoLo8WQjNVrFJXxzviUbig JEcy5SNft5LhRGT3RNecUuRuiCMn/bZ+dhHDqJ2SZ7+f3nt/DEMOcqv9E9AdQTsD7fPw6hRIz+iw xxuhbMBn3SUtRofk95CTa9D49UIWiRvt4TnTiNmUbHIIDykUxdwm8lTvQUmergwoCpXR/qwojXqk 7jTEK1xANXhKOgD8eRmHggrt2CNKKtfcAU3EHkCbB5OJn4Ws40Prco6jhAyiDoSyeTrAb1gNe+dI eKNVlpvXNE5+pT6HUIjEi24a8B6XvjSrd0rCon5vCDwX7eA2wvV9bqrPWdCAFZBtfA0tQRWmRsE6 uZCMA6qYHbRDg6I5RlxVSFNCISG56QB3oIBNSRKL+JuLMg9LZlGqIUhCFlH9m8FN74GxFQwEFxKm crWYQJQ680v43TSEGEDArAWLJPVAObN8BHDghhrwcI1RYH2GSLMfiKnzWd6DGx4DvwNc41mIC0QQ WqzgXH0HV+kvVoohvIB5AaHRSyCZHyzawtOd4SBUyXR9lxOb2RB7Sz4T0AB8zY/smvWzRIrN0OQL GcsbW8zf7dY1gfsIlZm66JUsdOK3ljjjNCbnoHuxq9jQnb+TkAa6XY0XyJmf7C1uRwfbk4b0m1tr 8+zljb+ROD0+xA9f4umHP9+CTAAesjfGPWNyBvzCAc5ax/I40CFJPvkQrC/vRP+NsiC58LpGKfWH 7Ppy/JMY8ObK0AJfTRUDTz5eQxHS2VxPlG1697N0ee4qSbjeQ64bjc94Nhex1b+2N5Hn1MoJJwlp pf1Rr7/8DXitGHanPc2gAAAAASUVORK5CYII= X-Attribution: Ted Jabber-ID: hober0@gmail.com User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (darwin) Cancel-Lock: sha1:++UqhNM0hNCkw7LSBBP8kwyMmr0= X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:85326 Archived-At: Eric Lilja wrote: >>> So there doesn't seem to be any harm in making the indentation >>> behaviour give the most aesthetically pleasing results. >> >> For what it's worth, nxml-mode's current indentation behavior is, to me, >> more aesthetically pleasing than that of xml-mode. > > Even as it appears in my second example? Well, consider nxml-mode's behavior with this:

This is a test of the emergency broadcast system. This is only a test. in the case of an actual emergency, something interesting would happen now.

Essentially, "newline after start tag" tells nxml to treat that element as block-level, whereas "element content immediately after start tag" tells nxml to treat that element as inline-level. At least in the cases of Atom, RSS, and XHTML, this heuristic pretty much nails the desired behavior. In this example, do you really want line 2 of the paragraph to be indented more than lines 1 and 3? -- Edward O'Connor hober0@gmail.com Ense petit placidam sub libertate quietem.