Please consider the following, self-contained
.org file MVE, which I hope is self-explanatory:
#+OPTIONS: toc:nil Figure [[captions-work-for-src-blocks]] shows that captions are correctly exported for SRC blocks. The second figure, in an EXAMPLE block, does not receive an exported caption. Furthermore, cross references to figure [[captions-dont-work-for-example-blocks]] incorrectly resolve to figure [[captions-work-for-src-blocks]]. ----- #+NAME: captions-work-for-src-blocks #+CAPTION: Captions work for SRC blocks #+BEGIN_SRC foo(bar) == baz(qux); #+END_SRC ----- ----- #+NAME: captions-dont-work-for-example-blocks #+CAPTION: Captions don't work for EXAMPLE blocks #+BEGIN_EXAMPLE foo(bar) == baz(qux); #+END_EXAMPLE -----
org-latex-export-to-pdf, it produces the following output:
I'm using the following versions of the software:
: Emacs version: GNU Emacs 25.1.1 (x86_64-apple-darwin13.4.0, NS appkit-1265.21 Version 10.9.5 (Build 13F1911)) : of 2016-09-17 : org version: 9.0.7
I looked at the official org-mode documentation, but I could not find information relating to this issue.