all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [BUG] new exporter and #+BEGIN_CENTER
@ 2012-07-17 23:31 cberry
  2012-07-17 23:45 ` Nicolas Goaziou
  2012-07-17 23:50 ` Jambunathan K
  0 siblings, 2 replies; 5+ messages in thread
From: cberry @ 2012-07-17 23:31 UTC (permalink / raw)
  To: emacs-orgmode



This throws an error:

------------------------------
* headline 1

#+BEGIN_CENTER

#+BEGIN_SRC R :exports both
rnorm(10)
#+END_SRC

#+END_CENTER
------------------------------

M-:  (org-export-to-buffer 'e-latex "latex buffer") RET 

It does not run the src block and the error is:

 (error "Invalid search bound (wrong side of point)")
  re-search-forward("@@[-A-Za-z0-9]+:" 31 t)
[snip]
 org-element-export-snippet-successor(31)
[rest deleted]

Removing the whitespace between the BEGIN_CENTER and BEGIN_SRC lines
runs, but wrongly fails to execute the src block.

Removing the CENTER results in running the src block and producing the
expected result.

My last pull was yesterday: b7be665..69af091

HTH,

Chuck

-- 
Charles C. Berry                            Dept of Family/Preventive Medicine
cberry at ucsd edu			    UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/  La Jolla, San Diego 92093-0901

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

* Re: [BUG] new exporter and #+BEGIN_CENTER
  2012-07-17 23:31 [BUG] new exporter and #+BEGIN_CENTER cberry
@ 2012-07-17 23:45 ` Nicolas Goaziou
  2012-07-17 23:50 ` Jambunathan K
  1 sibling, 0 replies; 5+ messages in thread
From: Nicolas Goaziou @ 2012-07-17 23:45 UTC (permalink / raw)
  To: cberry; +Cc: emacs-orgmode

Hello,

cberry@tajo.ucsd.edu writes:

> This throws an error:
>
> ------------------------------ * headline 1
>
> #+BEGIN_CENTER
>
> #+BEGIN_SRC R :exports both
> rnorm(10)
> #+END_SRC
>
> #+END_CENTER
> ------------------------------
>
> M-:  (org-export-to-buffer 'e-latex "latex buffer") RET 
>
> It does not run the src block and the error is:
>
>  (error "Invalid search bound (wrong side of point)")
>   re-search-forward("@@[-A-Za-z0-9]+:" 31 t)
> [snip]
>  org-element-export-snippet-successor(31)
> [rest deleted]
>
> Removing the whitespace between the BEGIN_CENTER and BEGIN_SRC lines
> runs, but wrongly fails to execute the src block.
>
> Removing the CENTER results in running the src block and producing the
> expected result.
>
> My last pull was yesterday: b7be665..69af091

I cannot reproduce it, but I fixed something similar recently. You may
want to upgrade a try again.


Regards,

-- 
Nicolas Goaziou

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

* Re: [BUG] new exporter and #+BEGIN_CENTER
  2012-07-17 23:31 [BUG] new exporter and #+BEGIN_CENTER cberry
  2012-07-17 23:45 ` Nicolas Goaziou
@ 2012-07-17 23:50 ` Jambunathan K
  2012-07-18  3:52   ` cberry
  1 sibling, 1 reply; 5+ messages in thread
From: Jambunathan K @ 2012-07-17 23:50 UTC (permalink / raw)
  To: cberry; +Cc: emacs-orgmode


Center within Src.  I don't think you can nest the blocks.

The cryptic message is org-export.el way of saying that there is a parse
error or that the Org file doesn't to conform to schema.

> This throws an error:
>
> ------------------------------
> * headline 1
>
> #+BEGIN_CENTER
>
> #+BEGIN_SRC R :exports both
> rnorm(10)
> #+END_SRC
>
> #+END_CENTER
> ------------------------------
>
> M-:  (org-export-to-buffer 'e-latex "latex buffer") RET 
>
> It does not run the src block and the error is:
>
>  (error "Invalid search bound (wrong side of point)")
>   re-search-forward("@@[-A-Za-z0-9]+:" 31 t)
> [snip]
>  org-element-export-snippet-successor(31)
> [rest deleted]
>
> Removing the whitespace between the BEGIN_CENTER and BEGIN_SRC lines
> runs, but wrongly fails to execute the src block.
>
> Removing the CENTER results in running the src block and producing the
> expected result.
>
> My last pull was yesterday: b7be665..69af091
>
> HTH,
>
> Chuck

-- 

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

* Re: [BUG] new exporter and #+BEGIN_CENTER
  2012-07-17 23:50 ` Jambunathan K
@ 2012-07-18  3:52   ` cberry
  2012-07-18  7:56     ` Nicolas Goaziou
  0 siblings, 1 reply; 5+ messages in thread
From: cberry @ 2012-07-18  3:52 UTC (permalink / raw)
  To: emacs-orgmode

Jambunathan K <kjambunathan@gmail.com> writes:

> Center within Src.  I don't think you can nest the blocks.
>

It seems you are right. At least as far as executing the src block is concerned.

I was thinking along the lines of LaTeX's center environment, but I see
now that a src block within a CENTER didn't work with the old exporter
either.

> The cryptic message is org-export.el way of saying that there is a parse
> error or that the Org file doesn't to conform to schema.

The latest git pull gives no error - it just doesn't run the src block.


>
>> This throws an error:
>>
>> ------------------------------
>> * headline 1
>>
>> #+BEGIN_CENTER
>>
>> #+BEGIN_SRC R :exports both
>> rnorm(10)
>> #+END_SRC
>>
>> #+END_CENTER
>> ------------------------------
>>
>> M-:  (org-export-to-buffer 'e-latex "latex buffer") RET 
>>
>> It does not run the src block and the error is:
>>
>>  (error "Invalid search bound (wrong side of point)")
>>   re-search-forward("@@[-A-Za-z0-9]+:" 31 t)
>> [snip]
>>  org-element-export-snippet-successor(31)
>> [rest deleted]
>>
>> Removing the whitespace between the BEGIN_CENTER and BEGIN_SRC lines
>> runs, but wrongly fails to execute the src block.
>>
>> Removing the CENTER results in running the src block and producing the
>> expected result.
>>
>> My last pull was yesterday: b7be665..69af091
>>
>> HTH,
>>
>> Chuck

-- 
Charles C. Berry                            Dept of Family/Preventive Medicine
cberry at ucsd edu			    UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/  La Jolla, San Diego 92093-0901

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

* Re: [BUG] new exporter and #+BEGIN_CENTER
  2012-07-18  3:52   ` cberry
@ 2012-07-18  7:56     ` Nicolas Goaziou
  0 siblings, 0 replies; 5+ messages in thread
From: Nicolas Goaziou @ 2012-07-18  7:56 UTC (permalink / raw)
  To: cberry; +Cc: emacs-orgmode, Eric Schulte

Hello,

cberry@tajo.ucsd.edu writes:

> Jambunathan K <kjambunathan@gmail.com> writes:
>
>> Center within Src.  I don't think you can nest the blocks.
>>
>
> It seems you are right. At least as far as executing the src block is
> concerned.

It's perfectly fine to nest blocks (as long as you don't nest blocks of
the same type – maybe I should allow this, btw).

It looks like a limitation from `org-export-blocks-preprocess' (that is
Babel).  Unless there's a good reason behind it, I think it can be
removed.  Eric Schulte (CCed) may have an answer.

There are a couple of changes to make in this function anyway once
org-element hits core.


Regards,

-- 
Nicolas Goaziou

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

end of thread, other threads:[~2012-07-18  7:59 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-07-17 23:31 [BUG] new exporter and #+BEGIN_CENTER cberry
2012-07-17 23:45 ` Nicolas Goaziou
2012-07-17 23:50 ` Jambunathan K
2012-07-18  3:52   ` cberry
2012-07-18  7:56     ` Nicolas Goaziou

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.