forked from mirrors/org-mode
Merge branch 'maint'
org-bbdb in master already contained declare-function for external bbdb-functions. Conflicts: lisp/org-bbdb.el
This commit is contained in:
commit
21c7ad67cf
|
@ -5889,8 +5889,18 @@ could bind the variable in the options section of a custom command.")
|
|||
(let ((pl (text-property-any 0 (length x) 'org-heading t x)))
|
||||
(setq re (get-text-property 0 'org-todo-regexp x))
|
||||
(when (and re
|
||||
;; Test `pl' because if there's no heading content,
|
||||
;; there's no point matching to highlight. Note
|
||||
;; that if we didn't test `pl' first, and there
|
||||
;; happened to be no keyword from `org-todo-regexp'
|
||||
;; on this heading line, then the `equal' comparison
|
||||
;; afterwards would spuriously succeed in the case
|
||||
;; where `pl' is nil -- causing an args-out-of-range
|
||||
;; error when we try to add text properties to text
|
||||
;; that isn't there.
|
||||
pl
|
||||
(equal (string-match (concat "\\(\\.*\\)" re "\\( +\\)")
|
||||
x (or pl 0)) pl))
|
||||
x pl) pl))
|
||||
(add-text-properties
|
||||
(or (match-end 1) (match-end 0)) (match-end 0)
|
||||
(list 'face (org-get-todo-face (match-string 2 x)))
|
||||
|
|
|
@ -112,11 +112,9 @@
|
|||
(&optional dont-check-disk already-in-db-buffer))
|
||||
(declare-function bbdb-split "ext:bbdb" (string separators))
|
||||
(declare-function bbdb-string-trim "ext:bbdb" (string))
|
||||
(declare-function bbdb-record-get-field "ext:bbdb"
|
||||
(fn file &optional arglist fileonly))
|
||||
;; These two functions below are part of BBDB3:
|
||||
(declare-function bbdb-search-name "ext:bbdb" (regexp &optional layout))
|
||||
(declare-function bbdb-search-organization "ext:bbdb" (regexp &optional layout))
|
||||
(declare-function bbdb-record-get-field "ext:bbdb" (record field))
|
||||
(declare-function bbdb-search-name "ext:bbdb-com" (regexp &optional layout))
|
||||
(declare-function bbdb-search-organization "ext:bbdb-com" (regexp &optional layout))
|
||||
|
||||
(declare-function calendar-leap-year-p "calendar" (year))
|
||||
(declare-function diary-ordinal-suffix "diary-lib" (n))
|
||||
|
@ -228,10 +226,10 @@ italicized, in all other cases it is left unchanged."
|
|||
(let ((inhibit-redisplay (not debug-on-error))
|
||||
(bbdb-electric-p nil))
|
||||
(if (fboundp 'bbdb-name)
|
||||
(org-bbdb-open-old)
|
||||
(org-bbdb-open-new))))
|
||||
(org-bbdb-open-old name)
|
||||
(org-bbdb-open-new name))))
|
||||
|
||||
(defun org-bbdb-open-old ()
|
||||
(defun org-bbdb-open-old (name)
|
||||
(catch 'exit
|
||||
;; Exact match on name
|
||||
(bbdb-name (concat "\\`" name "\\'") nil)
|
||||
|
@ -251,7 +249,7 @@ italicized, in all other cases it is left unchanged."
|
|||
(delete-window (get-buffer-window "*BBDB*"))
|
||||
(error "No matching BBDB record"))))
|
||||
|
||||
(defun org-bbdb-open-new ()
|
||||
(defun org-bbdb-open-new (name)
|
||||
(catch 'exit
|
||||
;; Exact match on name
|
||||
(bbdb-search-name (concat "\\`" name "\\'") nil)
|
||||
|
|
|
@ -7948,7 +7948,7 @@ the following will happen:
|
|||
repeater intact.
|
||||
- the start days in the repeater in the original entry will be shifted
|
||||
to past the last clone.
|
||||
I this way you can spell out a number of instances of a repeating task,
|
||||
In this way you can spell out a number of instances of a repeating task,
|
||||
and still retain the repeater to cover future instances of the task."
|
||||
(interactive "nNumber of clones to produce: \nsDate shift per clone (e.g. +1w, empty to copy unchanged): ")
|
||||
(let (beg end template task idprop
|
||||
|
@ -7975,7 +7975,7 @@ and still retain the repeater to cover future instances of the task."
|
|||
(setq end (point))
|
||||
(setq template (buffer-substring beg end))
|
||||
(when (and doshift
|
||||
(string-match "<[^<>\n]+ \\+[0-9]+[dwmy][^<>\n]*>" template))
|
||||
(string-match "<[^<>\n]+ [.+]?\\+[0-9]+[dwmy][^<>\n]*>" template))
|
||||
(delete-region beg end)
|
||||
(setq end beg)
|
||||
(setq nmin 0 nmax (1+ nmax) n-no-remove nmax))
|
||||
|
@ -8006,7 +8006,7 @@ and still retain the repeater to cover future instances of the task."
|
|||
(while (re-search-forward org-ts-regexp nil t)
|
||||
(save-excursion
|
||||
(goto-char (match-beginning 0))
|
||||
(if (looking-at "<[^<>\n]+\\( +\\+[0-9]+[dwmy]\\)")
|
||||
(if (looking-at "<[^<>\n]+\\( +[.+]?\\+[0-9]+[dwmy]\\)")
|
||||
(delete-region (match-beginning 1) (match-end 1)))))))
|
||||
(setq task (buffer-string)))
|
||||
(insert task))
|
||||
|
|
Loading…
Reference in a new issue