From mboxrd@z Thu Jan 1 00:00:00 1970 From: azw@fastmail.fm (Albert Z. Wang) Subject: Re: fill paragraph: math and latex environments Date: Mon, 17 Sep 2012 20:37:10 -0400 Message-ID: <874nmwrwsp.fsf@gmail.com> References: <87mx0osk29.fsf@gmail.com> <878vc8h33x.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:48006) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDloh-0001oG-De for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 20:37:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TDlog-0005rT-EE for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 20:37:31 -0400 Received: from plane.gmane.org ([80.91.229.3]:45473) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDlog-0005rK-7K for emacs-orgmode@gnu.org; Mon, 17 Sep 2012 20:37:30 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1TDloi-0004C1-2b for emacs-orgmode@gnu.org; Tue, 18 Sep 2012 02:37:32 +0200 Received: from 81.17.19.124 ([81.17.19.124]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 18 Sep 2012 02:37:32 +0200 Received: from azw by 81.17.19.124 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 18 Sep 2012 02:37:32 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Nicolas Goaziou writes: > Hello, > > azw@fastmail.fm (Albert Z. Wang) writes: > >> I've just recently been having an issue I was wondering if anybody >> could help with, namely, that fill-paragraph does not seem to work as >> expected. >> >> For display math equations delimited as >> \[ >> a^2 + b^2 = c^2 >> \] >> the equation gets folded inline -- seems to work fine with explicit >> environments though ( \begin{equation*}...\end{equation*} ). Has >> anybody else experienced this? Tweaking paragraph-start and >> paragraph-separate do not seem to be doing the trick... > > Yes, \[...\] constructs are considered as inline objects (they belong to > a paragraph, so they will be filled along with the paragraph). On the > other hand, \begin{equation*} environments are full-fledged elements: > they do not belong to a paragraph and are not filled. Thanks for the clarification! Is there an easy way to have them be treated as full-fledged environments? I usually prefer to use the above for unnumbered display equations since it reduces visual clutter and looks closer to the intent. I've noticed that adding "\\\\\\[" and "\\\\\\]" to org-element-paragraph-separate will prevent complete inlining, but that the newline after the mark will be removed, which makes the formatting a little less clear. Is it possible to treat \[ ... \] as full-fledged unnumbered equation environments? My own understanding of how the parser works is insufficient to the task of changing its behavior here... It's not a very big deal, but if there's an easy way to accomplish this I'd appreciate any help. Thanks, --Albert