Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to display the full context of the entries in org-mode agenda tree view

In org-mode's daily/weekly agenda view, is there a way to display the full context of the entries?

My reading of the code is that it finds the first heading above the timestamp and displays that. However, in my case, that heading is often 3-4 levels deep and doesn't make sense without the bullets above it. It also doesn't seem like there are hooks to easily change that. Filtering is trivial, but not changing the fundamental presentation format.

like image 873
Ray Avatar asked May 11 '10 00:05

Ray


2 Answers

There is no way to display all the context directly in the agenda view, but you can right click on the headline in agenda view and it will show you that headline in the main window in a sparse tree context.

You may have to collapse everything in the main window in order for the right-click-locating to show the sparse-tree view.

That seems pretty close to what you're looking for. To check, do this:

  1. Create desired agenda view.
  2. In main document window collapse everything to just first level headlines.
  3. Right-click on the desired headline in the agenda view. It should show the headline in sparse tree context in the main document window.

There are several things you can do to get better information about context in agenda views, short of using the right-click function described above.

First, you can arrange your headlines themselves so that they give you more context information. It would be possible, e.g., to have numerous 4th level headlines labeled 'Tasks', each which includes tasks related to the headings above in each tree. That's not going to give good context info in agenda view, though, since each line's headline text would be the same (i.e., 'Task') and have no info in context. A simple solution would simply be to make the headlines more specific, e.g., 'Project xxxx Tasks' and 'Project yyy Tasks'.

A different way of getting more context in agenda view would be by using 'categories'. The first column in agenda view is the filename containing the headline by default, but if the headline has a category the category will be shown. To assign a category to a headline and all of its subtree you can add a category property to the main headline, like this:

 :PROPERTIES:
  :CATEGORY:Project xxx Stuff
  :END:

Now agenda view will show 'Project xxx Stuff' in the first column for each of the agenda lines that are gathered from that headlines subtree.

like image 168
Herbert Sitz Avatar answered Oct 20 '22 01:10

Herbert Sitz


Follow-mode (S-f) gets pretty close to what the OP is looking for. Credit to @armando.sano in a comment on another answer.

like image 40
andytilia Avatar answered Oct 19 '22 23:10

andytilia