* Feature: Group and limit items in agenda
@ 2013-01-23 18:13 Muchenxuan Tong
2013-01-23 21:35 ` AW
2013-02-07 10:41 ` Bastien
0 siblings, 2 replies; 9+ messages in thread
From: Muchenxuan Tong @ 2013-01-23 18:13 UTC (permalink / raw)
To: emacs-orgmode
Hi everyone.
* Motivation
- Sacha Chua proposed a solution for viewing top three tasks by
context (http://sachachua.com/blog/2012/12/emacs-org-display-subset-tasks-context/)
- In the Next view in Things (http://culturedcode.com/), one is able
to setting to see only a limited numbers of top tasks of each project.
I find that it helps a lot for reducing stress by grouping and
limiting the number of tasks you see when reviewing. So I wrote some
code to get something similar to the Next view in Things. The concept
of project in Things is substituted with category in Emacs. See a
snapshot: http://d.pr/i/GXnx
For me this is enough. However, I wonder whether this could be useful
for others. The proposed feature is a general "group by and limit":
- In agenda view, you are able to group todo or agendas with a certain
criterion (category, tags..)
- You are able to restrict the items shown in this group. Optionally,
some special todo states could be unlimited. For example, I only want
to limit the number of TODO tasks, while seeing all the DONE tasks.
For others, maybe they want to see all the NEXT tasks, but limiting
the number of TODO tasks.
I wonder how many people would be interested in this feature.
Otherwise it would just be a waste of time to generalize my personal
taste.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-01-23 18:13 Feature: Group and limit items in agenda Muchenxuan Tong
@ 2013-01-23 21:35 ` AW
2013-02-07 10:41 ` Bastien
1 sibling, 0 replies; 9+ messages in thread
From: AW @ 2013-01-23 21:35 UTC (permalink / raw)
To: emacs-orgmode
>
> For me this is enough. However, I wonder whether this could be useful
> for others. The proposed feature is a general "group by and limit":
>
> - In agenda view, you are able to group todo or agendas with a certain
> criterion (category, tags..)
> - You are able to restrict the items shown in this group. Optionally,
> some special todo states could be unlimited. For example, I only want
> to limit the number of TODO tasks, while seeing all the DONE tasks.
> For others, maybe they want to see all the NEXT tasks, but limiting
> the number of TODO tasks.
>
> I wonder how many people would be interested in this feature.
> Otherwise it would just be a waste of time to generalize my personal
> taste.
This sounds like a good idea. I'd love to group my different tasks in the
agenda, instead of getting them sorted by due dates.
Regards,
Alexander
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-01-23 18:13 Feature: Group and limit items in agenda Muchenxuan Tong
2013-01-23 21:35 ` AW
@ 2013-02-07 10:41 ` Bastien
2013-02-11 5:10 ` Muchenxuan Tong
1 sibling, 1 reply; 9+ messages in thread
From: Bastien @ 2013-02-07 10:41 UTC (permalink / raw)
To: Muchenxuan Tong; +Cc: emacs-orgmode
Hi Muchenxuan,
Muchenxuan Tong <demon386@gmail.com> writes:
> * Motivation
> - Sacha Chua proposed a solution for viewing top three tasks by
> context (http://sachachua.com/blog/2012/12/emacs-org-display-subset-tasks-context/)
> - In the Next view in Things (http://culturedcode.com/), one is able
> to setting to see only a limited numbers of top tasks of each
> project.
Thanks for the pointers. From latest Org (master branch), you
can now use `org-agenda-max-entries' either as a global option,
or locally in each agenda view.
See the docstring on how to use this option and its friends:
org-agenda-max-effort
org-agenda-max-tags
org-agenda-max-todos
org-agenda-max-effort might be particularily useful in TODO views.
Let me know if this works for you.
As for "grouping", I think this is more about setting agenda views,
sorting options and agenda filters properly -- but I'm open to any
idea on how to improve this (or to make it easier to set.)
Thanks!
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-07 10:41 ` Bastien
@ 2013-02-11 5:10 ` Muchenxuan Tong
2013-02-11 13:42 ` Bastien
0 siblings, 1 reply; 9+ messages in thread
From: Muchenxuan Tong @ 2013-02-11 5:10 UTC (permalink / raw)
To: Bastien; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1670 bytes --]
Thanks for the new feature. I tried and it works well for what it intended
to do. However, I still haven't found a way to do the kind of things I
mentioned.
My intention is to limit the number of tasks in each category. For the new
proposed 'org-agenda-max-todos', I can only limit the number of TODOs in
the whole TODO lists.
Maybe for what I want, it's desirable to add a auto-split or auto-group
features, where a list of TODOs, can be split further into multiple lists
of TODOs, by a certain criteria (tags, category).
What do you think about it?
On Thu, Feb 7, 2013 at 6:41 PM, Bastien <bzg@altern.org> wrote:
> Hi Muchenxuan,
>
> Muchenxuan Tong <demon386@gmail.com> writes:
>
> > * Motivation
> > - Sacha Chua proposed a solution for viewing top three tasks by
> > context (
> http://sachachua.com/blog/2012/12/emacs-org-display-subset-tasks-context/)
> > - In the Next view in Things (http://culturedcode.com/), one is able
> > to setting to see only a limited numbers of top tasks of each
> > project.
>
> Thanks for the pointers. From latest Org (master branch), you
> can now use `org-agenda-max-entries' either as a global option,
> or locally in each agenda view.
>
> See the docstring on how to use this option and its friends:
>
> org-agenda-max-effort
> org-agenda-max-tags
> org-agenda-max-todos
>
> org-agenda-max-effort might be particularily useful in TODO views.
>
> Let me know if this works for you.
>
> As for "grouping", I think this is more about setting agenda views,
> sorting options and agenda filters properly -- but I'm open to any
> idea on how to improve this (or to make it easier to set.)
>
> Thanks!
>
> --
> Bastien
>
[-- Attachment #2: Type: text/html, Size: 2980 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-11 5:10 ` Muchenxuan Tong
@ 2013-02-11 13:42 ` Bastien
2013-02-17 6:29 ` Muchenxuan Tong
0 siblings, 1 reply; 9+ messages in thread
From: Bastien @ 2013-02-11 13:42 UTC (permalink / raw)
To: Muchenxuan Tong; +Cc: emacs-orgmode
Hi Muchenxuan,
Muchenxuan Tong <demon386@gmail.com> writes:
> My intention is to limit the number of tasks in each category.
Did you check (info "(org)Block Agenda") ?
That's the way I would suggest: define a block agenda listing
the various categories, then use `org-agenda-max-todos' in each
of them to limit the number of TODOs.
> For the new proposed 'org-agenda-max-todos', I can only limit the
> number of TODOs in the whole TODO lists.
>
> Maybe for what I want, it's desirable to add a auto-split or
> auto-group features, where a list of TODOs, can be split further into
> multiple lists of TODOs, by a certain criteria (tags, category).
>
> What do you think about it?
I understand defining block agendas is not as straightforward than the
solution you envision, but my feeling is that allowing grouping+limits
will have too much overlap with the block agenda functionality.
Let me know if you find the path to happiness with a combinaison of
block agendas and the new variables.
Thanks,
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-11 13:42 ` Bastien
@ 2013-02-17 6:29 ` Muchenxuan Tong
2013-02-23 9:58 ` Bastien
0 siblings, 1 reply; 9+ messages in thread
From: Muchenxuan Tong @ 2013-02-17 6:29 UTC (permalink / raw)
To: Bastien; +Cc: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 1976 bytes --]
Yes I understand your point. However, setting TODO for each category
manually would be laborious in my situation, I have to adjust the
configuration file each time I add/delete the project.
For my implementation, I advice on function 'org-agenda-finalize-entries'
to put lists into different groups, limit them and add separator after the
line '(setq list (mapcar 'org-agenda-highlight-todo list))'
There's a 'org-agenda-before-sorting-filter-function' variable. However,
I'm not able to use it for grouping things, because it's used as '(mapcar
org-agenda-before-sorting-filter-function list)'
Would it be useful to add another function here, not used in 'mapcar', but
work directly on the whole list? I don't know whether it is worthy, and I'm
OK if that's not general enough to be added, because I can use defadvice
anyway :)
On Mon, Feb 11, 2013 at 9:42 PM, Bastien <bzg@altern.org> wrote:
> Hi Muchenxuan,
>
> Muchenxuan Tong <demon386@gmail.com> writes:
>
> > My intention is to limit the number of tasks in each category.
>
> Did you check (info "(org)Block Agenda") ?
>
> That's the way I would suggest: define a block agenda listing
> the various categories, then use `org-agenda-max-todos' in each
> of them to limit the number of TODOs.
>
> > For the new proposed 'org-agenda-max-todos', I can only limit the
> > number of TODOs in the whole TODO lists.
> >
> > Maybe for what I want, it's desirable to add a auto-split or
> > auto-group features, where a list of TODOs, can be split further into
> > multiple lists of TODOs, by a certain criteria (tags, category).
> >
> > What do you think about it?
>
> I understand defining block agendas is not as straightforward than the
> solution you envision, but my feeling is that allowing grouping+limits
> will have too much overlap with the block agenda functionality.
>
> Let me know if you find the path to happiness with a combinaison of
> block agendas and the new variables.
>
> Thanks,
>
> --
> Bastien
>
[-- Attachment #2: Type: text/html, Size: 2777 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-17 6:29 ` Muchenxuan Tong
@ 2013-02-23 9:58 ` Bastien
2013-02-24 20:23 ` Samuel Wales
0 siblings, 1 reply; 9+ messages in thread
From: Bastien @ 2013-02-23 9:58 UTC (permalink / raw)
To: Muchenxuan Tong; +Cc: emacs-orgmode
Hi Muchenxuan,
Muchenxuan Tong <demon386@gmail.com> writes:
> There's a 'org-agenda-before-sorting-filter-function' variable.
> However, I'm not able to use it for grouping things, because it's
> used as '(mapcar org-agenda-before-sorting-filter-function list)'
>
> Would it be useful to add another function here, not used in
> 'mapcar', but work directly on the whole list? I don't know whether
> it is worthy, and I'm OK if that's not general enough to be added,
> because I can use defadvice anyway :)
Well, I guess you don't want the grouping to take place *before* the
sorting, as the sorting may destroy it, so a defadvice is the way to
go here I'd say. If your defadvice can be useful for others, please
consider adding it to Worg! (Just send me your public key and I'll
give you write access to Worg.)
Thanks,
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-23 9:58 ` Bastien
@ 2013-02-24 20:23 ` Samuel Wales
2013-02-25 9:50 ` Bastien
0 siblings, 1 reply; 9+ messages in thread
From: Samuel Wales @ 2013-02-24 20:23 UTC (permalink / raw)
To: Bastien; +Cc: emacs-orgmode, Muchenxuan Tong
One other use here is to show a small random sample of your tasks
without affecting speed.
In before sorting filter function, set a pseudorandom number (biased
according to a distribution of your choice) on a text property. You
can set some to appear always.
In the mapcar function, use user-defined sorting to sort according to
the numbers and limit to just the first 5.
Can defadvice be relied on to keep working in future versions of Org?
On 2/23/13, Bastien <bzg@altern.org> wrote:
> Hi Muchenxuan,
>
> Muchenxuan Tong <demon386@gmail.com> writes:
>
>> There's a 'org-agenda-before-sorting-filter-function' variable.
>> However, I'm not able to use it for grouping things, because it's
>> used as '(mapcar org-agenda-before-sorting-filter-function list)'
>>
>> Would it be useful to add another function here, not used in
>> 'mapcar', but work directly on the whole list? I don't know whether
>> it is worthy, and I'm OK if that's not general enough to be added,
>> because I can use defadvice anyway :)
>
> Well, I guess you don't want the grouping to take place *before* the
> sorting, as the sorting may destroy it, so a defadvice is the way to
> go here I'd say. If your defadvice can be useful for others, please
> consider adding it to Worg! (Just send me your public key and I'll
> give you write access to Worg.)
>
> Thanks,
>
> --
> Bastien
>
>
--
The Kafka Pandemic: http://thekafkapandemic.blogspot.com
The disease DOES progress. MANY people have died from it. ANYBODY
can get it. There is no hope without action.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Feature: Group and limit items in agenda
2013-02-24 20:23 ` Samuel Wales
@ 2013-02-25 9:50 ` Bastien
0 siblings, 0 replies; 9+ messages in thread
From: Bastien @ 2013-02-25 9:50 UTC (permalink / raw)
To: Samuel Wales; +Cc: emacs-orgmode, Muchenxuan Tong
Hi Samuel,
Samuel Wales <samologist@gmail.com> writes:
> One other use here is to show a small random sample of your tasks
> without affecting speed.
>
> In before sorting filter function, set a pseudorandom number (biased
> according to a distribution of your choice) on a text property. You
> can set some to appear always.
>
> In the mapcar function, use user-defined sorting to sort according to
> the numbers and limit to just the first 5.
Yes, this is a nice use of `org-agenda-before-sorting-filter-function'.
> Can defadvice be relied on to keep working in future versions of Org?
As much as possible, yes.
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2013-02-25 9:50 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-23 18:13 Feature: Group and limit items in agenda Muchenxuan Tong
2013-01-23 21:35 ` AW
2013-02-07 10:41 ` Bastien
2013-02-11 5:10 ` Muchenxuan Tong
2013-02-11 13:42 ` Bastien
2013-02-17 6:29 ` Muchenxuan Tong
2013-02-23 9:58 ` Bastien
2013-02-24 20:23 ` Samuel Wales
2013-02-25 9:50 ` Bastien
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).