* lisp/org.el (org-show-context-detail): New variable.
(org-context-choice, org-show-following-heading, org-show-siblings,
org-show-entry-below, org-show-hierarchy-above): Remove variables.
(org-show-set-visibility): New function.
(org-convert-to-oddeven-levels, org-get-location, org-show-context,
org-reveal): Use new function.
(org-link-search): Update docstring.
* lisp/org-agenda.el (org-agenda-cycle-show): Use new function.
(org-agenda-show): Replace missing variable.
* testing/lisp/test-org.el (test-org/show-set-visibility): New test.
* doc/org.texi (Sparse trees):
* doc/orgguide.texi (Sparse trees): Document changes.
* etc/ORG-NEWS: Signal changes.
Configuration of `org-show-context' is done with a single variable
offering six different views, instead of four variables for a total
of 16 configurations.
* lisp/org.el (org-time-stamp): Correctly match repeater, if any.
Refactor code.
* testing/lisp/test-org.el (test-org/time-stamp): New test.
Reported-by: Nicolas Richard <theonewiththeevillook@yahoo.fr>
<http://permalink.gmane.org/gmane.emacs.orgmode/94974>
* lisp/org.el (org-closed-string, org-deadline-string,
org-scheduled-string): Use a defvar.
DEADLINE, SCHEDULED and CLOSED are now meant to be constants. However,
we preserve backward-compatibility during obsolencence phase.
* lisp/org.el (org-scan-tags): Fix agenda org tags scans to properly
add timestamp property, completely analogously to
org-agenda-get-todos.
* lisp/org-agenda.el (org-agenda-entry-get-agenda-timestamp,
org-agenda-get-todos): Factored timestamp retrieval code out to
separate function org-agenda-entry-get-agenda-timestamp from
org-agenda-get-todos.
Before this fix, timestamps were ignored when sorting agenda views of
the 'tags' and 'tags-todo' types.
TINYCHANGE
* lisp/org-agenda.el (org-agenda-insert-diary-as-top-level):
* lisp/org.el (org-link-search): Call `org-insert-heading' instead
of (insert "* ").
This allows, in particular, to run `org-insert-heading-hook' and
possibly fix up blank lines around.
* lisp/org.el (org-link-search): Change headline search such that it
always does an exact search, ignoring spaces.
* testing/lisp/test-org.el (test-org/fuzzy-links): Test exact headline
match with spaces and cookies.
* doc/org.texi (External links): Cleanup footnote about the
`org-link-search-must-match-exact-headline' option for text searches
and add a footnote about the effect of the same option for heading
searches.
* doc/ORG-NEWS: Document changes.
* lisp/org.el (org-toggle-heading): Avoid adding spurious stars when
changing a plain list into a subtree.
Reported-by: Rainer Stengele <rainer.stengele@online.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/94223>
(org-babel-load-file): When org-mode FILE has multiple target files
for tangle blocks, `exported-file' will be set to last found
target file, which might not be the `file'.
Therefore fix for this bug is to select the last element of that
tangled file list, which is the tangle target file of the first found
tangle block, most typically the `file'.
TINYCHANGE
* lisp/org.el (org-special-properties): Add missing "CATEGORY".
* doc/org.texi (Special properties): Remove "NOBLOCKING" as a special
property, since it can only be set through a properties drawer.
This is a reserved property.
Reported-by: Samuel Loury <konubinix@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/94483>
* lisp/org.el (org--get-display-dpi): New function.
(org-create-formula-image-with-dvipng):
(org-create-formula-image-with-imagemagick): Use it.
The previous method tried to calculate the display dpi from the font
height, but this is wonky and not necessary, since it can be
calculated directly.
* lisp/org.el (org-toggle-inline-images): Only message if
called-interactively-p.
The old code made a halfhearted attempt to do this; this patch
provides the other half of the heart.
* lisp/org-clock.el: Replace occurances of
'calendar-absolute-from-iso' with 'calendar-iso-to-absolute'.
* lisp/org-agenda.el: Same as above.
* lisp/org.el: Same as above.
Some (long marked obsolete) calendar entities have been dropped from
Emacs recently. One of those is 'calendar-absolute-from-iso'.
* lisp/org.el (org-read-date-analyze): When
`org-read-date-prefer-future', offer a date in the future even if
default date is different from now.
* testing/lisp/test-org.el (test-org/org-read-date): Add tests.
Reported-by: Rasmus <rasmus@gmx.us>
<http://permalink.gmane.org/gmane.emacs.orgmode/93805>
* lisp/org.el (org-check-before-date, org-check-after-date,
org-check-dates-range): Make sure we're really at a timestamp before
validating the entry.
Reported-by: James Harkins <jamshark70@qq.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/93126>
* lisp/org.el (org-sparse-tree-default-date-type): Use new default
value instead of the undocumented previous one. Fix docstring, too.
(org-sparse-tree): Apply change to previous variable.
(org-re-timestamp): Apply change to previous variable. Refactor code.
* lisp/org.el (org-do-sort): Remove function.
* lisp/org-table.el (org-table--do-sort): New function.
(org-table-sort-lines): Use new function.
`org-do-sort' is really a helper function for `org-table-sort-lines',
which applies exclusively on tables.
* lisp/org.el (org-do-sort): Properly reverse results when ?F and
a compare function is provided. Small refactoring.
* testing/lisp/test-org-table.el (test-org-table/sort-lines): New
test.
* lisp/org.el (org-do-sort): Implement the ?f and ?F sorting options
to allow user-defined table sorting. Update the DOC string.
* lisp/org-table (org-table-sort-lines): Add the GETKEY-FUNC and
COMPARE-FUNC optional parameters and pass them to the call to
`org-do-sort'. Update the DOC string.
* doc/org.texi (org-table-sort-lines): Update documentation to reflect
the addition of the ?f and ?F options.
This patch implements user-defined extraction and comparison functions
for table sorting. Thanks to Nicolas Goaziou for helpful suggestions.
This patch was discussed on the Org Mode mailing list:
http://article.gmane.org/gmane.emacs.orgmode/93334
* lisp/org.el (org-hide-archived-subtrees): Prevent an error when END
argument doesn't match the end of a subtree. Prevent false
positives. Also, archive tag is case-sensitive.