* lisp/ox.el (org-export--generate-copy-script): Call `org-mode' when
duplicating a buffer. It will properly set every variable, like
`comment-start'.
(org-export-async-start): Do not call `org-mode' since this is done
already in the previous function.
* lisp/ox.el (org-export-as): Store export options in :export-options
porperty within communication channel.
This patch allows export options activated to be available to export
back-ends.
* lisp/ox.el (org-export--selected-trees): Also mark inlinetasks with
a select tag.
(org-export--skip-p): Skip inlinetasks with a :noexport: tag.
* testing/lisp/test-ox.el: Add tests.
* lisp/ox.el (org-export-async-start): Ignore `org-mode-hook' and
`kill-emacs-hook'. The first one has been run in the original
buffer. The second is not necessary and can pollute output to
a temporary buffer (e.g. with `org-clock-persistence-insinuate').
Export commands can be restricted to a specific subtree. When using a
prefix argument to org-export-dispatch, the restriction did not stick,
i.e. the command would be restricted to whatever note the cursor
happens to be in. This made it difficult to repeat export of a
subtree while editing it. This change introduces a new marker and
uses this marker to remember the cursor position of the previous
export command. So repeating a subtree-restricted command will now
re-export the same subtree, provided you are still in the same
buffer. To break this connection, just make a new export without
relying on the prefix argument.
* lisp/ox.el (org-export-dispatch-last-position): New variable
(org-export-dispatch): Save position of cursor at the moment when
the export command is called. Restore that position temporarily
when repeating the previous export command.
* lisp/ox.el (org-export-get-previous-element): Change order of
retured elements in `org-export-get-previous-element'.
* testing/lisp/test-ox.el: Update test.
* lisp/ox.el (org-export-stack): Rewrite.
(org-export-stack-refresh): Refactor.
(org-export-stack-remove, org-export-stack-view): Apply renaming.
(org-export-stack-mode-map): Use tabulated list map as a basis.
(org-export-stack--generate, org-export-stack--num-predicate): New
function.
* lisp/ox.el (org-export-get-optional-title): Return regular title
when no optional title is found.
* lisp/ox-ascii.el (org-ascii--build-title): Apply change to
`org-export-get-optional-title'.
* lisp/ox-html.el (org-html--format-toc-headline): Apply change to
`org-export-get-optional-title'.
* lisp/ox-latex.el (org-latex-headline): Apply change to
`org-export-get-optional-title'.
* testing/lisp/test-ox.el: Add tests.
* lisp/org-element.el (org-element-headline-parser): Node
property :OPTIONAL_TITLE: in a headline will be parsed and stored
under :optional-title property.
* lisp/ox.el (org-export-get-optional-title): New function.
* lisp/ox.el (org-export--generate-copy-script): Clone
`buffer-file-coding-system' when creating a buffer copy.
This patches makes sure the output will share the same encoding as the
original buffer.
* org-compat.el (org-file-equal-p): New compatibility function.
* ox.el (org-export-output-file-name): Use the new function.
Thanks to Mark Edgington for reporting this.
* lisp/ox.el (org-export-install-filters): Properly install filters
send through ext-plist mechanism.
* lisp/ox-publish.el (org-publish-org-to): Small refactoring.
* lisp/ox-html.el (org-html-keyword): Remove INDEX keyword handling.
ox-publish.el takes care of it already.
* lisp/ox.el (org-export-resolve-fuzzy-link): Whitespaces are not
significant when matching a fuzzy link.
* lisp/org-element.el (org-element-link-parser): Do not remove
newlines characters in paths anymore, since this is not required.
* testing/lisp/test-org-element.el: Update tests.
* testing/lisp/test-ox.el: Add test.
* lisp/ox.el (org-export--dispatch-ui): Renamed from
`org-export-dispatch-ui'. Handle scrolling.
(org-export--dispatch-action): Renamed from
`org-export-dispatch-action'. Implement scrolling.
(org-export-dispatch): Apply renaming.
Heavily based on a patch from Jambunathan K.
* lisp/ox.el (org-export-output-file-name): Add a protection when
output file name is the same as the original org.
* testing/lisp/test-ox.el: Add tests.
* lisp/ox.el (org-export--collect-headline-numbering): Remove footnote
section from TOC.
(org-export-collect-headlines): Do not count footnote section when
numbering a headline.
* testing/lisp/test-ox.el: Add tests.
* lisp/ox.el (org-export-as): Call `inner-template' function, if
available.
* lisp/ox-html.el (org-html-inner-template): New function.
(org-html-template): Move all parts that should be inserted even in
a body-only export into `org-html-inner-template'.
* testing/lisp/test-ox.el: Add tests.
* lisp/org.el (org-modules): Remove export back-ends from the list.
Update docstring.
(org-export-backends): New variable.
* lisp/ox.el (org-export-async-start): Make sure export framework is
required in the external process.
* lisp/ob-exp.el (org-babel-exp-process-buffer): Renamed from
`org-export-blocks-preprocess'.
* lisp/ox.el (org-export-execute-babel-code): Apply previous renaming.
* testing/org-test.el (org-test-at-id): Make sure the function returns
the value of the last form in its body.
* testing/lisp/test-ob-exp.el: Fix tests.
* testing/lisp/test-ob-lob.el: Fix tests.