Hi Rasmus,

On 2015-06-23 11:32, Rasmus <ras...@gmx.us> writes:

> Alan Schmitt <alan.schm...@polytechnique.org> writes:
>
>> Is there a way to tell org to leave the contents of myres blocks as-is?
>> Can I declare myres as a literal block?
>
> I think your issue here is similar to Jacob's a couple of weeks back.  I
> don't remember the outcome anymore, but check
>
>       http://thread.gmane.org/gmane.emacs.orgmode/97798

Thanks a lot for the link, I ended up using the solution from Charles
Berry:

have these header arguments

  :PROPERTIES:
  :header-args:js: :wrap latex :results output :exports both :post 
postenv("myres")
  :END:

and use this postenv wrapper

#+NAME: postenv
#+BEGIN_SRC emacs-lisp :var env="myres" :exports none
(format "$\\Rightarrow$ \\begin{%s}\n%s\\end{%s}" env *this* env)
#+END_SRC

The resulting latex is exactly what I want.

Thanks again,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Weekly CO₂ average (2015-05-30, Mauna Loa Observatory): 403.41 ppm

Attachment: signature.asc
Description: PGP signature

Reply via email to