emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: Richard Lawrence <richard.lawrence@berkeley.edu>
Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org
Subject: Re: Latex export: Differing behavior for symbols in headlines
Date: Thu, 21 Oct 2010 12:36:22 -0400	[thread overview]
Message-ID: <19863.1287678982@gamaville.dokosmarshall.org> (raw)
In-Reply-To: Message from Richard Lawrence <richard.lawrence@berkeley.edu> of "Thu, 21 Oct 2010 09:09:16 PDT." <87lj5rplxv.fsf@berkeley.edu>

Richard Lawrence <richard.lawrence@berkeley.edu> wrote:

> Dear Orgsters,
> 
> I am seeing differing behavior for how special symbols that appear in a
> headline are exported to LaTeX, depending on whether I export an entire
> Org document or just the current subtree.
> 
> I have, for example, a file that looks like this:
> 
> * Headline 1
> ** Headline 2, concerning $\alpha$ and $\beta$
> 
> If I export the whole document, the $'s around \alpha and \beta are
> properly interpreted as math-mode delimiters, and Headline 2 becomes a
> section title that looks exactly as I would expect.
> 
> If I export just Headline 2, however, the $'s are escaped, and show up
> as literal '$' characters in the title of the exported document.
> 
> (I can't remove the $'s, because I am actually using some custom LaTeX
> commands, not special symbols like \alpha and \beta that Org would
> recognize as needing to be put in math mode.)
> 
> So, two questions:
> 
> 1) Is this difference between whole-document vs. current-subtree export
> the expected behavior?
> 
Looks like a bug to me. I can reproduce it too.

> 2) If so, what's the right way to work around it?  If not, where should
> I look to try and fix it?
> 

I tried using \( and \) as the inline math delimiters but that did not
work either: I got $ signs *inserted* and then latex complains about that:

foo.org:
--8<---------------cut here---------------start------------->8---
* Headline 1
** Headline 2, concerning \(\alpha\) and \(\beta\)
--8<---------------cut here---------------end--------------->8---

foo.tex (elided):
--8<---------------cut here---------------start------------->8---
...
\title{Headline 2, concerning \($\alpha$\) and \($\beta$\)}
...
--8<---------------cut here---------------end--------------->8---

Nick

  reply	other threads:[~2010-10-21 16:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-21 16:09 Latex export: Differing behavior for symbols in headlines Richard Lawrence
2010-10-21 16:36 ` Nick Dokos [this message]
2010-10-24  3:45   ` Bug: " Richard Lawrence
2010-10-24  7:30     ` Richard Lawrence
2010-10-25  8:42     ` Giovanni Ridolfi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=19863.1287678982@gamaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=richard.lawrence@berkeley.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).