aziz / PlainTasks

An opinionated todo-list plugin for Sublime Text editor (version 2 and 3)
MIT License
3.29k stars 286 forks source link

Enhancement: Better nesting support #355

Closed pykong closed 6 years ago

pykong commented 6 years ago

Hierarchy is vital to provide structure not only to code but also to the organization of tasks. Therefore PlainTaks should feature a better support of nested structures.

In this regard, I got two related enhancement proposals.

1. Auto indent on Enter Thereby the right indentation level of a respective child task is automatically selected. (Think python here.)

☐ Parent:|  <-- has colon = is parent, | = caret

On enter, the caret is positioned...

☐ Parent:
.... |  

where Child 1 should begin

☐ Parent:
.... ☐ Child 1 |  

2. Couple parent child tasks

If Parent is marked complete/canceled, all children are marked complete/canceled as well.

✔ Parent:
    ☐ Child 1
    ☐ Child 2

leads to:

✔ Parent:
    ✔ Child 1
    ✔ Child 2

And vice versa if all children tasks are complete/canceled the parent task is set to complete/canceled automatically.

✔ Parent:
    ☐ Child 1
    ☐ Child 2

leads to:

✔ Parent:
    ✔ Child 1
    ✔ Child 2
vovkkk commented 6 years ago

Earlier we had keybinding which add indent on enter after each task (because even if it won’t have child then it may have a note), the binding was removed in #214 You can add removed binding in your user keybindings file and also may change "preceding_text" regex so it wil work only if task ends with colon.

The second proposal is a duplicate of #39