From: Nick Dokos <ndokos@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: how putting \begin{document} at the right place to export a specific latex class ?
Date: Mon, 11 Jun 2018 15:17:15 -0400 [thread overview]
Message-ID: <874li9m8uc.fsf@alphaville.usersys.redhat.com> (raw)
In-Reply-To: 87muw1a40g.fsf@gmail.com
Joseph Vidal-Rosset <joseph.vidal.rosset@gmail.com> writes:
> Here is my problem: for a specific latex class (xxllp.cls), I have
> difficulties to get the \begin{document} at the right place in this
> add-to-list:
>
> (add-to-list 'org-latex-classes
> '("xxllp"
> "\\documentclass\[oumk,xs]\{xxllp\}
> [NO-DEFAULT-PACKAGES]
> [NO-PACKAGES]
> \\usepackage{amsmath}
> \\usepackage{amssymb}
> \\usepackage{blabla}
> \\usepackage{blablabla}
> \\pagestyle{myheadings}\\markboth{Author}{Title of the paper}
> \\LaLPonline{??} \\setcounter{page}{1} \\thispagestyle{LLPrrobezissn} \\label{p}
> \\AuthorTitle{Joseph Vidal-Rosset}{\\uppercase{Title of the paper}}"
> ("\\section\{%s\} . \\section*\{%s\}")
> ("\\subsection\{%s\} . \\subsection*\{%s\}")
> ))
>
>
> For this class, the \begin{document} should be just after
> \\pagestyle{myheadings}\\markboth{Author}{Title of the paper}
> and just before
> \\LaLPonline{??} \\setcounter{page}{1} \\thispagestyle{LLPrrobezissn}
> \\label{p}
>
I don't think you can do that with org-latex-classes: you can define
the header part (i.e. some of what goes before the \begin{document}_
and you can define how to map headers at different depths to the latex
sectioning structure, but you cannot do precise placement the way that
you are trying to.
There may be a better way now, but in the old days I used to redefine
the org-latex-title-command variable. It gets emitted after the
\begin{document} so you can do something like this
(setq org-latex-title-command "\\foo\\maketitle")
to insert additional stuff.
--
Nick
"There are only two hard problems in computer science: cache
invalidation, naming things, and off-by-one errors." -Martin Fowler
next prev parent reply other threads:[~2018-06-11 19:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-11 12:42 how putting \begin{document} at the right place to export a specific latex class ? Joseph Vidal-Rosset
2018-06-11 14:01 ` John Kitchin
2018-06-11 14:16 ` Joseph Vidal-Rosset
2018-06-11 14:23 ` John Kitchin
2018-06-11 15:29 ` Joseph Vidal-Rosset
2018-06-11 16:51 ` John Kitchin
2018-06-11 19:17 ` Nick Dokos [this message]
2018-06-11 22:58 ` Tim Cross
2018-06-12 7:08 ` Joseph Vidal-Rosset
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874li9m8uc.fsf@alphaville.usersys.redhat.com \
--to=ndokos@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.