Jambunathan K
b495c92239
org-odt.el: Correctly format link to headlines that have description
...
* lisp/org-odt.el (org-odt-format-org-link): Add check for
presence of description in headline links.
Fix
http://lists.gnu.org/archive/html/emacs-orgmode/2012-11/msg00841.html
2012-12-23 12:42:43 +01:00
Bastien Guerry
f015ae5b8b
org.el (org-todo): Ignore the comment string when changing a TODO state
...
* org.el (org-todo): Ignore the comment string when changing
the TODO state of a headline.
Thanks to Samuel Wales for reporting this.
2012-12-22 20:16:17 +01:00
Sebastien Vauban
ce4e0846b2
When pasting a copied subtree, respect the whitelines before and after
...
* org.el (org-copy-subtree, org-paste-subtree): Fix whitespace
handling when copying/pasting a subtree.
2012-12-22 16:22:12 +01:00
Bastien Guerry
9333426c12
Re-apply commit 27bcf9a
together with a workaround for `process-file'.
...
Thanks to Michael Albinus for hunting this bug and for providing
this workaround.
2012-12-21 09:45:53 +01:00
Bastien Guerry
30922bd7e9
org.el (org-edit-special): Fix docstring.
...
* org.el (org-edit-special): Fix docstring.
(org-in-src-block-p): Small enhancement.
2012-12-21 09:32:38 +01:00
Bastien Guerry
483aa1312d
Revert "Backport revno 111277 from Emacs trunk."
...
This reverts commit 27bcf9a70b
.
2012-12-21 08:50:26 +01:00
Bastien Guerry
f8aab87141
Fix compiler warning.
2012-12-20 19:01:17 +01:00
Bastien Guerry
44558f0bbd
Unify the list of args for org-export-as-* functions.
...
* org-publish.el (org-publish-org-to): Call `org-export-as-*'
functions with the correct list of arguments.
* org-html.el (org-export-as-html): Delete obsolete arg
`hidden'.
(org-export-as-html-and-open, org-export-as-html-batch)
(org-export-region-as-html): Don't use obsolete arg.
* org-ascii.el (org-export-as-ascii): Delete obsolete arg
`hidden'.
(org-export-as-ascii-to-buffer): Don't use obsolete arg.
2012-12-20 18:54:33 +01:00
Bastien Guerry
8165be3aa5
org.el: Prevent link activation in source code blocks
...
* org.el (org-in-fixed-width-region-p): Save match data.
(org-in-src-block-p): Use case-folding for searching the block
boundaries.
(org-activate-plain-links, org-activate-angle-links)
(org-activate-bracket-links): Prevent link activation in
source code blocks.
Thanks to Sébastien Vauban for reporting a related issue.
2012-12-20 16:34:27 +01:00
Bastien Guerry
e89994a75c
Revert "org.el (org-set-font-lock-defaults): Don't activate links in source code blocks and fixed-width regions"
...
This reverts commit f983cf1729
.
2012-12-20 16:15:54 +01:00
Bastien Guerry
de84aadf8f
org-odt.el: Fix Emacs bug #13197 .
...
* org-odt.el (org-odt-cleanup-xml-buffers): Fix Emacs
Bug#13197 by setting the correct buffer before marking it
unmodified to silently kill him.
Thanks to Drew Adams for reporting this and to Jambunathan for
offering to fix it.
2012-12-20 16:06:25 +01:00
Michael Albinus
27bcf9a70b
Backport revno 111277 from Emacs trunk.
...
* ob.el (org-babel-temp-file): Fix setting of
`temporary-file-directory' on remote hosts.
* ob-eval.el (org-babel-shell-command-on-region): Use
`process-file' instead of `call-process-region'. The latter one
does not work on remote hosts.
2012-12-20 15:49:19 +01:00
Bastien Guerry
f983cf1729
org.el (org-set-font-lock-defaults): Don't activate links in source code blocks and fixed-width regions
...
* org.el (org-set-font-lock-defaults): Don't activate links in
source code blocks and fixed-width regions.
Thanks to Sébastien Vauban for reporting an error related to this.
2012-12-20 15:42:53 +01:00
Bastien Guerry
ab5e372926
org-agenda.el (org-agenda-finalize): Fix links activation
...
* org-agenda.el (org-agenda-finalize): Fix links activation.
2012-12-20 15:34:10 +01:00
Dmitry Antipov
bfb9f9d10f
Use (point-marker) instead of (move-marker (make-marker) (point))
...
* org-agenda.el (org-agenda-get-restriction-and-command): Use `point-marker'.
* org-capture.el (org-capture-place-template): Likewise.
* org-colview-xemacs.el (org-dblock-write:columnview): Likewise.
* org-colview.el (org-dblock-write:columnview): Likewise.
* org-mobile.el (org-mobile-locate-entry): Likewise.
* org-table.el (org-table-convert-region): Likewise.
* org.el (org-update-statistics-cookies): Likewise.
* contrib/lisp/org-invoice.el (org-dblock-write:invoice): Likewise.
2012-12-20 13:16:41 +01:00
Achim Gratz
b508943d32
org-compat: new macro org-no-popups
...
* lisp/org-compat.el (org-no-popups): New wrapper macro which
let-binds the correct variables to suppress popup windows depending
on the Emacs version in use. This is a compile-time decision when
byte-compiling.
* lisp/org.el (org-get-location, org-switch-to-buffer-other-window):
Use the wrapper `org-no-popups´ to let-bind the correct variables
for suppression of popup windows.
2012-12-20 12:57:52 +01:00
Bastien Guerry
dfa3c74e34
Fix commit 14ffe2.
2012-12-20 11:13:30 +01:00
Bastien Guerry
14ffe22b8f
org.el (org-open-at-point): Handle non-links correctly.
...
* org.el (org-open-at-point): Throw the correct error on
non-links. Use `user-error' instead of `error'.
This fixes a bug introduced in ad35e2.
Thanks to Samuel Loury for spotting this and for submitting a patch.
2012-12-20 09:39:35 +01:00
Bastien Guerry
963ede0a9d
Fix some compiler warnings.
...
* org.el (org-in-fixed-width-region-p): Define before use.
* org-src.el (org-in-src-block-p): Declare function.
2012-12-20 01:16:01 +01:00
Bastien Guerry
23e2346c4c
org-compat.el: Fix bug: don't use `eval-when-compile' when aliasing `user-error'.
...
* org-compat.el: Fix bug: don't use `eval-when-compile' when
aliasing `user-error'.
Thanks to Bernt Hansen for reporting this bug.
2012-12-19 17:43:57 +01:00
Achim Gratz
b9ea74a195
Backwards compatibility for `user-error´
...
* lisp/org-compat.el (user-error): Defalias to `error´ for Emacsen
that don't have it.
2012-12-19 15:33:29 +01:00
Achim Gratz
bdc95549dd
Backwards compatibility: use compatibility macro
...
* lisp/org-agenda.el (org-agenda-write): Use
org-called-interactively-p instead of called-interactively-p.
2012-12-19 15:30:23 +01:00
Achim Gratz
9a71174348
Backwards compatibility: check for possibly undefined variables in org-find-invisible-foreground
...
* lisp/org.el (org-find-invisible-foreground): Do not use the value of
variables `default-frame-alist´, `initial-frame-alist´ and
`window-system-default-frame-alist´ when their symbol is not bound.
This avoids an error with Emacs 22, which does not define
`window-system-default-frame-alist´, that prevents the test suite from
even starting, the other variables are treated the same as a defensive
measure.
2012-12-19 11:04:22 +01:00
Bastien Guerry
db28a7a0ab
Merge branch 'maint' of orgmode.org:org-mode into maint
2012-12-19 00:23:59 +01:00
Bastien Guerry
1c57cd5a7d
org-agenda.el (org-agenda-skip): Only check if point is inside a code block, not at a code block.
...
* org-agenda.el (org-agenda-skip): Only check if point is
inside a code block, not at a code block.
Thanks to Eric Fraga for reporting this problem.
2012-12-19 00:23:30 +01:00
Nicolas Goaziou
7739e8b5f7
Small refactoring
...
* lisp/org.el (org-fill-paragraph): Small refactoring.
2012-12-18 19:32:50 +01:00
Bastien Guerry
374efdd63e
org.el (org-in-fixed-width-region-p): Rewrite using org-element.el.
...
* org.el (org-in-fixed-width-region-p): Rewrite using
org-element.el.
Thanks to Nicolas Goaziou for suggesting this.
2012-12-18 15:09:40 +01:00
Bastien Guerry
9d4dd69b30
org.el (org-fill-paragraph): Fill correctly in source code block.
...
* org.el (org-fill-paragraph): Fill correctly in source code
block.
Thanks to Sébastien Vauban for reporting this.
2012-12-18 12:49:49 +01:00
Nicolas Goaziou
20839ced71
org-element: Fix parsing of a list in a block in a list
...
* lisp/org-element.el (org-element--parse-elements,
org-element-at-point): Fix parsing of a list in a block in a list.
* testing/lisp/test-org-element.el: Add test.
2012-12-16 00:45:17 +01:00
Bastien Guerry
df099175e7
org.el (org-edit-special): Fix bug about editing special environments.
...
* org.el (org-in-fixed-width-region-p): New function.
(org-edit-special): Fix bug: make sure to DTRT in every
special environment. Also use the new function to check
against fixed-width environment.
Thanks to Bernt Hansen for reporting a bug in this area.
2012-12-14 10:30:16 +01:00
Bastien Guerry
81d5ebce8d
org-src.el (org-edit-src-code): Check if we are in a source code block with `org-in-src-block-p'.
...
* org-src.el (org-edit-src-code): Check if we are in a source
code block with `org-in-src-block-p'. Slightly reformat the
docstring.
2012-12-14 10:10:40 +01:00
Bastien Guerry
a7afe7df1a
org.el (org-in-src-block-p): Return t when on #+BEGIN|END_SRC lines.
...
* org.el (org-in-src-block-p): Return t when point is at the
#+BEGIN_SRC/#+END_SRC lines unless the new optional parameter
'inside is set to t.
2012-12-14 10:02:25 +01:00
Michael Gauland
4524a02b39
Edit source: fix 'end' initialisation
...
* org-src.el: Create a marker to pass to copy-marker.
This fixes a 'wrong type argument' error when running
org-edit-src-code (observed on Emacs 23.2.1).
The problem was that copy-marker expects a marker, and it was given
nil. This change gives it a marker that doesn't point anywhere, but
still lets us set the insertion type of the end marker.
TINYCHANGE
2012-12-13 23:47:07 +01:00
Bastien Guerry
22e4a4ecb9
Revert "org-src.el (org-edit-src-code): Fix bug on Emacs <24.1."
...
This reverts commit 7a770c10c1
.
2012-12-13 23:45:55 +01:00
Bastien Guerry
0584dffefe
ob-exp.el (obe-marker): Delete useless var.
...
* ob-exp.el (obe-marker): Delete useless var.
2012-12-13 17:36:52 +01:00
Bastien Guerry
7a770c10c1
org-src.el (org-edit-src-code): Fix bug on Emacs <24.1.
...
* org-src.el (org-edit-src-code): Fix bug triggered by the
sexp (copy-marker nil) on Emacs <24.1.
Thanks to Bernt Hansen for reporting this.
2012-12-13 17:04:38 +01:00
Bastien Guerry
488eea6d25
org-latex.el: Escape raw path when exporting links to files.
...
* org-latex.el (org-export-latex-links): Escape raw path when
exporting links to files.
Thanks to John Smith for reporting this.
2012-12-12 10:57:34 +01:00
Bastien Guerry
570ecb4e31
org-src.el: Fix bug: the S-TAB key should not trigger a native TAB command.
...
* org-src.el (org-src-native-tab-command-maybe): Fix bug: the
S-TAB key should not trigger a native TAB command.
2012-12-12 09:09:04 +01:00
Bastien Guerry
20b3d550e0
org.el: Allow to open any link within footnotes definition, not only bracket links.
...
* org.el (org-open-at-point): Allow to open any link within
footnotes definition, not only bracket links.
2012-12-12 08:42:55 +01:00
Bastien Guerry
7f0e7cb9b9
org.el (org-sort-entries): Bugfix: keep track of the clock marker when sorting entries.
...
* org.el (org-sort-entries): Bugfix: keep track of the clock
marker when sorting entries. Enhance the docstring.
2012-12-11 18:13:41 +01:00
Bastien Guerry
0c68a27ac9
org-clock.el (org-clock-out): Use `user-error'.
...
* org-clock.el (org-clock-out): Use `user-error' when the user
tries to clock out while there is no running clock.
2012-12-11 18:11:24 +01:00
Bastien Guerry
c3a0dc11a3
org-table.el: Ensure table coordinates are correctly displayed when sorting.
...
* org-table.el (org-table-sort-lines): Ensure coordinates are
correctly displayed when sorting.
* org.el (org-do-sort): Enhance prompt.
2012-12-11 17:29:38 +01:00
Bastien Guerry
980e52282d
org-agenda.el (org-agenda-finalize): Fix order of link activation.
...
* org-agenda.el (org-agenda-finalize): Fix order of link
activation.
2012-12-11 17:20:33 +01:00
Bastien Guerry
08e411109e
org-agenda.el (org-agenda-finalize): Activate plain links.
...
* org-agenda.el (org-agenda-finalize): Activate plain links.
2012-12-11 17:08:00 +01:00
Bastien Guerry
57a13ab9d9
org-timer.el (org-timer-stop): Add message.
...
* org-timer.el (org-timer-stop): Add message.
2012-12-11 16:56:00 +01:00
Bastien Guerry
5d673e890a
org-agenda.el (org-agenda-schedule, org-agenda-deadline): Fix redundant messages.
...
* org-agenda.el (org-agenda-schedule, org-agenda-deadline):
Fix redundant messages.
2012-12-11 16:53:44 +01:00
Bastien Guerry
1a41eeae1d
org-agenda.el (org-agenda-finalize): Fix clock highlighting.
...
* org-agenda.el (org-agenda-finalize): Fix clock highlighting.
Thanks to Rares Pop who reported this.
2012-12-11 16:44:03 +01:00
Le Wang
8d22b11978
org-src: Fix org-edit-src-code for empty blocks and block with just an empty line
...
* lisp/org-src.el (org-edit-src-code): Use marker with insertion type
t to track end and remove hack requiring delete from beg to (1- end).
2012-11-30 14:19:27 +01:00
Nicolas Goaziou
89b8a8ca6d
org-element: Fix `org-element-context'
...
* lisp/org-element.el (org-element-context): When point is between two
objects, be sure to return the second one.
* testing/lisp/test-org-element.el: Add test.
2012-11-23 23:46:52 +01:00
Nicolas Goaziou
5dbccdb432
org-list: Fix infloop when inserting an item
...
* lisp/org-list.el (org-list-separating-blank-lines-number): When
computing number of blank lines separating items, also count those
in unparsed blocks, like example blocks.
* testing/lisp/test-org-list.el: Add tests.
In the following situation, with `org-blank-before-new-entry' set to
`auto' for `plain-list-item, a blank line should be inserted when
inserting the following item:
- item1
#+BEGIN_EXAMPLE
contents
#+END_EXAMPLE
2012-11-13 15:45:09 +01:00