emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* New LaTeX exporter and #+call:
@ 2012-09-14 20:51 Thomas S. Dye
  2012-09-15 13:29 ` Nicolas Goaziou
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas S. Dye @ 2012-09-14 20:51 UTC (permalink / raw)
  To: Org-mode

Aloha Nicolas,

#+call: lines appear to flummox the new LaTeX exporter.

This exports as I expect:

#+caption[Old wood]: Old wood graph.
#+label: fig:old-wood
#+results: old-wood[:file old-wood.pdf]():results file
[[file:old-wood.pdf]]

But this yields "\url{file://nil}":

#+call: old-wood[:file old-wood.pdf]() :results file
#+caption[Old wood]: Old wood graph.
#+label: fig:old-wood
#+results: old-wood[:file old-wood.pdf]():results file
[[file:old-wood.pdf]]

Similarly with tables, where export with the #+call: line looks like this:

\label{tab:old-wood}
\begin{verbatim}
nil
\end{verbatim}

All the best,
Tom

-- 
T.S. Dye & Colleagues, Archaeologists
735 Bishop St, Suite 315, Honolulu, HI 96813
Tel: 808-529-0866, Fax: 808-529-0884
http://www.tsdye.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: New LaTeX exporter and #+call:
  2012-09-14 20:51 New LaTeX exporter and #+call: Thomas S. Dye
@ 2012-09-15 13:29 ` Nicolas Goaziou
  2012-09-15 19:16   ` Thomas S. Dye
  0 siblings, 1 reply; 3+ messages in thread
From: Nicolas Goaziou @ 2012-09-15 13:29 UTC (permalink / raw)
  To: Thomas S. Dye; +Cc: Org-mode

Hello,

tsd@tsdye.com (Thomas S. Dye) writes:

> #+call: lines appear to flummox the new LaTeX exporter.
>
> This exports as I expect:
>
> #+caption[Old wood]: Old wood graph.
> #+label: fig:old-wood
> #+results: old-wood[:file old-wood.pdf]():results file
> [[file:old-wood.pdf]]

It doesn't matter here, but #+label ought to be to #+name in the new
exporter.

> But this yields "\url{file://nil}":
>
> #+call: old-wood[:file old-wood.pdf]() :results file
> #+caption[Old wood]: Old wood graph.
> #+label: fig:old-wood
> #+results: old-wood[:file old-wood.pdf]():results file
> [[file:old-wood.pdf]]

I cannot reproduce the problem. It may be an hiccup in your "old-wood"
src-block, which you didn't provide.

You may try to eval:

  (let ((org-current-export-file (current-buffer))) (org-export-blocks-preprocess))

in a copy of the buffer you're trying to export. It will reveal what the
parser really see. Is there anything suspicious?


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: New LaTeX exporter and #+call:
  2012-09-15 13:29 ` Nicolas Goaziou
@ 2012-09-15 19:16   ` Thomas S. Dye
  0 siblings, 0 replies; 3+ messages in thread
From: Thomas S. Dye @ 2012-09-15 19:16 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: Org-mode

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> Hello,
>
> tsd@tsdye.com (Thomas S. Dye) writes:
>
>> #+call: lines appear to flummox the new LaTeX exporter.
>>
>> This exports as I expect:
>>
>> #+caption[Old wood]: Old wood graph.
>> #+label: fig:old-wood
>> #+results: old-wood[:file old-wood.pdf]():results file
>> [[file:old-wood.pdf]]
>
> It doesn't matter here, but #+label ought to be to #+name in the new
> exporter.
>
Thanks.

>> But this yields "\url{file://nil}":
>>
>> #+call: old-wood[:file old-wood.pdf]() :results file
>> #+caption[Old wood]: Old wood graph.
>> #+label: fig:old-wood
>> #+results: old-wood[:file old-wood.pdf]():results file
>> [[file:old-wood.pdf]]
>
> I cannot reproduce the problem. It may be an hiccup in your "old-wood"
> src-block, which you didn't provide.
>
> You may try to eval:
>
>   (let ((org-current-export-file (current-buffer)))
> (org-export-blocks-preprocess))
>
> in a copy of the buffer you're trying to export. It will reveal what the
> parser really see. Is there anything suspicious?

Interesting.  If I evaluate org-export-blocks-preprocess, all looks well
and the resulting buffer exports correctly with org-export-dispatch.
The evaluated results of the #+call: lines are present in the
preprocessed buffer, and the #+call: lines themselves are gone.

Apparently, something else happens when the original buffer is exported
with org-export-dispatch. This route appears to ignore the evaluated
results of the #+call: lines and instead uses the results of a new call.
This was failing for me because I'd set :eval no-export on the source
code blocks after I'd evaluated the #+call: lines in the buffer,
thinking that the exporter would find the results and use them.

Thanks for your help, and apologies for the noisy posts.

All the best,
Tom

-- 
Thomas S. Dye
http://www.tsdye.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-09-15 19:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-14 20:51 New LaTeX exporter and #+call: Thomas S. Dye
2012-09-15 13:29 ` Nicolas Goaziou
2012-09-15 19:16   ` Thomas S. Dye

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).