[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking depen
From: |
Ihor Radchenko |
Subject: |
Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency |
Date: |
Tue, 13 Sep 2022 10:24:31 +0800 |
Karl Voit <devnull@Karl-Voit.at> writes:
> I was using list checkboxes like that:
>
> - [ ] open task
> - [X] closed task
> - [-] cancelled task
>
> The latter one is supported via C-u C-u C-c C-c.
>From the manual (5.6 Checkboxes):
‘C-c C-x C-b’ (‘org-toggle-checkbox’)
Toggle checkbox status or—with prefix argument—checkbox presence at
point. With double prefix argument, set it to ‘[-]’, which is
considered to be an intermediate state.
[-] is not considered done by our conventions
Here is an example of a checkbox list.
* TODO Organize party [2/4]
- [-] call people [1/3]
- [ ] Peter
- [X] Sarah
- [ ] Sam
- [X] order food
- [ ] think about what music to play
- [X] talk to the neighbors
> However, when I'm using:
>
> (setq org-enforce-todo-checkbox-dependencies t)
>
> ... any [-] checkbox will be regarded as non-finished contrary to
> the behavior of TODO/DONE/CANCELLED heading states.
>
> As a workaround, I may use:
>
> - +[ ]+ cancelled task
>
> ... but this is tedious.
>
> Therefore I'm asking if this might be a viable syntax change:
> handling [-] list items similar to CANCELLED headings as
> non-blocking when used with org-enforce-todo-checkbox-dependencies.
As you can see, we already have conflicting convention, and we cannot
change it without breaking backwards compatibility.
`org-block-todo-from-checkboxes', currently uses
(org-list-search-forward
(concat (org-item-beginning-re)
"\\(?:\\[@\\(?:start:\\)?\\([0-9]+\\|[A-Za-z]\\)\\][
\t]*\\)?"
"\\[[- ]\\]")
end t)
as a condition that some list items are marked incomplete.
So, you can use something like
- [C] cancelled task
But beware that this is an internal implementation detail that might be
changed in future unless we decide to document the existing behaviour.
--
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92
- Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Karl Voit, 2022/09/12
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency,
Ihor Radchenko <=
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Karl Voit, 2022/09/13
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Marcin Borkowski, 2022/09/13
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Christophe Schockaert, 2022/09/13
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Karl Voit, 2022/09/13
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Ihor Radchenko, 2022/09/14
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Christophe Schockaert, 2022/09/15
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Ihor Radchenko, 2022/09/16
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Karl Voit, 2022/09/19
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Daniel Fleischer, 2022/09/14
- Re: Suggested Syntax for cancelled checkboxes: [-] as non-blocking dependency, Bastien, 2022/09/22