emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* switching between todo groups
@ 2007-11-02  0:51 Richard G Riley
  2007-11-02 14:53 ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-02  0:51 UTC (permalink / raw)
  To: org-mode


I have

#+SEQ_TODO: TODO(t) WAITING(w@) INPROGRESS(p@) | DONE(d) CANCELLED(x@) DELEGATED(l@)
#+SEQ_TODO: TODO(t) | DONE(d)


but C-S-right doesn't switch to the new group. The status
line however shows it stays in "group 1/2" but I cant get it into group
2.

The documentation states that its better to have all different keywords.

If I dont have a same keyword

#+SEQ_TODO: TODO(t) WAITING(w@) INPROGRESS(p@) | DONE(d) CANCELLED(x@) DELEGATED(l@)
#+SEQ_TODO: apple(a) | orange(d)

it works as documented.

Will it be possible to have same state names in different groups at some
stage? e.g Most "Subsequence" (to use a word from the info file) would
have a Done state I would think.

Version 5.13h

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02 14:53 ` Bastien
@ 2007-11-02 14:16   ` Richard G Riley
  2007-11-02 15:49     ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-02 14:16 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>> Will it be possible to have same state names in different groups at
>> some stage? e.g Most "Subsequence" (to use a word from the info file)
>> would have a Done state I would think.
>
> Actually, you can already switch between sets of keywords if their
> *first* element is different.
>
> But imagine this:
>
> Seq1: k1 k2 k3 | k0
> Seq2: ka k1 kb kc | k0
>
> If a headline starts with k1, how Org would know what should be the next
> logical keyword?  k2 or kb?  For now, it uses k2, ignoring Seq2.

Occam's razor. Simplest solution. The first one unless the user selects
the second group and this is "remembered" in memory for the duration of
the session or the user changes it again. Certainly better than showing
two groups but only allowing selection of first group.

>
> This problem is not *that* fundamental when two sequences share the same
> k0 state, because it's more likely that this state won't change.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02  0:51 switching between todo groups Richard G Riley
@ 2007-11-02 14:53 ` Bastien
  2007-11-02 14:16   ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-02 14:53 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

> Will it be possible to have same state names in different groups at
> some stage? e.g Most "Subsequence" (to use a word from the info file)
> would have a Done state I would think.

Actually, you can already switch between sets of keywords if their
*first* element is different.

But imagine this:

Seq1: k1 k2 k3 | k0
Seq2: ka k1 kb kc | k0

If a headline starts with k1, how Org would know what should be the next
logical keyword?  k2 or kb?  For now, it uses k2, ignoring Seq2.

This problem is not *that* fundamental when two sequences share the same
k0 state, because it's more likely that this state won't change.

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02 15:49     ` Bastien
@ 2007-11-02 15:05       ` Richard G Riley
  2007-11-02 17:38         ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-02 15:05 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>>> Seq1: k1 k2 k3 | k0
>>> Seq2: ka k1 kb kc | k0
>>>
>>> If a headline starts with k1, how Org would know what should be the next
>>> logical keyword?  k2 or kb?  For now, it uses k2, ignoring Seq2.
>>
>> Occam's razor. Simplest solution. The first one unless the user selects
>> the second group and this is "remembered" in memory for the duration of
>> the session or the user changes it again. Certainly better than showing
>> two groups but only allowing selection of first group.
>
> Mh... how do you "remember" what set you're using for en entry?  

I don't know the details of the elisp but I assume that for one open
file there is a "current sequence" variable? It is initialised to the
first.

It is only to be remembered for the life of the session.

>
> Even if we imagine some internal mechanism to keep track of sets
> changes, how do the user knows what is the current set in use for
> a headline, if its TODO keyword belongs to several sets? 

He knows because he set it. If he is unsure he can just loop around back
with the status showing which is the current sequence group-

>
> Should this be "remembered" between emacs sessions as well??
>

I am not suggesting anything is remembered between sessions.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02 14:16   ` Richard G Riley
@ 2007-11-02 15:49     ` Bastien
  2007-11-02 15:05       ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-02 15:49 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

>> Seq1: k1 k2 k3 | k0
>> Seq2: ka k1 kb kc | k0
>>
>> If a headline starts with k1, how Org would know what should be the next
>> logical keyword?  k2 or kb?  For now, it uses k2, ignoring Seq2.
>
> Occam's razor. Simplest solution. The first one unless the user selects
> the second group and this is "remembered" in memory for the duration of
> the session or the user changes it again. Certainly better than showing
> two groups but only allowing selection of first group.

Mh... how do you "remember" what set you're using for en entry?  

Even if we imagine some internal mechanism to keep track of sets
changes, how do the user knows what is the current set in use for
a headline, if its TODO keyword belongs to several sets? 

Should this be "remembered" between emacs sessions as well??

...

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02 15:05       ` Richard G Riley
@ 2007-11-02 17:38         ` Bastien
  2007-11-03 13:10           ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-02 17:38 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

>> Mh... how do you "remember" what set you're using for en entry?  
>
> I don't know the details of the elisp but I assume that for one open
> file there is a "current sequence" variable? It is initialised to the
> first.

`org-todo-sets' is buffer-local and is a list of keywords sets.

AFAIK there is no variable identifying the "current sequence". 

And I don't know if such a variable would be useful, because the
"current sequence" has no sense outside each specific headline.

BTW, having slightly different keywords could be a temporary
workaround.  What about:

  #+SEQ_TODO: TODO_1 | DONE_1
  #+SEQ_TODO: TODO_2 NEXT WAITING | DONE_2

> It is only to be remembered for the life of the session.

I think I need an example to see how such a piece of information could
be used...  can you provide one?

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-02 17:38         ` Bastien
@ 2007-11-03 13:10           ` Richard G Riley
  2007-11-03 14:23             ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-03 13:10 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>>> Mh... how do you "remember" what set you're using for en entry?  
>>
>> I don't know the details of the elisp but I assume that for one open
>> file there is a "current sequence" variable? It is initialised to the
>> first.
>
> `org-todo-sets' is buffer-local and is a list of keywords sets.
>
> AFAIK there is no variable identifying the "current sequence". 
>
> And I don't know if such a variable would be useful, because the
> "current sequence" has no sense outside each specific headline.
>
> BTW, having slightly different keywords could be a temporary
> workaround.  What about:
>
>   #+SEQ_TODO: TODO_1 | DONE_1
>   #+SEQ_TODO: TODO_2 NEXT WAITING | DONE_2
>
>> It is only to be remembered for the life of the session.
>
> I think I need an example to see how such a piece of information could
> be used...  can you provide one?

I'm not sure I understand.

I set the todo sequence for a particular task and it remembers, for the
life of the session, which is the sequence in use for that task. Nothing
more, nothing less and not very, very important, just "nice". Reason? I
want "Done", "Cancelled" on all or most sequences.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 14:23             ` Bastien
@ 2007-11-03 13:43               ` Richard G Riley
  2007-11-03 14:59                 ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-03 13:43 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>>> I think I need an example to see how such a piece of information could
>>> be used...  can you provide one?
>>
>> I'm not sure I understand.
>>
>> I set the todo sequence for a particular task and it remembers, for
>> the life of the session, which is the sequence in use for that task.
>
> My question is: 1) how do you make org.el "remember" what sequence is in
> use for a particular task?  2) how do you tell the user what sequence is
> in use for a particular task?

At a guess internally a certain task is remembered via a task id or
something. If its not possible or not worth it, fine - no big deal. But
there is a bug in the latest in that it says there are two sets of todo
sequences but wont allow selection of the second one.

>
> The reason behind my suggestion to use "TODO_1 NEXT_1 | DONE_1" is that
> it solves both questions without requiring anothing new.  You can even

It's effectively different keywords so doesn't really solve anything and
is just the current "way" :-;

If there is no current "remembering" of tasks then I'm happy to forget I
asked - it was merely a "nice to have".

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 14:59                 ` Bastien
@ 2007-11-03 14:06                   ` Richard G Riley
  2007-11-03 15:40                     ` Bastien
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-03 14:06 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>> At a guess internally a certain task is remembered via a task id or
>> something. If its not possible or not worth it, fine - no big deal. But
>> there is a bug in the latest in that it says there are two sets of todo
>> sequences but wont allow selection of the second one.
>
> Hey you mentionned in your first email that the manual explicitely said
> the two sets should have different keywords, so "bug" is a bit too much
> here :-)

You misunderstand. When you try to switch it says "1/2" but wont
switch. It should not recognise the second if you cant switch to it I
think.

>
>> If there is no current "remembering" of tasks then I'm happy to forget
>> I asked - it was merely a "nice to have".
>
> I should acknowledge I came across this limitation before and here is
> the only way I can think of to handle it: have SEQ_TODO and TYP_TODO
> properties and make C-S-<down> select the right one for an entry.
>
> * TODO 
>   :PROPERTIES:
>   :SEQ_TODO: TODO NEXT SOMEDAY | DONE CANCELED
>   :END:
>
> * TODO 
>   :PROPERTIES:
>   :SEQ_TODO: TODO WAITING | DONE DELEGATED
>   :END:
>
> * TODO 
>   :PROPERTIES:
>   :TYP_TODO: TODO Fred Isabelle Kevin WAITING | DONE
>   :END:
>
> Would you use this?

Probably not as my initial query was more interest than anything else
and I don't know what TYP_TODO is off the top of my head:-;

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 13:10           ` Richard G Riley
@ 2007-11-03 14:23             ` Bastien
  2007-11-03 13:43               ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-03 14:23 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

>> I think I need an example to see how such a piece of information could
>> be used...  can you provide one?
>
> I'm not sure I understand.
>
> I set the todo sequence for a particular task and it remembers, for
> the life of the session, which is the sequence in use for that task.

My question is: 1) how do you make org.el "remember" what sequence is in
use for a particular task?  2) how do you tell the user what sequence is
in use for a particular task?

The reason behind my suggestion to use "TODO_1 NEXT_1 | DONE_1" is that
it solves both questions without requiring anothing new.  You can even
replace DONE_1 by DONE, because you usually don't need to cycle through
keywords once an entry is marked DONE.

> Nothing more, nothing less and not very, very important, just
> "nice". Reason? I want "Done", "Cancelled" on all or most sequences.

As I said, you can switch from one sequence to another if they start
with a different keyword.

Then you can use "Done" and "Cancelled" as you wish, provided that you
don't expect S-<right> on them will produce something logical -- e.g.
set-dependant.

I'm not trying to say the current way of handling sets is the only one,
not even the better one, it's just that I don't know how they could be
handled otherwise - maybe i'm too myopic on this.

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 13:43               ` Richard G Riley
@ 2007-11-03 14:59                 ` Bastien
  2007-11-03 14:06                   ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-03 14:59 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

> At a guess internally a certain task is remembered via a task id or
> something. If its not possible or not worth it, fine - no big deal. But
> there is a bug in the latest in that it says there are two sets of todo
> sequences but wont allow selection of the second one.

Hey you mentionned in your first email that the manual explicitely said
the two sets should have different keywords, so "bug" is a bit too much
here :-)

> If there is no current "remembering" of tasks then I'm happy to forget
> I asked - it was merely a "nice to have".

I should acknowledge I came across this limitation before and here is
the only way I can think of to handle it: have SEQ_TODO and TYP_TODO
properties and make C-S-<down> select the right one for an entry.

* TODO 
  :PROPERTIES:
  :SEQ_TODO: TODO NEXT SOMEDAY | DONE CANCELED
  :END:

* TODO 
  :PROPERTIES:
  :SEQ_TODO: TODO WAITING | DONE DELEGATED
  :END:

* TODO 
  :PROPERTIES:
  :TYP_TODO: TODO Fred Isabelle Kevin WAITING | DONE
  :END:

Would you use this?

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 15:40                     ` Bastien
@ 2007-11-03 15:15                       ` Richard G Riley
  2007-11-04  7:22                         ` Carsten Dominik
  0 siblings, 1 reply; 14+ messages in thread
From: Richard G Riley @ 2007-11-03 15:15 UTC (permalink / raw)
  To: Bastien; +Cc: emacs-orgmode

Bastien <bzg@altern.org> writes:

> Richard G Riley <rileyrgdev@googlemail.com> writes:
>
>>> Hey you mentionned in your first email that the manual explicitely said
>>> the two sets should have different keywords, so "bug" is a bit too much
>>> here :-)
>>
>> You misunderstand. When you try to switch it says "1/2" but wont
>> switch. It should not recognise the second if you cant switch to it I
>> think.
>
> So your proposal is to ignore the second set if it is not well
> defined?

Yes. I was confused for a while as to why I couldn't select the second
set. Or maybe no. But let the user know why they cant be used.

It might be even better to really allow the selection. The next state
change must be preceeded by a sequence selection each and every time if
you are not wanting to use the default (first) sequence. That would make
sense to me too.


>
> Maybe this would be even more confusing for the user: having 1/2 in the
> echo-area and not being able to get 2/2 makes you wonder what is wrong
> with the second set...  what you precisely did.  If the second set is
> simply ignored, then the user will be tempted to make Org know about 
> it rather than fixing it. 
>
>>> Would you use this?
>>
>> Probably not as my initial query was more interest than anything else
>
> :-)
>
>> and I don't know what TYP_TODO is off the top of my head:-;
>
> Org used to handle the cycling through SEQ_TODO and TYP_TODO keywords
> differently -- looks like it's not the case anymore...

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 14:06                   ` Richard G Riley
@ 2007-11-03 15:40                     ` Bastien
  2007-11-03 15:15                       ` Richard G Riley
  0 siblings, 1 reply; 14+ messages in thread
From: Bastien @ 2007-11-03 15:40 UTC (permalink / raw)
  To: emacs-orgmode

Richard G Riley <rileyrgdev@googlemail.com> writes:

>> Hey you mentionned in your first email that the manual explicitely said
>> the two sets should have different keywords, so "bug" is a bit too much
>> here :-)
>
> You misunderstand. When you try to switch it says "1/2" but wont
> switch. It should not recognise the second if you cant switch to it I
> think.

So your proposal is to ignore the second set if it is not well defined?

Maybe this would be even more confusing for the user: having 1/2 in the
echo-area and not being able to get 2/2 makes you wonder what is wrong
with the second set...  what you precisely did.  If the second set is
simply ignored, then the user will be tempted to make Org know about 
it rather than fixing it. 

>> Would you use this?
>
> Probably not as my initial query was more interest than anything else

:-)

> and I don't know what TYP_TODO is off the top of my head:-;

Org used to handle the cycling through SEQ_TODO and TYP_TODO keywords
differently -- looks like it's not the case anymore...

-- 
Bastien

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: switching between todo groups
  2007-11-03 15:15                       ` Richard G Riley
@ 2007-11-04  7:22                         ` Carsten Dominik
  0 siblings, 0 replies; 14+ messages in thread
From: Carsten Dominik @ 2007-11-04  7:22 UTC (permalink / raw)
  To: Richard G Riley; +Cc: emacs-orgmode

Hi Bastien, Richard,

thanks for the discussion!

Org-mode is plain text, so I don't have a good way to store which  
sequence is
being used *between* sessions.  Because of that, it seems to me that  
it does
not make a lot of sense to store the sequence during the current  
session, because
that would cause random behavior with exactly the same input.

So I don't really have a good solution for this.  Properties would be  
a way out, but
seem to be overkill for me.  The whole purpose of TODO keywords is to  
have something
much easier than properties.

It is best to have different keywords where possible, and in  
particular for the first
keyword in a sequence.  I will beef up the documentation in this  
respect.

- Carsten

On  3Nov2007, at 4:15 PM, Richard G Riley wrote:

> Bastien <bzg@altern.org> writes:
>
>> Richard G Riley <rileyrgdev@googlemail.com> writes:
>>
>>>> Hey you mentionned in your first email that the manual  
>>>> explicitely said
>>>> the two sets should have different keywords, so "bug" is a bit  
>>>> too much
>>>> here :-)
>>>
>>> You misunderstand. When you try to switch it says "1/2" but wont
>>> switch. It should not recognise the second if you cant switch to  
>>> it I
>>> think.
>>
>> So your proposal is to ignore the second set if it is not well
>> defined?
>
> Yes. I was confused for a while as to why I couldn't select the second
> set. Or maybe no. But let the user know why they cant be used.
>
> It might be even better to really allow the selection. The next state
> change must be preceeded by a sequence selection each and every  
> time if
> you are not wanting to use the default (first) sequence. That would  
> make
> sense to me too.
>
>
>>
>> Maybe this would be even more confusing for the user: having 1/2  
>> in the
>> echo-area and not being able to get 2/2 makes you wonder what is  
>> wrong
>> with the second set...  what you precisely did.  If the second set is
>> simply ignored, then the user will be tempted to make Org know about
>> it rather than fixing it.
>>
>>>> Would you use this?
>>>
>>> Probably not as my initial query was more interest than anything  
>>> else
>>
>> :-)
>>
>>> and I don't know what TYP_TODO is off the top of my head:-;
>>
>> Org used to handle the cycling through SEQ_TODO and TYP_TODO keywords
>> differently -- looks like it's not the case anymore...
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2007-11-04  7:22 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-02  0:51 switching between todo groups Richard G Riley
2007-11-02 14:53 ` Bastien
2007-11-02 14:16   ` Richard G Riley
2007-11-02 15:49     ` Bastien
2007-11-02 15:05       ` Richard G Riley
2007-11-02 17:38         ` Bastien
2007-11-03 13:10           ` Richard G Riley
2007-11-03 14:23             ` Bastien
2007-11-03 13:43               ` Richard G Riley
2007-11-03 14:59                 ` Bastien
2007-11-03 14:06                   ` Richard G Riley
2007-11-03 15:40                     ` Bastien
2007-11-03 15:15                       ` Richard G Riley
2007-11-04  7:22                         ` Carsten Dominik

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).