0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-09-29 20:37:51 +00:00

ox-html: Support for exporting inline source code to HTML

* lisp/ox-html.el (org-html-inline-src-block): support for exporting
inline source code to HTML.
This commit is contained in:
Nicolas Berthier 2014-06-13 16:39:18 +02:00 committed by Nicolas Goaziou
parent 795c004396
commit 2ea7bf4042

View file

@ -2414,7 +2414,13 @@ CONTENTS holds the contents of the item. INFO is a plist holding
contextual information."
(let* ((org-lang (org-element-property :language inline-src-block))
(code (org-element-property :value inline-src-block)))
(error "Cannot export inline src block")))
(let ((lang (org-element-property :language inline-src-block))
(code (org-html-format-code inline-src-block info))
(label (let ((lbl (org-element-property :name inline-src-block)))
(if (not lbl) ""
(format " id=\"%s\""
(org-export-solidify-link-text lbl))))))
(format "<code class=\"src src-%s\"%s>%s</code>" lang label code))))
;;;; Inlinetask