* org-protocol.el:
* org-bibtex.el: Remove remember support.
* org-clock.el (org-clock-heading-for-remember): Delete.
(org-clock-in): Do not set the heading for remember.
Users are encouraged to migrate their remember templates to
`org-capture-templates' instead of `org-remember-templates'.
See `org-capture-import-remember-templates' on how to ease
the transition.
* lisp/ox-latex.el (org-latex-property-drawer): Remove function.
* contrib/lisp/ox-groff.el (org-groff-property-drawer): Remove
function.
This changes ensures that:
paragraph
# comment
another paragraph
will be exported as:
paragraph
another paragraph
and not as:
paragraph
another paragraph
It only applies on back-end where empty lines are meaningful (e.g. not
html).
* org.el (org-move-subtree-down, org-forward-element)
(org-backward-element):
* org-table.el (org-table-previous-field)
(org-table-move-column, org-table-move-row):
* org-list.el (org-move-item-down, org-move-item-up)
(org-cycle-item-indentation): Use `user-error' when moving or
modifying the element at point is not possible.
* contrib/lisp/ox-koma-letter.el (org-koma-letter-template): Allow to
span documentclass options accross multiple lines in template.
* lisp/ox-beamer.el (org-beamer-template): Allow to span documentclass
options accross multiple lines in template.
* lisp/ox-latex.el (org-latex-template): Allow to span documentclass
options accross multiple lines in template.
Thanks to Michael Strey for reporting this bug.
* lisp/ox-texinfo.el (org-texinfo--get-node): New function.
(org-texinfo-headline, org-texinfo-link): Use new function.
The same function is used to create @node entries and links to nodes,
to avoid any discrepancy between them
* org-agenda.el (org-agenda-local-vars): Don't include
`org-agenda-show-window' as it needs to be checked outside of
the agenda window.
Thanks to Bernt Hansen for reporting this.
* org-compat.el (org-file-equal-p): New compatibility function.
* ox.el (org-export-output-file-name): Use the new function.
Thanks to Mark Edgington for reporting this.
* org-clock.el (org-clock-set-current)
(org-clock-delete-current): Delete.
(org-clock-in, org-clock-out): Set and delete
`org-clock-current-task'. Minor code clean-up.
* org-clock.el (org-clock-in, org-clock-in-last): Tell
`org-current-time' to always return a past time.
* org.el (org-current-time): New argument `past' to force
returning a past time when rounding.
If (setq org-clock-rounding-minutes 5) and time is 12:33
the clock start time would be 12:35, and the clock mode-line
would display 0:-2. The fix ensures the rounded value is
always in the past.
* org-agenda.el (org-agenda-unmark-clocking-task): New
function.
(org-agenda-mark-clocking-task): Use it.
(org-agenda-clock-in): Let the cursor where it is.
(org-agenda-clock-out): Ditto. Also remove the
`org-agenda-clocking' overlay.
* org.el (org-next-link): New parameter `search-backward'.
Fix bug when at a link with no 'org-link face, e.g., in a DONE
headline. Throw a message instead of an error.
(org-previous-link): Use `org-next-link'.
* lisp/ox-publish.el (org-publish-index-generate-theindex): Do not
create an "* Index" headline in "theindex.inc". Though, create an
"Index" title in fallback "theindex.org".
* org.el (org-mode): Don't make characters from
`org-emphasis-alist' word constituants.
(org-mode-transpose-word-syntax-table): Rename from
`org-syntax-table'.
(org-transpose-words): Use
`org-mode-transpose-word-syntax-table'.
Thanks to Achim Gratz and T.F. Torrey for reporting the broken tests.
When using C-RET to insert a new headline, the new headline was
inserted after arbitrary amounts of whitespace at the end of the
subtree. This whitespace is now shrunk, to avoid unnatural spacing.
* lisp/org.el (org-insert-heading): Shrink whitespace at end of
subtree when `org-insert-heading-respect-content' is on.
* lisp/org-element.el (org-element-headline-parser,
org-element-inlinetask-parser): Upcase properties. This is done to
avoid confusion between properties from parser (e.g. `:end') and
properties from the property drawer (e.g. :END:).
In particular, it means that :CUSTOM_ID: property is accessed through:
(org-element-property :CUSTOM_ID headline)
* org-agenda.el (org-agenda-set-restriction-lock): Put the
overlay until the end of the subtree, not the end of the
headline.
When the agenda restriction is on, user expect agenda views to check
every entry in the subtree. If a user add an entry outside of the
overlay without noticing it, this entry will not be checked and the
user will wonder why. Put the end of the overlay at the end of the
subtree so that the user always knows if the entries she is adding
are within the current restriction.
We might need to find a less instrusive overlay color, though.
* org.el (org-entry-delete, org-delete-property): New optional
arg delete-empty-drawer, a string, to delete any empty drawer
with that name.
(org-toggle-ordered-property): Delete the drawer "PROPERTIES"
if empty.
* org.el (org-set-tags-command): Fix bug when setting tags for
multiple headlines in an active region.
Do not set the end of the region back to the beginning of the
previous headline.
* lisp/org-faces.el (org-latex-and-related): Renamed from
`org-latex-and-export-specials', which wasn't appropriate anymore.
* lisp/org.el (org-highlight-latex-and-related,
org-latex-and-related-regexp): New variables.
(org-compute-latex-and-related-regexp, org-do-latex-and-related): New
function, revived from a previous commit.
(org-set-regexps-and-options, org-set-font-lock-defaults): Use new
functions.
* org-src.el (org-src-mode-map, org-edit-src-code)
(org-edit-fixed-width-region, org-edit-src-save): Use C-c C-k
for `org-edit-src-abort'.
Thanks to Bernt Hansen for the suggestion.
* lisp/ox.el (org-export-install-filters): Properly install filters
send through ext-plist mechanism.
* lisp/ox-publish.el (org-publish-org-to): Small refactoring.
* lisp/ox-html.el (org-html-keyword): Remove INDEX keyword handling.
ox-publish.el takes care of it already.
* org-table.el (org-table-align): Only set the window start
when table alignment is performed in the selected window.
Thanks to Michael Brand for reporting this.
When opening an .org file from another .org file, org-mode
is initialized in the second one while the window is not yet
selected. So, functions run during org-mode's initialization
need to check if the org-mode window is the selected one before
manipulating the "current window".
* org-src.el (org-edit-src-auto-save-idle-delay): New option.
(org-src-ask-before-returning-to-edit-buffer): Make a defcustom.
(org-edit-src-code-timer): New timer variable.
(org-edit-src-code): Run the timer.
(org-edit-fixed-width-region): Enhance message.
(org-edit-src-exit): Cancel the timer.
Thanks to Andreas Leha for suggesting this.
* lisp/org.el (org-org-menu): Use correct key "C-u C-c C-x !" to do
org-reload uncompiled in the menu.
The key binding has been changed in 8619361669 due to a conflict with
agenda mode, but the menu entry had never been corrected.
* org-src.el (org-edit-src-save): Prevent saving when editing
fixed-width buffer, exiting will save already.
(org-edit-src-exit): Inconditionally kill the src/example
editing buffer.
* org-pcomplete.el (pcomplete/org-mode/file-option): Require
'org-element. This fixes a bug about unbound variable
`org-element-affiliated-keywords' when trying to complete a
keyword before 'org-element was required.
* org-src.el (org-src-mode-map): New binding C-c k to abort
editing.
(org-edit-src-code): Mention the keybinding to abort editing
and go back to the correct position.
(org-edit-src-abort): New command to abort editing.
Thanks to Zech for suggesting this.
* lisp/ox.el (org-export-resolve-fuzzy-link): Whitespaces are not
significant when matching a fuzzy link.
* lisp/org-element.el (org-element-link-parser): Do not remove
newlines characters in paths anymore, since this is not required.
* testing/lisp/test-org-element.el: Update tests.
* testing/lisp/test-ox.el: Add test.
* lisp/ox.el (org-export--dispatch-ui): Renamed from
`org-export-dispatch-ui'. Handle scrolling.
(org-export--dispatch-action): Renamed from
`org-export-dispatch-action'. Implement scrolling.
(org-export-dispatch): Apply renaming.
Heavily based on a patch from Jambunathan K.
* lisp/org-element.el (org-element-at-point): Return nil when in the
first empty lines of the buffer. Return headline when in empty
lines just after the headline.
* lisp/ox.el (org-export-output-file-name): Add a protection when
output file name is the same as the original org.
* testing/lisp/test-ox.el: Add tests.
* lisp/ox-beamer.el (org-beamer-template): Add missing `class'
argument for `format-string'.
* lisp/ox-latex.el (org-latex-template): Add missing `class' argument
for `format-string'.
Thanks to Sébastien Vauban for reporting the problem and providing the
initial patch.
* org.el (org-syntax-table, org-transpose-words): Delete.
(org-mode): Syntactically Define {} and <> as parentheses.
(org-drag-line-forward, org-drag-line-backward): New
functions.
(org-shiftmetaup, org-shiftmetadown): Fall back on the new
functions instead of throwing an error.
M-up/down used to drag a line up or down in contexts where it could not do
another move. When org-element.el was integrated to core, dragging line by
line was not possible anymore since a line is not an "element". This
commit reintroduces the ability to drag a line up/down with S-M-<up/down>.
* org.el (org-make-org-heading-search-string): Don't use
statistic or [x/y] cookies when creating a link.
Thanks to William Lechelle for reporting this.
recognized depth
* lisp/ox-texinfo.el (org-texinfo-max-toc-depth): Maximum depth
recognized by texinfo for nodes and sectioning. Left as a constant
to be updated if ever necessary.
(org-texinfo--generate-detailed): Use the smaller between
org-texinfo-max-toc-depth and headline levels (H: )
* org.el (org-startup-folded):
* org.texi (Visibility cycling): Suggest to set
`org-agenda-inhibit-startup' to nil if user wants the startup
visibility settings to be honored in any circumstances.
Thanks to Tassilo for pointing this.
* org.el (org-emphasis-alist, org-protecting-blocks):
* org-src.el (org-edit-src-find-region-and-lang):
* org-list.el (org-list-forbidden-blocks):
* org-footnote.el (org-footnote-forbidden-blocks): Remove
references to the deleted DocBook exporter.
* org.texi (Top, Markup, Initial text, Images and tables)
(@LaTeX{} fragments, @LaTeX{} fragments, Exporting)
(Export options, JavaScript support, Beamer class export):
Remove references to the DocBook export, which has been
deleted.
(History and Acknowledgments): Mention that DocBook has been
deleted, suggest to use the Texinfo exporter instead, then to
convert the .texi to DocBook with makeinfo.
(Links in ODT export, Tables in ODT export): Fix indices.
* org.el (org-startup-with-latex-preview): New option.
(org-startup-options): New startup keywords for the new
option.
(org-mode): Turn on/off LaTeX preview depending on the new
option.
* org-agenda.el (org-agenda-prefix-format): Add documentation for
the new %b option.
(org-prefix-has-breadcrumbs): Add flag, `t' when %b is set.
(org-agenda-format-item): Add breadcrumbs if requested.
(org-compile-prefix-format): Add compiled information for
breadcrumbs, add %b option.
If org file has the structure
* project
** task1
*** TODO item1
then when using %b in org-agenda-prefix-format the agenda will display
"project->taks1->TODO item1".
* org-mobile.el (org-mobile-edit): DTRT when inserting a heading
in an invisible region.
* org.el (org-insert-heading-respect-content): New
`invisible-ok' parameter. Add docstring.
(org-insert-todo-heading-respect-content): Add docstring.
Thanks to James Harkins for the extra detailed reports and
the proposed solutions, both for org.el and org-mobile.el.
* lisp/org.el (org-reverse-string): Add `org-reverse-string' to
reverse a string.
* lisp/org-id.el(org-id-new, org-id-decode): Replace
`org-id-reverse-string' by `org-reverse-string'.
* lisp/ob-core.el(org-babel-trim): Replace `org-babel-reverse-string'
by `org-reverse-string' and declare it.
TINYCHANGE
* org.el (org-open-at-point): Open a plain link even if the
cursor is before it, which is consistent with the behavior
with respect to bracket and angle links.
TINYCHANGE
* lisp/ox.el (org-export--collect-headline-numbering): Remove footnote
section from TOC.
(org-export-collect-headlines): Do not count footnote section when
numbering a headline.
* testing/lisp/test-ox.el: Add tests.
* ox-html.el (org-html-link): Don't throw an error if the
value of the :ID: property has not been generated by uuidgen.
Thanks to Florian Beck for requesting this.
* org-pcomplete.el (pcomplete/org-mode/file-option/x):
Resurrect. Use `org-default-options' to initialize completion
fonctions for the most important keywords.
* org-macs.el (org-default-options): Rename and adapt from
`org-get-current-options'.
This is a partial revert of e14cf780 feature-wise. The idea is
that it may be useful to get completion, even when it ends up with
the default value, because the user may want to adapt the default
values instead of re-typing them.
* lisp/ox-ascii.el (org-ascii-inner-template): New function.
(org-ascii-template): Use new function.
(org-ascii-export-as-ascii, org-ascii-export-to-ascii): Update
docstring.
* org.el (org-timestamp-change): New optional parameter
`suppress-tmp-delay' to suppress temporary delay like "--2d".
(org-auto-repeat-maybe): Suppress temporary delays.
Thanks to Michael Brand for suggesting this.
* org-agenda.el (org-agenda-get-scheduled): When the delay is
of the form "--2d" and there is a repeater, ignore the delay
for further repeated occurrences.
Thanks to Michael Brand for suggesting this was somehow needed.
* lisp/ox.el (org-export-as): Call `inner-template' function, if
available.
* lisp/ox-html.el (org-html-inner-template): New function.
(org-html-template): Move all parts that should be inserted even in
a body-only export into `org-html-inner-template'.
* testing/lisp/test-ox.el: Add tests.
* lisp/org-element.el (org-element--current-element): Add a limit
argument.
(org-element--collect-affiliated-keywords): Fix parsing of orphaned
keyword at the end of an element.
* testing/lisp/test-org-element.el: Add test.
* org-agenda.el (org-agenda-schedule, org-agenda-deadline):
Cosmetic changes.
(org-agenda-show-new-time): Fix bug when displaying a
temporary overlay with the scheduled/deadline information.
Thanks to Thomas Morgan for reporting this bug and testing the patch.
* org.el (org-fill-paragraph-with-timestamp-nobreak-p): New
function.
(org-setup-filling): Use it to prevent breaking a timestamp
when filling a paragraph.
Thanks to William for requesting this.
* lisp/ox-texinfo.el (org-texinfo-src-block): Remove spurious newline
character as `org-export-format-code-default' already makes sure the
string returned will end with a single one.
Thanks to Frank Fischer for reporting it.
* lisp/org.el (org-cycle-global-status)
(org-cycle-subtree-status): Set state property.
(org-heading-components): Use org-heading-regexp in
orgstruct-mode.
(orgstruct-heading-prefix-regexp, orgstruct-setup-hook): New
options.
(orgstruct-initialized): New variable.
(orgstruct-mode): Simplify implementation.
(orgstruct-setup): Simplify implementation. Translate keys to
their most general equivalent.
(orgstruct-make-binding): Generate index on the fly. Discard
alternative keys. Bind variables according to
orgstruct-heading-prefix-regexp.
(org-get-local-variables): Honour state property.
(org-run-like-in-org-mode): Do not override variables with
non-default values.
(org-forward-heading-same-level): Do not skip to headlines on
another level. Handle negative prefix argument correctly.
(org-backward-heading-same-level): Use
org-forward-heading-same-level.
* lisp/ox-latex.el (org-latex-headline): When a function returns
a sectionning command, only one placeholder should be required.
Thanks to Florian Beck for reporting this.
* add a header-row delimiter to the tables returned from mysql
* add new sql-specific header args for the database connection, and implements them for mysql
* add support for :colnames (mysql only)
* (minor) add an edebug spec to org-babel-result-cond to allow edebugging through it
* add some doc about what header args are used
The syntax of result hashes with times are now as show below.
#+RESULTS[<TIME> HASH]:
* lisp/ob-core.el (org-babel-result-regexp): Simplified regexp given new
time hash layout.
(org-babel-current-result-hash): New match string.
(org-babel-hide-hash): New match string.
(org-babel-where-is-src-block-result): New match string, and inserting
hashes in the new format.
* lisp/ox-latex.el (org-latex-special-block): Add :options attribute
to special blocks to specify options.
With this patch, the following is now possible (again):
#+attr_latex: :options [Someone]
#+begin_theorem
Something
#+end_theorem
* org.el (org-read-date-minibuffer-local-map): Use "." to go
to today's date.
Unless I'm crazy, there is a regression here, but I'm unable to find
when the regression started for now.
* ob-core.el (org-babel-next-src-block)
(org-babel-previous-src-block): Rewrite using
`org-next-block'.
* org.el (org-next-block, org-previous-block): New navigation
commands.
(org-mode-map): Bind the new commands to C-c C-F and C-c C-B
respectively.
Thanks to Bill White for suggesting this.
* org-agenda.el (org-agenda-write): Don't copy headlines'
subtrees when writing to an .org file.
* org.el (org-copy-subtree): New parameter `nosubtrees'.
* lisp/ox-latex.el (org-latex-example-block, org-latex-src-block):
Ignore element if it's empty. This fixes error "apply: Wrong number
of arguments: max, 0".