mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-08-25 13:02:51 +00:00
Merge branch 'maint'
This commit is contained in:
commit
6ed60a797a
27
lisp/org.el
27
lisp/org.el
|
@ -14952,16 +14952,27 @@ When JUST-ALIGN is non-nil, only align tags."
|
|||
(if just-align current
|
||||
;; Get a new set of tags from the user.
|
||||
(save-excursion
|
||||
(let* ((table
|
||||
(let* ((seen)
|
||||
(table
|
||||
(setq
|
||||
org-last-tags-completion-table
|
||||
(delete-dups
|
||||
(append
|
||||
(or org-current-tag-alist (org-get-buffer-tags))
|
||||
(and
|
||||
org-complete-tags-always-offer-all-agenda-tags
|
||||
(org-global-tags-completion-table
|
||||
(org-agenda-files)))))))
|
||||
;; Uniquify tags in alists, yet preserve
|
||||
;; structure (i.e., keywords).
|
||||
(delq nil
|
||||
(mapcar
|
||||
(lambda (pair)
|
||||
(let ((head (car pair)))
|
||||
(cond ((symbolp head) pair)
|
||||
((member head seen) nil)
|
||||
(t (push head seen)
|
||||
pair))))
|
||||
(append
|
||||
(or org-current-tag-alist
|
||||
(org-get-buffer-tags))
|
||||
(and
|
||||
org-complete-tags-always-offer-all-agenda-tags
|
||||
(org-global-tags-completion-table
|
||||
(org-agenda-files))))))))
|
||||
(current-tags (org-split-string current ":"))
|
||||
(inherited-tags
|
||||
(nreverse (nthcdr (length current-tags)
|
||||
|
|
Loading…
Reference in a new issue