Suvayu Ali <fatkasuvayu+li...@gmail.com> writes: > On Tue, Jun 11, 2013 at 11:31:39AM +0200, Andreas Leha wrote: >> >> So I'd like to ask: Is there a possibility to get a really empty LaTeX >> export that reads everything (including the documentclass) from the >> #+LATEX_HEADER ? >> >> The reason for this is, that many journals/conferences come with their >> own LaTeX template (if I am lucky, that is). It would be very >> convenient, if I could just yank the provided header into my *.org >> file (and prefix with #+LATEX_HEADER). > > I think you can just define a minimal class in org-latex-classes; > something like > > \documentclass{article} > [NO-DEFAULT-PACKAGES] > [NO-PACKAGES] > [EXTRA] > > Then none of the packages listed in org-latex-default-packages-alist and > org-latex-packages-alist are included, and only the > #+LATEX_HEADER(_EXTRA) keywords are considered. > > Hope this helps,
Hi Suvayu, this did help, indeed. Thanks a lot. I did not think it was that easy. I found, that I can just omit the documentclass from the org-latex-classes. So, now I have: --8<---------------cut here---------------start------------->8--- (add-to-list 'org-latex-classes '("bare" " \[NO-DEFAULT-PACKAGES] \[NO-PACKAGES] \[EXTRA]" ("\\section{%s}" . "\\section*{%s}") ("\\subsection{%s}" . "\\subsection*{%s}") ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))) --8<---------------cut here---------------end--------------->8--- This should work in most cases. To use this I do: --8<---------------cut here---------------start------------->8--- #+OPTIONS: toc:nil author:nil skip:nil #+LATEX_CLASS: bare #+LATEX_HEADER: % everything from the template --8<---------------cut here---------------end--------------->8--- One problem remains, though: orgmode keeps messing with the title. I can, of course, set the title through #+TITLE: but I would prefer to set it through some #+LATEX_HEADER as the templates often require their own title setting directives. So, my follow-up question is: How can I get orgmode to not fiddle with the title in a LaTeX export? Regards, Andreas