I use org-mode to handle my tasks and projects in multiple files.
On the weekly agenda, you can navigate to the location of each TODO entry using <TAB> or <RET> . If the target file was not previously opened, it is loaded, the cursor is positioned on the correct header, and the entire document is expanded, including mailboxes.
I would really like to see only a rare tree with everything except the correct addition of the title (the visibility of the subtree does not matter).
You can collapse the whole tree cyclically using global visibility using Cu <TAB , but then I need to find the title again.
I know that I can hide the rest by narrowing the buffer, as described here: Emacs, how can I display only the current task and hide others in org-mode? but then I lose context (parent title, easy access to siblings) and the boxes are still open.
Ideally, I would like to have a team that shows the following:
- Top Level Headers
- Current title and all its parents to the top level
- Current kids title
Edit:
The small modified version of user3173715 functions seems to do the trick:
(defun org-show-current-heading-tidily () "Show next entry, keeping other entries closed." (if (save-excursion (end-of-line) (outline-invisible-p)) (progn (org-show-entry) (show-children)) (outline-back-to-heading) (unless (and (bolp) (org-on-heading-p)) (org-up-heading-safe) (hide-subtree) (error "Boundary reached")) (org-overview) (org-reveal t) (org-show-entry) (show-children)))
source share