mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-08-23 20:18:42 +00:00
ox-html: Fix infojs integration
* lisp/ox-html.el (html): Add infojs installation script in options filter. (org-html-infojs-install-script): Remove check for back-end as we can safely assume the function will be called from `html' back-end or one of its derivative. `org-export-filter-*-functions' are user oriented. Developer filters should be installed in back-end definition.
This commit is contained in:
parent
c299c109bb
commit
3049f1c75f
|
@ -101,7 +101,8 @@
|
||||||
(verbatim . org-html-verbatim)
|
(verbatim . org-html-verbatim)
|
||||||
(verse-block . org-html-verse-block))
|
(verse-block . org-html-verse-block))
|
||||||
:export-block "HTML"
|
:export-block "HTML"
|
||||||
:filters-alist ((:filter-final-output . org-html-final-function))
|
:filters-alist ((:filter-options . org-html-infojs-install-script)
|
||||||
|
(:filter-final-output . org-html-final-function))
|
||||||
:menu-entry
|
:menu-entry
|
||||||
(?h "Export to HTML"
|
(?h "Export to HTML"
|
||||||
((?H "As HTML buffer" org-html-export-as-html)
|
((?H "As HTML buffer" org-html-export-as-html)
|
||||||
|
@ -386,8 +387,7 @@ Option settings will replace the %MANAGER-OPTIONS cookie."
|
||||||
"Install script in export options when appropriate.
|
"Install script in export options when appropriate.
|
||||||
EXP-PLIST is a plist containing export options. BACKEND is the
|
EXP-PLIST is a plist containing export options. BACKEND is the
|
||||||
export back-end currently used."
|
export back-end currently used."
|
||||||
(unless (or (not (org-export-derived-backend-p backend 'html))
|
(unless (or (not org-html-use-infojs)
|
||||||
(not org-html-use-infojs)
|
|
||||||
(and (eq org-html-use-infojs 'when-configured)
|
(and (eq org-html-use-infojs 'when-configured)
|
||||||
(or (not (plist-get exp-plist :infojs-opt))
|
(or (not (plist-get exp-plist :infojs-opt))
|
||||||
(string-match "\\<view:nil\\>"
|
(string-match "\\<view:nil\\>"
|
||||||
|
@ -463,8 +463,6 @@ export back-end currently used."
|
||||||
;; Return the modified property list.
|
;; Return the modified property list.
|
||||||
exp-plist)))
|
exp-plist)))
|
||||||
|
|
||||||
(when org-html-use-infojs
|
|
||||||
(add-to-list 'org-export-filter-options-functions 'org-html-infojs-install-script))
|
|
||||||
|
|
||||||
;;;; Bold etc
|
;;;; Bold etc
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue