org-toggle-heading: Use buffer-local keyword settings when possible
* lisp/org.el (org-toggle-heading): Prefer `car' of `org-done-keywords' and `org-not-done-keywords' when converting checkboxes to TODO-keywords. Reported-by: autofrettage <autofrettage@protonmail.ch> Link: https://orgmode.org/list/87v91vle4u.fsf@gmail.com
This commit is contained in:
parent
1966a7a8a8
commit
fcd3817450
10
lisp/org.el
10
lisp/org.el
|
@ -17755,7 +17755,15 @@ number of stars to add."
|
|||
(org-list-to-lisp t)
|
||||
(pcase (org-current-level)
|
||||
(`nil 1)
|
||||
(l (1+ (org-reduced-level l)))))
|
||||
(l (1+ (org-reduced-level l))))
|
||||
;; Keywords to replace checkboxes.
|
||||
(list
|
||||
;; [X]
|
||||
:cbon (concat (or (car org-done-keywords) "DONE") " ")
|
||||
;; [ ]
|
||||
:cboff (concat (or (car org-not-done-keywords) "TODO") " ")
|
||||
;; [-]
|
||||
:cbtrans (concat (or (car org-not-done-keywords) "TODO") " ")))
|
||||
"\n")))
|
||||
(setq toggled t))
|
||||
(forward-line)))
|
||||
|
|
Loading…
Reference in New Issue