[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Captions for src and example blocks

From: Nicolas Goaziou
Subject: Re: [O] Captions for src and example blocks
Date: Sat, 14 Jan 2012 09:43:38 +0100


Christian Wittern <address@hidden> writes:

> There was a thread last April about a way to introduce captions and
> labels to src and example blocks (see
> http://lists.gnu.org/archive/html/emacs-orgmode/2011-04/msg00877.html).
>  Now I would like to use captions in a similar way, but not just for
> LaTex, but also for the ODT export.  So a generic org-mode solution
> would be much more helpful. I wonder if somebody has any idea about
> how to achieve this.

The new export engine has support for captions and labels for almost any
element, through the use of affiliated keywords. Thus, the following
special block will have ":caption" and ":name" properties attached to

--8<---------------cut here---------------start------------->8---
#+caption: Here is /something/.
#+name: something
A special "something" block.
--8<---------------cut here---------------end--------------->8---

Now, it doesn't mean that it will do anything during export, as
back-ends can choose to make use of those properties or ignore them.

With regards to the previous special block, the e-latex back-end
currently makes use of the :name property, but ignore the :caption one.
Though it's not hard to support this by modifying accordingly the
`org-e-latex-special-block' function.


Nicolas Goaziou

reply via email to

[Prev in Thread] Current Thread [Next in Thread]