Function: todo-category-select

todo-category-select is a byte-compiled function defined in otodo-mode.el.gz.

Signature

(todo-category-select)

Documentation

Make TODO mode display the current category correctly.

Aliases

todo-cat-slct

Source Code

;; Defined in /usr/src/emacs/lisp/obsolete/otodo-mode.el.gz
;; ---------------------------------------------------------------------------

(defun todo-category-select ()
  "Make TODO mode display the current category correctly."
  (let ((name (nth todo-category-number todo-categories)))
    (setq mode-line-buffer-identification
;;          (concat "Category: " name))
          (concat "Category: " (format "%18s" name)))
    (widen)
    (goto-char (point-min))
    (search-forward-regexp
     (concat "^"
             (regexp-quote (concat todo-prefix todo-category-beg name))
             "$"))
    (let ((begin (1+ (line-end-position))))
      (search-forward-regexp (concat "^" todo-category-end))
      (narrow-to-region begin (line-beginning-position))
      (goto-char (point-min)))))