emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Restore raw output in LaTeX export from in-line code block


From: Eric Schulte
Subject: Re: [O] Restore raw output in LaTeX export from in-line code block
Date: Wed, 02 Oct 2013 07:28:07 -0600
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Liam Healy <address@hidden> writes:

> On Sun, Sep 29, 2013 at 3:46 PM, Eric Schulte <address@hidden> wrote:
>> Liam Healy <address@hidden> writes:
>>
>>> I noticed that raw results from in-line code blocks were disappearing in
>>> the new LaTeX exporter, and bisected the repo to the change 7117ad4f92. I
>>> have created the attached patch to fix the problem and restore the previous
>>> behavior.
>>>
>>> example file
>>>       * Test
>>>         1. Inline common lisp raw: src_lisp[:results raw]{(+ 2 2)}, should
>>> say 4.
>>>
>>>
>>> Desired output, restored by patch
>>>   \item Inline common lisp raw: 4, should say 4.
>>> Output without patch
>>>    \item Inline common lisp raw: , should say 4.
>>>
>>> If this looks right, please apply.
>>>
>>> Liam
>>>
>>
>> Hi Liam,
>>
>> You're actually noticing a symptom of an error in the way lisp code
>> blocks were handling results (conflating the output/results and the
>> scalar/vector distinction).  I've just pushed up a fix, please let me
>> know if you continue to see these types of errors.
>>
>> Best,
>>
>> --
>> Eric Schulte
>> https://cs.unm.edu/~eschulte
>> PGP: 0x614CA05D
>
> Thanks Eric. Indeed, your patches work to produce the correct output
> for that case. Now I have another problem. I'm really not interested
> in producing "4" of course, what I do is use lisp to produce LaTeX.
> For example,
>
> + Inline common lisp raw: $src_lisp[:results raw]{(format nil
> "\\sqrt{2~c" (code-char 125))}$, should say "$\sqrt{2}$".
>
> Which used to produce (Org-mode version 7.9.4) the right thing,
> \item Inline common lisp raw: $\sqrt{2}$, should say ``$\sqrt{2}$".
> and now (Org-mode version 8.2.1) doesn't evaluate the lisp,
> \item Inline common lisp raw: $src_lisp[:results raw]{(format nil
> "\\sqrt{2~c" (code-char 125))}$, should say "$\sqrt{2}$".
>
> Is this a bug? How do I restore the evaluation of the src_lisp in this 
> context?
>

When I export a file such as the following,

#+Options: ^:{}

inline src_lisp[:results raw]{(format nil "\\sqrt{2~c" (code-char 125))} works
I do find that inline code blocks are evaluated on export resulting in
the following.

                            ━━━━━━━━━━━━━━━━
                             EXAMPLE-W-LISP
                            ━━━━━━━━━━━━━━━━


Table of Contents
─────────────────




inline "\\sqrt{2}" works
Are you able to interactively execute inline code blocks?

I'm not sure what the issue could be.

Best,

>
> Thanks.
> Liam

-- 
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D

reply via email to

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