org-mode.git
5 days agoorg-protocol: Don't push url to kill-ring maint
Matt Lundin [Tue, 18 Apr 2017 01:58:30 +0000 (20:58 -0500)]
org-protocol: Don't push url to kill-ring

* lisp/org-protocol.el: (org-protocol-do-capture) Don't push link to
  kill-ring when invoking `org-protocol-capture'.  Otherwise,
  `org-protocol-do-capture' interferes with capture templates that
  insert the contents of the clipboard or the kill ring.

5 days agoorg-capture: Fix typo
Nicolas Goaziou [Mon, 17 Apr 2017 18:04:09 +0000 (20:04 +0200)]
org-capture: Fix typo

* lisp/org-capture.el (org-capture-fill-template): Fix typo introduced
  in last commit.

Reported-by: Kaushal Modi <kaushal.modi@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/113126>

6 days agoorg-capture: Fix clipboard history with %^C or %^L place holders
Nicolas Goaziou [Mon, 17 Apr 2017 12:18:06 +0000 (14:18 +0200)]
org-capture: Fix clipboard history with %^C or %^L place holders

* lisp/org-capture.el (org-capture--clipboards): New variable.
(org-capture-fill-template): Use new variable.

Reported-by: Allen Li <darkfeline@felesatra.moe>
<http://permalink.gmane.org/gmane.emacs.orgmode/113020>

6 days agoox-confluence.el: Blank table cells produce required whitespace
Stephen Mackenzie [Mon, 17 Apr 2017 04:00:39 +0000 (00:00 -0400)]
ox-confluence.el: Blank table cells produce required whitespace

* contrib/lisp/ox-confluence.el (org-confluence-table-cell): Add blank
space in an empty table cell such that Confluence tables do not skip
empty entries and produce erroneous table headers.

Confluence tables are formatted incorrectly when empty cells
cause `||' to generate the next cell as a table header, skipping
the empty cell.  Empty cells must be formatted as `| |'.

TINYCHANGE

6 days agoorg-protocol: Do not catch all errors when providing backward compatibility
Nicolas Goaziou [Mon, 17 Apr 2017 09:03:47 +0000 (11:03 +0200)]
org-protocol: Do not catch all errors when providing backward compatibility

* lisp/org-protocol.el (org-protocol-check-filename-for-protocol): Do
  not catch every error so as to ease old style support.  Re-format
  code to fit within 80 columns.

Reported-by: Adam Porter <adam@alphapapa.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/113102>

6 days agoFix explanation, if state change is blocked by contained checkboxes
Marc Ihm [Fri, 14 Apr 2017 15:49:50 +0000 (17:49 +0200)]
Fix explanation, if state change is blocked by contained checkboxes

* lisp/org.el (org-todo): Fix explanation, if state change is blocked
  by contained checkboxes.

Consider a node, which contains unchecked checkboxes; if you have set
org-enforce-todo-checkbox-dependencies and try to change the node to
DONE, you will be denied with a message explaining why. However in this
special case the explanation would be wrong in talking of an unrelated
node instead of the checkboxes.

The fix uses the already existing variable org-blocked-by-checkboxes
(which is handled in org-block-todo-from-checkboxes).  Similar code is
already present in org-agenda-dim-blocked-tasks within org-agenda.el.

6 days agoorg-clock: Silence byte-compiler
Nicolas Goaziou [Mon, 17 Apr 2017 08:04:54 +0000 (10:04 +0200)]
org-clock: Silence byte-compiler

6 days agoorg-clock: Fix :link parameter in Clock table
Nicolas Goaziou [Mon, 17 Apr 2017 08:02:15 +0000 (10:02 +0200)]
org-clock: Fix :link parameter in Clock table

* lisp/org-clock.el (org-clock-get-table-data): Fix link creation with
  headlines containing COMMENT or TODO keywords.  Fix docstring.
  Small refactoring.

Reported-by: "Stacey Marshall" <stacey.marshall@oracle.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/113094>

6 days agoDon't call kill-this-buffer outside of menus
Kyle Meyer [Sun, 16 Apr 2017 21:07:44 +0000 (17:07 -0400)]
Don't call kill-this-buffer outside of menus

* contrib/lisp/org-toc.el (org-toc-quit):
* lisp/org-mhe.el (org-mhe-follow-link): Use kill-buffer rather than
  menu-bar.el's kill-this-buffer.

See Emacs bug#26466 and discussion on emacs.devel:
https://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00346.html.

This is in favor of backporting Emacs's 2e4f4c9d48 (Don't call
'kill-this-buffer' outside of menus, 2017-04-12), which introduces a
new function kill-current-buffer that provides special handling of
minibuffers.

7 days agoox-latex: Remove unwanted indentation in horizontal rules
Nicolas Goaziou [Sun, 16 Apr 2017 07:33:33 +0000 (09:33 +0200)]
ox-latex: Remove unwanted indentation in horizontal rules

* lisp/ox-latex.el (org-latex-horizontal-rule): Add "\noindent" macro
  before the horizontal rule.

Reported-by: Justen Rickert <justenrickert@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/113092>

7 days agoob-sql.el: Fix filename conversion in minGW environment.
Xi Shen [Sun, 16 Apr 2017 07:24:06 +0000 (09:24 +0200)]
ob-sql.el: Fix filename conversion in minGW environment.

(org-babel-sql-convert-standard-filename): If it is not in Cygwin
environment, and `system-nt' is "windows-nt", Emacs must be in minGW
or MSYS environment, and can handle Windows filename correctly.

TINYCHANGE

7 days agoUpdating MathJax CDN links
aviv [Sat, 15 Apr 2017 20:21:57 +0000 (16:21 -0400)]
Updating MathJax CDN links

* doc/org.texi : Change reference to "cdn.mathjax.org" to "cdnjs.com",
  removing comment about no longer relevant terms of service.
* lisp/ox-html.el (org-html-mathjax-options) : Change link to
  appropriate cdnjs.com link to load MathJax.

Updating MathJax CDN links to reflect cdnjs.com as cdn.mathjax.org
will be disconitnued as of 30 April 2017.

TINYCHANGE

8 days agoorg-element: Fix radio link parser
Nicolas Goaziou [Sat, 15 Apr 2017 15:27:01 +0000 (17:27 +0200)]
org-element: Fix radio link parser

* lisp/org-element.el (org-element--object-lex): Fix parsing of radio
  links within emphasis.
* testing/lisp/test-org-element.el (test-org-element/link-parser): Add
  test.

Reported-by: R C <recifx@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/113063>

8 days agoFix `org-forward-heading-same-level'
Nicolas Goaziou [Sat, 15 Apr 2017 14:51:33 +0000 (16:51 +0200)]
Fix `org-forward-heading-same-level'

* lisp/org.el (org-forward-heading-same-level): Do not fail when
  heading is at the beginning of the buffer.
* testing/lisp/test-org.el (test-org/forward-heading-same-level): New
  test.

Reported-by: Rafael Laboissière <rafael@laboissiere.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/113084>

12 days agoorg-mobile: Fix bug in mobile outline path handling
Ian Dunn [Fri, 7 Apr 2017 22:58:42 +0000 (18:58 -0400)]
org-mobile: Fix bug in mobile outline path handling

* org-mobile.el (org-mobile-get-outline-path-link): Use a `:' after
  file instead of a `/'.

12 days agoEnsure test files are opened in Emacs in test-org/fuzzy-links
Skip Collins [Fri, 7 Apr 2017 15:41:47 +0000 (11:41 -0400)]
Ensure test files are opened in Emacs in test-org/fuzzy-links

13 days agoorg-insert-link: Correct changes from a08dd527d
Kyle Meyer [Mon, 10 Apr 2017 00:44:10 +0000 (20:44 -0400)]
org-insert-link: Correct changes from a08dd527d

* lisp/org.el (org-insert-link): Fix regexp and undefined variable.

13 days agoBackport commit c92bae9a0 from Emacs
Tom Tromey [Sat, 18 Mar 2017 22:03:15 +0000 (23:03 +0100)]
Backport commit c92bae9a0 from Emacs

* lisp/org-list.el (org-list-insert-radio-list):
* lisp/org-table.el (orgtbl-setup, orgtbl-insert-radio-table): Use
derived-mode-p.

change org to use derived-mode-p
c92bae9a08cc7c2eb61bad32d9a9d6553b6d2c19
Tom Tromey
Wed Apr 5 15:53:38 2017 -0600

13 days agoorg-link-edit.el: Sync with upstream
Kyle Meyer [Mon, 10 Apr 2017 00:44:10 +0000 (20:44 -0400)]
org-link-edit.el: Sync with upstream

Update to version 1.1.0 (af79eebdb).

3 weeks agoox-man: Add new line before line break tag
Francesco Montanari [Sun, 26 Mar 2017 09:59:19 +0000 (12:59 +0300)]
ox-man: Add new line before line break tag

* lisp/ox-man.el (org-man-line-break): Transcode a LINE-BREAK object
  from Org to Man by adding the appropriate tag on a new line.

TINYCHANGE

3 weeks agoFix `org-startup-with-latex-preview' handling
Nicolas Goaziou [Thu, 30 Mar 2017 10:46:46 +0000 (12:46 +0200)]
Fix `org-startup-with-latex-preview' handling

* lisp/org.el (org-mode): When honoring
  `org-startup-with-latex-preview', make sure to preview the whole
  buffer.

Reported-by: Diego Nicola Barbato
<http://permalink.gmane.org/gmane.emacs.orgmode/112925>

3 weeks agoorg-clock: Preserve narrowing when building clock table
Nicolas Goaziou [Wed, 29 Mar 2017 14:33:10 +0000 (16:33 +0200)]
org-clock: Preserve narrowing when building clock table

* lisp/org-clock.el (org-dblock-write:clocktable): Preserve current
  narrowing, if any, when building the table.

Reported-by: Christof Musik <ml-orgmode@litephone.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/112872>

3 weeks agoSmall refactoring
Nicolas Goaziou [Wed, 29 Mar 2017 13:34:27 +0000 (15:34 +0200)]
Small refactoring

* lisp/org.el (org-insert-link): Small refactoring.

3 weeks agoAllow insertion of links with multi-line search strings
Matt Lundin [Mon, 27 Mar 2017 14:55:33 +0000 (09:55 -0500)]
Allow insertion of links with multi-line search strings

* lisp/org.el: (org-insert-link): Fix regexps to match across
  newlines.

3 weeks agoAdd test for link search
Nicolas Goaziou [Wed, 29 Mar 2017 12:17:50 +0000 (14:17 +0200)]
Add test for link search

* testing/lisp/test-org.el (test-org/fuzzy-links): Add test.

3 weeks agoAllow blank lines in text search link
Nicolas Goaziou [Wed, 29 Mar 2017 12:12:58 +0000 (14:12 +0200)]
Allow blank lines in text search link

* lisp/org.el (org-link-search): Allow blank lines.

This is a follow-up to 4dde26f08.

3 weeks agoox-latex: Fix last commit
Nicolas Goaziou [Mon, 27 Mar 2017 12:01:32 +0000 (14:01 +0200)]
ox-latex: Fix last commit

* lisp/ox-latex.el (org-latex--align-string): Fix typo in last commit.

3 weeks agoMerge branch 'maint' of orgmode.org:org-mode into maint
Nicolas Goaziou [Mon, 27 Mar 2017 11:52:40 +0000 (13:52 +0200)]
Merge branch 'maint' of orgmode.org:org-mode into maint

3 weeks agoox-latex: Fix user-defined align string in matrices
Nicolas Goaziou [Mon, 27 Mar 2017 11:43:49 +0000 (13:43 +0200)]
ox-latex: Fix user-defined align string in matrices

* lisp/ox-latex.el (org-latex--align-string): Change signature.
  Center all cells in matrices, yet preserve user-defined align
  string.
(org-latex--math-table): Apply signature change.

Reported-by: Phil Regier <phil.regier@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112873>

3 weeks agoox-latex: Fix user-defined align string in matrices
Nicolas Goaziou [Mon, 27 Mar 2017 11:43:49 +0000 (13:43 +0200)]
ox-latex: Fix user-defined align string in matrices

* lisp/ox-latex.el (org-latex--align-string): Change signature.
  Center all cells in matrices, yet preserve user-defined align
  string.
(org-latex--math-table): Apply signature change.

Reported-by: Phil Regier <phil.regier@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112873>

3 weeks agoFix lsearch strings with newline characters
Nicolas Goaziou [Mon, 27 Mar 2017 11:34:04 +0000 (13:34 +0200)]
Fix lsearch strings with newline characters

* lisp/org.el (org-link-search): Fix regexp.
* testing/lisp/test-org.el (test-org/fuzzy-links): Add test.

Reported-by: Matt Lundin <mdl@imapmail.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/112876>

3 weeks agoBackport commit 14d8b6858 from Emacs
Paul Eggert [Tue, 21 Mar 2017 16:18:42 +0000 (09:18 -0700)]
Backport commit 14d8b6858 from Emacs

* doc/org.texi (noweb-ref): Simplify shell script example and don’t
use ‘tail -1’, which is not portable.

Port and simplify example sh script
14d8b6858a49e97f9b69593df5a8a7886430d43f
Paul Eggert
Tue Mar 21 09:19:42 2017 -0700

4 weeks agoorg: Fix tag setter
Marco Wahl [Sun, 26 Mar 2017 13:39:20 +0000 (15:39 +0200)]
org: Fix tag setter

* lisp/org.el (org-set-tags): Treat ':' and '::' as no tag.

4 weeks agoox-html.el (org-html-scripts): Fix copyright years
Bastien [Thu, 23 Mar 2017 22:46:13 +0000 (23:46 +0100)]
ox-html.el (org-html-scripts): Fix copyright years

* lisp/ox-html.el (org-html-scripts): Fix copyright years.

4 weeks agoox: Fix "Fix :filter-options"
Nicolas Goaziou [Thu, 23 Mar 2017 15:41:26 +0000 (16:41 +0100)]
ox: Fix "Fix :filter-options"

* lisp/ox.el (org-export-as): Remove uninterpreted data from back-end
  specific parsed keywords.

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

This fixes 6cd42b08f9347a8d6084ec23548b754f9e02b2a1.

4 weeks agoox: Clarify a docstring
Nicolas Goaziou [Thu, 23 Mar 2017 15:38:59 +0000 (16:38 +0100)]
ox: Clarify a docstring

* lisp/ox.el (org-export-get-all-options): Specify return value for
  unknown back-ends.
(org-export--parse-option-keyword):
(org-export--get-subtree-options):
(org-export--get-inbuffer-options):
(org-export--get-global-options): Remove useless check.

4 weeks agoorg-agenda: Fix agenda buffer name after reload sticky agenda
Marco Wahl [Tue, 21 Mar 2017 19:47:30 +0000 (20:47 +0100)]
org-agenda: Fix agenda buffer name after reload sticky agenda

* lisp/org-agenda.el (org-agenda-list): Don't rename the buffer when
  redoing sticky.

This fix has been proposed by Ian Dunn.

<http://permalink.gmane.org/gmane.emacs.orgmode/112833>

TINYCHANGE

4 weeks agotest-org-agenda: Test agenda buffername when reload sticky agenda
Marco Wahl [Tue, 21 Mar 2017 19:42:08 +0000 (20:42 +0100)]
test-org-agenda: Test agenda buffername when reload sticky agenda

* testing/lisp/test-org-agenda.el: One additional test to Check that
  buffer name remains the same after reload.  (BTW some cleanup.)

4 weeks agoorg-src: Fix fontification error
Aaron Jensen [Sun, 19 Mar 2017 22:55:51 +0000 (23:55 +0100)]
org-src: Fix fontification error

* lisp/org-src.el (org-src-font-lock-fontify-block): Fix fontification
error introduced in commit f2a5104e45b6f44a08960ae49ba20c124a8fa9d8.

TINYCHANGE

4 weeks agoBackport commit 265a5d979 from Emacs
Michael Albinus [Thu, 16 Mar 2017 15:23:07 +0000 (16:23 +0100)]
Backport commit 265a5d979 from Emacs

* doc/org.texi (dir): Change example to use a method.

Document remote file name syntax change
265a5d9791bf42da0bab7bdbef4352e8d734ef31
Michael Albinus
Thu Mar 16 16:23:07 2017 +0100

5 weeks agoorg-clock: Fix percent formula column in clock table
Yasushi SHOJI [Sun, 19 Mar 2017 09:55:44 +0000 (10:55 +0100)]
org-clock: Fix percent formula column in clock table

* lisp/org-clock.el (org-clocktable-write-default): Fix percent
  formula column in clock table.

5 weeks agoob-exp: Fix export of src blocks with pathological name
Nicolas Goaziou [Sat, 18 Mar 2017 09:28:15 +0000 (10:28 +0100)]
ob-exp: Fix export of src blocks with pathological name

* lisp/ob-exp.el (org-babel-exp-process-buffer): Discard false
  positives.
* testing/lisp/test-ob-exp.el (ob-exp/src-block-with-affiliated-keyword):
  New test.

Reported-by: Skip Collins <skip.collins@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112797>

5 weeks agoorg-agenda: Fix agenda standard name when going unsticky
Marco Wahl [Fri, 17 Mar 2017 18:44:56 +0000 (19:44 +0100)]
org-agenda: Fix agenda standard name when going unsticky

* lisp/org-agenda.el (org-agenda-list): Reset `org-agenda-buffer-name'
  to the original name.
* testing/lisp/test-org-agenda.el: Pertaining unit test.  + 2 basic
  agenda tests.
* testing/examples/agenda-file.org: File to produce content for an
  agenda to test.

5 weeks agoorg-agenda: Fix off-by-one scheduled repeat
Nicolas Goaziou [Fri, 17 Mar 2017 07:35:47 +0000 (08:35 +0100)]
org-agenda: Fix off-by-one scheduled repeat

* lisp/org-agenda.el (org-agenda-get-scheduled): Make the second
  repeat appear as "Sched. 1x".

Reported-by: Eric S Fraga <e.fraga@ucl.ac.uk>
<http://permalink.gmane.org/gmane.emacs.orgmode/112755>

5 weeks agolisp/org-table.el: Bugfix: correctly handle increment of -/+ numbers
Bastien [Thu, 16 Mar 2017 21:15:11 +0000 (22:15 +0100)]
lisp/org-table.el: Bugfix: correctly handle increment of -/+ numbers

* lisp/org-table.el (org-table-copy-down): Bugfix: correctly
handle increment of numbers with a -/+ sign.

5 weeks agoFix custom timestamps during export (ox-groff)
Robert Klein [Mon, 13 Mar 2017 06:29:27 +0000 (07:29 +0100)]
Fix custom timestamps during export (ox-groff)

* contrib/lisp/ox-groff.el (org-groff-clock, org-groff-planning): Use
  org-translate-time'.

(propagate changes introduced to other export backends in commit
e1adb17ba509a43e9a03a5b367a98b8bc8de8b02.)

5 weeks agoorg.texi: Fix link
Nicolas Goaziou [Thu, 16 Mar 2017 12:00:39 +0000 (13:00 +0100)]
org.texi: Fix link

* doc/org.texi (Hooks): Fix link.

5 weeks agoox-org: Fix footnotes export, part 2
Nicolas Goaziou [Wed, 15 Mar 2017 13:30:52 +0000 (14:30 +0100)]
ox-org: Fix footnotes export, part 2

* lisp/ox-org.el (org-org--add-missing-sections): New function.
(org-org-section): Small refactoring.

Since footnote definitions are inserted in the section of the
headline, make sure those are not being skipped.

5 weeks agoox-org: Correctly export footnote references in headlines
Nicolas Goaziou [Wed, 15 Mar 2017 10:51:16 +0000 (11:51 +0100)]
ox-org: Correctly export footnote references in headlines

* lisp/ox-org.el (org-org-section): Also include references found in
  headlines when inserting footnote definitions at the end of
  a section.

Reported-by: WY H <jcjuly@outlook.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112678>

5 weeks agoox: Fix :filter-options
Nicolas Goaziou [Tue, 14 Mar 2017 17:10:07 +0000 (18:10 +0100)]
ox: Fix :filter-options

* lisp/ox.el (org-export--remove-uninterpreted-data): Do not modify
  communication channel.  Change "blob" to "datum".
(org-export--remove-uninterpreted-data-1): Remove function.
(org-export-as): Remove uninterpreted data from parsed keyword before
applying filters.

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

Reported-by: Rasmus <rasmus@gmx.us>
<http://permalink.gmane.org/gmane.emacs.orgmode/112730>

5 weeks agoorg-capture: Fix escaping characters in template embedded S-exps
Nicolas Goaziou [Mon, 13 Mar 2017 21:45:54 +0000 (22:45 +0100)]
org-capture: Fix escaping characters in template embedded S-exps

* lisp/org-capture.el (org-capture-fill-template): Escape backslash
  characters in %i contents when those are inserted within a S-exp.
  Also prevent adding any prefix to %i contents spanning over multiple
  lines when they are inserted within a S-exp.

* testing/lisp/test-org-capture.el (test-org-capture/fill-template):
  Add tests.

Reported-by: Samuel Wales <samologist@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112232>

6 weeks agoRevert "ox-ascii: Remove useless brackets in sub/super script"
Nicolas Goaziou [Sat, 11 Mar 2017 10:21:26 +0000 (11:21 +0100)]
Revert "ox-ascii: Remove useless brackets in sub/super script"

This reverts commit 5b4215eb166554a2a358be457318c4dab5a5b55d.

6 weeks agoorg-agenda: Fix infloop in `org-find-top-headline'
Nicolas Goaziou [Sat, 11 Mar 2017 10:17:52 +0000 (11:17 +0100)]
org-agenda: Fix infloop in `org-find-top-headline'

* lisp/org-agenda.el (org-find-top-headline): Prevent infloop when top
  headline has not level 1.

Reported-by: Adrian Bradd <adrian.bradd@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112623>

6 weeks agoox-md: Fix internal links
Nicolas Goaziou [Fri, 10 Mar 2017 17:52:06 +0000 (18:52 +0100)]
ox-md: Fix internal links

* lisp/ox-md.el (org-md-headline): Add an anchor when a link is
  referring to the headline.
(org-md--headline-referred-p): New function.

6 weeks agoox-ascii: Remove useless brackets in sub/super script
Nicolas Goaziou [Wed, 8 Mar 2017 11:28:28 +0000 (12:28 +0100)]
ox-ascii: Remove useless brackets in sub/super script

* lisp/ox-ascii.el (org-ascii-subscript):
(org-ascii-superscript): Only use brackets when there are multiple
words.

6 weeks agoFix LaTeX and Beamer publishing processes
Nicolas Goaziou [Wed, 8 Mar 2017 08:33:09 +0000 (09:33 +0100)]
Fix LaTeX and Beamer publishing processes

* lisp/ox-beamer.el (org-beamer-publish-to-pdf):
* lisp/ox-latex.el (org-latex-publish-to-pdf): Set default directory
  prior to compiling the generated tex file.

Reported-by: Robert Klein <roklein@roklein.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/112388>

6 weeks agoox-html: Fix verse blocks
Nicolas Goaziou [Tue, 7 Mar 2017 23:12:55 +0000 (00:12 +0100)]
ox-html: Fix verse blocks

* lisp/ox-html.el (org-html-verse-block): Add missing line break at
  the end of each line in verse environments.

Reported-by: Skip Collins <skip.collins@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112537>

6 weeks agotest-org-list.el: Fix visibility tests
Marco Wahl [Tue, 7 Mar 2017 15:37:25 +0000 (16:37 +0100)]
test-org-list.el: Fix visibility tests

* testing/lisp/test-org-list.el (test-org-list/move-item-down):
  Replace several calls of `org-invisible-p2' with calls on a lower
  level.

6 weeks agoox-confluence: Handle checkboxes and inactive timestamps correctly
Marc Ihm [Sun, 5 Mar 2017 17:36:30 +0000 (18:36 +0100)]
ox-confluence: Handle checkboxes and inactive timestamps correctly

* contrib/lisp/ox-confluence.el (org-confluence-timestamp): New
  function.
(org-confluence-headline): Use new function.
(org-confluence-table-cell): Add missing space.

Fix handling of square brackets from timestamps and checkboxes; avoid
invalid confluence markup for empty table headers.

6 weeks agoFix failing tests
Nicolas Goaziou [Sun, 5 Mar 2017 17:05:02 +0000 (18:05 +0100)]
Fix failing tests

* testing/lisp/test-ob.el (test-ob/org-babel-insert-result): Fix
  failing tests.

Reported-by: "Charles C. Berry" <ccberry@ucsd.edu>
<http://permalink.gmane.org/gmane.emacs.orgmode/112475>

7 weeks agoorg.texi: Document alternatives to M-TAB
Th. Rikl [Tue, 28 Feb 2017 15:11:43 +0000 (16:11 +0100)]
org.texi: Document alternatives to M-TAB

* doc/org.texi (Drawers):
(Editing and debugging formulas):
(Export settings):
(Completion): Document alternatives to M-TAB

(Built-in table editor): Change <TAB> into TAB.

TINYCHANGE

7 weeks agoob-core: Properly escape Org syntax when inserting results
Nicolas Goaziou [Wed, 1 Mar 2017 21:19:04 +0000 (22:19 +0100)]
ob-core: Properly escape Org syntax when inserting results

* lisp/ob-core.el (org-babel-examplify-region): Escape Org syntax
  before wrapping it.

* testing/lisp/test-ob.el (test-ob/org-babel-insert-result): Add test.
  Renamed from `test-ob/org-babel-insert-result--improper-lists'.

Reported-by: D M German <dmg@turingmachine.org>
7 weeks agoorg-protocol: Fix library name
Nicolas Goaziou [Tue, 28 Feb 2017 12:37:48 +0000 (13:37 +0100)]
org-protocol: Fix library name

* lisp/org-protocol.el (org-protocol-create-for-org): Use `ox-publish'
  instead of outdated `org-publish'.  Improve warning message.

Reported-by: Jonas Bernoulli <jonasbernoulli@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112386>

7 weeks agoorg-agenda-menu: Correct key for fortnight view
Kyle Meyer [Mon, 27 Feb 2017 16:10:02 +0000 (11:10 -0500)]
org-agenda-menu: Correct key for fortnight view

* lisp/org-agenda.el (org-agenda-menu): Correct key for fortnight
  view.

Reported-by: J. David Boyd <dboyd2@mmm.com>
8 weeks agoorg.texi: Fix example
Nicolas Goaziou [Thu, 23 Feb 2017 18:15:22 +0000 (19:15 +0100)]
org.texi: Fix example

* doc/org.texi (noweb-ref): Update Babel parameter syntax in example.

8 weeks agoorg.el: Make faces org-quote and org-verse be appended
Anders Johansson [Thu, 23 Feb 2017 13:14:50 +0000 (14:14 +0100)]
org.el: Make faces org-quote and org-verse be appended

* lisp/org.el (org-fontify-quote-and-verse-blocks): Append faces.  Use
  `add-face-text-property'.

This means fontification of emphasis, links etc. is kept in quote and
verse blocks even with org-fontify-quote-and-verse-blocks non-nil.

TINYCHANGE

8 weeks agoorg-capture: Tiny refactoring
Nicolas Goaziou [Thu, 23 Feb 2017 11:59:24 +0000 (12:59 +0100)]
org-capture: Tiny refactoring

* lisp/org-capture.el (org-capture-refile): Tiny refactoring.

2 months agoorg-capture: Fix commit 7d7c38
Bastien [Tue, 21 Feb 2017 14:41:15 +0000 (15:41 +0100)]
org-capture: Fix commit 7d7c38

2 months agoorg-capture: Fix `org-capture-refile'
Nicolas Goaziou [Sun, 19 Feb 2017 14:27:09 +0000 (15:27 +0100)]
org-capture: Fix `org-capture-refile'

* lisp/org-capture.el (org-capture-refile): Preserve location of point
  when refiling.

* testing/lisp/test-org-capture.el (test-org-capture/refile): New
  test.

Reported-by: Liu Hui <liuhui1610@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112202>

2 months agoorg-clock: Add german translation.
Axel Kielhorn [Sun, 19 Feb 2017 06:25:01 +0000 (07:25 +0100)]
org-clock: Add german translation.

* lisp/org-clocl.el (org-clock-clocktable-language-setup): German
  translations added.

Axel Kielhorn <org-mode@axelkielhorn.de>
TINYCHANGE

2 months agoorg-src: Fix typo in code comment
Nicolas Goaziou [Sat, 18 Feb 2017 13:56:41 +0000 (14:56 +0100)]
org-src: Fix typo in code comment

* lisp/org-src.el (org-edit-src-save): Fix typo.

2 months agoorg-clock: Fix number of columns with :compact parameter
Nicolas Goaziou [Sat, 18 Feb 2017 13:20:18 +0000 (14:20 +0100)]
org-clock: Fix number of columns with :compact parameter

* lisp/org-clock.el (org-clocktable-write-default): Fix number of
  columns with :compact parameter.

Reported-by: Stefan Nobis <stefan-ml@snobis.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/112217>

2 months agoProperly save source blocks with `save-some-buffers'
Nicolas Goaziou [Fri, 17 Feb 2017 21:29:06 +0000 (22:29 +0100)]
Properly save source blocks with `save-some-buffers'

* lisp/org-src.el (org-src-mode-configure-edit-buffer): Set
  `write-contents-functions' so that saving a remote editing buffer
  always call `org-edit-src-save'.
(org-edit-src-save): Return a non-nil value explicitly.

Reported-by: Thibault Polge <thibault@thb.lt>
<http://permalink.gmane.org/gmane.emacs.orgmode/112201>

2 months agoorg-clock: Fix error when using unknown language
Nicolas Goaziou [Fri, 17 Feb 2017 13:34:19 +0000 (14:34 +0100)]
org-clock: Fix error when using unknown language

* lisp/org-clock.el (org-clocktable-write-default): Be careful
  that (nth 4 lwords) and (nth 5 lwords) can be nil, if :lang as an
  unknown value.

2 months agoorg-lint: Add checker for empty headlines with tags
Nicolas Goaziou [Fri, 17 Feb 2017 12:23:26 +0000 (13:23 +0100)]
org-lint: Add checker for empty headlines with tags

* lisp/org-lint.el (org-lint--checkers): Add checker.
(org-lint-empty-headline-with-tags): New function.

* testing/lisp/test-org-lint.el (test-org-lint/empty-headline-with-tags):
  New test.

2 months agoFix file:// uri handling for windows-nt and cygwin
Fabrice Popineau [Thu, 16 Feb 2017 21:42:59 +0000 (22:42 +0100)]
Fix file:// uri handling for windows-nt and cygwin

* lisp/org-element.el (org-element-link-parser):
  Handle drive names in uri like file:///c:/dir/file

* lisp/ox.el (org-export-file-uri):
  Handle drive names in uri like file:///c:/dir/file

* testing/lisp/test-ox.el (test-org-export/file-uri):
  Generate the right uri to be tested against link exporter.

2 months agoorg-clock: Fix regression in Clock table
Nicolas Goaziou [Mon, 13 Feb 2017 20:24:40 +0000 (21:24 +0100)]
org-clock: Fix regression in Clock table

* lisp/org-clock.el (org-clocktable-write-default): Do not raise an
  error when :maxlevel is 0.  Small refactoring.

* testing/lisp/test-org-clock.el (test-org-clock/clocktable): Split
into ...
(test-org-clock/clocktable/ranges):
(test-org-clock/clocktable/tags):
(test-org-clock/clocktable/scope):
(test-org-clock/clocktable/maxlevel):
(test-org-clock/clocktable/formula): ... these.  Add tests.

This fixes regression introduced in ccf832e83.

Reported-by: Christoph LANGE <math.semantic.web@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112091>

2 months agoFix some tests
Nicolas Goaziou [Mon, 13 Feb 2017 16:14:38 +0000 (17:14 +0100)]
Fix some tests

* testing/lisp/test-org-element (test-org-element/link-parser): Remove
  a test.
* testing/lisp/test-org-pcomplete (test-org-pcomplete/keyword):
* testing/lisp/test-ox.el (test-org-export/file-uri): Fix tests.

2 months agoorg-element: Fix `org-element-insert-before'
Nicolas Goaziou [Mon, 13 Feb 2017 15:29:54 +0000 (16:29 +0100)]
org-element: Fix `org-element-insert-before'

* lisp/org-element.el (org-element-insert-before): Do not call
  `reverse' as contents might use `eq' objects.

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

Reported-by: Justin Kirby <justinkirby@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/112065>

2 months agoorg-table: Move table column with leaving text-properties untouched
Stefan-W. Hahn [Sun, 12 Feb 2017 11:41:19 +0000 (12:41 +0100)]
org-table: Move table column with leaving text-properties untouched

* lisp/org-table.el (org-table-move-column): Use `transpose-regions'.

Moving org-table rows is implemented with delete-region and insert which
preserve text-properties. Moving org-table columns is implemented
with replace-string, which removes text-properties.

My proposal is to use transpose-regions in org-table-move-column which
will preserve text-properties when moving columns in org-tables.

2 months agoMerge branch 'improve-org-eww' into maint
Marco Wahl [Sun, 12 Feb 2017 08:08:52 +0000 (09:08 +0100)]
Merge branch 'improve-org-eww' into maint

2 months agoorg-eww: Fix copy of form-elements
Marco Wahl [Sun, 12 Feb 2017 08:00:56 +0000 (09:00 +0100)]
org-eww: Fix copy of form-elements

* lisp/org-eww.el (org-eww-copy-for-org-mode): New behavior: Just add
  link-title when link-location is not a string.  This fixes copying
  from www.indeed.co.uk.

Reported and a suggestion of a fix by Andrea.
<http://permalink.gmane.org/gmane.emacs.orgmode/112052>.

2 months agoorgcard: Update export section
Kyle Meyer [Sat, 11 Feb 2017 22:33:18 +0000 (17:33 -0500)]
orgcard: Update export section

* doc/orgcard.tex (Export and Publishing): Correct stale bindings.
  Add asynchronous, body, and subtree bindings.

This section now includes all bindings listed in
(info "(org)The Export Dispatcher").

Reported-by: Charles C. Berry <ccberry@ucsd.edu>
<https://lists.gnu.org/archive/html/emacs-orgmode/2017-02/msg00200.html>

2 months agoSilence byte-compiler
Nicolas Goaziou [Sat, 11 Feb 2017 17:37:32 +0000 (18:37 +0100)]
Silence byte-compiler

2 months agoFix header in LaTeX snippets
Nicolas Goaziou [Sat, 11 Feb 2017 01:35:00 +0000 (02:35 +0100)]
Fix header in LaTeX snippets

* lisp/ox-latex.el (org-latex-make-preamble): Add optional argument.
* lisp/org.el (org-create-formula-image): Use it.

Reported-by: plus <ctre@users.sourceforge.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/112015>

2 months agoorgcard: Remove another timeline entry release_9.0.5
Kyle Meyer [Thu, 9 Feb 2017 17:55:27 +0000 (12:55 -0500)]
orgcard: Remove another timeline entry

* doc/orgcard.tex (Filtering and Sparse Trees): Don't mention timeline
  because this feature will be removed in version 9.1.

90f87cb98 removed the org-timeline reference in the "Agenda Views"
section but missed this one.

As a bonus, this fixes a column formatting issue in the
orgcard_letter.pdf output (orgcard.pdf was not affected) that was
caused by an extra line added in 4340cc78f.

Reported-by: David Talmage <david.talmage@shoutpoint.com>
<http://lists.gnu.org/archive/html/emacs-orgmode/2017-02/msg00193.html>

2 months agoorgcard.tex: Remove timeline reference
Kyle Meyer [Thu, 9 Feb 2017 02:41:57 +0000 (21:41 -0500)]
orgcard.tex: Remove timeline reference

* doc/orgcard.tex: Don't mention timeline because this feature will be
  removed in version 9.1.

2 months agoUpdate few bindings' descriptions based on org 9.0.4
Kaushal Modi [Sun, 5 Feb 2017 20:05:19 +0000 (15:05 -0500)]
Update few bindings' descriptions based on org 9.0.4

* doc/orgcard.tex: Update descriptions for M-UP/DOWN and M-S-UP/DOWN
  bindings for structural editing.  Removed the C-c C-q binding
  description in the Tables/Regions section as it sets org tags as
  usual, does not fill paragraph.

2 months agoorg-clock: Fix clock percent
Nicolas Goaziou [Tue, 7 Feb 2017 15:48:14 +0000 (16:48 +0100)]
org-clock: Fix clock percent

* lisp/org-clock.el (org-clocktable-write-default): Fix percent computation.
(org-clock-time%): Remove function.

* testing/lisp/test-org-clock.el (test-org-clock/clocktable): Update
  test.

As a consequence of this patch, a ":formula %" doesn't generate
a TBLFM line anymore.

2 months agoox-bibtex: Take key with spaces or non-alphabetic characters into account
Sebastien Le Maguer [Sun, 5 Feb 2017 07:11:16 +0000 (08:11 +0100)]
ox-bibtex: Take key with spaces or non-alphabetic characters into account

* ox-bibtex.el (org-bibtex-process-bib-files): Solve a bug in which
ox-bibtex was not considering enterily keys like "Author et&bsp; al.,
1999" as valid.

TINYCHANGE

2 months agoorg-clock: Do not associate a note to removed zero time CLOCKs
Nicolas Goaziou [Fri, 3 Feb 2017 21:51:56 +0000 (22:51 +0100)]
org-clock: Do not associate a note to removed zero time CLOCKs

* lisp/org-clock.el (org-clock-out): When a zero time CLOCK is
  removed, do not offer to add a note for it.

2 months agoNotes associated to CLOCKs are located after the clock
Nicolas Goaziou [Fri, 3 Feb 2017 21:46:15 +0000 (22:46 +0100)]
Notes associated to CLOCKs are located after the clock

* lisp/org.el (org-store-log-note): Make sure a note added after
  clocking out is inserted right after the CLOCK line.

Reported-by: Jorge Morais Neto <jorge13515@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/111795>

2 months agoFix indentation of some elements
Nicolas Goaziou [Fri, 3 Feb 2017 20:59:08 +0000 (21:59 +0100)]
Fix indentation of some elements

* lisp/org.el (org--get-expected-indentation): Tiny refactoring.
(org-indent-line): Ignore LaTex environments.
(org-indent-region): Better handling for export blocks, LaTeX
environments and example blocks.

* testing/lisp/test-org.el (test-org/indent-line):
(test-org/indent-region): Add tests.

2 months agoFix repeating entries without a TODO keyword
Nicolas Goaziou [Thu, 2 Feb 2017 13:17:04 +0000 (14:17 +0100)]
Fix repeating entries without a TODO keyword

* lisp/org.el (org-auto-repeat-maybe): Allow repeating entries without
  a TODO keyword.

2 months agoorg-agenda: Fix scheduled and deadline S-exp entries display
Nicolas Goaziou [Wed, 1 Feb 2017 21:36:29 +0000 (22:36 +0100)]
org-agenda: Fix scheduled and deadline S-exp entries display

* lisp/org-agenda.el (org-agenda-get-deadlines):
(org-agenda-get-scheduled): Properly handle S-exp entries.

Reported-by: Ken Mankoff <mankoff@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/111805>

2 months agoorg-table: Fix error with `org-table-get-field' at bob
Nicolas Goaziou [Wed, 1 Feb 2017 19:56:38 +0000 (20:56 +0100)]
org-table: Fix error with `org-table-get-field' at bob

* lisp/org-table.el (org-table-get-field): Do not return
  `beginning-of-buffer' error when called at beginning of buffer.

* testing/lisp/test-org-table.el (test-org-table/get-field): New test.

2 months agoReplace org-set-local by setq-local in the documentation
Nicolas Goaziou [Wed, 1 Feb 2017 14:42:04 +0000 (15:42 +0100)]
Replace org-set-local by setq-local in the documentation

* contrib/orgmanual.org (Conflicts): Update yasnippet instructions.

* doc/org.texi (Packages that conflict with Org mode): Update
  yasnippet instructions

TINYCHANGE

2 months agoorg-capture: Small fix
Nicolas Goaziou [Tue, 31 Jan 2017 21:50:09 +0000 (22:50 +0100)]
org-capture: Small fix

* lisp/org-capture.el (org-mks): Find entries with full prefix, not
last pressed key.

This fixes a bug introduced in 8194e7b09.

Reported-by: Charles Millar <millarc@verizon.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/111779>

2 months agoox-latex.el: Wrap 'minted' src blocks in a 'listing' environment
Lixin Chin [Tue, 31 Jan 2017 06:15:40 +0000 (14:15 +0800)]
ox-latex.el: Wrap 'minted' src blocks in a 'listing' environment

* lisp/ox-latex.el (org-latex-src-block): Make source highlighting
  using the 'minted' syntax highlighting package behave the same as
  using the 'listings' syntax highlighting package.

The source block should be floating if a caption is provided, or if
':float t' is provided in an '#+ATTR_LATEX:' block.  Previously, the
source block would only be floating if ':float multicolumn' was
provided.  This now matches the Org mode documentation for source
blocks.

TINYCHANGE

2 months agoorg-capture: Fix freeze when capture templates are ill-defined
Nicolas Goaziou [Mon, 30 Jan 2017 22:36:52 +0000 (23:36 +0100)]
org-capture: Fix freeze when capture templates are ill-defined

* lisp/org-capture.el (org-mks): Do not freeze when there is a missing
  step in the key hierarchy.  Fix docstring.  Refactor code for clarity.

Reported-by: Roland Everaert <reveatwork@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/111716>