Hi Juan, I’d rather not have this merged at this stage, as I think it may be redundant once my conditional/generated export work makes its way into Org (next few months?). Juan Manuel Macías writes: > Rationale for this patch: in certain cases, in a LaTeX document, it is > necessary to add code before the class declaration (\documentclass…). > For example, commands like \PassOptionsToPackage, \DocumentMetadata{ }, > etc.; or certain packages that should be loaded first using > \RequirePackage{}; and other miscellaneous cases[1]. I think that by > defining a new keyword `latex_pre_header’, which behaves the same as > latex_header but concatenated before the class, these situations can be > resolved from Org. > > [1] A longer example to export to a pdf that has pdf-x compliance, with > the pdfx package: > > \providecommand{\pdfxopts}{x-1a} > \begin{filecontents*}{\jobname.xmpdata} > \Title{Some Title} > \Author{Author} > \Language{es-ES} > \Keywords{keywords} > \Publisher{publisher} > \end{filecontents*} > \documentclass{… All the best, Timothy -- Timothy (‘tecosaur’/‘TEC’), Org mode contributor. Learn more about Org mode at . Support Org development at , or support my work at .