From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrey Yankin Subject: Re: LaTeX export. Substitute some headlines with arbitrary command Date: Thu, 14 Mar 2013 12:07:38 +0400 Message-ID: References: <11008.1363220062@alphaville> <13742.1363241858@alphaville> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7b5d882321780504d7de0404 Return-path: Received: from eggs.gnu.org ([208.118.235.92]:47503) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UG3CS-0002Tw-84 for emacs-orgmode@gnu.org; Thu, 14 Mar 2013 04:07:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UG3CN-0008N1-DZ for emacs-orgmode@gnu.org; Thu, 14 Mar 2013 04:07:44 -0400 Received: from mail-vb0-x229.google.com ([2607:f8b0:400c:c02::229]:37611) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UG3CN-0008Mx-7n for emacs-orgmode@gnu.org; Thu, 14 Mar 2013 04:07:39 -0400 Received: by mail-vb0-f41.google.com with SMTP id l22so1041601vbn.28 for ; Thu, 14 Mar 2013 01:07:38 -0700 (PDT) In-Reply-To: <13742.1363241858@alphaville> 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: nicholas.dokos@hp.com, ccberry@ucsd.edu Cc: emacs-orgmode@gnu.org --047d7b5d882321780504d7de0404 Content-Type: text/plain; charset=ISO-8859-1 Charles, Nick, thanks for the tip of using filters. As far as I can see it requires version 8 of org-mode to be installed. Am I right? I am using now 7.8.11. I'll try to install a new version and check out filters. 2013/3/14 Nick Dokos > Andrey Yankin wrote: > > > Sorry if it wasn't clear. > > I should have illustrate this. > > > > Input: > > > > * Headline 1 > > ** Node 1.1 > > Content 1 > > * Headline 2 > > Content 2 > > * Headline 3 > > Content 3 > > * Headline 4 > > Content 4 > > * Headline 5 > > Content 5 > > > > Desired output: > > > > \intro > > \subsection{Node 1.1} > > Content 1 > > \section{Headline 2} > > Content 2 > > \section{Headline 3} > > Content 3 > > \section{Headline 4} > > Content 4 > > \conclusion > > Content 5 > > > > First and fifth top headlines output is replaced. And others are > defaults. > > All children keep the same. > > > > OK - I don't think you can do this with org-latex-classes: there is no > provision for exceptional cases there. Charles Berry suggested filters: > maybe something can be done with that. > > FWIW, I would just wait until the last minute and then when it's time to > produce the final pdf, I'd replace the two headlines by hand - but that > assumes that the document is a one-off, do-it-once-and-never-again kind > of thing. > > Nick > > > 2013/3/14 Nick Dokos > > > > Andrey Yankin wrote: > > > > > Hi! > > > > > > I want arbitrary top level headline to be exported not as \section > (or whatever it is) but > > with some > > > other arbitrary latex command. > > > > > > I even do not want to use headline text. Just write \intro instead > of \section{...} in tex > > file. > > > > > > I've tried some fiddling with :noexport: and :export: tags to hide > output for selected > > headlines. It > > > didn't work. > > > > > > Currently I'm heading to this metod: > http://stackoverflow.com/a/9679105 of creating my own > > parser. > > > > > > Are there any easier solutions? > > > > > > > Have you tried customizing the org-latex-classes variable? I'm not > quite > > sure what you are trying to do (an example would help), but I don't > see > > any obstacles. > > > > Nick > > > > > > ---------------------------------------------------- > > Alternatives: > > > > ---------------------------------------------------- > --047d7b5d882321780504d7de0404 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Charles, Nick, thanks for the tip of using filters.
As far as I can see it requires version 8 of org-mode to be installed. Am = I right?
I am using now 7.8.11.

I'll try to install a new ver= sion and check out filters.





2013/3/14 Nick Dokos <nicholas.dokos@hp.com>
Andrey Yankin <yankin013@gmail.com> wrote:

> Sorry if it wasn't clear.
> I should have illustrate this.
>
> Input:
>
> * Headline 1
> ** Node 1.1
> =A0 Content 1
> * Headline 2
> =A0 Content 2
> * Headline 3
> =A0 Content 3
> * Headline 4
> =A0 Content 4
> * Headline 5
> =A0 Content 5
>
> Desired output:
>
> \intro
> \subsection{Node 1.1}
> =A0 Content 1
> \section{Headline 2}
> =A0 Content 2
> \section{Headline 3}
> =A0 Content 3
> \section{Headline 4}
> =A0 Content 4
> \conclusion
> =A0 Content 5
>
> First and fifth top headlines output is replaced. And others are defau= lts.
> All children keep the same.
>

OK - I don't think you can do this with org-latex-classes: = there is no
provision for exceptional cases there. Charles Berry suggested filters:
maybe something can be done with that.

FWIW, I would just wait until the last minute and then when it's time t= o
produce the final pdf, I'd replace the two headlines by hand - but that=
assumes that the document is a one-off, do-it-once-and-never-again kind
of thing.

Nick

> 2013/3/14 Nick Dokos <nich= olas.dokos@hp.com>
>
> =A0 =A0 Andrey Yankin <yanki= n013@gmail.com> wrote:
>
> =A0 =A0 > Hi!
> =A0 =A0 >
> =A0 =A0 > I want arbitrary top level headline to be exported not as= \section (or whatever it is) but
> =A0 =A0 with some
> =A0 =A0 > other arbitrary latex command.
> =A0 =A0 >
> =A0 =A0 > I even do not want to use headline text. Just write \intr= o instead of \section{...} in tex
> =A0 =A0 file.
> =A0 =A0 >
> =A0 =A0 > I've tried some fiddling with :noexport: and :export:= tags to hide output for selected
> =A0 =A0 headlines. It
> =A0 =A0 > didn't work.
> =A0 =A0 >
> =A0 =A0 > Currently I'm heading to this metod: http://stackoverflow.com/a= /9679105 of creating my own
> =A0 =A0 parser.
> =A0 =A0 >
> =A0 =A0 > Are there any easier solutions?
> =A0 =A0 >
>
> =A0 =A0 Have you tried customizing the org-latex-classes variable? I&#= 39;m not quite
> =A0 =A0 sure what you are trying to do (an example would help), but I = don't see
> =A0 =A0 any obstacles.
>
> =A0 =A0 Nick
>
>
> ----------------------------------------------------
> Alternatives:
>
> ----------------------------------------------------

--047d7b5d882321780504d7de0404--