emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] Renaming of +NAME for code blocks to in HTML export, no longer u


From: Adam Aviv
Subject: Re: [O] Renaming of +NAME for code blocks to in HTML export, no longer user defined
Date: Tue, 5 Jan 2016 11:44:59 -0500


On Mon, Jan 4, 2016 at 1:29 PM, Nick Dokos <address@hidden> wrote:
It may be a bug: the code (in org-html-src-block) looks like this

          (label (let ((lbl (and (org-element-property :name src-block)
                                 (org-export-get-reference src-block info))))
                   (if lbl (format " id=\"%s\"" lbl) ""))))

and I'm wondering whether the "and" should be an "or".

Interesting. I don't know if it is a bug, though, as this seems intentional and matches my experience. The idea being that if you want to label something, you use the :name tag, but this will make it so the second item is evaluated, producing a unique identifier. The unique identifier is then assigned instead of the :name tag. If it was an, OR, however, then every element block would get a label, and that might be suboptimal given that not every block is referenced later.

I would still like to be able to add my own name tags, but understand why this might have been changed to avoid to blocks having the same label. 


--
Adam J. Aviv, PhD
Asst. Professor
Computer Science
U.S. Naval Academy
(410) 293- 6655

reply via email to

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