emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* interaction between org-latex-custom-lang-environments and name when exporting to latex
@ 2015-11-16 12:59 Alan Schmitt
  2015-11-20  7:55 ` Alan Schmitt
  0 siblings, 1 reply; 15+ messages in thread
From: Alan Schmitt @ 2015-11-16 12:59 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1385 bytes --]

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 #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 472 bytes --]

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

end of thread, other threads:[~2015-12-01  8:15 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-16 12:59 interaction between org-latex-custom-lang-environments and name when exporting to latex Alan Schmitt
2015-11-20  7:55 ` Alan Schmitt
2015-11-20 10:41   ` Rasmus
2015-11-20 11:06     ` Alan Schmitt
2015-11-23 11:13     ` Alan Schmitt
2015-11-23 17:54       ` Rasmus
2015-11-24  8:07         ` Alan Schmitt
2015-11-24 13:14           ` Rasmus
2015-11-25  7:59             ` Alan Schmitt
2015-11-25  9:57               ` Rasmus
2015-11-27 16:27                 ` Alan Schmitt
2015-11-27 21:05                   ` Rasmus
2015-11-30 12:12                     ` Alan Schmitt
2015-11-30 13:11                       ` Rasmus
2015-12-01  8:14                         ` Alan Schmitt

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).