瀏覽代碼

LaTeX export: Allow multiple arguments to LaTeX macros

Carsten Dominik 15 年之前
父節點
當前提交
9f4d3e8016
共有 2 個文件被更改,包括 4 次插入1 次删除
  1. 2 0
      lisp/ChangeLog
  2. 2 1
      lisp/org-latex.el

+ 2 - 0
lisp/ChangeLog

@@ -4,6 +4,8 @@
 	(org-export-latex-fontify): Fix regexp bug that takes special
 	care of protecting the right boundary characters in emphasis
 	matches.
+	(org-export-latex-preprocess): Allow multiple arguments to latex
+	macros.
 
 	* org.el (org-make-link-regexps): Use John Gruber's regexp for
 	urls.

+ 2 - 1
lisp/org-latex.el

@@ -1795,7 +1795,8 @@ The conversion is made depending of STRING-BEFORE and STRING-AFTER."
   (let ((re (concat "\\\\[a-zA-Z]+\\(?:"
 		    "\\[.*\\]"
 		    "\\)?"
-		    (org-create-multibrace-regexp "{" "}" 3))))
+		    "\\(" (org-create-multibrace-regexp "{" "}" 3)
+		    "\\)\\{1,3\\}")))
     (while (re-search-forward re nil t)
       (unless (save-excursion (goto-char (match-beginning 0))
 			      (equal (char-after (point-at-bol)) ?#))