emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to expand macro in LaTeX export? How to use different options pe


From: Jean Louis
Subject: Re: How to expand macro in LaTeX export? How to use different options per export type?
Date: Wed, 31 Mar 2021 13:29:11 +0300
User-agent: Mutt/2.0.6 (2021-03-06)

* Eric S Fraga <e.fraga@ucl.ac.uk> [2021-03-31 13:06]:
> On Wednesday, 31 Mar 2021 at 12:40, Jean Louis wrote:
> > But then the line with \def\version{ {{{version}}} } gets shown in
> > HTML export, which is not what I want. How to resolve that?
> 
> Can you surround the line with @@latex: ... @@?
> 
> You might need to do @@latex:\def\version{@@ {{{version}}}
> @@latex:}@@

I did not know this, it looks like a solution in sight. Thank you.

By doing this:

@@latex:\def\version{@@ {{{version}}} @@latex:}@@

Then {{{version}}} will get expanded in the document, right? As I have
hidden then only tags surrounding {{{version}}}.

> Also, a macro can itself use the @@ directive to provide alternate
> versions for LaTeX and HTML, as in
> 
> #+macro: blah @@html:some HTML code@@@@latex: some LaTeX code@@

I have tried this:

#+OPTIONS: @@html:title:t toc:t@@ @@latex:title:nil toc:nil@@ todo:nil

But it is not working in options. It would be good if it works in OPTIONS.

-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns




reply via email to

[Prev in Thread] Current Thread [Next in Thread]