From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas S. Dye Subject: Re: html export Date: Sun, 20 Jun 2010 10:54:16 -1000 Message-ID: <72BE7A36-2C7D-4343-A87D-2A2CB0288E33@tsdye.com> References: <871vc28js3.fsf@gmail.com> <48C8312A-7793-49D0-AA26-24AB15AC662F@tsdye.com> <877hlt606l.fsf@gmail.com> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: multipart/mixed; boundary="===============1897099572==" Return-path: Received: from [140.186.70.92] (port=44343 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OQRX9-00020k-My for emacs-orgmode@gnu.org; Sun, 20 Jun 2010 16:54:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OQRX8-00079t-CS for emacs-orgmode@gnu.org; Sun, 20 Jun 2010 16:54:27 -0400 Received: from oproxy2-pub.bluehost.com ([67.222.39.60]:33893) by eggs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1OQRX8-00079l-4A for emacs-orgmode@gnu.org; Sun, 20 Jun 2010 16:54:26 -0400 In-Reply-To: <877hlt606l.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Eric Schulte , nicholas.dokos@hp.com Cc: Org Mode --===============1897099572== Content-Type: multipart/alternative; boundary=Apple-Mail-9-259829566 --Apple-Mail-9-259829566 Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Hi Eric, On Jun 20, 2010, at 8:14 AM, Eric Schulte wrote: > "Thomas S. Dye" writes: > > [...] >> Removing the blank line doesn't work for me either. >> >> Org-mode version 6.36trans (release_6.36.291.gaf90f) >> > > Hmm, I just tried the above again using the HEAD (same org-version > output as you have above) of the org-mode git repository and a minimal > emacs config, and it *is* working for me, so maybe your problems > will be > resolved with an update of org-mode, or maybe they're due to something > in your config? > >> >> Ah, I'm finally able to reproduce the problem in my larger file. >> Here >> is an example: >> >> * No results exported >> >> #+srcname: problem >> #+begin_src R >> b <- 4 >> #+end_src >> >> #+results: problem >> [[file:~/Public/projects/903_adzes/r/sr-nb-scatter.png]] >> >> The key is that srcname: and results: have the same name. Changing >> the results: name works. >> >> * Results exported >> >> #+srcname: problem >> #+begin_src R >> b <- 4 >> #+end_src >> >> #+results: problem-not >> [[file:~/Public/projects/903_adzes/r/sr-nb-scatter.png]] >> > > Yes, the key with the above is that babel by default only exports the > code of a code block, which means that if there are results in the > buffer they will be removed on export. If you want both the code and > the results to be exported then change > > #+srcname: problem > #+begin_src R > b <- 4 > #+end_src > > to > > #+srcname: problem > #+begin_src R :exports both > b <- 4 > #+end_src > > Hope this helps -- Eric I didn't pay close attention when the default behavior changed. Adding #+property: exports both gets me back where I was before. Also, following on Nick's message, the captions exported properly to html with absolute paths in the links and with lots of space between the caption and link. Here's an example that exported properly: #+CAPTION: Pairwise comparison of six metric variables #+LABEL: fig:pairwise #+srcname: pairs #+begin_src R :results output :var x=whole-adzes :file r/adze_pairs.png whole.adze.metric <- x[,c(5,12,15,16,17,18)] names(whole.adze.metric) <- c("wt","len","edge","front","back","thick") pairs(whole.adze.metric) #+end_src #+results: pairs [[file:r/adze_pairs.png]] Thanks for your help. Tom --Apple-Mail-9-259829566 Content-Type: text/html; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Hi Eric,

On = Jun 20, 2010, at 8:14 AM, Eric Schulte wrote:

"Thomas= S. Dye" <tsd@tsdye.com> = writes:

[...]
Removing the blank = line doesn't work for me either.

Org-mode = version 6.36trans (release_6.36.291.gaf90f)


Hmm, I just tried the above again = using the HEAD (same org-version
output as you have above) of the = org-mode git repository and a minimal
emacs config, and it *is* = working for me, so maybe your problems will be
resolved with an = update of org-mode, or maybe they're due to something
in your = config?


Ah, I'm finally able to reproduce the problem in my larger = file.  Here
is an = example:

* No results = exported

#+srcname: = problem
#+begin_src = R
 b <- = 4
#+end_src

#+results: = problem
[[file:~/Public/projects/903_adzes/r/sr-nb-scatter.png]]
=

The key is that srcname: and results: have the same name. =  Changing
the results: = name works.

* Results = exported

#+srcname: = problem
#+begin_src = R
 b <- = 4
#+end_src

#+results: = problem-not
[[file:~/Public/projects/903_adzes/r/sr-nb-scatter.png]]
=


Yes, the key = with the above is that babel by default only exports the
code of a = code block, which means that if there are results in the
buffer they = will be removed on export.  If you want both the code and
the = results to be exported then change

 #+srcname: problem
=  #+begin_src R
   b <- 4
=  #+end_src

to

 #+srcname: problem
=  #+begin_src R :exports both
   b <- 4
=  #+end_src

Hope this helps -- = Eric

I didn't pay close = attention when the default behavior changed.  Adding #+property: exports = both gets me back where I was before. =  

Also, following on Nick's message, the = captions exported properly to html with absolute paths in the links and = with lots of space between the caption and link.  Here's an example = that exported properly:

#+CAPTION: = Pairwise comparison of six metric variables
#+LABEL: = fig:pairwise

#+srcname: = pairs
#+begin_src R :results output :var x=3Dwhole-adzes :file = r/adze_pairs.png
  whole.adze.metric <- = x[,c(5,12,15,16,17,18)]
  names(whole.adze.metric) = <- = c("wt","len","edge","front","back","thick")
  pairs(wh= ole.adze.metric)
#+end_src

#+results: = pairs
[[file:r/adze_pairs.png]]

T= hanks for your = help.

Tom


= --Apple-Mail-9-259829566-- --===============1897099572== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --===============1897099572==--