LaTeX export: Fix bug with export of x^{(0)}

Report by Dan Davison
This commit is contained in:
Carsten Dominik 2010-04-28 17:21:41 +02:00
parent e41f76a1f7
commit 9fdff15758
2 changed files with 6 additions and 1 deletions

View File

@ -1,5 +1,8 @@
2010-04-28 Carsten Dominik <carsten.dominik@gmail.com>
* org-latex.el (org-export-latex-treat-sub-super-char): Make
sure parenthesis matching is consistent.
* org-table.el (org-table-colgroup-line-p)
(org-table-cookie-line-p): New functions.

View File

@ -1472,7 +1472,9 @@ Convert CHAR depending on STRING-BEFORE and STRING-AFTER."
((and (> (length string-after) 1)
(or (eq subsup t)
(and (equal subsup '{}) (eq (string-to-char string-after) ?\{)))
(string-match "[({]?\\([^)}]+\\)[)}]?" string-after))
(or (string-match "[{]?\\([^}]+\\)[}]?" string-after)
(string-match "[(]?\\([^)]+\\)[)]?" string-after)))
(org-export-latex-protect-string
(format "%s$%s{%s}$" string-before char
(if (and (> (match-end 1) (1+ (match-beginning 1)))