From mboxrd@z Thu Jan 1 00:00:00 1970 From: Feng Shu Subject: Re: Better way to specify the latex documentclass of an exported file without changing my configuration? Date: Wed, 26 Mar 2014 17:24:36 +0800 Message-ID: <87ob0tjorv.fsf@news.tumashu-localhost.org> References: Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44176) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WSkFJ-0002a2-GK for emacs-orgmode@gnu.org; Wed, 26 Mar 2014 05:35:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WSkFC-00056P-Ps for emacs-orgmode@gnu.org; Wed, 26 Mar 2014 05:35:41 -0400 Received: from plane.gmane.org ([80.91.229.3]:51095) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WSkFC-00055s-JX for emacs-orgmode@gnu.org; Wed, 26 Mar 2014 05:35:34 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WSkFB-0001Sx-M2 for emacs-orgmode@gnu.org; Wed, 26 Mar 2014 10:35:33 +0100 Received: from 120.4.230.251 ([120.4.230.251]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 26 Mar 2014 10:35:33 +0100 Received: from tumashu by 120.4.230.251 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 26 Mar 2014 10:35:33 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Alan Schmitt writes: > Hello, > > I'm collaborating on a paper with some colleagues, and I convinced them > to use org-mode. I'm trying to make sure the paper is as self-contained > as possible (I don't want them to have to change their emacs > configuration file).To change the documentclass name of the exported Maybe you can write a Makefile to change their emacs configure... > article, I added the following block in a section that is not exported: > --8<---------------cut here---------------start------------->8--- > #+begin_src emacs-lisp :results silent :exports results > (add-to-list 'org-latex-classes > '("llncs" > "\\documentclass{llncs}" > ("\\section{%s}" . "\\section*{%s}") > ("\\subsection{%s}" . "\\subsection*{%s}") > ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))) > #+end_src > --8<---------------cut here---------------end--------------->8--- > > My questions are: > - is there a way to do this without an emacs-lisp block? > - is there a nicer way to make sure that an emacs-lisp block is > evaluated upon export than ":exports results :results silent"? (If > I don't put it there, the block is not evaluated.) > - is there a way to just say the name of the documentclass without all > the boilerplate code below? In other words, can I say "this is a llncs > documentclass with the same sectioning as an article"? You should defun a classe for llncs.sty before use it. maybe you can rename llncs.sty to article.sty, and put it to directory which contain your org file. > > Thanks, > > Alan --