Beamer: Put extra header last in header
* lisp/org-beamer.el (org-beamer-amend-header): Put extra header last in header. Tassilo Horn writes: > I'm doing a LaTeX beamer presentation with org. The org doc starts with > these lines: > > --8<---------------cut here---------------start------------->8--- > #+STARTUP: beamer > #+LaTeX_CLASS: beamer > #+TITLE: Implementieren, Integrieren, Installieren > #+AUTHOR: Tassilo Horn > #+EMAIL: horn@uni-koblenz.de > #+LANGUAGE: de > #+BEAMER_FRAME_LEVEL: 2 > #+LaTeX_CLASS_OPTIONS: [presentation] > #+BEAMER_HEADER_EXTRA: \usetheme[secheader]{Boadilla} \institute{Universitt Koblenz, IST} > --8<---------------cut here---------------end--------------->8--- > > In the presentation, the in Universitt is printed as an A with a ~ on > top, followed by a d'. The reason is that the BEAMER_HEADER_EXTRA is > put before the input encoding declaration. To be clear, org produces a > TeX file that starts with > > --8<---------------cut here---------------start------------->8--- > % Created 2010-07-06 Tue 08:57 > \documentclass[presentation]{beamer} > \usetheme[secheader]{Boadilla} \institute{Universitt Koblenz, IST} > \usepackage[utf8]{inputenc} > \usepackage[T1]{fontenc} > --8<---------------cut here---------------end--------------->8--- > > but it should be at least: > > --8<---------------cut here---------------start------------->8--- > % Created 2010-07-06 Tue 08:57 > \documentclass[presentation]{beamer} > \usepackage[utf8]{inputenc} > \usetheme[secheader]{Boadilla} \institute{Universitt Koblenz, IST} > \usepackage[T1]{fontenc} > --8<---------------cut here---------------end--------------->8--- > > In general, I'd say that it would be even more safe to put the extra > headers below all default headers.
This commit is contained in:
parent
4f26d13f52
commit
b7157cc666
|
@ -390,8 +390,8 @@ the value will be inserted right after the documentclass statement."
|
|||
((re-search-forward "^[ \t]*BEAMER-HEADER-EXTRA-HERE[ \t]*$" nil t)
|
||||
(replace-match org-beamer-header-extra t t)
|
||||
(or (bolp) (insert "\n")))
|
||||
((re-search-forward "^[ \t]*\\\\documentclass\\>" nil t)
|
||||
(beginning-of-line 2)
|
||||
((re-search-forward "^[ \t]*\\\\begin{document}" nil t)
|
||||
(beginning-of-line 1)
|
||||
(insert org-beamer-header-extra)
|
||||
(or (bolp) (insert "\n"))))))
|
||||
|
||||
|
|
Loading…
Reference in New Issue