Function: todo-toggle-view-done-items
todo-toggle-view-done-items is an interactive and byte-compiled
function defined in todo-mode.el.gz.
Signature
(todo-toggle-view-done-items)
Documentation
Show hidden or hide visible done items in current category.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/calendar/todo-mode.el.gz
(defun todo-toggle-view-done-items ()
"Show hidden or hide visible done items in current category."
(interactive)
(if (zerop (todo-get-count 'done (todo-current-category)))
(message "There are no done items in this category.")
(let ((opoint (point)))
(goto-char (point-min))
(let* ((shown (re-search-forward todo-done-string-start nil t))
(todo-show-with-done (not shown)))
(todo-category-select)
(goto-char opoint)
;; If start of done items sections is below the bottom of the
;; window, make it visible.
(unless shown
(setq shown (progn
(goto-char (point-min))
(re-search-forward todo-done-string-start nil t)))
(if (pos-visible-in-window-p shown)
(goto-char opoint)
(recenter)
(if transient-mark-mode (deactivate-mark))))))))