Quellcode durchsuchen

BEAMER: Standardize the header cookie for the beamer extra stuff

* lisp/org-beamer.el (org-beamer-amend-header): Standardize the
header cookie for the beamer extra stuff.
Carsten Dominik vor 14 Jahren
Ursprung
Commit
2cc4c0d564
2 geänderte Dateien mit 3 neuen und 1 gelöschten Zeilen
  1. 2 1
      lisp/org-beamer.el
  2. 1 0
      lisp/org-latex.el

+ 2 - 1
lisp/org-beamer.el

@@ -387,7 +387,8 @@ the value will be inserted right after the documentclass statement."
 	     org-beamer-header-extra)
 	     org-beamer-header-extra)
     (goto-char (point-min))
     (goto-char (point-min))
     (cond
     (cond
-     ((re-search-forward "^[ \t]*BEAMER-HEADER-EXTRA-HERE[ \t]*$" nil t)
+     ((re-search-forward
+       "^[ \t]*\\[?BEAMER-HEADER-EXTRA\\(-HERE\\)?\\]?[ \t]*$" nil t)
       (replace-match org-beamer-header-extra t t)
       (replace-match org-beamer-header-extra t t)
       (or (bolp) (insert "\n")))
       (or (bolp) (insert "\n")))
      ((re-search-forward "^[ \t]*\\\\begin{document}" nil t)
      ((re-search-forward "^[ \t]*\\\\begin{document}" nil t)

+ 1 - 0
lisp/org-latex.el

@@ -148,6 +148,7 @@ class, you can use the following macro-like placeholders.
  [NO-PACKAGES]           do not include the packages
  [NO-PACKAGES]           do not include the packages
  [EXTRA]                 the stuff from #+LaTeX_HEADER
  [EXTRA]                 the stuff from #+LaTeX_HEADER
  [NO-EXTRA]              do not include #+LaTeX_HEADER stuff
  [NO-EXTRA]              do not include #+LaTeX_HEADER stuff
+ [BEAMER-HEADER-EXTRA]   the beamer extra headers
 
 
 So a header like
 So a header like