29 hours agoorg-element: Fix search failed error in `org-element-context' maint
Nicolas Goaziou [Thu, 11 Feb 2016 08:47:54 +0000]
org-element: Fix search failed error in `org-element-context'

* lisp/org-element.el (org-element-context): Make sure point is on tag
  line before searching for it.

* testing/lisp/test-org-element.el (test-org-element/context): Add test.
  Small refactoring.

Reported-by: Kaushal Modi <>

38 hours agoorg-archive: Speed-up archiving subtrees
Nicolas Goaziou [Wed, 10 Feb 2016 23:47:55 +0000]
org-archive: Speed-up archiving subtrees

* lisp/org-archive.el (org-toggle-archive-tag): Use `org-flag-subtree',
  which is much faster than outline-hide-subtree'.

Reported-by: Michael Ziems <>

2 days agoox-odt: Fix End of file during parsing error
Nicolas Goaziou [Tue, 9 Feb 2016 20:52:10 +0000]
ox-odt: Fix End of file during parsing error

* lisp/ox-odt.el (org-odt-template): Do not call `read' on an empty

Reported-by: Damien Cassou <>

3 days agoBackport commit ec90220 from Emacs
Alan Mackenzie [Mon, 25 Jan 2016 12:35:15 +0000]
Backport commit ec90220 from Emacs

Expunge "allow" + infinitive from source and doc, part 2.
Alan Mackenzie
Mon Jan 25 12:35:15 2016 +0000

4 days agoorg-capture: Document org-directory
Kyle Meyer [Sun, 7 Feb 2016 16:56:04 +0000]
org-capture: Document org-directory

* lisp/org-capture.el (org-capture-templates):
* doc/org.texi (Template elements): Document org-directory.

5 days agoob-core: fix bug when source block is at bob
Aaron Ecay [Sat, 6 Feb 2016 22:01:22 +0000]
ob-core: fix bug when source block is at bob

* lisp/ob-core.el (org-babel-get-src-block-info): Fix bug.

6 days agoRemove `org-latex-fragment-image-overlays'
Nicolas Goaziou [Fri, 5 Feb 2016 21:47:14 +0000]
Remove `org-latex-fragment-image-overlays'

* lisp/org.el (org-latex-fragment-image-overlays): Remove variable.
(org--format-latex-make-overlay): Do not register anymore created
overlays in the removed variable.
(org--list-latex-overlays): New function.
(org-remove-latex-fragment-image-overlays): Use new function.
(org-context): Work around use of `org-latex-fragment-image-overlays'.

Reported-by: Dima Kogan <>

6 days agoSilence byte-compiler
Nicolas Goaziou [Fri, 5 Feb 2016 17:39:06 +0000]
Silence byte-compiler

* lisp/org.el (org--format-latex-make-overlay): Silence byte-compiler.

7 days agoRemove LaTeX overlay when text below is modified
Nicolas Goaziou [Thu, 4 Feb 2016 08:32:51 +0000]
Remove LaTeX overlay when text below is modified

* lisp/org.el (org--format-latex-make-overlay): New function.
(org-format-latex): Use new function.

Reported-by: Dima Kogan <>

8 days agoorg-agenda: Fix org-agenda-filter-by-tag-refine
Kyle Meyer [Thu, 4 Feb 2016 04:34:26 +0000]
org-agenda: Fix org-agenda-filter-by-tag-refine

* lisp/org-agenda.el (org-agenda-filter-by-tag-refine): Refine rather
  than exlude tags, reverting change from 6c6ae99.  Mark as obsolete
  because this functionality is now redundant with

Reported-by: Viktor Rosenfeld <>

8 days agoFix "it's" typos
Kyle Meyer [Thu, 4 Feb 2016 04:33:28 +0000]
Fix "it's" typos

* lisp/ob-C.el (org-babel-expand-body:cpp):
* lisp/ob-exp.el (org-babel-exp-src-block):
* lisp/ob-fortran.el (org-babel-expand-body:fortran):
* testing/org-test.el (org-test-buffer):
Correct "it's" typo in docstring.

* doc/org.texi:
Correct "it's" typos.

9 days agoorg-compat: Fix error on newest Emacsen (>= 25)
Nicolas Goaziou [Tue, 2 Feb 2016 16:49:23 +0000]
org-compat: Fix error on newest Emacsen (>= 25)

* lisp/org-compat.el (org-move-to-column): Ensure `remove' is called on
a list.

Reported-by: Julien Cubizolles <>

11 days agoorg-element: Disable cache for orgstruct-mode
Nicolas Goaziou [Sun, 31 Jan 2016 23:17:39 +0000]
org-element: Disable cache for orgstruct-mode

* lisp/org-element.el (org-element--cache-active-p):
(org-element-cache-reset): Do not activate cache outside Org buffers,
even if using "orgstruct-mode".

Reported-by: "Mark A. Hershberger" <>

11 days agoob-tangle: Fix :comment org behavior
Nicolas Goaziou [Sun, 31 Jan 2016 22:59:50 +0000]
ob-tangle: Fix :comment org behavior

* lisp/ob-tangle.el (org-babel-spec-to-string): Do not try to comment
  empty text.

Reported-by: Titus von der Malsburg <>

11 days agoox-latex: Fix numbering of source blocks
Nicolas Goaziou [Sun, 31 Jan 2016 22:30:49 +0000]
ox-latex: Fix numbering of source blocks

* lisp/ox-latex.el (org-latex-src-block): Fix numbering reset on source
  blocks when using the listings package.

Reported-by: P-O Gustafsson <>

11 days agoox-html: Properly encode links without a description
Nicolas Goaziou [Sun, 31 Jan 2016 22:21:34 +0000]
ox-html: Properly encode links without a description

* lisp/ox-html.el (org-html-link): Encode URI in default description
  when none is provided.


11 days agoob-core: Silence byte-compiler
Nicolas Goaziou [Sun, 31 Jan 2016 19:57:47 +0000]
ob-core: Silence byte-compiler

11 days agoob-tangle: Fix `org-babel-tangle-jump-to-org'
Nicolas Goaziou [Sun, 31 Jan 2016 10:37:05 +0000]
ob-tangle: Fix `org-babel-tangle-jump-to-org'

* lisp/ob-tangle.el (org-babel-tangle-jump-to-org): Find correct
  location in the Org document.

* testing/lisp/test-ob-tangle.el (ob-tangle/jump-to-org): New test.

11 days agoob: Fix `org-babel-update-block-body'
Nicolas Goaziou [Sun, 31 Jan 2016 10:36:52 +0000]
ob: Fix `org-babel-update-block-body'

* lisp/ob-core.el (org-babel-update-block-body): Correctly handle block
(org-babel-where-is-src-block-head): Accept an optional argument in
order to avoid parsing twice the same element.

* testing/lisp/test-ob.el (org-test-ob/update-block-body): New test.

2 weeks agoorg-src: Use font-lock-ensure to highlight blocks
Kyle Meyer [Fri, 29 Jan 2016 05:10:08 +0000]
org-src: Use font-lock-ensure to highlight blocks

* lisp/org-src.el (org-src-font-lock-fontify-block): Use
  org-font-lock-ensure instead of font-lock-fontify-buffer.

This replacement has previously been made (f36b19e, d81e6b5) and then reverted
(99f9999, 003a0f1) twice because source blocks were not being reliably
highlighted when font-lock-ensure was used instead of
font-lock-fontify-buffer.  This was due to a bug in font-lock-ensure
that has now been fixed (see Emacs's 21beb19 and bug#22399).

font-lock-ensure was introduced after Emacs 24.5, so this issue only
pertains to users with a developmental version of Emacs.

2 weeks agoorg-compat: Update font-lock-ensure alias
Kyle Meyer [Fri, 29 Jan 2016 05:07:33 +0000]
org-compat: Update font-lock-ensure alias

* lisp/org-compat.el (org-font-lock-ensure): Add new alias that accepts
  the same number of arguments as font-lock-ensure does.  Use an org-
* lisp/org-clock.el (org-clock-get-clocktable):
* lisp/org.el (org-fontify-like-in-org-mode):
* lisp/ox-html.el (org-html-fontify-code):
* lisp/ox-odt.el (org-odt-do-format-code):
* lisp/ox-org.el (org-org-publish-to-org): Use org-font-lock-ensure.

See Emacs's bug#22399.

2 weeks agoorg-macro: Fix expansion in narrowed buffers
Nicolas Goaziou [Thu, 28 Jan 2016 23:52:49 +0000]
org-macro: Fix expansion in narrowed buffers

* lisp/org-macro.el (org-macro-replace-all): Expand macro even outside
  narrowed part of the buffer.

* testing/lisp/test-org-macro.el (test-org/macro-replace-all): Add test.

Reported-by: Kaushal Modi <>

2 weeks agoorg-table: Fix table formulas editing
Nicolas Goaziou [Tue, 26 Jan 2016 23:28:56 +0000]
org-table: Fix table formulas editing

* lisp/org-table.el (org-table-show-reference): Do not move point
  outside the table when editing formulas.  Fix docstring.

Reported-by: Samuel Wales <>

2 weeks agoox-latex: PDF generation timestamp check
Anthony Cowley [Thu, 14 Jan 2016 23:13:45 +0000]
ox-latex: PDF generation timestamp check

* lisp/ox-latex.el (org-latex-compile): Improve timestamp check on HFS+
  filesystem by only considering 1-second clock resolution.

Previously, the call to (current-time) could return a timestamp with
a non-zero microsecond or picosecond fields, while the file attribute
always has zeros for these fields.  The check that the generated file is
newer than the reference timestamp only succeeded when the time to
generate the file crossed a 1-second clock interval.


2 weeks agoob-core: Fix comment typo from Emacs's 1203e8a
Kyle Meyer [Tue, 26 Jan 2016 06:13:51 +0000]
ob-core: Fix comment typo from Emacs's 1203e8a

2 weeks agoBackport commit 1203e8a from Emacs
Stefan Monnier [Mon, 25 Jan 2016 15:11:31 +0000]
Backport commit 1203e8a from Emacs

* lisp/ob-core.el (org-babel-check-confirm-evaluate)
(org-babel-map-src-blocks): Don't emit warnings if added vars are not used.
(*this*): Declare as dyn-bound.
(org-babel-expand-src-block, org-babel-load-in-session)
(org-babel-switch-to-session-with-code, org-babel-get-rownames):
Mark unused args.
(org-babel-combine-header-arg-lists): Remove unused var `args'.

* lisp/org-src.el (org-inhibit-startup):
Declare as dyn-bound.

lisp/org: Fix some compiler warnings
Stefan Monnier
Mon Jan 25 10:11:31 2016 -0500

2 weeks agoFix logic when activating plain links
Rafael Laboissiere [Mon, 25 Jan 2016 16:09:23 +0000]
Fix logic when activating plain links

* lisp/org.el: Activate plain link when point is outside a tag, instead
  of the other way around.


2 weeks agoTiny refactoring
Nicolas Goaziou [Mon, 25 Jan 2016 12:58:05 +0000]
Tiny refactoring

* lisp/org.el (org-activate-plain-links): Tiny refactoring.

2 weeks agoFix (wrong-type-argument listp org-link) error
Nicolas Goaziou [Mon, 25 Jan 2016 12:54:47 +0000]
Fix (wrong-type-argument listp org-link) error

* lisp/org.el (org-activate-plain-links): `face' property doesn't not
  necessarily is a list.

Reported-by: gongzhitaao <>

2 weeks agoorg-crypt: Fix comment typo from Emacs's fbce475
Kyle Meyer [Sun, 24 Jan 2016 21:21:53 +0000]
org-crypt: Fix comment typo from Emacs's fbce475

2 weeks agoBackport commit fbce475 from Emacs
Alan Mackenzie [Sun, 24 Jan 2016 20:30:39 +0000]
Backport commit fbce475 from Emacs

Expunge "allow" + infinitive without direct object from source and doc.
Alan Mackenzie
Sun Jan 24 20:30:39 2016 +0000

2 weeks agoFix plain links fontification in a narrowed buffer
Nicolas Goaziou [Sun, 24 Jan 2016 17:22:00 +0000]
Fix plain links fontification in a narrowed buffer

* lisp/org.el (org-activate-plain-links): Fix fontification when buffer
  is narrowed and (point-min) is no longer 1.

2 weeks agoFix `org-format-latex' with $$...$$ snippets
Nicolas Goaziou [Sun, 24 Jan 2016 17:08:23 +0000]
Fix `org-format-latex' with $$...$$ snippets

* lisp/org.el (org-format-latex): Transform $$...$$ into \[...\] before
  processing with mathjax.

2 weeks agolisp/org.el: correct filemode, changed in b3fbd31f17
Achim Gratz [Sun, 24 Jan 2016 11:09:03 +0000]
lisp/org.el: correct filemode, changed in b3fbd31f17

2 weeks agoFix fontification of plain links at beginning of buffer
Rafael Laboissiere [Fri, 22 Jan 2016 23:16:56 +0000]
Fix fontification of plain links at beginning of buffer

* lisp/org.el (org-activate-plain-links): Ensure that a valid buffer
  position is given as first argument to get-text-property, in
  particular when the plain link is at the very beginning of the buffer.


2 weeks agoox-icalendar: Fix timezone export bug
Richard Lawrence [Fri, 22 Jan 2016 01:28:58 +0000]
ox-icalendar: Fix timezone export bug

* ox-icalendar.el (org-icalendar-export-current-agenda): Correct
  argument order in call to org-icalendar--vcalendar (timezone should be
  third, description fourth).


3 weeks agoUse `org-back-to-heading' instead of `outline-back-to-heading'
Nicolas Goaziou [Thu, 21 Jan 2016 09:42:03 +0000]
Use `org-back-to-heading' instead of `outline-back-to-heading'

* lisp/org-agenda.el (org-search-view):
* lisp/org-clock.el (org-with-clock):
* lisp/org.el (org-entry-beginning-position): Use `org-back-to-heading'
  instead of `outline-back-to-heading'.

Reported-by: Derek Feichtinger <>

3 weeks agoorg-colview: Fix column view editing
Nicolas Goaziou [Wed, 20 Jan 2016 23:51:13 +0000]
org-colview: Fix column view editing

* lisp/org-colview.el (org-columns-next-allowed-value): Fix error when
  trying to edit a column from a headline starting at the very beginning
  of the buffer.

This patch also prepares for lexical binding.

Reported-by: "T.F. Torrey" <>

3 weeks agoFix memory leak in `org-agenda-prepare-buffers'
Nicolas Goaziou [Sat, 16 Jan 2016 14:56:03 +0000]
Fix memory leak in `org-agenda-prepare-buffers'

* lisp/org.el (org-agenda-prepare-buffers): Do not use
  `org-uniquify-alist' since it uses `eq' for comparison, whereas where
  are using strings as keys.

Reported-by: Vincent Emanuele <>

3 weeks agoFix tags looking like plain links
Nicolas Goaziou [Sat, 16 Jan 2016 13:50:25 +0000]
Fix tags looking like plain links

* lisp/org-element.el (org-element-context): Do not look for objects
  within TODO keyword, priority cookie, comment keyword or tags.
* lisp/org.el (org-activate-tags): Fix regexp.

* testing/lisp/test-org-element.el (test-org-element/context): Add test.

Reported-by: John Kitchin <>

4 weeks agoorg-table: Fix editing multiple TBLFM lines
Nicolas Goaziou [Thu, 14 Jan 2016 20:11:12 +0000]
org-table: Fix editing multiple TBLFM lines

* lisp/org-table.el (org-table-store-formulas):
(org-table-get-stored-formulas): Add an optional argument to handle
subsequent TBLFM lines.
(org-table--fedit-source): New variable.
(org-table-fedit-finish): Handle additional TBLFM lines.

Reported-by: Nick Dokos <>

4 weeks agoorg-table: Fix a comment
Nicolas Goaziou [Thu, 14 Jan 2016 16:51:39 +0000]
org-table: Fix a comment

* lisp/org-table.el (org-table-end): Fix a comment.

4 weeks agoorg-table: Fix infloop in `org-table-current-field-formula'
Nicolas Goaziou [Thu, 14 Jan 2016 16:36:39 +0000]
org-table: Fix infloop in `org-table-current-field-formula'

* lisp/org-table.el (org-table-current-field-formula): Fix infloop when
  called from outside the table, e.g., on a TBLFM line.

4 weeks agoorg-table: Fix `org-table-current-field-formula'
Nicolas Goaziou [Thu, 14 Jan 2016 13:57:46 +0000]
org-table: Fix `org-table-current-field-formula'

* lisp/org-table.el (org-table-current-field-formula): Column formulas
  are stored with a leading dollar sign.  Also raise an error when no
  field applies, unless NOERROR is non-nil.

* lisp/org-table.el (org-table-eval-formula): Remove unnecessary error.

4 weeks agoorg-table: Fix formula editor
Nicolas Goaziou [Thu, 14 Jan 2016 10:57:09 +0000]
org-table: Fix formula editor

* lisp/org-table.el (org-table-edit-formulas):
(org-table-fedit-finish): Do not remove "$" from column formulas when
exiting the editor.

4 weeks agoorg-element: Fix footnote definition parsing
Nicolas Goaziou [Thu, 14 Jan 2016 08:31:24 +0000]
org-element: Fix footnote definition parsing

* lisp/org-element.el (org-element--footnote-separator): New variable.
(org-element-footnote-definition-parser): Handle footnotes with
affiliated keywords.

* testing/lisp/test-org-element.el (test-org-element/footnote-definition-parser):
Add test.

4 weeks agoorg-directory: Update docstring
Kyle Meyer [Wed, 13 Jan 2016 05:42:09 +0000]
org-directory: Update docstring

* lisp/org.el (org-directory): Fix docstring description of where this
  variable is used.

4 weeks agoorg-bibtex: Fix type error in non-file buffers
Kyle Meyer [Wed, 13 Jan 2016 05:18:42 +0000]
org-bibtex: Fix type error in non-file buffers

* lisp/org-bibtex.el (org-bibtex): Fix type error in cases where the
  buffer is not visiting a file.  In an indirect buffer, use the file
  name for the base buffer.

4 weeks agoorg-bibtex: Mark filename argument as required
Kyle Meyer [Wed, 13 Jan 2016 05:16:07 +0000]
org-bibtex: Mark filename argument as required

* lisp/org-bibtex.el (org-bibtex): Mark FILENAME argument as required
  because, when called from Lisp, the function does not provide a
  default file name when FILENAME is nil, leading to a type error.

4 weeks agoMerge remote-tracking branch 'origin/maint' into maint
Kyle Meyer [Tue, 12 Jan 2016 07:22:47 +0000]
Merge remote-tracking branch 'origin/maint' into maint

4 weeks agoox-bibtex: Fix bibliography location in HTML
Kyle Meyer [Tue, 12 Jan 2016 04:29:03 +0000]
ox-bibtex: Fix bibliography location in HTML

* contrib/lisp/ox-bibtex.el (org-bibtex-process-bib-files): Fix
  insertion location of bibliography in HTML export.

Reported-by: gongzhitaao <>

4 weeks agoorg-clock.el: Fix column count for :formula %
Fernando Varesi [Mon, 11 Jan 2016 16:56:27 +0000]
org-clock.el: Fix column count for :formula %

* lisp/org-clock.el (org-clocktable-write-default): Count properties
columns when using special :formula %

The previous count did not consider properties columns, so the generated
formula was incorrect.

4 weeks agoorg-agenda: Fix filter for org-habits in agenda
Marco Wahl [Mon, 11 Jan 2016 21:54:09 +0000]
org-agenda: Fix filter for org-habits in agenda

* lisp/org-agenda.el (org-agenda-filter-apply): Get text at bol instead
  of eol.  Note that eol can be overwritten by org-habits.

4 weeks agoUpdate copyright years
Kyle Meyer [Sat, 9 Jan 2016 22:12:03 +0000]
Update copyright years

4 weeks agoFix copyright headers.
Bastien [Sat, 9 Jan 2016 07:15:24 +0000]
Fix copyright headers.

5 weeks agoAdd missing argument release_8.3.3
Nicolas Goaziou [Wed, 6 Jan 2016 13:50:37 +0000]
Add missing argument

* lisp/org.el (org-set-property): Add missing argument.

5 weeks agoThrow an error when trying to set invalid properties
Nicolas Goaziou [Wed, 6 Jan 2016 13:43:37 +0000]
Throw an error when trying to set invalid properties

* lisp/org.el (org--valid-property-p): New function.
(org-set-property): Use new function.

Suggested-by: Julien Cubizolles <>

5 weeks agoorg-clock: Improve docstring
Nicolas Goaziou [Sun, 3 Jan 2016 19:48:14 +0000]
org-clock: Improve docstring

* lisp/org-clock.el (org-clock-display): Point to

Reported-by: David Bremner <>

5 weeks agoob-tangle: Silence byte-compiler
Nicolas Goaziou [Sat, 2 Jan 2016 16:40:22 +0000]
ob-tangle: Silence byte-compiler

5 weeks agoUpdate copyright years
Nicolas Goaziou [Sat, 2 Jan 2016 16:06:30 +0000]
Update copyright years

5 weeks agoob-tangle: Fix commented links
Nicolas Goaziou [Sat, 2 Jan 2016 16:05:00 +0000]
ob-tangle: Fix commented links

* lisp/ob-tangle.el (org-babel-spec-to-string):
(org-babel-tangle-collect-blocks): Fix numbering and relative path of
commented links.

* testing/lisp/test-ob-tangle.el (ob-tangle/comment-links-numbering):
  New test.

Reported-by: Tobias Müller <>

5 weeks agoorg-indent: Update coyright years
Nicolas Goaziou [Sat, 2 Jan 2016 13:12:24 +0000]
org-indent: Update coyright years

5 weeks agoorg-indent: Fix refresh when using `org-toggle-heading'
Nicolas Goaziou [Sat, 2 Jan 2016 13:10:49 +0000]
org-indent: Fix refresh when using `org-toggle-heading'

* lisp/org-indent.el (org-indent-notify-modified-headline):
(org-indent-refresh-maybe): Ignore narrowing.  Also ignore inlinetasks.

Reported-by: Ingo Lohmar <>

6 weeks agoorg-publish: Fix get `included-file' logic
aman [Wed, 30 Dec 2015 23:26:55 +0000]
org-publish: Fix get `included-file' logic

* lisp/ox-publish.el (org-publish-cache-file-needs-publishing):
  According to the syntax of #+INCLUDE statement in *info* page,
  there's no space between search option and file path.


7 weeks agoorg-agenda: Don't kill or bury non-agenda buffer
Kyle Meyer [Thu, 24 Dec 2015 06:48:34 +0000]
org-agenda: Don't kill or bury non-agenda buffer

* lisp/org-agenda.el (org-agenda--quit): Fix changes introduced by
  9b1c682 and 8594aed that incorrectly assume that the agenda buffer is
  always the current buffer at the time of killing or burying.

Reported-by: David Mann <>

7 weeks agoorg-table: Fix "$<" constructs in formulas
Nicolas Goaziou [Fri, 18 Dec 2015 21:30:41 +0000]
org-table: Fix "$<" constructs in formulas

* lisp/org-table.el (org-table-recalculate): Expand "$<" without
  returning an error.  Small refactoring.

* testing/lisp/test-org-table.el (test-org-table/first-rc): New test.

Reported-by: Stefan Nobis <>

8 weeks agoorg-velocity: New version of org-velocity.
Paul M. Rodriguez [Mon, 14 Dec 2015 23:51:40 +0000]
org-velocity: New version of org-velocity.

* contrib/lisp/org-velocity.el: New version.

8 weeks agoorg-table: Fix missing dollar bug revealed by commit 16c7594
Thierry Banel [Mon, 14 Dec 2015 21:22:03 +0000]
org-table: Fix missing dollar bug revealed by commit 16c7594

* org-table.el (orgtbl-ascii-plot): Add missing dollar in formula.

2 months agoorg-agenda: Refactoring
Marco Wahl [Sat, 12 Dec 2015 18:46:34 +0000]
org-agenda: Refactoring

* lisp/org-agenda.el(org-agenda--quit): Removed an unnecessary variable.

2 months agoorg-agenda: Fix quit sticky agenda
Marco Wahl [Sat, 12 Dec 2015 18:35:26 +0000]
org-agenda: Fix quit sticky agenda

* lisp/org-agenda.el(org-agenda--quit): Removed the argument from the
  call to `bury-buffer' to let the agenda disappear.

2 months agoox: Fix uninterpreted subscript
Nicolas Goaziou [Fri, 11 Dec 2015 23:38:39 +0000]
ox: Fix uninterpreted subscript

* lisp/ox.el (org-export--remove-uninterpreted-data-1): Fix
  un-interpreted subscript containing another object.

* testing/lisp/test-ox.el (test-org-export/uninterpreted): Add test.

Reported-by: Yasushi SHOJI <>

2 months agoorg-table: Fix named fields with TAB-indentation
Nicolas Goaziou [Fri, 4 Dec 2015 20:34:40 +0000]
org-table: Fix named fields with TAB-indentation

* lisp/org-table.el (org-table-eval-formula): Properly parse named
  fields when indentation of current line ends with a TAB character.

* testing/lisp/test-org-table.el (test-org-table/tab-indent): New test.

Reported-by: Piotr Gajewski <>

2 months agoorg-footnote: Fix error on 32 bits system
Nicolas Goaziou [Mon, 30 Nov 2015 15:08:00 +0000]
org-footnote: Fix error on 32 bits system

* lisp/org-footnote.el (org-footnote-new): Use a value in the 32-bit range.

Reported-by: Sam Halliday <>

2 months agoorg-table: Fix c651e150cc8fb230fca99dfff27caedfddced8ff
Nicolas Goaziou [Thu, 26 Nov 2015 21:41:14 +0000]
org-table: Fix c651e150cc8fb230fca99dfff27caedfddced8ff

* lisp/org-table.el (org-table-get-stored-formulas): Correctly detect
  named fields in formulas' LHS.
* testing/lisp/test-org-table.el (test-org-table/named-field):
(test-org-table/named-column): New tests.

Reported-by: "Stefan-W. Hahn" <>

2 months agoorg-agenda: Write only currently visible items
Nicolas Goaziou [Thu, 26 Nov 2015 13:20:42 +0000]
org-agenda: Write only currently visible items

* lisp/org-agenda.el (org-agenda-write): Fix arguments passed to
  `org-agenda-remove-marked-text' to properly remove entries with
  `invisible' property set to `org-filtered'.
* lisp/ox-icalendar.el (org-icalendar-export-current-agenda): Always
  include TODO entries in the output.  The motivation is that a user not
  filtering out TODO or DONE items in the current agenda probably wants
  them in the output.

Reported-by: "sgeorgii ." <>

2 months agoorg-table: Fix `org-table-eval-formula'
Nicolas Goaziou [Mon, 23 Nov 2015 22:19:14 +0000]
org-table: Fix `org-table-eval-formula'

* lisp/org-table.el (org-table-get-formula):
(org-table-store-formulas): Column formulas references are stored along
with their dollar-sign since "Fix `org-table-get-range' with column
formulas". Update functions accordingly.

Reported-by: John Hendy <>

2 months agoox-publish: Handle includes with searches
Nick Gunn [Mon, 23 Nov 2015 09:50:03 +0000]
ox-publish: Handle includes with searches

* lisp/ox-publish.el (org-publish-cache-file-needs-publishing): Ignore
  any link search suffix on an include so that the path represents
  a valid file during the publishing check.


2 months agoorg-colview: Fix skip-empty-rows without ITEM
Nicolas Goaziou [Wed, 18 Nov 2015 22:36:23 +0000]
org-colview: Fix skip-empty-rows without ITEM

* lisp/org-colview.el (org-columns-capture-view): Obey to
  skip-empty-rows even when "ITEM" doesn't belong to current title.

Reported-by: Joon Ro <>

2 months agoBackport commit ac16149 from Emacs
Paul Eggert [Tue, 17 Nov 2015 23:28:50 +0000]
Backport commit ac16149 from Emacs

Fix docstring quoting problems with ‘ '’
Paul Eggert
Tue Nov 17 15:29:35 2015 -0800

2 months agoorg-feed.el: Load the xml library before substituting a guid XML element
Hiroshi Saito [Sun, 18 Oct 2015 23:07:01 +0000]
org-feed.el: Load the xml library before substituting a guid XML element

* lisp/org-feed.el (org-feed-parse-rss-feed): Load the xml library
before calling `xml-substitute-special`.


3 months agoorg-table: Fix `org-table-get-range' with column formulas
Nicolas Goaziou [Thu, 12 Nov 2015 22:12:18 +0000]
org-table: Fix `org-table-get-range' with column formulas

* lisp/org-table.el (org-table-get-stored-formulas): Store complete
  column formulas including the "$" sign.  Remove interactive status.
(org-table-get-range): Handle nicely "$n..$m" ranges.  Apply
changes to `org-table-get-stored-formulas'.  Rename some bindings for
(org-table-expand-lhs-ranges): Ignore column formalas.
(org-table-remote-reference-indirection): Refactor function.

Reported-by: Junpeng Qiu <>

3 months agoox: Fix comments removal
Nicolas Goaziou [Thu, 12 Nov 2015 10:28:13 +0000]
ox: Fix comments removal

* lisp/ox.el (org-export--delete-comments): Preserve document's
  structure when removing comment lines or comment blocks.

* testing/lisp/test-ox.el (test-org-export/comments): New test.

Reported-by: Samuel Wales <>

3 months agoorg-table: Fix code typo
Nicolas Goaziou [Wed, 11 Nov 2015 00:28:27 +0000]
org-table: Fix code typo

* lisp/org-table.el (org-table-analyze): Fix code typo introduced in

3 months agoorg-table: Fix bug with "$>" reference
Nicolas Goaziou [Tue, 10 Nov 2015 23:37:57 +0000]
org-table: Fix bug with "$>" reference

* lisp/org-table.el (org-table-analyze): Fix incorrect replacement for
  "$>" reference when the table ends on a hline.
* testing/lisp/test-org-table.el (test-org-table/end-on-hline): New

3 months agoFix table editing with an active region
Nicolas Goaziou [Thu, 5 Nov 2015 22:07:18 +0000]
Fix table editing with an active region

* lisp/org.el (org-self-insert-command): Do not call
  `backward-delete-char' since it possibly deletes active region.
  Simplify code.

This fixes bug#21838.

3 months agoFix bug#21818
Nicolas Goaziou [Thu, 5 Nov 2015 11:26:01 +0000]
Fix bug#21818

* lisp/org.el (org-insert-link): Redisplay after inserting link.

Reported-by: Emanuel Evans <>

3 months agoorg-format-outline-path: Ignore nil path elements
Kyle Meyer [Sat, 31 Oct 2015 16:36:16 +0000]
org-format-outline-path: Ignore nil path elements

* lisp/org.el (org-format-outline-path): Ignore nil path elements.
* testing/lisp/test-org.el (test-org/format-outline-path): Add test.

The PATH argument shouldn't contain a nil item.  However, this didn't
fail before 1c74002, and helm-get-org-candidates-in-file relies on this
behavior, so prevent it from failing now.

Reported-by: Simon Thum <>

3 months agoorg-format-outline-path: Cosmetic fix
Kyle Meyer [Sat, 31 Oct 2015 16:28:51 +0000]
org-format-outline-path: Cosmetic fix

* lisp/org.el (org-format-outline-path): Change loop counter.

The old version gives the same result when combined with the other for
clause, but it reads as though the intention is to reach
(length path) rather than (1- (length path)).

3 months agobabel: fix header arg duplication
Aaron Ecay [Thu, 29 Oct 2015 13:31:28 +0000]
babel: fix header arg duplication

* lisp/ob-core.el (org-babel-process-params): Make idempotent.
* testing/lisp/test-ob.el (ob/process-params-no-duplicates): New test.

3 months agoRewrite org-format-outline-path
Kyle Meyer [Tue, 27 Oct 2015 02:49:45 +0000]
Rewrite org-format-outline-path

* lisp/org.el (org-format-outline-path): Avoid out-of-range error when
  the length of PREFIX is greater than the value given for WIDTH.
  Prevent result from extending beyond WIDTH.  Simplify code.
* testing/lisp/test-org.el (test-org/format-outline-path): Add tests.

Reported-by: Simon Thum <>

3 months agodoc/org.texi: Add index for Archive mode
Marco Wahl [Tue, 27 Oct 2015 09:14:10 +0000]
doc/org.texi: Add index for Archive mode

3 months agoorg-clock: Fix clocking in
Nicolas Goaziou [Sun, 25 Oct 2015 14:51:53 +0000]
org-clock: Fix clocking in

* lisp/org-clock.el (org-clock-find-position): Correctly position cursor
  on the correct headline.

Reported-by: Jan Malakhovski <>

3 months agoob-core: Fix "wrong-type-argument stringp nil"
Nicolas Goaziou [Sat, 24 Oct 2015 09:37:46 +0000]
ob-core: Fix "wrong-type-argument stringp nil"

* lisp/ob-core.el (org-babel-merge-params): Tolerate empty :exports

Reported-by: Rainer M Krug <>

3 months agoRestore behavior of '.' in org-read-date
Kyle Meyer [Fri, 23 Oct 2015 15:15:44 +0000]
Restore behavior of '.' in org-read-date

* lisp/org.el (org-read-date-minibuffer-local-map): Fix period behavior
  broken by e802936.

Reported-by: Matt Lundin <>

3 months agoFix `org-return-follows-link' on links with emphasis
Nicolas Goaziou [Sun, 18 Oct 2015 07:36:15 +0000]
Fix `org-return-follows-link' on links with emphasis

* lisp/org.el (org-return): Properly follow links when description is
  emphasized.  Also tolerate links and timestamps in otherwise forbidden
  areas (e.g., comments, node properties...), much like

* testing/lisp/test-org.el (test-org/return): Add tests.

Reported-by: Samuel Wales <>

3 months agoox-ascii: Fix code typo
Nicolas Goaziou [Sun, 18 Oct 2015 07:27:28 +0000]
ox-ascii: Fix code typo

* lisp/ox-ascii.el (org-ascii--describe-links): Fix code typo introduced
  in d6a718a.

3 months agoorg-clock: Fix clock drawer creation
Nicolas Goaziou [Sat, 17 Oct 2015 23:39:36 +0000]
org-clock: Fix clock drawer creation

* lisp/org-clock.el (org-clock-find-position): Create clock drawer when
  a drawer is missing, even though requested, but some clocks are
  already present in the entry.

Reported-by: Nikolay Kudryavtsev <>

3 months agoox-ascii: Fix external id links
Nicolas Goaziou [Sat, 17 Oct 2015 22:02:31 +0000]
ox-ascii: Fix external id links

* lisp/ox-ascii.el (org-ascii--describe-links): Fix export when id link
  targets an external file.

Reported-by: Samuel Wales <>

3 months agoorg-element: Fix parsing of planning in inline tasks
Nicolas Goaziou [Fri, 16 Oct 2015 21:19:06 +0000]
org-element: Fix parsing of planning in inline tasks

* lisp/org-element.el (org-element--next-mode): Line following an
  inlinetask can be a planning.
* testing/lisp/test-org-element.el (test-org-element/inlinetask-parser):
  Update test.

Reported-by: Gregor Zattler <>

3 months agoox-beamer: Fix labels
Nicolas Goaziou [Fri, 16 Oct 2015 20:38:14 +0000]
ox-beamer: Fix labels

* lisp/ox-beamer.el (org-beamer--get-label): Remove protective braces
  when extracting label from options.
(org-beamer--format-frame): Protect label with braces if it contains

Based off a patch from Fabrice
Popineau (<>).