[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Confused about src vs example and LaTeX export
From: |
Norman Walsh |
Subject: |
Confused about src vs example and LaTeX export |
Date: |
Sun, 05 Jan 2020 10:53:10 +0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.3 (darwin) |
Hello again,
I’m confused about the distinction between BEGIN_EXAMPLE and BEGIN_SRC
and LaTeX export. I tend to use BEGIN_SRC more often because I’m
taking advantage of Babel output.
Consider this file:
#+TITLE: Test Org File
This is an example.
* Simple environments
#+BEGIN_EXAMPLE emacs-lisp
(+ 3 4)
#+END_EXAMPLE
#+BEGIN_SRC emacs-lisp
(+ 3 4)
#+END_SRC
* LaTeX attributes
#+ATTR_LATEX: :environment lstlisting
#+BEGIN_EXAMPLE emacs-lisp
(+ 3 4)
#+END_EXAMPLE
#+ATTR_LATEX: :environment lstlisting
#+BEGIN_SRC emacs-lisp
(+ 3 4)
#+END_SRC
In the simple case, both EXAMPLE and SRC export as {verbatim}
environments; that’s fine as a default. In the second case, the
ATTR_LATEX request for the {lstlisting} environment works on EXAMPLE
but appears to be ignored on SRC.
To confound me further, setting org-latex-custom-lang-environments
doesn’t seem to have any effect in either case.
(setq org-latex-custom-lang-environments
'((emacs-lisp "lstlisting")))
I’m not sure what I’m overlooking.
Be seeing you,
norm
--
Norman Walsh <address@hidden> | There has never been a perfect
http://nwalsh.com/ | government, because men have passions;
| and if they did not have passions,
| there would be no need for
| government.--Voltaire
signature.asc
Description: PGP signature
- Confused about src vs example and LaTeX export,
Norman Walsh <=