Top |
Functions
GtdTask * | gtd_task_new () |
gboolean | gtd_task_get_complete () |
void | gtd_task_set_complete () |
ECalComponent * | gtd_task_get_component () |
GDateTime * | gtd_task_get_creation_date () |
const gchar * | gtd_task_get_description () |
void | gtd_task_set_description () |
GDateTime * | gtd_task_get_due_date () |
void | gtd_task_set_due_date () |
GtdTaskList * | gtd_task_get_list () |
void | gtd_task_set_list () |
gint | gtd_task_get_priority () |
void | gtd_task_set_priority () |
const gchar * | gtd_task_get_title () |
void | gtd_task_set_title () |
void | gtd_task_abort () |
void | gtd_task_save () |
gint | gtd_task_compare () |
Properties
gboolean | complete | Read / Write |
ECalComponent * | component | Read / Write / Construct Only |
GDateTime * | creation-date | Read |
guint | depth | Read |
gchar * | description | Read / Write |
GDateTime * | due-date | Read / Write |
GtdTaskList * | list | Read / Write |
GtdTask * | parent | Read |
gint | priority | Read / Write |
gchar * | title | Read / Write |
Description
A GtdTask is an object that represents a task. All GtdTasks must be inside a GtdTaskList.
Functions
gtd_task_get_complete ()
gboolean
gtd_task_get_complete (GtdTask *task
);
Retrieves whether the task is complete or not.
gtd_task_set_complete ()
void gtd_task_set_complete (GtdTask *task
,gboolean complete
);
Updates the complete state of task
.
gtd_task_get_component ()
ECalComponent *
gtd_task_get_component (GtdTask *task
);
Retrieves the internal ECalComponent of task
.
gtd_task_get_creation_date ()
GDateTime *
gtd_task_get_creation_date (GtdTask *task
);
Returns the GDateTime that represents the task's creation date.
The value is referenced for thread safety. Returns NULL
if
no date is set.
gtd_task_get_description ()
const gchar *
gtd_task_get_description (GtdTask *task
);
Retrieves the description of the task.
gtd_task_set_description ()
void gtd_task_set_description (GtdTask *task
,const gchar *description
);
Updates the description of task
. The string is not stripped off of
spaces to preserve user data.
gtd_task_get_due_date ()
GDateTime *
gtd_task_get_due_date (GtdTask *task
);
Returns the GDateTime that represents the task's due date.
The value is referenced for thread safety. Returns NULL
if
no date is set.
gtd_task_set_due_date ()
void gtd_task_set_due_date (GtdTask *task
,GDateTime *dt
);
Updates the internal GtdTask
::due-date property.
gtd_task_get_list ()
GtdTaskList *
gtd_task_get_list (GtdTask *task
);
Returns a weak reference to the GtdTaskList that
owns the given task
.
Returns
a weak reference to the
GtdTaskList that owns task
. Do not free after
usage.
[transfer none]
gtd_task_set_list ()
void gtd_task_set_list (GtdTask *task
,GtdTaskList *list
);
Sets the parent GtdTaskList of task
.
gtd_task_get_priority ()
gint
gtd_task_get_priority (GtdTask *task
);
Returns the priority of task
inside the parent GtdTaskList,
or -1 if not set.
gtd_task_set_priority ()
void gtd_task_set_priority (GtdTask *task
,gint priority
);
Sets the task
priority inside the parent GtdTaskList. It
is up to the interface to handle two or more GtdTask with
the same priority value.
gtd_task_get_title ()
const gchar *
gtd_task_get_title (GtdTask *task
);
Retrieves the title of the task, or NULL
.
gtd_task_set_title ()
void gtd_task_set_title (GtdTask *task
,const gchar *title
);
Updates the title of task
. The string is stripped off of
leading spaces.
gtd_task_abort ()
void
gtd_task_abort (GtdTask *task
);
Cancels any editing made on task
after the latest
call of gtd_task_save
.
Types and Values
struct GtdTaskClass
struct GtdTaskClass { GtdObjectClass parent; /*< signals >*/ void (*subtask_added) (GtdTask *self, GtdTask *subtask); void (*subtask_removed) (GtdTask *self, GtdTask *subtask); gpointer padding[8]; };
Property Details
The “complete”
property
“complete” gboolean
Whether the task is marked as completed by the user.
Flags: Read / Write
Default value: FALSE
The “component”
property
“component” ECalComponent *
The #ECalComponent this task handles.
Flags: Read / Write / Construct Only
The “depth”
property
“depth” guint
The depth of the task inside the subtasks tree.
Flags: Read
Default value: 0
The “description”
property
“description” gchar *
Optional string describing the task.
Flags: Read / Write
Default value: NULL
The “due-date”
property
“due-date” GDateTime *
The day the task is supposed to be completed.
Flags: Read / Write
The “priority”
property
“priority” gint
The priority of the task. 0 means no priority set, and tasks will be sorted alphabetically.
Flags: Read / Write
Allowed values: >= 0
Default value: 0