From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: [bug] equations in latex equation environment with leading +/- misinterpreted Date: Tue, 13 Sep 2011 20:02:16 +0100 Message-ID: <87wrdc1d1j.fsf@ucl.ac.uk> References: <87mxef8o51.fsf@ucl.ac.uk> <877h5cjtd6.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([140.186.70.92]:46691) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R3YFW-0003eH-Hi for emacs-orgmode@gnu.org; Tue, 13 Sep 2011 15:02:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R3YFU-0008NR-Vw for emacs-orgmode@gnu.org; Tue, 13 Sep 2011 15:02:26 -0400 Received: from vscane-b.ucl.ac.uk ([144.82.108.141]:63112) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R3YFU-0008Hh-Rf for emacs-orgmode@gnu.org; Tue, 13 Sep 2011 15:02:24 -0400 In-Reply-To: <877h5cjtd6.fsf@gmail.com> (Nicolas Goaziou's message of "Tue, 13 Sep 2011 18:32:21 +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: Nicolas Goaziou Cc: emacs-orgmode@gnu.org Nicolas Goaziou writes: > Hello, > > Eric S Fraga writes: > >> the attached org file illustrates a problem with the latex exporter in >> which any line within a \begin{equation}...\end{equation} that begins >> with a + or - is interpreted as a list item. >> >> It's easy enough to avoid this problem by either reformatting the lines >> in question or by enclosing the equation block in a LATEX org block. >> Therefore, there's no urgency in addressing this bug. > > [...] > >> * equation with leading minus sign >> The following equation > >> \begin{equation} >> \label{eq:test} >> y = 3 x >> - 5 >> + 4 >> \end{equation} illustrates a problem in \LaTex export where the >> leading arithmetic operators are interpreted as list entries. > > I understand your concern, but, as far as I can tell, that's not a bug. > > Lists have precedence over LaTeX snippets. In other words, you're asking > to start a list here, and Org starts one. Okay, I understand. "Unintended behaviour" instead of "bug" ;-) but behaviour that I can accept, especially as the easy solution is to simply enclose the equation in a latex block: --8<---------------cut here---------------start------------->8--- * equation with leading minus sign The following equation #+begin_latex \begin{equation} \label{eq:test} y = 3 x - 5 + 4 \end{equation} #+end_latex --8<---------------cut here---------------end--------------->8--- This works just fine and is probably for the best in any case. Using a latex block allows for latex specific editing (C-c '). Should have done this in the first place! Sorry for the noise! Thanks, eric -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1 : using Org-mode version 7.7 (release_7.7.282.g0037)