summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2012-10-26 15:12:02 +0200
committerBastien Guerry <bzg@altern.org>2012-10-26 15:12:02 +0200
commit8866f86624b0737e3f9052be7582b51330e2365b (patch)
tree0edb7bcbf7239c8a3ba5e0cac2ece204346482d6
parentb5aded108df66f1ddb13a2caace65c3a823fcb77 (diff)
parent7a9d3457073ce60670d0d0a02cbfcb9c34e9794b (diff)
downloadorg-mode-8866f86624b0737e3f9052be7582b51330e2365b.tar.gz
Merge branch 'maint'
-rw-r--r--contrib/lisp/org-contacts.el1
-rw-r--r--lisp/ob-haskell.el2
-rw-r--r--lisp/org-agenda.el3
-rw-r--r--lisp/org-capture.el3
-rw-r--r--lisp/org-clock.el2
-rw-r--r--lisp/org-latex.el32
-rw-r--r--lisp/org.el6
7 files changed, 25 insertions, 24 deletions
diff --git a/contrib/lisp/org-contacts.el b/contrib/lisp/org-contacts.el
index bc52648..30b9ed0 100644
--- a/contrib/lisp/org-contacts.el
+++ b/contrib/lisp/org-contacts.el
@@ -42,6 +42,7 @@
(eval-and-compile
(require 'org))
(require 'gnus-util)
+(require 'org-agenda)
(defgroup org-contacts nil
"Options concerning contacts management."
diff --git a/lisp/ob-haskell.el b/lisp/ob-haskell.el
index 7f43faf..03972ef 100644
--- a/lisp/ob-haskell.el
+++ b/lisp/ob-haskell.el
@@ -148,7 +148,7 @@ specifying a variable of the same value."
(defvar org-src-preserve-indentation)
(declare-function org-export-as-latex "org-latex"
- (arg &optional hidden ext-plist to-buffer body-only pub-dir))
+ (arg &optional ext-plist to-buffer body-only pub-dir))
(defun org-babel-haskell-export-to-lhs (&optional arg)
"Export to a .lhs file with all haskell code blocks escaped.
When called with a prefix argument the resulting
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 08066d2..fbe5cc1 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -5482,7 +5482,8 @@ Do we have a reason to ignore this TODO entry because it has a time stamp?
tags (save-excursion (org-backward-heading-same-level 0)
(org-get-tags-at))
todo-state (org-get-todo-state)
- warntime (org-entry-get (point) "APPT_WARNTIME"))
+ warntime (org-entry-get (point) "APPT_WARNTIME")
+ extra nil)
(dolist (r (if (stringp result)
(list result)
diff --git a/lisp/org-capture.el b/lisp/org-capture.el
index be973b0..1dfffc6 100644
--- a/lisp/org-capture.el
+++ b/lisp/org-capture.el
@@ -1250,7 +1250,8 @@ Of course, if exact position has been required, just put it there."
(save-restriction
(widen)
(goto-char pos)
- (bookmark-set "org-capture-last-stored")
+ (with-demoted-errors
+ (bookmark-set "org-capture-last-stored"))
(move-marker org-capture-last-stored-marker (point)))))))
(defun org-capture-narrow (beg end)
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index e5488e4..84eb2fd 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -1149,7 +1149,6 @@ make this the default behavior.)"
(if (and (eobp) (not (org-at-heading-p)))
(point-at-bol 0)
(point)))
- (run-hooks 'org-clock-in-prepare-hook)
(save-excursion
(when (and selected-task (marker-buffer selected-task))
;; There is a selected task, move to the correct buffer
@@ -1168,6 +1167,7 @@ make this the default behavior.)"
;; beginning of the heading, since the
;; user is liking to insert stuff here
;; manually
+ (run-hooks 'org-clock-in-prepare-hook)
(org-clock-history-push))
(org-clock-set-current)
(cond ((functionp org-clock-in-switch-to-state)
diff --git a/lisp/org-latex.el b/lisp/org-latex.el
index d7d18ca..9ce84f1 100644
--- a/lisp/org-latex.el
+++ b/lisp/org-latex.el
@@ -787,14 +787,14 @@ emacs --batch
--load=$HOME/lib/emacs/org.el
--eval \"(setq org-export-headline-levels 2)\"
--visit=MyFile --funcall org-export-as-latex-batch"
- (org-export-as-latex org-export-headline-levels 'hidden))
+ (org-export-as-latex org-export-headline-levels))
;;;###autoload
(defun org-export-as-latex-to-buffer (arg)
"Call `org-export-as-latex` with output to a temporary buffer.
No file is created. The prefix ARG is passed through to `org-export-as-latex'."
(interactive "P")
- (org-export-as-latex arg nil nil "*Org LaTeX Export*")
+ (org-export-as-latex arg nil "*Org LaTeX Export*")
(when org-export-show-temporary-export-buffer
(switch-to-buffer-other-window "*Org LaTeX Export*")))
@@ -848,7 +848,7 @@ in a window. A non-interactive call will only return the buffer."
(set-mark (point)) ;; to activate the region
(goto-char beg)
(setq rtn (org-export-as-latex
- nil nil ext-plist
+ nil ext-plist
buffer body-only))
(if (fboundp 'deactivate-mark) (deactivate-mark))
(if (and (org-called-interactively-p 'any) (bufferp rtn))
@@ -856,21 +856,19 @@ in a window. A non-interactive call will only return the buffer."
rtn)))
;;;###autoload
-(defun org-export-as-latex (arg &optional hidden ext-plist
- to-buffer body-only pub-dir)
+(defun org-export-as-latex (arg &optional ext-plist to-buffer body-only pub-dir)
"Export current buffer to a LaTeX file.
If there is an active region, export only the region. The prefix
ARG specifies how many levels of the outline should become
headlines. The default is 3. Lower levels will be exported
depending on `org-export-latex-low-levels'. The default is to
convert them as description lists.
-HIDDEN is obsolete and does nothing.
-EXT-PLIST is a property list with
-external parameters overriding org-mode's default settings, but
-still inferior to file-local settings. When TO-BUFFER is
-non-nil, create a buffer with that name and export to that
-buffer. If TO-BUFFER is the symbol `string', don't leave any
-buffer behind but just return the resulting LaTeX as a string.
+EXT-PLIST is a property list with external parameters overriding
+org-mode's default settings, but still inferior to file-local settings.
+When TO-BUFFER is non-nil, create a buffer with that name and export
+to that buffer. If TO-BUFFER is the symbol `string', don't leave any
+buffer behind and just return the resulting LaTeX as a string, with
+no LaTeX header.
When BODY-ONLY is set, don't produce the file header and footer,
simply return the content of \\begin{document}...\\end{document},
without even the \\begin{document} and \\end{document} commands.
@@ -957,10 +955,9 @@ when PUB-DIR is set, use this as the publishing directory."
(auto-insert nil); Avoid any auto-insert stuff for the new file
(TeX-master (boundp 'TeX-master))
(buffer (if to-buffer
- (cond
- ((eq to-buffer 'string) (get-buffer-create
- "*Org LaTeX Export*"))
- (t (get-buffer-create to-buffer)))
+ (if (eq to-buffer 'string)
+ (get-buffer-create "*Org LaTeX Export*")
+ (get-buffer-create to-buffer))
(find-file-noselect filename)))
(odd org-odd-levels-only)
(header (org-export-latex-make-header title opt-plist))
@@ -1120,8 +1117,7 @@ when PUB-DIR is set, use this as the publishing directory."
(interactive "P")
(message "Exporting to PDF...")
(let* ((wconfig (current-window-configuration))
- (lbuf (org-export-as-latex arg hidden ext-plist
- to-buffer body-only pub-dir))
+ (lbuf (org-export-as-latex arg ext-plist to-buffer body-only pub-dir))
(file (buffer-file-name lbuf))
(base (file-name-sans-extension (buffer-file-name lbuf)))
(pdffile (concat base ".pdf"))
diff --git a/lisp/org.el b/lisp/org.el
index a1b6692..4e79125 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -10967,11 +10967,13 @@ prefix argument (`C-u C-u C-u C-c C-w')."
(and org-auto-align-tags
(let ((org-loop-over-headlines-in-active-region nil))
(org-set-tags nil t)))
- (bookmark-set "org-refile-last-stored")
+ (with-demoted-errors
+ (bookmark-set "org-refile-last-stored"))
;; If we are refiling for capture, make sure that the
;; last-capture pointers point here
(when (org-bound-and-true-p org-refile-for-capture)
- (bookmark-set "org-capture-last-stored-marker")
+ (with-demoted-errors
+ (bookmark-set "org-capture-last-stored-marker"))
(move-marker org-capture-last-stored-marker (point)))
(if (fboundp 'deactivate-mark) (deactivate-mark))
(run-hooks 'org-after-refile-insert-hook))))