Commit Graph

232 Commits

Author SHA1 Message Date
Kyle Meyer 5a229cbc44 Update copyright year to 2022 2022-01-01 15:17:08 -05:00
Bastien 806ac1b7f6 *el: Fix indentation 2021-09-29 09:22:47 +02:00
Stefan Kangas 51cdd6e30f Various minor docfixes found by checkdoc 2021-09-16 21:24:59 +02:00
Kyle Meyer d477f61ee1 Merge branch 'km/from-emacs-master' 2021-03-14 22:07:30 -04:00
Stefan Monnier a85b4cc5c6 Backport commit 7d0dc3183 from Emacs
* lisp/ob-lilypond.el (org-babel-lilypond-compile-lilyfile):
Remove always-nil variable `arg-2`.

* lisp/ol-gnus.el (org-gnus-store-link):
Remove always-nil variables `newsgroup` and `xarchive`.

* lisp/ol.el (org-store-link):
Remove always-nil variable `description`.

* lisp/org-clock.el (org-clock-special-range):
Remove always-nil variables `m1` and `m`.

* lisp/org-crypt.el (org--matcher-tags-todo-only): Declare var.

* lisp/org-protocol.el (org-protocol-open-source):
Remove always-nil variable `result`.

* lisp/ox-odt.el (org-odt-format-label):
Remove always-nil variable `short-caption`.
(org-odt-link--inline-formula):
Remove always-nil variables `width` and `height`.

* lisp/ox.el (org-export--missing-definitions):
Remove always-nil variable `seen`.

* lisp/: Delete some always-nil variables
7d0dc31833d471a6f86e947d3165d3fd1452a184
Stefan Monnier
Thu Mar 11 13:07:37 2021 -0500
2021-03-14 17:54:17 -04:00
Kyle Meyer 291993888d Merge branch 'maint' 2021-01-01 15:02:10 -05:00
Kyle Meyer 99eafe3787 Update copyright year to 2021 2021-01-01 14:59:01 -05:00
Kyle Meyer 5121209baa Merge branch 'maint' 2020-11-28 10:51:57 -05:00
Nick Dokos 546b2ba26b org-odt-planning: Fix scheduled item output
* lisp/ox-odt.el (org-odt-planning): Use org-scheduled-string, not
  org-deadline-string, for scheduled items.

See <https://emacs.stackexchange.com/questions/61985/org-export-to-odt-incorrectly-use-deadline-for-scheduled> for an ECM.
2020-11-28 10:50:39 -05:00
Kyle Meyer 6e5399d54f Merge branch 'maint' 2020-11-22 22:25:11 -05:00
Cheong Yiu Fung 2d23d55ac5 ox-odt.el: quote output file name
* lisp/ox-odt.el (org-odt-do-convert): Add `shell-quote-argument'
around output file name.

TINYCHANGE
2020-11-22 22:24:51 -05:00
Stefan Kangas 1a480e01a4 Remove redundant 'function's around lambda
* contrib/lisp/org-secretary.el (join):
* contrib/lisp/ox-taskjuggler.el (org-taskjuggler-project-plan):
* lisp/org-clock.el (org-resolve-clocks):
* lisp/org-element.el (org-element--interpret-affiliated-keywords):
* lisp/org-list.el (org-list-struct, org-list-get-item-number)
(org-list-separating-blank-lines-number)
(org-list-struct-fix-bul, org-list-struct-apply-struct):
* lisp/org.el (org-agenda-files, org-toggle-heading):
* lisp/ox-ascii.el (org-ascii-table-row):
* lisp/ox-beamer.el (org-beamer--format-section)
(org-beamer-template):
* lisp/ox-odt.el (org-odt--render-image/formula):
* testing/org-batch-test-init.el (load-path): Remove redundant
'function's around lambda.
2020-11-18 22:02:19 -05:00
Kyle Meyer 23896ba683 ox-odt: Drop another (function (lambda ...))
* lisp/ox-odt.el (org-odt--image-size): Drop unnecessary `function'
call around `lambda'.

The previous commit from Emacs removed a (function (lambda ...))
instance immediately above.  Do the same here.
2020-11-14 15:44:26 -05:00
Stefan Kangas a97bb27f32 Backport commit 61dca6e92 from Emacs
* lisp/org/ox-odt.el (org-odt--image-size): Don't quote lambdas.

Don't quote lambdas in several places
61dca6e92ac972b832e889fbeab9b6131fc896fa
Stefan Kangas
Sat Nov 14 17:04:23 2020 +0100
2020-11-14 15:44:24 -05:00
Bastien 9ad3606bf3 Use `org-preview-latex-image-directory' instead of hardcoding
* lisp/ox-odt.el (org-odt--translate-latex-fragments):
* lisp/ox-html.el (org-html--format-image): Use
`org-preview-latex-image-directory' instead of hardcoding the
directory name.

See <https://orgmode.org/list/87a70v9jan.fsf@ucl.ac.uk>

Reported-by: Eric S Fraga <e.fraga@ucl.ac.uk>
2020-09-05 10:41:36 +02:00
Kyle Meyer 89b0d485b1 Merge branch 'maint' 2020-05-05 00:16:53 -04:00
Eric Timmons 0f783cbca8 ox-odt: Do not ignore org-odt-styles-file
* lisp/ox-odt.el (odt): Delete a repeated entry for :odt-styles-file
and absorb its org-odt-styles-file, which had no effect due to the
repeated entries, into the first definition.

TINYCHANGE
2020-05-05 00:15:57 -04:00
Nicolas Goaziou 42ec2462a0 Do not leak "attachment" links
* lisp/ol.el (org-link-open): Remove "attachment" for special cases.
* lisp/org-attach.el (org-attach-expand-links):
(org-attach-follow): New functions.
(org-attach-link-expand): Remove function.
* lisp/org-element.el (org-element-link-parser):
* lisp/ox-ascii.el (org-ascii-link):
* lisp/ox-html.el (org-html-link):
* lisp/ox-latex.el (org-latex--inline-image):
(org-latex-link):
* lisp/ox-man.el (org-man-link):
* lisp/ox-md.el (org-md-link):
* lisp/ox-odt.el (org-odt-inline-image-rules):
(org-odt-link):
* lisp/ox-texinfo.el (org-texinfo-inline-image-rules):
(org-texinfo-link): Remove "attachment" from special cases.
2020-02-22 14:22:49 +01:00
Nicolas Goaziou ab9166ad29 Extend export tooling in link parameters
* lisp/ol.el (org-link-parameters): Allow a fourth "info" argument for
`:export' property.  Expound docstring.
* lisp/ox.el (org-export-custom-protocol-maybe): Accept a fourth
optional argument.
* lisp/ox-ascii.el (org-ascii--describe-links):
(org-ascii-link):
* lisp/ox-beamer.el (org-beamer-link):
* lisp/ox-html.el (org-html-link):
* lisp/ox-latex.el (org-latex-link):
* lisp/ox-man.el (org-man-link):
* lisp/ox-md.el (org-md-link):
* lisp/ox-odt.el (org-odt-link):
* lisp/ox-org.el (org-org-link):
* lisp/ox-texinfo.el (org-texinfo-link):
* contrib/lisp/ox-groff.el (org-groff-link): Provide expected fourth
argument.
* lisp/ox.el (org-export-link-as-file): New function.
* lisp/ol.el (org-link-parameters): Add reference to new function in docstring.
* testing/lisp/test-ox.el (test-org-export/link-as-file): Add tests.
(test-org-export/custom-protocol-maybe): Update tests.
2020-02-19 18:41:37 +01:00
Gustav Wikström a24c8c481f Refactor attachment path expansion
* lisp/org-attach.el (org-attach-link-expand): New function for link
  element expansion.

* lisp/org-element.el (org-element-link-parser): Remove info about
  expanded attachment paths from link elements.

* lisp/ol.el (org-link-open)
* lisp/ox-texinfo.el (org-texinfo-link)
* lisp/ox-odt.el (org-odt-link)
* lisp/ox-md.el (org-md-link)
* lisp/ox-man.el (org-man-link)
* lisp/ox-latex.el (org-latex--inline-image, org-latex-link)
* lisp/ox-html.el (org-html-link)
* lisp/ox-ascii.el (org-ascii-link): Refactor to use new link
  expansion function from org-attach.el instead of (now removed)
  custom link property from org-element.el.
2020-02-06 22:09:18 +01:00
Bastien 499cff10ef Merge branch 'maint' 2020-01-31 17:22:01 +01:00
Bastien 04bd110b2b Small fixes
* lisp/ox-odt.el (org-odt--format-timestamp): Fix timestamp
display.

* lisp/org-agenda.el (org-agenda-show-and-scroll-up): Remove
useless code.
2020-01-31 17:21:43 +01:00
Gustav Wikström 52fafd3005 Fix backtick in org-odt-inline-image-rules
* lisp/ox-odt.el (org-odt-inline-image-rules): Fix error to make the
  list evaluate inline code at definition.
2020-01-18 01:41:16 +01:00
Gustav Wikström 20d293b4aa Give link parser knowledge of attachment link expanded path
* lisp/org-element.el (org-element-link-parser): Add info about
  expanded attachment paths to the link parse tree export.

* lisp/org-attach.el Remove org-attach-open-link.  Let attachment
  links use the built in code that already is developed for file
  links.

* lisp/ol.el (org-link-open): Add knowledge about attachment links to
  the function opening links, so they can be opened exactly as file
  links are opened.

* lisp/ox-texinfo.el (org-texinfo-link)
* lisp/ox-odt.el (org-odt-link)
* lisp/ox-md.el (org-md-link)
* lisp/ox-man.el (org-man-link)
* lisp/ox-latex.el (org-latex--inline-image, org-latex-link)
* lisp/ox-html.el (org-html-link)
* lisp/ox-ascii.el (org-ascii-link): Refactor to use property from
  link parser instead of invoking attachment expansion in the
  exporter.
2020-01-18 01:41:01 +01:00
Gustav Wikström f93020d5e6 Expand attachment links with point in correct place
* lisp/ox-texinfo.el (org-texinfo-link)
* lisp/ox-odt.el (org-odt-link)
* lisp/ox-md.el (org-md-link)
* lisp/ox-man.el (org-man-link)
* lisp/ox-latex.el (org-latex--inline-image, org-latex-link)
* lisp/ox-html.el (org-html-link)
* lisp/ox-ascii.el (org-ascii-link): Move point to the link for
  org-attach-expand to know from which headline to expand the link.
2020-01-15 20:40:24 +01:00
Gustav Wikström 0ac6a9e1fc Further fix of exporting attachment links in export backends
* lisp/ox-html.el (org-html-link, org-html-inline-image-rules)
* lisp/ox-odt.el (org-odt-inline-image-rules)
* lisp/ox-texinfo.el (org-texinfo-link)
  (org-texinfo-inline-image-rules): Make attachment links consistently
  expand as relative to file and add attachment link type to
  image rules for consistency among export backends.
2020-01-14 21:45:31 +01:00
Gustav Wikström d70db54dbc Improve attachment link export functionality
Make attachment links export just as file links.

* lisp/ox-ascii.el
* lisp/ox-html.el
* lisp/ox-latex.el
* lisp/ox-man.el
* lisp/ox-md.el
* lisp/ox-texinfo.el
* lisp/org-attach.el: Move export functionality for attachment links
  into the respective export backend, for feature parity with file
  links.
2020-01-14 04:15:38 +01:00
Kyle Meyer ff5fc050d3 Update copyright year to 2020 2020-01-01 13:38:46 -05:00
nixo 6315e1e760 ox-odt: Get write permissions on styles.xml
* lisp/ox-odt.el (org-odt-template): The file `styles.xml' might be
copied from a location where it is read-only.  Since we need to modify
it (and its copied under /tmp, so we can modify it), we need to ensure
we have write persmissions on it.  Set mode to 600.

This is especially needed for projects like Guix, where all system
files are stored in a read-only location.

TINYCHANGE
2019-12-22 10:07:29 +01:00
Jonas Bernoulli 5117d8a159 Fix typos 2019-11-16 17:17:36 -05:00
Kyle Meyer d215c3a8c0 Merge branch 'maint' 2019-09-29 15:49:08 -04:00
Juanma Barranquero 001306c1c0 Backport commit 79a01866a from Emacs
* lisp/org-agenda.el (org-agenda-change-all-lines)
(org-agenda-today-p):
* lisp/org-id.el (org-id-get):
* lisp/org.el (org-highlight-latex-and-related)
(org--valid-property-p):
* lisp/ox-beamer.el (org-beamer--get-label):
* lisp/ox-latex.el (org-latex--caption-above-p):
* lisp/ox-odt.el (org-odt--copy-image-file)
(org-odt--copy-formula-file):
* lisp/ox.el (org-export-with-timestamps): Fix typos in docstrings.

lisp/*.el, src/*.c: Fix typos in docstrings
79a01866a01754b9f566af76ef96e80cd90d094b
Juanma Barranquero
Thu Sep 19 04:32:25 2019 +0200
2019-09-29 15:47:57 -04:00
Sacha Chua a41e9950ae Add :target option for the TOC keyword
* doc/org-manual.org, etc/ORG_NEWS: Document :target option
  for the TOC keyword.

* lisp/ox.el (org-export-resolve-link): New function.

* lisp/ox-ascii.el (org-ascii-keyword): Added :target to the TOC
  keyword.
  (org-ascii--build-toc): Changed LOCAL argument to SCOPE.

* lisp/ox-html.el (org-html-keyword): Added :target to the TOC keyword.

* lisp/ox-md.el (org-md-keyword): Added :target to the TOC keyword.
  (org-md--build-toc): Changed LOCAL argument to SCOPE.

* lisp/ox-odt.el (org-odt-keyword): Added :target to the TOC keyword.

* testing/lisp/test-ox.el (test-org-export/collect-headlines): Added
  tests for specifying scope by CUSTOM_ID or by fuzzy matching.
  (test-org-export/resolve-link): New test.
2019-05-30 15:25:46 +02:00
Nicolas Goaziou de54bbd759 reproducibility: Remove absolute file names in ox-odt.elc
* lisp/ox-odt.el (org-odt-schema-dir-list):
(org-odt-styles-dir-list): Remove `eval-when-compile'.
* mk/org-fixup.el (org-make-org-version): Change signature. Do not
  hard-code ODT style directory at build time.

Fixes: bug#34323
2019-02-09 12:31:37 +01:00
Kyle Meyer ba321d0e44 Merge branch 'maint' 2019-01-13 15:14:37 -05:00
Glenn Morris 16c8187db1 Backport commit d5f6ff99c from Emacs
* lisp/org.el (image-refresh):
* lisp/ox-odt.el (clear-image-cache, image-size): Declare.

Quieten without-x org compilation
d5f6ff99c2b594919931b277a2d94d3a289ca764
Glenn Morris
Wed Feb 28 16:55:41 2018 -0500
2019-01-13 12:43:04 -05:00
Bastien 7a22b8f93b Merge branch 'maint' 2019-01-01 11:54:01 +01:00
Bastien f584d37a67 Update copyright year 2019-01-01 11:50:56 +01:00
Nicolas Goaziou 683199e6e1 Merge branch 'master' into next 2018-11-10 22:00:34 +01:00
Nicolas Goaziou 5dfbe46b1e ox-odt: Fix typo
* lisp/ox-odt.el (org-odt-template): Fix typo.
2018-11-10 21:59:52 +01:00
Nicolas Goaziou a97903944b Merge branch 'master' into next 2018-11-10 21:57:29 +01:00
Nicolas Goaziou 9056d2b706 ox-odt: Fix last commit
* lisp/ox-odt.el (org-odt-template): Add missing `org-strip-quote'
  call.
2018-11-10 21:56:10 +01:00
Nicolas Goaziou cd12a9eefe Merge branch 'master' into next 2018-11-10 20:00:31 +01:00
Nicolas Goaziou bea916d9f6 ox-odt: Improve styles file handling
* lisp/ox-odt.el (org-odt-template): Allow double quotes around file
  name.  Better error handling.  Small refactoring.
2018-11-10 20:00:02 +01:00
Nicolas Goaziou 1e063b401a Merge branch 'master' into next 2018-11-04 23:40:27 +01:00
Nicolas Goaziou bfb946c7da ox-odt: Read list values in ODT_STYLES_FILE
* lisp/ox-odt.el (org-odt-template): Read value for ODT_STYLES_FILE
  when it is enclosed in round brackets.

Reported-by: Christian Moe <mail@christianmoe.com>
<http://lists.gnu.org/r/emacs-orgmode/2018-10/msg00418.html>
2018-11-04 23:00:01 +01:00
Mark A. Hershberger eb806aa503 ox-odt: Add support for text:start-value
* lisp/ox-odt.el (org-odt-item): Support starting lists at a set
number via "text:start-value".  Without this, ODF files just restart
numbering when they should continue with the specified number.
2018-10-19 21:49:54 +02:00
Nicolas Goaziou 17edaf8c14 "src block" -> "source block" in documentation and comments
* etc/ORG-NEWS (Maxima: new headers ~:prologue~ and ~:epilogue~):
(Texinfo exports inline source blocks as ~@code{}~):
(Default lexical evaluation of emacs-lisp source blocks):
* lisp/ob-clojure.el (org-babel-clojure-default-ns):
* lisp/ob-core.el (org-babel-named-src-block-regexp-for-name):
(org-babel-current-src-block-location):
(org-babel-mark-block):
(org-babel-insert-result):
* lisp/ob-emacs-lisp.el (org-babel-default-header-args:emacs-lisp):
* lisp/ob-exp.el (org-babel-exp-process-buffer):
* lisp/ob-lob.el (org-babel-lob-ingest):
* lisp/ob-ref.el:
* lisp/org-element.el (org-element-object-restrictions):
(org-element-src-block-parser):
(org-element-inline-src-block-parser):
* lisp/org-lint.el:
(org-lint--checkers):
* lisp/org-pcomplete.el (pcomplete/org-mode/block-option/src):
* lisp/org-src.el (org-edit-inline-src-code):
* lisp/org.el (org-ctrl-c-ctrl-c):
(org-in-src-block-p):
(org-fill-element):
* lisp/ox-html.el (org-html--textarea-block):
(org-html-format-code):
* lisp/ox-latex.el (org-latex-minted-options):
(org-latex-custom-lang-environments):
* lisp/ox-md.el:
* lisp/ox-odt.el (org-odt-format-code):
* lisp/ox.el (org-export-collect-listings):
* testing/lisp/test-ob-exp.el (ob-exp/src-block-with-affiliated-keyword):
* testing/lisp/test-ob.el (test-ob/preserve-results-indentation):
  Correct "src block" occurrences when they do not specifically refer
  to the element type `src-block'.
2018-09-20 11:23:49 +02:00
Charles Celerier 30498ef932 ox-odt: Fix `org-odt-template' styles file retrieval
* lisp/ox-odt.el (org-odt-template): Fix `org-odt-template' styles
  file retrieval.

TINYCHANGE

Signed-off-by: Charles Celerier <chckyn@gmail.com>
2018-08-05 08:02:00 +02:00
Glenn Morris ec8590d5e2 Backport commit 69107f347 from Emacs
; Fix doc typos related to indefinite articles
69107f347b3ac7f51cd22333f57393fd735915f2
Glenn Morris
Fri Feb 16 17:33:57 2018 -0500
2018-02-18 16:32:41 -05:00