Function: org-agenda-show-1

org-agenda-show-1 is an interactive and byte-compiled function defined in org-agenda.el.gz.

Signature

(org-agenda-show-1 &optional MORE)

Documentation

Display the Org file which contains the item at point.

The prefix arg selects the amount of information to display:

0 hide the subtree
1 just show the entry according to defaults.
2 show the children view
3 show the subtree view
4 show the entire subtree and any drawers
With prefix argument FULL-ENTRY, make the entire entry visible if it was hidden in the outline.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/org/org-agenda.el.gz
(defun org-agenda-show-1 (&optional more)
  "Display the Org file which contains the item at point.
The prefix arg selects the amount of information to display:

0   hide the subtree
1   just show the entry according to defaults.
2   show the children view
3   show the subtree view
4   show the entire subtree and any drawers
With prefix argument FULL-ENTRY, make the entire entry visible
if it was hidden in the outline."
  (interactive "p")
  (let ((win (selected-window)))
    (org-agenda-goto t)
    (org-back-to-heading)
    (set-window-start (selected-window) (line-beginning-position))
    (cond
     ((= more 0)
      (org-fold-subtree t)
      (save-excursion
	(org-back-to-heading)
	(run-hook-with-args 'org-cycle-hook 'folded))
      (message "Remote: FOLDED"))
     ((and (called-interactively-p 'any) (= more 1))
      (message "Remote: show with default settings"))
     ((= more 2)
      (org-fold-show-entry 'hide-drawers)
      (org-fold-show-children)
      (save-excursion
	(org-back-to-heading)
	(run-hook-with-args 'org-cycle-hook 'children))
      (message "Remote: CHILDREN"))
     ((= more 3)
      (org-fold-show-subtree)
      (save-excursion
	(org-back-to-heading)
	(run-hook-with-args 'org-cycle-hook 'subtree))
      (message "Remote: SUBTREE"))
     ((> more 3)
      (org-fold-show-subtree)
      (message "Remote: SUBTREE AND ALL DRAWERS")))
    (select-window win)))