emacs-orgmode
[Top][All Lists]
Advanced

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

[O] interaction between org-latex-custom-lang-environments and name when


From: Alan Schmitt
Subject: [O] interaction between org-latex-custom-lang-environments and name when exporting to latex
Date: Mon, 16 Nov 2015 13:59:47 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (darwin)

Hello,

I want to export some code for a custom language environment (to be able
to use minted's global customization), and I find there is a strange
interaction with adding a name to the block. Here is an ECM.

Init file:
--8<---------------cut here---------------start------------->8---
(defvar emacsd-dir "~/.emacs.d/")
(add-to-list 'load-path (concat emacsd-dir "org/emacs/site-lisp/org"))
(require 'org)

(require 'ox-latex)

(setq org-latex-listings 'minted)

(setq org-latex-custom-lang-environments
      '((emacs-lisp "common-lisp-code")))
--8<---------------cut here---------------end--------------->8---

Org file:
--8<---------------cut here---------------start------------->8---
#+name: test
#+BEGIN_SRC emacs-lisp
(message "hello")
#+END_SRC
--8<---------------cut here---------------end--------------->8---

Exported latex (only for the source block):
--8<---------------cut here---------------start------------->8---
\begin{common-lisp-code}
(message "hello")
\label{orgsrcblock1}

\end{common-lisp-code}
--8<---------------cut here---------------end--------------->8---

The problem is the “\label” in the middle of the source block, which
plays badly with minted.

Is this a known bug?

Thanks,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Athmospheric CO₂ (Updated November 9, 2015, Mauna Loa Obs.): 399.06 ppm

Attachment: signature.asc
Description: PGP signature


reply via email to

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