* lisp/org.el (org-occur-next-match): New function.
(org-mode): Set the variable `next-error-function'.
(org-highlight-new-match): Add an `org-type' property to the overlays.
* doc/org.texi (Sparse trees): Document the next-error / previous-error
functionality.
After a sparse tree construction, `M-g n' and `M-g p' will now jump to
the location of matches.
* Makefile (LISPF): Add org-special-blocks to the list of Lisp files
* lisp/org-special-blocks.el (htmlp):
(latexp):
(line): Add defvars for dynamically scoped variables.
* lisp/org.el (org-modules): Move org-special-blocks into
the core modules section.
* lisp/org.el (org-get-category): New optional argument FORCE-REFRESH.
Automatically refresh if the property is not there.
(org-entry-properties): Remove refresh - this is now done in
org-get-category.
* lisp/org-clock.el (org-clock-insert-selection-line): Let `org-get-category'
do the property refresh.
* lisp/org-archive.el (org-archive-subtree): Force a refresh of
category properties.
Based on a patch by Julien Danjou.
* org-icalendar.el (org-print-icalendar-entries): Do not manually
refresh categories.
* org-clock.el (org-clock-insert-selection-line): Do not manually
refresh categories.
* org.el (org-get-category): Refresh categories if no category found.
(org-entry-properties): Do not manually refresh categories.
(org-prepare-agenda-buffers): Do not manually refresh categories.
It seems a very bad thing to call manually for a category refresh. It
seems better to try to refresh if we do not have a category.
Signed-off-by: Julien Danjou <julien@danjou.info>
* lisp/org.el (org-before-first-heading-p): If point is on an org-mode heading line then we are not before the first heading
If point is anywhere on the first line of the first heading then we
are not before the first heading. This makes
org-before-first-heading-p returns t instead of nil when on the '*' or
blank of the first level 1 heading in an org file.
This was noticed when the first heading has an encryption
tag :crypt:. C-c C-r would not decrypt this entry if point is at the
beginning of the line since it was considered before the first
heading.
* org-capture.el (org-capture-fill-template): Use `org-set-property'
directly.
* org.el (org-set-property): Split property and values reading.
(org-read-property-name, org-read-property-value)
(org-set-property-function): New functions.
(org-property-set-functions-alist): New variable.
The goal of this patch is to introduce a special variable
`org-property-set-functions-alist'. This variable allows to read
properties values in a more intelligent way from `org-set-property' or
from `org-capture'.
For that, it simplifies the `org-set-property' code and remove
duplication between `org-capture' and `org-set-property'.
Signed-off-by: Julien Danjou <julien@danjou.info>
* lisp/org.el (org-make-target-link-regexp): regexp-quote target
before replacing whitespace.
Previously a radio link <<<...>>> would match all three-letter words
in the buffer. The manual indicates the radio links are meant to
match literally (modulo whitespace differences), so we should
regexp-quote all the targets to avoid over-eager matching.
* lisp/org.el: (org-entry-properties) Stop scanning for timestamps if
a specific timestamp property (e.g., DEADLINE, SCHEDULED, etc.) is
requested and a match is found. Also, if a specific timestamp property
is requested, do not push non-relevant timestamps onto property list.
This change only effects org-entry-properties when a specific
timestamp is requested with the special flag, as in:
(org-entry-properties nil 'special "SCHEDULED")
Previously, even if only the SCHEDULED timestamp was requested,
org-entry-properties would parse all the timestamps in an entry. This
extra parsing could slow down the construction of agenda views,
especially with entries that contained a large number of log
items (CLOCK, state changes, etc.). The function org-entry-get,
however, is only interested in the first occurrence of the item. When
looking for a specific type of timestamp, org-entry-properties now
stops searching for timestamps after the match is found, unless the
property is "CLOCK".
Here are the relevant ELP results:
Before:
org-entry-get 296 0.4724579999 0.0015961418
org-entry-properties 31 0.3438769999 0.0110928064
After:
org-entry-get 296 0.1447729999 0.0004890979
org-entry-properties 31 0.015765 0.0005085483
* org-inlinetask.el (org-inlinetask-outline-regexp): new function
* org-inlinetask.el (org-inlinetask-goto-beginning): new function
* org-inlinetask.el (org-inlinetask-goto-end): new function
* org.el (org-mark-subtree): new command
* org.el (org-speed-commands-default, org-mode-map): make use of new command
This reverts commit 383802d063.
The commit had org-mode process the headlines from bottom to top, which
meant that any changes to the visibility of lower headlines were
overridden/modified by changes higher up the tree. Reverting the commit
causes VISIBILITY to work correctly.
* lisp/org.el: (org-make-heading-search-string) Optionally limit
number of lines stored in file link search strings.
(org-context-in-file-links) Add option to set to integer specifying
number of lines.
* lisp/ob.el (org-babel-insert-result): Responds to new "wrap" header
argument.
(org-babel-merge-params): Includes new "wrap" header argument in
one of the results header argument exclusive groups.
* lisp/org.el (org-additional-option-like-keywords): Fontify begin and
and results lines as comments.
* lisp/org.el (org-open-at-point): Don't do footnote action if cursor is
on a bracket link.
Sebastian Mengin writes:
> Hi,
>
> Consider the following minimal example:
>
> Text[fn:1]
>
> * Footnotes
> [fn:1] Note with a [[file:abecedaire.jpg][link]].
>
> Here with orgmode 7.02, doing C-c C-o on the link moves the cursor on
> [fn:1] and says in the minibuffer: "Position saved mark to ring, go back
> with C-c &", instead of opening the linked file.
>
> Is this a bug?
>
* lisp/org.el (org-indent-line-function): drawers and blocks have no
influence on indentation of text below. Also fix indentation problem
with a block at column 0 and add a special case for literal examples.