Re: [O] Octave/Matlab Code Export Issue?

2014-03-13 Thread Eric S Fraga
Phil Regier preg...@math.ku.edu writes:

 I'm having trouble with Octave export, and I am not quite sure where to look.

 In an Org file I have the following:

#+BEGIN_SRC octave
  a = [1;3;5;7;9]
  b = [2;4;6;8]
  ans=a;
#+END_SRC octave

 When exporting to LaTeX I get the following:

 \#+BEGIN\_SRC octave
   a = [1;3;5;7;9]
   b = [2;4;6;8]
   ans=a;
 \#+END\_SRC octave

Remove octave from the #+end_src line.  There should be nothing else
on that line.
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.2, Org release_8.2.5h-709-g99f1ff



Re: [O] Octave/Matlab Code Export Issue?

2014-03-13 Thread Phil Regier
Wow; I'm embarrassed.  Thanks so much for the assist; terribly sorry to spam 
the list with such a simple error. X(

Phil

- Original Message -
From: Eric S Fraga e.fr...@ucl.ac.uk
To: Phil Regier preg...@math.ku.edu
Cc: emacs-orgmode@gnu.org
Sent: Thursday, March 13, 2014 11:08:36 AM
Subject: Re: [O] Octave/Matlab Code Export Issue?

Remove octave from the #+end_src line.  There should be nothing else
on that line.
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.2, Org release_8.2.5h-709-g99f1ff



Re: [O] Octave/Matlab Code Export Issue?

2014-03-13 Thread Charles Berry
Phil Regier pregier at math.ku.edu writes:

 
 I'm having trouble with Octave export, and I am not quite sure where to look.
 
 In an Org file I have the following:
 
#+BEGIN_SRC octave
  a = [1;3;5;7;9]
  b = [2;4;6;8]
  ans=a;
#+END_SRC octave
 


Instead try this:

--8---cut here---start-8---
#+NAME: abc
#+BEGIN_SRC octave
  a = [1;3;5;7;9]
  b = [2;4;6;8]
  ans=a;
#+END_SRC
--8---cut here---end---8---

Note that the #+END_SRC line has no trailing language nor anything else:

14.1 Structure of code blocks
=

Live code blocks can be specified with a `src' block or inline.(1)  The
structure of a `src' block is

 #+NAME: name
 #+BEGIN_SRC language switches header arguments
   body
 #+END_SRC


HTH,

Chuck




Re: [O] Octave/Matlab Code Export Issue?

2014-03-13 Thread Eric S Fraga
Phil Regier preg...@math.ku.edu writes:

 Wow; I'm embarrassed.  Thanks so much for the assist; terribly sorry
 to spam the list with such a simple error. X(

No need to be embarrassed.  This error catches me out *all* the time
which is why I know what to look for.

It would probably help if the fontification didn't make it look like a
valid line or if a check for unmatched #+begin_src lines were
performed.  The latter, however, is non-trivial I believe.

Anyway, glad it works.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.2, Org release_8.2.5h-709-g99f1ff



[O] Octave/Matlab Code Export Issue?

2014-03-12 Thread Phil Regier
I'm having trouble with Octave export, and I am not quite sure where to look.

In an Org file I have the following:

   #+BEGIN_SRC octave
 a = [1;3;5;7;9]
 b = [2;4;6;8]
 ans=a;
   #+END_SRC octave

When exporting to LaTeX I get the following:

\#+BEGIN\_SRC octave
  a = [1;3;5;7;9]
  b = [2;4;6;8]
  ans=a;
\#+END\_SRC octave

The style is consistent whether I export to LaTeX (buffer or PDF) or HTML; I've 
tried 'matlab' in lieu of 'octave', and various :results and :exports 
combinations, and I always get the literal output of the org syntax itself for 
the code, though I get a proper verbatim block of output contents when I export 
results.  'sh' and 'latex' blocks work properly (as do 'org' and 'awk' in other 
documents), exporting code and results alike without passing Org markup 
through, but this issue persists with octave on older and newer (emacs 24.3.1 
with org 8.2.5h) builds.  I've set the usual execution confirmation options and 
added matlab and octave to the loaded languages, and even disabled 
super/subscript rendering, all through customize, and even tried wiping out my 
.emacs and starting over just in case.

I've tried poking around the source but I don't know what I'm looking for; I 
don't see direct references to export/publish in ob-octave, and ox is way 
beyond me, I'm afraid.  Can anyone guess either what I'm doing wrong or where I 
might start looking look for such a language-specific, non-option-specific, 
non-backend-specific export glitch?

Thanks for any suggestions...

Phil