ox-latex: Don't add optional title on unnumbered headlines

* lisp/ox-latex.el (org-latex-headline): Don't add optional title on
  unnumbered headlines.
This commit is contained in:
Nicolas Goaziou 2013-03-04 21:18:34 +01:00
parent 3ab73c4816
commit cd23825d62
1 changed files with 2 additions and 1 deletions

View File

@ -1487,7 +1487,8 @@ holding contextual information."
(org-export-data (org-export-data
(org-export-get-alt-title headline info) info) (org-export-get-alt-title headline info) info)
(and (eq (plist-get info :with-tags) t) tags)))) (and (eq (plist-get info :with-tags) t) tags))))
(if (and opt-title (string-match "\\`\\\\\\(.*?[^*]\\){" section-fmt)) (if (and numberedp opt-title
(string-match "\\`\\\\\\(.*?[^*]\\){" section-fmt))
(format (replace-match "\\1[%s]" nil nil section-fmt 1) (format (replace-match "\\1[%s]" nil nil section-fmt 1)
;; Replace square brackets with parenthesis ;; Replace square brackets with parenthesis
;; since square brackets are not supported in ;; since square brackets are not supported in