* lisp/org-agenda.el (org-agenda-dim-blocked-tasks): Do not check if an
entry can be blocked when it doesn't have any TODO keyword.
* lisp/org.el (org-entry-blocked-p): Make sure entry is really an open
task before even considering it as a blocked task. Small refactoring.
* testing/lisp/test-org.el (test-org/entry-properties): Update tests.
(test-org/entry-blocked-p): New test.
Reported-by: Bingo UV <right.ho@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/99544>
* lisp/org.el (org-get-priority-face): New function.
(org-font-lock-add-priority-faces): Use new function.
* lisp/org-colview.el (org-columns-new-overlay): Preserve face from
string to display.
(org-columns-display-here): Apply usual face on TODO keywords, tags and
priorities in the columns overlay.
* lisp/org-element.el (org-element-link-parser): Correctly parse links
with newline characters.
* lisp/org.el (org-make-link-regexps): Allow newline characters within
angle links.
(org-activate-angle-links): Support multiline angle links.
* testing/lisp/test-org-element.el (test-org-element/link-parser):
Update tests.
As a rule of thumb, any newline character and all surrounding
whitespaces are treated as a single space in a bracket link. They are
removed in angle links.
* lisp/org.el (org-open-at-point): Do not call twice `org-link-search'
when destination is not accessible within the current narrowed part of
the buffer.
* lisp/org.el (org-link-search): Remove TYPE argument, used to force
`org-occur' or `org-do-occur' on fuzzy search. Instead, enclose string
within forward slashes.
* lisp/org-macro.el (org-macro-initialize-templates):
* lisp/ob-exp.el (org-link-search): Apply signature change.
* lisp/org.el (org-open-at-point): Find radio targets again.
(org-search-radio-target): New function.
* testing/lisp/test-org.el (test-org/open-at-point/radio-target): New
test.
* lisp/org.el (org-set-tags): Use let* for c0 p0 c1 rpl di tc;
Restructure so that no check on c0 is needed; Don't return a useless
tags var from cond; Change and into an equivalent when.
* lisp/org-compat.el (org-number-sequence):
* lisp/org.el (org-remove-highlights-with-change)
(org-structure-template-alist):
* lisp/ox-html.el (org-html-link-org-files-as-html):
Fix minor quoting problems in doc strings, e.g., missing quote,
``x'' where `x' was meant, etc.
Fix minor quoting problems in doc strings
9d35bb8d6518bb913ab08bace2af08963c003177
Paul Eggert
Tue May 19 15:01:16 2015 -0700
* lisp/org-compat.el (org-font-lock-ensure): Remove in favor of
font-lock-ensure alias from dcbaebc.
Instead of org-font-lock-ensure alias introduced in dcbaebc ("Backport
commit 6711a21 from Emacs master branch", 2014-05-28), use
font-lock-ensure alias added in e6883dd ("org-compat: Provide
compatibility definition for font-lock-ensure", 2014-06-01).
* lisp/org-compat.el (org-font-lock-ensure): New function.
* lisp/ox-odt.el (org-odt-do-format-code):
* lisp/ox-html.el (org-html-fontify-code):
* lisp/org.el (org-fontify-like-in-org-mode):
* lisp/org-src.el (org-src-font-lock-fontify-block):
* lisp/org-clock.el (org-clock-get-clocktable): Use it.
* lisp/ox-org.el (org-org-publish-to-org):
Use it. Avoid using find-file from Elisp.
6711a21f1125c0047c56eb266eb374c1ec90a967
Stefan Monnier
Wed May 28 23:45:29 2014 -0400
* lisp/org.el (org-read-date-analyze):
* lisp/org-timer.el (org-timer-seconds): Explicitly pass current-time as
optional time argument and explain reason in comment.
This reverts some changes from 91ab6c4 ("Backport commit 123ddec from
Emacs master branch", 2014-10-28).
* doc/org.texi (Dynamic blocks):
* lisp/org-archive.el (org-archive-subtree)
(org-archive-to-archive-sibling):
* lisp/org-clock.el (org-resolve-clocks, org-clock-get-sum-start)
(org-clock-special-range):
* lisp/org-timer.el (org-timer-seconds):
* lisp/org.el (org-read-date-analyze, org-get-cursor-date):
* lisp/ox-html.el (org-html-format-spec):
* lisp/ox-icalendar.el (org-icalendar--vtodo):
Omit unnecessary call to current-time.
* lisp/org.el (org-get-cursor-date):
Don't call current-time twice to get the current time stamp,
as this can lead to inconsistent results.
* lisp/org-compat.el (org-float-time):
Simplify to an alias because time-to-seconds now behaves like float-time
with respect to nil arg.
* lisp/org-clock.el (org-clock-get-table-data): Omit unnecessary, lossy
conversion from floating point to Emacs time and back.
(org-resolve-clocks): Prefer two-argument floor.
Simplify use of current-time and friends.
123ddec7f807f4bd7400bbbe08219afb02269c00
Paul Eggert
Tue Oct 28 18:42:51 2014 -0700
* lisp/org.el (org-beginning-of-line): Prevent an error when buffer
contains only a single star.
* testing/lisp/test-org.el (test-org/beginning-of-line): Add tests.
* lisp/org.el (org-goto-local-search-headings): Do not rely on
`org-context' just to check if point is on a headline but not on its
tags.
Reported-by: Gregor Zattler <telegraph@gmx.net> <w>
<http://permalink.gmane.org/gmane.emacs.orgmode/99111>
* lisp/org.el (org-time-string-to-absolute): Don't pass a canceled
repeater to org-closest-date.
(org-closest-date): Raise an error when passed a canceled repeater.
Prevent arith-error from occurring when a canceled repeater is passed to
org-closest-date.
* lisp/org.el (org-property--local-values): New function.
(org-entry-get): Use new function. Ignore global values when there is
no inheritance.
(org-entry-get-with-inheritance): Fix extended values, which do not
stop anymore inheritance search.
* testing/lisp/test-org.el (test-org/entry-get): Add tests.
* lisp/org.el (org-log-note-headings): Improve docstring.
(org-store-log-note): When re-scheduling or re-deadlining, convert old
or new timestamp to an inactive one so as to not clutter the agenda.
Reported-by: Karl Voit <devnull@Karl-Voit.at>
<http://permalink.gmane.org/gmane.emacs.orgmode/93498>
* lisp/org.el (org-add-planning-info): Reset point before each
planning entry search. Clean up extra spaces.
* testing/lisp/test-org.el (test-org/add-planning-info): Add tests.
- Reposition save-excursion call to reset point every dolist
iteration. Otherwise, the order of the entries to be removed
matters, and a call like
(org-add-planning-info nil nil 'scheduled 'deadline)
on
DEADLINE: <2015-06-26 Fri> SCHEDULED: <2015-06-26 Fri>
will fail to remove the deadline entry.
- Delete leading white space even when at the beginning of the line so
that, when org-adapt-indentation is nil, a space is not inserted
when removing the leading planning info entry.
This prevents headings with repeating entries like
SCHEDULED: <2015-06-26 Fri +1w>
from being closed and recycled with an extra space in front of
SCHEDULED.
- Add leading white space to the planning info entry regexp to prevent
leftover white space when removing entries other than the first
entry.
* lisp/org.el (org-clone-subtree-with-time-shift): Allow argument
specifying number of clones to be 0.
* testing/lisp/test-org.el (test-org/clone-with-time-shift): Add
tests.
This makes it possible to clone a subtree with a repeating timestamp
so that the repeater is removed from the original subtree and a single
shifted, repeating clone is created. If the original subtree does not
have a repeating timestamp, no clones will be made.
* lisp/org.el (org-icompleting-read): Let `completing-read' or
equivalent sort out type of completion.
(org-olpath-completing-read): Revert partially
1a73641770.
* lisp/org.el (org-store-log-note): Ensure insertion point is
available in the narrowed part of the current buffer.
Reported-by: Mark Edgington <edgimar@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/98152>
* lisp/org.el (org-store-link): When creating a link from an edit
buffer, re-use label on current line, if any. Give up if call is
non-interactive, as it would otherwise ask for user's input.
Reported-by: Samuel Wales <samologist@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/97902>
* lisp/org.el (org-not-done-heading-regexp): Fix a typo and make
variable buffer-local, as expected.
Reported-by: Alexander Borkowski <alex-b@opus-b.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/97996>
* org.el (org-latex-default-packages-alist): Add grffile for files
with spaces and periods.
Reported-by: Vaidheeswaran C <vaidheeswaran.chinnaraju@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/97846>
* lisp/org.el (org-cycle-show-empty-lines): Fix visibility cycling
with `org-cycle-separator-lines' set to -1.
Reported-by: Michael Crouch <creidieki@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/97879>
* org.el (org-return): RET breaks headline text.
* test-org.el (test-org/return): Test org-return on headline text.
* ORG-NEWS: Add entry on new org-return behavior.
* org-element.el (org-element-latex-fragment-parser):
* org.el (org-latex-regexps): Fix the detection of latex
fragments. Uses syntax tables to detect whitespaces and punctuation
marks following the final $ sign.
In order to qualify as a math delimiter, the final $ sign of a LaTeX
fragment has to be followed by a whitespace or punctuation mark but the
regexp used in the previous code matched only a small number of
punctuation marks and therefore missed some latex fragments.
* lisp/org-capture.el (org-capture-expand-file): Empyt string defaults
to `org-default-notes-file'.
* lisp/org.el (org-default-notes-file): Do not fallback on
`remember-data-file' since "org-capture.el" is not based off
"remember.el" anymore.
Reported-by: Florian Lindner <mailinglists@xgm.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/97448>
* lisp/org-table.el (org-table-TBLFM-begin-regexp): Take into
consideration that table lines are not required to end with "|".
(org-table-calc-current-TBLFM): Properly clean markers at the end of
the process.
(org-table-TBLFM-begin): Small refactoring.
* lisp/org.el (org-at-TBLFM-p): Prevent false positives.
Suggested-by: Oleg Sivokon <olegsivokon@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/97461>
* lisp/org.el (org-open-at-point): Make sure org shell output buffer
is a string of buffer name before appending to
`clean-buffer-list-kill-buffer-names' for cleaning later.
TINYCHANGE
* lisp/org.el (org-refresh-category-properties): Prevent the `put-text-property'
to change the point in order to take into account the CATEGORY
property in subtrees also.
* testing/lisp/test-org.el (test-org/entry-properties): Add test.
* lisp/org-src.el (org-src--element-contents-area): Make a special
case for footnote definitions.
(org-edit-footnote-reference): New function.
* lisp/org.el (org-edit-special): Use new function.
* lisp/org.el: (org-cycle): Ignore invisible newlines and cycle
visibility when point is visibly on a headline.
Requested by: Nikolaus Rath <Nikolaus@rath.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/97125>
* lisp/ox.el (org-export-registered-backends): Renamed from
`org-export--registered-backends'.
(org-export-get-backend):
(org-export-register-backend):
(org-export-insert-default-template):
(org-export--dispatch-ui):
* lisp/org.el (org-export-registered-backends):
(org-export-backends):
(org-get-export-keywords):
* lisp/org-pcomplete.el (pcomplete/org-mode/file-option/options):
* testing/lisp/test-ox.el (test-org-export/define-backend):
(test-org-export/define-derived-backend):
(test-org-export/derived-backend-p):
(test-org-export/get-all-transcoders):
(test-org-export/get-all-options):
(test-org-export/get-all-filters):
(test-org-export/with-backend): Apply renaming.
Since the variable is copiously used outside of "ox.el", there's no
reason to mark it as internal.
* lisp/ob-shell.el (org-babel-sh-evaluate):
* lisp/org-clock.el (org-x11idle-exists-p): Do not use last
`call-process-shell-command' arg.
* lisp/org-mouse.el (org-mouse-show-context-menu): Ignore
`redisplay-dont-pause'.
* lisp/org.el (org-icompleting-read): Fix typo. Small refactoring.
* lisp/org.el (org--get-expected-indentation): Diary sexps are to be
indented at column 0.
* testing/lisp/test-org.el (test-org/indent-line): Add test.
* lisp/org.el (org-refresh-category-properties): Extract default
category before entering `with-silent-modifications', as
`buffer-file-name' is then bound to nil.
Reported-by: John Hendy <jw.hendy@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/96620>
* lisp/org.el (org-find-property): Small optimization.
Since VALUE is included in the regexp, it doesn't need to be found
again with `org-entry-get'. However, we still need to make sure match
really is a node property.
* lisp/org.el (org-refresh-category-properties): Ignore false
positives when setting category. Also, deprecate old CATEGORY
keyword behaviour: new keywords override old ones.
* lisp/org.el (org-refresh-property): Ignore function when before
first headline or inlinetask. Small refactoring.
Reported-by: Nick Dokos <ndokos@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/96552>
* lisp/org.el (org-backward-sentence):
(org-forward-sentence): Properly move at the boundaries of an element.
* testing/lisp/test-org.el (test-org/forward-sentence):
(test-org/backward-sentence): New tests.
Reported-by: Rasmus <rasmus@gmx.us>
<http://permalink.gmane.org/gmane.emacs.orgmode/96377>
* lisp/org-element.el (org-element--set-regexps):
(org-element-entity-parser): Update regexps for entities.
* lisp/org-entities.el (org-entities): Add new entities.
* lisp/org.el (org-fontify-entities): Add comment.
* etc/ORG-NEWS (title): Introduce new entities.
"\..." are used to insert an arbitrary number of spaces in various
back-ends. In particular, this family can be used to introduce
leading spaces within table cells.
Also, unlike to other entities, these can be used mid-word, e.g.,
wo\....rd
Curly brackets can still be added before a dot, e.g.,
This is the end\...{}.
* lisp/org.el (org-tags-expand): Nesting grouptags.
Allowing subtags to be defined as groups themselves.
: #+TAGS: [ Group : SubOne(1) SubTwo ]
: #+TAGS: [ SubOne : SubOne1 SubOne2 ]
: #+TAGS: [ SubTwo : SubTwo1 SubTwo2 ]
Should be seen as a tree of tags:
- Group
- SubOne
- SubOne1
- SubOne2
- SubTwo
- SubTwo1
- SubTwo2
Searching for "Group" should return all tags defined above.
* lisp/org.el (org-tags-expand): Grouptags can have regular expressions as
"sub-tags".
The regular expressions in the group must be marked up within { }.
Example use:
: #+TAGS: [ Project : {P@.+} ]
Searching for the tag Project will now list all tags also including
regular expression matches for P@.+. Good for example if tags for a
certain project is tagged with a common project-identifier,
i.e. P@2014_OrgTags.
* lisp/org.el (org-tag-alist) : New symbols for grouptags when the
tags in the group don't have to be distinct on a heading.
Grouptags had to previously be defined with { }. This syntax is
already used for exclusive tags and Grouptags need their own,
non-exclusive syntax. This behaviour is achieved with [ ]. Note: {
} can still be used also for Grouptags but then only one of the
given tags can be used on the headline at the same time. Example:
[ group : sub1 sub2 ]
Grouptags also are not filtered when setting up tags. This means
they can exist multiple times in org-tag-alist list. It will be
usable if nesting of grouptags is ever to become reality.
There is a slightly annoying side-effect when setting tags in that a
tag which is both a part of a grouptag and a grouptag of it's own
will get multiple key-choices in the selection-UI.
* lisp/org.el (org--setup-process-tags): Adaption for the added syntax
for non-distinct grouptags.
* lisp/org.el (org-fast-tag-selection): Add support for the added,
non-unique, grouptag-syntax. Minor (if ...) to (when ...) refactor.
* lisp/org.el (org-entry-delete): Remove all occurrences of
accumulated properties, too. Return a non-nil value when some
property was removed.
* testing/lisp/test-org.el (test-org/entry-delete): Add test.
* doc/org.texi (Special properties): Remove "CATEGORY"
* lisp/org.el (org-special-properties): Remove "CATEGORY".
(org-property-get-allowed-values): Ignore "CATEGORY".
(org-entry-get): Make sure to get CATEGORY value using
`org-entry-properties'.
* testing/lisp/test-org.el (test-org/entry-put): Add test.
"CATEGORY" is not a special property as it can also be set using
a properties drawer.
* lisp/org.el (org-remove-latex-fragment-image-overlays): Allow to
limit overlay removal through optional arguments. Define a new
return value.
(org-toggle-latex-fragment): Change behaviour. Update docstring
accordingly.
(org-format-latex): Update docstring. Remove overlay when LaTeX
fragment is deleted.
* etc/ORG-NEWS: Signal change.
The new behaviour is the following:
- With a double prefix argument or with a single prefix argument
when point is before the first headline, toggle overlays in the
whole buffer;
- With a single prefix argument, toggle overlays in the current
subtree;
- On latex code, toggle overlay at point;
- Otherwise, toggle overlays in the current section.
Suggested-by: <kuangdash@163.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/95492>
* lisp/org.el (org-adaptive-fill-function): Use
`org-table-line-regexp' instead of `orgtbl-line-start-regexp', which
may not be defined.
Reported-by: Eric Abrahamsen <eric@ericabrahamsen.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/95500>
* org.el (org-latex-to-mathml-convert-command): Work with
other converters than mathtoweb.
(org-latex-to-mathml-convert-command): Add possibility of
passing latex-fragment.
* org.texi (Working with @LaTeX{} math snippets): Show LaTeXML config.
* lisp/org.el (org-fontify-meta-lines-and-blocks-1): Forbid invisible
characters (e.g. bracket links) in all keywords but TITLE, DATE,
AUTHOR, CAPTION and EMAIL. Also remove back-end specific keywords,
which are treated just like any other regular keyword.
Reported-by: Rasmus <rasmus@gmx.us>
<http://permalink.gmane.org/gmane.emacs.orgmode/95415>
* 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.
* lisp/org.el (org-todo-yesterday):
* lisp/org-agenda.el (org-agenda-todo-yesterday): Ignore global
`org-use-effective-time' value.
Otherwise, if `org-use-effective-time' being nil,
`org-extend-today-until' will not be considered, resulting in the
current time being used instead of 23:59 yesterday.
Reported-by: Nikolay Kudryavtsev <nikolay.kudryavtsev@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/93224>
* lisp/org.el (org-add-log-setup): A property drawer may be inserted
where the note is going to be added. Make sure the note ends after
the drawer.
Reported-by: Bradley M. Kuhn <bkuhn@ebb.org>
<http://permalink.gmane.org/gmane.emacs.orgmode/93199>
* lisp/org.el (org-set-regexps-and-options,
org--setup-collect-keywords): Check OPTIONS keywords for information
about sub/superscript.
Reported-by: Thomas Holst <thomas.holst@de.bosch.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/93117>
* lisp/org.el (org-translate-time): Remove function.
(org-timestamp-translate): Rewrite function so it doesn't use the one
above.
* lisp/ox-ascii.el (org-ascii-clock, org-ascii-planning):
* lisp/ox-html.el (org-html-clock, org-html-planning, org-html-timestamp):
* lisp/ox-latex.el (org-latex-clock, org-latex-planning):
* lisp/ox-texinfo.el (org-texinfo-clock, org-texinfo-planning): Use
`org-timestamp-translate' instead of `org-translate-time'.
* etc/ORG-NEWS: Document function removal.
Reported-by: Ian Barton <lists@wilkesley.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/93127>
* lisp/org.el (org-add-planning-info): Preserve indentation when
modifying planning info. Refactor code.
Thanks to Sébastien Vauban for suggesting the idea.
* lisp/org.el (org-insert-labeled-timestamps-at-point): Remove
variable.
(org-add-planning-info): Remove reference to removed variable.
* lisp/org-agenda.el (org-agenda-schedule, org-agenda-deadline):
Remove reference to removed variable.
* etc/ORG-NEWS (Skipping): Document removal.
Org syntax assumes planning info line is always right below the
headline. Setting this variable to anything but nil defeats that and,
as a consequence, produces invalid planning lines.
* lisp/org.el (org-remove-file): Reword success message.
Before this change, when `org-remove-file' succeeded in removing a
file from `org-agenda-files', it would display this unduly alarming
message to the user: "Removed file: foo.org". This made it seem as
though the file itself were removed from the filesystem, rather than
simply being delisted from `org-agenda-files'.
After this change, the message "Removed from Org Agenda list: foo.org"
is displayed instead, so the user will experience only the normal
level of panic involved in using Org Mode, not the increased panic
that results from thinking a file has been removed when it hasn't.
TINYCHANGE
* lisp/org.el (org-open-at-point): Open outer link on nested links.
* testing/lisp/test-org.el (test-org/open-at-point/inline-image): New
test.
Suggested-by: Daniel Bausch <bausch@dvs.tu-darmstadt.de>
<http://permalink.gmane.org/gmane.emacs.orgmode/92796>
* lisp/org.el (org-entry-properties): Fix returned CATEGORY property
when no specific keyword is provided.
* testing/lisp/test-org.el (test-org/entry-properties): Add test.
* lisp/org.el (org-entry-properties): Fix storing SCHEDULED property
when specific argument is not specified.
* testing/lisp/test-org.el (test-org/entry-properties): Add test.
Reported-by: Richard Lawrence <richard.lawrence@berkeley.edu>
<http://permalink.gmane.org/gmane.emacs.orgmode/92728>
* lisp/org.el (org-insert-heading): Fix some corner case when point is
in an invisible list.
* testing/lisp/test-org.el (test-org/insert-heading): Add tests.
Reported-by: Luke Crook <luke@balooga.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/92619>
* lisp/org.el (org-return): Avoid false positives in function.
* testing/lisp/test-org.el (test-org/return): New test.
Thanks to Sébastien Vauban for reporting it.
<http://permalink.gmane.org/gmane.emacs.orgmode/92657>
* lisp/org.el (org-read-date): Respect `org-replace-disputed-keys'.
Beginning from org-8.1, org-read-date ignores
`org-replace-disputed-keys'. This commit restores the original
behavior. Users who want the org-8.1 behavior should customize
`org-read-date-minibuffer-local-map' instead.
See http://thread.gmane.org/gmane.emacs.orgmode/90626/focus=91318 for
the discussion on this issue.
This commit in effect reverts a6986494a0
and e8023dde58.
TINYCHANGE
* lisp/org.el (org-adapt-indentation): Update docstring.
(org-fixup-indentation): Ignore contents of source blocks and example
blocks when indentation should be preserved.
* testing/lisp/test-org.el (test-org/demote, test-org/promote): Add
tests.
* lisp/org-element.el (org-element-paragraph-separate,
org-element--object-regexp): Turn defconst into defvar.
(org-element--set-regexps): Properly set previous variables.
(org-element-update-syntax): New function.
* lisp/org-list.el (org-plain-list-ordered-item-terminator,
org-list-allow-alphabetical): Call new function whenever these
variables are modified and Org is already loaded.
* lisp/org.el (org-add-link-type): Call new function since a new link
type triggers a rebuild of syntax regexps, possibly invalidating
cache in all Org buffers.
Reported-by: Christopher Dannheim <ch.dannheim@gmail.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/92487>
* lisp/org.el (org-promote, org-demote): Fix docstring. Small
refactoring. Ignore narrowing.
(org-fixup-indentation): Smarter indentation: handle inlinetasks and
footnote definitions.
* testing/lisp/test-org.el (test-org/demote, test-org/promote): New
test.
`org-called-with-limited-levels' check is removed when promoting
a top-level headline. The motivation behind it in this particular
case wasn't clear (see 10aba6b126) and
I couldn't find a good reason to keep it.
Suggested-by: Sébastien Vauban
<http://permalink.gmane.org/gmane.emacs.orgmode/92450>
* lisp/org.el (org-goto): Update for isearch changes that removed
isearch-other-control-char.
isearch-other-control-char has been removed from isearch.el [1]. The
default interface for org-goto uses isearch-other-control-char to pass
certain key presses from org-goto-local-auto-isearch-map to
org-goto-map. Specifically, 'C-i' calls org-cycle and 'C-m' calls
org-goto-ret.
With the current isearch, the keys that should be passed to org-goto-map
can be set to nil. In addition to 'C-i' and 'C-m', RET must also be set
to nil because isearch-mode-map sets both 'C-m' and RET.
[1] bzr revision 114586, git commit aa04ac2c6,
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=15200
<http://thread.gmane.org/gmane.emacs.orgmode/92317>
* lisp/org.el (org-org-menu): Fix entries.
`org-shiftmetaup' and `org-shiftmetadown' only drag a single line up
or down. They are not about structure editing.
Reported-by: James Harkins <jamshark70@qq.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/92299>
* lisp/org.el (org-effort-durations): Allow "min" modifier.
This is a standard abbreviation. It also improves compatibility with
other programs using this property (e.g. "Taskjuggler").
* lisp/org.el (org-set-regexps-and-options): Fix "Symbol nil may not
be buffer-local" error when encountering an nonexistent startup
keyword.
Reported-by: Mike McLean <mike.mclean@pobox.com>
<http://permalink.gmane.org/gmane.emacs.orgmode/92279>
* lisp/org.el (org-log-beginning): New function.
(org-ts-regexp-inactive): New variable.
(org-add-log-setup): Use new function.
(org-skip-over-state-notes): Make function more robust to
customization.
(org-store-log-note): Update function according to previous changes.
Small refactoring.
* lisp/org.el (org--setup-collect-keywords): Correctly collect
multiple TODO lines.
* testing/lisp/test-org.el (test-org/set-regexps-and-options): Add
test.
Thanks to Eric Abrahamsen for reporting it.
* lisp/org.el (org-get-property-block): Fix property drawer insertion
with consecutive headlines
* testing/lisp/test-org.el (test-org/entry-put): Add test.
Thanks to Eric Abrahamsen for reporting it.
* lisp/org-table.el (org-table-set-constants): Remove function.
* lisp/org.el (org-set-regexps-and-options): Rewrite function. Merge
it with `org-set-regexps-and-options-for-tags'.
(org-set-regexps-and-options-for-tags): Remove function
(org--setup-collect-keywords, org--setup-process-tags): New functions.
(org-mode): Remove `org-set-regexps-and-options-for-tags' call.
(org-agenda-prepare-buffers): Use optimized setup for tags in all
cases. Improve docstring.
(org-make-options-regexp): Make returned regexp more efficient.
* lisp/org.el (org-ds-keyword-length, org-deadline-regexp,
org-deadline-time-regexp, org-deadline-time-hour-regexp,
org-deadline-line-regexp, org-scheduled-regexp,
org-scheduled-time-regexp, org-scheduled-time-hour-regexp,
org-closed-time-regexp, org-keyword-time-regexp,
org-keyword-time-not-clock-regexp, org-maybe-keyword-time-regexp,
org-all-time-keywords): Turn into a defconst, no longer
buffer-local.
(org-set-regexps-and-options): No need to set anymore previous
variables.
* lisp/org.el (org-special-properties): Remove "CLOCK" as a special
keyword.
(org-entry-properties): Rewrite function according to property drawer
syntax. Change signature.
(org-entry-get): Apply signature change.
"CLOCK" removal is motivated by the fact that it isn't listed as
a special keyword in the manual, it is not used throughout the code
base, and there is no meaningful value for this property.
* lisp/org.el (org-entry-put): Refactor code, taking into account
changes to property drawer syntax. Fix errors when handling special
values, which cannot be symbols. Remove CLOCKSUM handling.
(org-entry-get): Refactor code.
(org-entry-delete): Small refactoring, do not rely on
`org-remove-empty-drawer-at' since parser is not necessary here.
(org-buffer-property-keys): Fix infloop. Ignore final "+" in extended
properties. Refactor code.
(org-property-values): Include extended values.
(org-entry-get-with-inheritance, org-insert-property-drawer): Small
refactoring.
(org-insert-drawer): Fix docstring and comments.
(org--update-property-plist): Renamed from org-update-property-plist.
Use side effects. Improve speed.
CLOCKSUM special property in `org-entry-put' is buggy (symbols instead
of strings) and ignores provided value. Since the expected behaviour
is neither clear nor documented, the property is not handled anymore
by the function.
* lisp/org.el (org-at-property-p): Rewrite. Don't use `org-element-at-point'. It
is faster to retrieve the property drawer location instead.
(org-get-property-block): Update function and docstring. Change
signature.
(org-entry-properties, org-entry-put, org-buffer-property-keys): Apply
signature change.
* lisp/org.el (org--flyspell-object-check-p): New function.
(org-mode-flyspell-verify): Check that table row or verse block under
point is not empty. Use previous function.
* lisp/org-list.el (org-list-item-body-column): Take into
consideration empty items and bullets followed by two spaces.
* lisp/org.el (org--get-expected-indentation): Fix return value for
items in lists.
(org-indent-region): Fix infloop when indenting some types of plain
lists. Also fix error when region starts with blank lines at the
beginning of the buffer.
* testing/lisp/test-org.el (test-org/indent-region): Add tests.
* org.el (org-mode-map): change key-binding from C-c p to C-c " a add
C-c " g key-binding for Gnuplot
(org-tbl-menu): add sub-menu for plotting featuring Gnuplot and ascii
plot
* org-table.el (orgtbl-setup): add sub-menu for plotting featuring
Gnuplot and ascii plot
* contrib/lisp/org-eww.el: New file
* contrib/README: Added org-eww.
* lisp/org.el (org-modules): Add org-eww to the pool of org-modules.
The hook gets hooked in the module.
The file is more or less a fraction of the org-w3m module with 'w3m'
replaced by 'eww'.
* lisp/ox-latex.el (org-latex-src-block): Support :float nil with
caption for minted.
(org-latex-listings): Edit docstring to describe this usecase.
* lisp/org.el (org-latex-default-packages-alist): Add “capt-of”
package.
This takes advantage of the capt-of package’s \captionof command,
which allows to insert a caption (with autogenerated number and
\ref-able label) without creating a floating environment. One example
of where this is useful is in the case of a minted source code listing
that spans more than one page. (Latex floats can’t be larger than a
page, generally speaking.)
The listings package already handles this case using its own mechanism.