[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Two modifications for source blocks processing (will be in 7.9.2
From: |
Sebastien Vauban |
Subject: |
Re: [O] Two modifications for source blocks processing (will be in 7.9.2) |
Date: |
Wed, 26 Sep 2012 22:20:08 +0200 |
User-agent: |
Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.1 (windows-nt) |
Hi Thomas,
A (very) quick answer...
Thomas S. Dye wrote:
> Sebastien Vauban writes:
>> Bastien wrote:
>>> this is to advertize two small modifications wrt source blocks
>>> processing.
>>>
>>> 1) Please use ":results drawer" instead of ":results wrap" to insert
>>> results like this:
>>>
>>> #+BEGIN_SRC emacs-lisp :results drawer
>>> (message "a")
>>> #+END_SRC
>>>
>>> #+RESULTS:
>>> :RESULTS:
>>> a
>>> :END:
>>
>> OK. That name is clearly better!
>>
>>> 2) Support for ":results org" has been removed.
>>
>> Why don't we have anymore "#+begin/end_org" blocks while we still have
>> "#+begin_html" and "#+begin_LaTeX" blocks? Org as the language seemed normal
>> to insert blocks in Org-syntax.
>>
>> How will Org constructs be supported, for example headlines in the old
>> "#+begin/end_org" blocks -- with the "," used for protecting the export?
>>
>> #+begin_src org
>> ,* This is an headline
>> ,This is some text.
>> #+end_src
>>
>>> You can either insert the results with ":results raw" or "results drawer"
>>> if you need to tell the exporter to include/exclude the results (by
>>> including/excluding the :RESULTS: drawer from export.)
>>
>> Will ":RESULTS:" drawers be included by default, to mimic the current support
>> of "#+begin/end_org" blocks?
>
> :results org was a synonym for :results raw
No!
With :results raw, the raw output is inserted directly into the Org mode
buffer. This is a good option if your code block will output *Org mode
formatted text* (this will even be fontified as Org text you would have typed
yourself).
As there are *no obvious markers to delimit the results* in the Org mode file,
there is no way to know where raw results begin or end: raw results *cannot be
removed* from the buffer.
With :results org, raw Org mode results will be harmlessly *wrapped in a Org
mode block*. The "#+begin/end_org" block wrapper makes it possible for the
entirety of the results to be clearly located and replaced upon code block
re-evaluation.
> so I think "small change" here probably means that support for the synonym
> was dropped.
Hence, not a synonym.
> #+begin/end_org blocks should still work with the :wrap header argument,
> which hasn't been altered, IIUC.
No. AFAICT:
- "wrap" will disappear (renamed as "drawer"),
- "drawer" is not the same as the old "org" option (as the results gets
inserted into a drawer, not into a block).
Best regards,
Seb
--
Sebastien Vauban