Module todo

Source

Structs§

Conf
The list of changes to apply to all records in a list. All operations with text are case insensitive, so if you, e.g., try to replace a project projectone to ProjectOne no todo is updated
DateTagChange
Describes how the date-like tag should be changed. action == Action::None means no changes.
ListTagChange
Describes how the list-like tag should be changed.
PriorityTagChange
Describes how the priority tag should be changed.
RecurrencyTagChange
Describes how the recurrency tag should be changed.
TagValuesChange
Describes how tags should be changed.

Enums§

Action
Type of operation applied to todo properties. Every field supports its own set of operations (except None that can be used for all of them):
NewDateValue
The new value for a date-like tag. Date - a fixed date, one for all tasks Expr - an expression that is calculated for each of selected tasks. E.g, due+1w

Constants§

INVALID_ID
The ID value returned instead of new todo ID if adding a new todo fails
SPENT_TAG
TIMER_OFF
TIMER_TAG

Functions§

add
Appends a new todo to todo list
archive
Appends todos to a file. If file does not exist it is created.
clone_tasks
Makes a clones of selected todos
done
Marks todos completed.
edit
Modifies existing todos.
is_tag_special
Returns if the tag needs special processing. All ‘special’ tags cannot be changed via ‘update_tags’ function because they usually requires running some extra operations on the data after a change (e.g, update internal fields in addition to updating the tag HashMap).
load
Load a list of todo from a file in todo.txt format. If the file does not exist or cannot be opened the function returns empty list
remove
Removes todos from the list
save
Saves the list of todos into a local file. Returns an error if saving fails.
start
Starts timers of all toods that are not done
stop
Stops timers of all toods that are running
undone
Removes flag done from todos.

Type Aliases§

ChangedSlice
ChangedVec
IDSlice
IDVec
TaskSlice
TaskVec