Commit Graph

22214 Commits

Author SHA1 Message Date
Marco Wahl dc2198971b org-agenda: Respect narrowing for agenda restricted to buffer
* lisp/org-agenda.el (org-agenda): Add a condition to check if
  narrowing is in effect and in case set the agenda restriction markers.
* etc/ORG-NEWS (Respect narrowing when agenda command is restricted to buffer):
* doc/org-manual.org (The Agenda Dispatcher): Mention the behavior.
2019-07-15 00:22:51 +02:00
Carsten Dominik 5e9c170f38 Merge branch 'master' of code.orgmode.org:bzg/org-mode 2019-07-14 22:58:08 +02:00
Carsten Dominik 8a30e8efef Fix typos in org-guide.org 2019-07-14 22:56:51 +02:00
Kyle Meyer 57e254e67c Merge branch 'maint' 2019-07-14 11:14:54 -04:00
Ismail S 64262af685 Backport commit fb48eb48f from Emacs
* lisp/org-capture.el (org-capture-templates): Fix typo in doc
string (bug#36491).

Fix minor typo in org-capture-templates
fb48eb48f3bd432307821bc7158d1090f0e4bbf0
Ismail S
Tue Jul 9 00:53:18 2019 +0200

TINYCHANGE
2019-07-14 11:12:33 -04:00
Konstantin Kharlamov c0d699e9ba Backport commit dfc322d77 from Emacs
* lisp/org-mobile.el (org-mobile-copy-agenda-files)
(org-mobile-update-checksum-for-capture-file):
* lisp/org-table.el (org-table-number-regexp):
Replace various combinations of [0-9a-fA-F] with [[:xdigit:]].
(Bug#36167)

Replace manually crafted hex regexes with [:xdigit:]
dfc322d77fd1ce3aa4d852e0ff07bb36944f6432
Konstantin Kharlamov
Sat Jul 6 10:54:25 2019 +0300
2019-07-14 11:12:12 -04:00
Carsten Dominik aaca138324 Apply the proper way to describe a key in the guide 2019-07-14 14:05:44 +02:00
Carsten Dominik e571ca8e9d Document structure template insertion in the compact guide 2019-07-14 14:02:12 +02:00
Marco Wahl 63b9c2634e Merge branch 'master' into compact-folding-refinement 2019-07-13 23:21:12 +02:00
Marco Wahl a1499af673 ORG-NEWS: Announce changes in org-ctrl-c-tab, org-kill-note-or-show-branches 2019-07-13 23:19:33 +02:00
Marco Wahl d2a5a6e4d0 Make feature "show children" applicable to whole file
* lisp/org.el (org-ctrl-c-tab): Make function applicable to a whole
  file.  Further flag (aka hide) all content in the subtrees.
2019-07-13 22:30:02 +02:00
Marco Wahl fd63eee797 Make feature "show branches" applicable to whole file
* lisp/org.el (org-kill-note-or-show-branches): Extend and refactor.
2019-07-13 22:29:29 +02:00
Nicolas Goaziou 2c8e8b4a18 contrib: Remove Org Drill
* contrib/README:
* lisp/org.el (org-modules): Remove reference to Org Drill.
contrib/lisp/org-drill.el: Remove file.

Org Drill is now developed externally, and available through an
ELPA (MELPA at this point).
2019-07-11 22:55:02 +02:00
Marco Wahl ee4fcc2aaa Add function to show just every headline in buffer
* lisp/org.el (org-show-branches-buffer): New function.
2019-07-11 12:12:37 +02:00
Marco Wahl add2614cf9 Add function to flag region above first heading
* lisp/org.el (org-flag-above-first-heading): New function.
2019-07-11 12:08:47 +02:00
Marco Wahl 4e6222f188 contrib/org-attach-embedded-images: switch to attachment type links 2019-07-09 19:52:19 +02:00
Nicolas Goaziou 1ff9cab0a3 Merge branch 'maint' 2019-07-09 12:43:29 +02:00
Nicolas Goaziou 63e851ddbd ox: Add test
* testing/lisp/test-ox.el (test-org-export/uninterpreted): Add test.
2019-07-09 12:42:49 +02:00
Nicolas Goaziou 9bde6350d1 ox: Add post-blanks when latex is verbatim
* lisp/ox.el (org-export--remove-uninterpreted-data): Add post-blanks
  when latex is verbatim.
2019-07-09 12:42:46 +02:00
Marcin Borkowski c2ef61ffcf Explain the `org-agenda-todo-ignore-...` variables in the manual 2019-07-09 12:19:25 +02:00
Nicolas Goaziou 24daf224c0 Fix test
* testing/lisp/test-org-table.el (test-org-table/copy-down): Fix test.
2019-07-09 12:03:32 +02:00
Nicolas Goaziou fae13929f4 Merge branch 'maint' 2019-07-09 11:57:21 +02:00
Nicolas Goaziou d73f65b57a org-list: Fix wrong list indentation
* lisp/org-list.el (org-list-struct-indent): Small refactoring.
(org-list-indent-item-generic): Copy old structure so
`org-list-write-struct' can notice bullet change.

Reported-by: Gustavo Barros <gusbrs.2016@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-07/msg00033.html>
2019-07-09 11:56:47 +02:00
Gustav Wikström ae9cd4370b org-attach*, org, org-manual, org-news, ox-html, testing/*
* lisp/org-attach.el

Changed the way attachments deal with property-inheritance.  It now
adheres to the =org-use-property-inheritance= setting by default but
it can be customized if needed (I recommend to enable it!).
The property ATTACH_DIR is deprecated in favour of the shorter and simpler
property DIR.

Added an explicit option to =org-attach= for unsetting
attachment-directories (i.e. remove DIR property and deal with the
attachments by interaction).

Added attachment link type with the prefix "attachment:".

Added customizations:
- org-attach-dir-relative
- org-attach-preferred-new-method
- org-attach-use-inheritance
- org-attach-id-to-path-function

Hooks added:
- org-attach-after-change-hook
- org-attach-open-hook

A new linktype "attachment" is added in order to reduce
link-duplication when wanting to link to files in attached folders of
nodes.  This works for both ID and DIR properties.  The goal is to
make the functionality for attachment links mirror the functionality
for file links.

* lisp/org-attach-git.el

New file, existing functionality.  Code here has been factored out
from org-attach.el and if GIT-functionality is to be used this module
needs to be required sepatately.  It extends org-attach by use of its
hooks.

Activating git functionality in org-attach is done by loading
org-attach-git from now on, instead of customizing a variable.

Naming of both functions and tests has been modified to match the move
of functionality into its own module.

* lisp/org.el

Inline images are shown also using attachment-links, exactly the same
as it works for file-links today.

Make org-open-at-point respect ARG when opening attachment-dir.

* lisp/org-compat.el

org-attach-directory has been deprecated in favour for
org-attach-id-dir.  The new name matches its purpose better.

* lisp/ox-html.el

Export attachment links to images as inline images, in the same way as
file links work today.

* etc/ORG-NEWS

Mention the changes in this patch.

* doc/org-manual.org

The chapter "Refile, Copy, Archive" has been split into two separate
chapters.
- "Refile, Copy and Archiving" for information related to moving
  existing data around.

- "Capture, Attachments, RSS Feeds and Protocols" for information
  related to working with external data.

The attachment-part has been rewritten and extended to match the
changes in this patch.

The new attachment link type is mentioned both inside the attachments
chapter and in the chapter dealing with links.

Documentation related to external links has been improved.

* testing/lisp/test-org-attach-annex.el

Require org-attach-git instead of org-attach, since this file tests
the GIT-functionality.

* testing/lisp/test-org-attach.el

Add tests for org-attach.

* testing/org-test.el

Define a symbol for a file to test attachments with.

* testing/examples/*

A bunch of new example files and folders are created and are used in
testing of org-attach to verify its functionality.
2019-07-07 19:55:49 +02:00
Gustav Wikström 3cbe356b0a org-test, test-org-element, test-org, test-ox, test-property-inheritance
* org-test.el:

Fix org-test-with-temp-text-in-file.  Make it work with <point>, as
some tests already expect it to do!  Also make it fail more gracefully
by still removing temporary buffers and files.

Improve org-test-in-example-file.  Make it behave similar to
org-test-with-temp-text and org-test-with-temp-text-in-file, in that
it will return the last evaluated expression.

* testing/lisp/test-org-element.el

Fix a temp-text strings so that it doesn't have an initial newline.

* testing/lisp/test-org.el

Minor cleanup to align code-structure with other tests.  Nothing
changes in the test execpt style.

* testing/lisp/test-ox.el

Fix a couple of temp-text strings so that they don't have initial
newlines.

** test-org-export/expand-include

Test specification was wrong, due to org-test-with-temp-text-in-file
not previously working with <point>.  Since that is fixed in this
patch the test needed to be updated to match the expected outcome.

* testing/lisp/test-property-inheritance.el

Fix wrong file-header and file-ending.
2019-07-07 19:42:50 +02:00
Nicolas Goaziou 0201d1c0cc Fix inserting capture templates at point
* lisp/org-capture.el (org-capture):
(org-capture-set-target-location):
(org-capture-place-entry):
(org-capture-place-item):
(org-capture-place-table-line): Fix inserting capture templates at
point.  Insert a new internal property for capture
template: :insert-here.
(org-capture-insert-template-here): Remove function.

* testing/lisp/test-org-capture.el (test-org-caputre/entry):
(test-org-capture/item):
(test-org-capture/table-line): Add tests.

Reported-by: Dominic Surano <sk8ingdom@gmail.com>
<http://lists.gnu.org/r/emacs-orgmode/2019-07/msg00002.html>
2019-07-06 16:02:37 +02:00
Nicolas Goaziou 1b3c7c28cf Merge branch 'maint' 2019-07-06 10:25:18 +02:00
Nicolas Goaziou acf4f0881a org-agenda: Fix "Args out of range" error in `org-agenda-list'
* lisp/org-agenda.el (org-agenda-list): Do not add text properties on
empty headers.
2019-07-06 10:24:11 +02:00
Nicolas Goaziou b855acc878 Merge branch 'maint' 2019-06-28 17:50:53 +02:00
Nicolas Goaziou 7bc6f8d619 org-table: Prevent formula evaluation from widening all tables
* lisp/org-table.el (org-table-recalculate): When a formula is
  evaluated, do not expand shrunk columns across the whole buffer.
2019-06-28 17:49:25 +02:00
Nicolas Goaziou 9ddfe45314 org-table: Improve `org-table-copy-down'
* lisp/org-table.el (org-table--increment-field): New function.
(org-table-copy-down): Use new function.
* testing/lisp/test-org-table.el (test-org-table/copy-down): New test.
* doc/org-manual.org (Calculations): Update documentation.
2019-06-28 00:07:25 +02:00
Nicolas Goaziou 7e4847a554 Merge branch 'maint' 2019-06-28 00:06:58 +02:00
Nicolas Goaziou 0553f2e31c org-table: Fix `org-table-next-row' at eob
* lisp/org-table.el (org-table-next-row): Fix misbehaviour when called
  on the last row, at the end of the buffer, without a final newline.
2019-06-28 00:05:44 +02:00
Nicolas Goaziou 2263634823 org-manual: Fix typo
* doc/org-manual.org (From Carsten): Fix typo.
2019-06-22 09:33:33 +02:00
Kyle Meyer 8e7280896f org-attach: Bind org-attach-method for org-attach-url
* lisp/org-attach.el (org-attach-url): Let-bind org-attach-method to
`url` so that org-attach-attach calls the correct method.

Before 72124726a (org-attach: Make dispatcher commands customizable,
2019-04-26), the dispatcher masked this issue by let-binding
org-attach-method around its call to org-attach-url.

Reported-by: stardiviner <numbchild@gmail.com>
<https://lists.gnu.org/archive/html/emacs-orgmode/2019-06/msg00130.html>
2019-06-21 18:15:52 -04:00
Aaron L. Zeng 1b74ae0ba3 org-clock: Clear org-clock-current-task on clock cancel
* org-mode/lisp/org-clock.el (org-clock-cancel): Clear
`org-clock-current-task' when a clock is canceled.

This variable is used by some mode line packages (e.g.,
spaceline-all-the-icons), so not clearing the variable incorrectly
displays the previous task as ongoing.
2019-06-15 11:53:42 +02:00
Nicolas Goaziou 439782ae00 Merge branch 'maint' 2019-06-12 18:22:50 +02:00
Thomas Plass 0d7d12ffe6 ox: Make `org-export-table-cell-alignment' more robust
* lisp/ox.el (org-export-table-cell-alignment): Make
`org-export-table-cell-alignment' handle tables with rows containing
unequal numbers of cells.

Patch modeled after previous fix for `org-export-table-cell-width'.

TINYCHANGE
2019-06-12 18:22:00 +02:00
Neil Jerram 85711ba3d9 Make capture's idea of the current day more intuitive 2019-06-10 11:20:20 +02:00
Nicolas Goaziou c30fe929cd Merge branch 'master' of code.orgmode.org:bzg/org-mode 2019-06-10 11:17:31 +02:00
Nicolas Goaziou 3ecf1fb7b9 ox: Silence byte-compiler
* lisp/ox.el (org-export-resolve-link): Use `org-link-make-string'
  instead of `org-make-link-string'.
2019-06-10 09:43:37 +02:00
Kyle Meyer 81920b3f86 Merge branch 'maint' 2019-06-09 21:39:18 -04:00
Paul Eggert 65a6f54605 Backport commit 852d28176 from Emacs
Update author/maintainer info
852d28176990d035366142bfde36a0440a317228
Paul Eggert
Sun May 26 01:00:16 2019 -0700
2019-06-09 21:35:45 -04:00
Paul Eggert 55e19d973e Backport commit 797ee5871 from Emacs
The convention is that a file with Author: but not Maintainer:
means the author is a maintainer, which makes it confusing
when a file lists the same person as author and maintainer.
Avoid the confusion by removing the duplicate Maintainer: line.

Remove Maintainer: when it duplicates Author:
797ee5871e458d6d97f57a24405412a053f5ef32
Paul Eggert
Sun May 26 01:00:15 2019 -0700
2019-06-09 21:28:44 -04:00
Paul Eggert 43bdc85b9d Backport commit 542443645 from Emacs
* lisp/org-id.el (org-id-link-to-org-use-id):
* lisp/org.el (org-support-shift-select, org-file-apps):
Remove backslash-newline that immediately precedes another
newline, as this is not the usual style and is confusing.

Avoid backslash-newline-newline in source code
5424436452bc0b3d8a62a8398f92d0c2db81e22b
Paul Eggert
Wed May 22 23:59:36 2019 -0700
2019-06-09 21:26:08 -04:00
Paul Eggert 96f439226e Backport commit bef1be873 from Emacs
Fixes for "Maintainer:" and related lines
bef1be873009d6e9f5a097396179f63a565bb6fd
Paul Eggert
Sun May 19 21:34:27 2019 -0700
2019-06-09 21:25:24 -04:00
Nicolas Goaziou 0ff65e9f4c org-list: Change `org-list-to-subtree' signature
* lisp/org-list.el (org-list-to-subtree): Add optional argument to
  specify level of the subtree.
(org-list-make-subtree):
* lisp/org.el (org-toggle-heading): Adapt to signature change.

Reported-by: Felix Wiemuth <felixwiemuth@hotmail.de>
<http://lists.gnu.org/r/emacs-orgmode/2019-06/msg00010.html>
2019-06-10 00:19:32 +02:00
Nicolas Goaziou bba9116cb8 org-element: Parse affiliated keywords according to granularity
* lisp/org-element.el (org-element--current-element): Parse affiliated
  keywords according to granularity.
* lisp/ox.el (org-export-get-caption): Refactor code.
* testing/lisp/test-org-element.el (test-org-element/affiliated-keywords-parser):
  Add tests.

Reported-by: ihor <ihor@antonovs.family>
<http://lists.gnu.org/r/emacs-orgmode/2019-06/msg00023.html>
2019-06-09 00:51:53 +02:00
Gregor Zattler f4083eefd8 manual: Fix URL
* doc/org-manual.org (External Links): Fix URL
2019-06-07 23:34:46 +02:00
Nik Clayton 380e2f7f82 ox-html: Include the line number as a data attribute
* lisp/ox-html.el (org-html-do-format-code): If line numbers are enabled
then include a data-ox-html-linenr attribute that contains this line's
line number.

This allows you to have more control over line number formatting and
placement. For example, the following CSS hides the span that contains
the line number, and uses a CSS :before property to position and format
the line number with a border instead of a semi-colon separating content
and line number.

span.linenr { display: none; }

code[data-ox-html-linenr]:before {
  content: attr(data-ox-html-linenr);
  display: inline-block;
  border-right: 1px solid;
  width: 1rem;
  text-align: right;
}

TINYCHANGE
2019-06-07 23:32:11 +02:00