| Top |  |  |  |  | 
| GdkRGBA * | color | Read / Write | 
| gboolean | handle-subtasks | Read / Write | 
| gboolean | show-completed | Read / Write | 
| gboolean | show-due-date | Read / Write | 
| gboolean | show-list-name | Read / Write | 
| gboolean | show-new-task-row | Read / Write | 
GObject ╰── GInitiallyUnowned ╰── GtkWidget ╰── GtkContainer ╰── GtkBin ╰── GtkOverlay ╰── GtdTaskListView
The GtdTaskListView widget shows the tasks of a GtdTaskList with various options to fine-tune the appearance. Alternatively, one can pass a GList of GtdTask objects.
It supports custom sorting and header functions, so the tasks can be sorted in various ways. See the "Today" and "Scheduled" panels for reference implementations.
Example:
| 1 2 3 4 5 6 7 8 9 | GtdTaskListView *view = gtd_task_list_view_new (); gtd_task_list_view_set_list (view, list); // Hide the '+ New task' row gtd_task_list_view_set_show_new_task_row (view, FALSE); // Date which tasks will be automatically assigned gtd_task_list_view_set_default_date (view, now); | 
void (*GtdTaskListViewHeaderFunc) (GtkListBoxRow *row,GtdTask *row_task,GtkListBoxRow *before,GtdTask *before_task,gpointer user_data);
The header function called on every task.
| row | the current GtkListBoxRow | |
| row_task | the GtdTask that  | |
| before | the GtkListBoxRow before  | |
| before_task | the GtdTask that  | |
| user_data | user data. | [closure] | 
gint (*GtdTaskListViewSortFunc) (GtkListBoxRow *row1,GtdTask *row1_task,GtkListBoxRow *row2,GtdTask *row2_task,gpointer user_data);
The sorting function called on every task.
| row1 | the current GtkListBoxRow | |
| row1_task | the GtdTask that  | |
| row2 | the GtkListBoxRow before  | |
| row2_task | the GtdTask that  | |
| user_data | user data. | [closure] | 
GList *
gtd_task_list_view_get_list (GtdTaskListView *view);
Retrieves the list of tasks from view
. Note that,
if a GtdTaskList is set, the GtdTaskList's list
of task will be returned.
void gtd_task_list_view_set_list (GtdTaskListView *view,GList *list);
Copies the tasks from list
 to view
.
GtdTaskList *
gtd_task_list_view_get_task_list (GtdTaskListView *view);
Retrieves the GtdTaskList from view
, or NULL if none was set.
void gtd_task_list_view_set_task_list (GtdTaskListView *view,GtdTaskList *list);
Sets the internal GtdTaskList of view
.
gboolean
gtd_task_list_view_get_show_list_name (GtdTaskListView *view);
Whether view
 shows the tasks' list names.
void gtd_task_list_view_set_show_list_name (GtdTaskListView *view,gboolean show_list_name);
Whether view
 should should it's tasks' list name.
gboolean
gtd_task_list_view_get_show_completed (GtdTaskListView *view);
Returns TRUE if completed tasks are visible, FALSE otherwise.
void gtd_task_list_view_set_show_completed (GtdTaskListView *view,gboolean show_completed);
Sets the ::show-completed property to show_completed
.
void gtd_task_list_view_set_header_func (GtdTaskListView *view,GtdTaskListViewHeaderFunc func,gpointer user_data);
Sets func
 as the header function of view
. You can safely call
gtk_list_box_row_set_header from within func
.
Do not unref nor free any of the passed data.
void gtd_task_list_view_set_sort_func (GtdTaskListView *view,GtdTaskListViewSortFunc func,gpointer user_data);
Sets func
 as the sorting function of view
.
Do not unref nor free any of the passed data.
gboolean
gtd_task_list_view_get_show_new_task_row
                               (GtdTaskListView *view);
Gets whether view
 shows the new task row or not.
void gtd_task_list_view_set_show_new_task_row (GtdTaskListView *view,gboolean show_new_task_row);
Sets the “show-new-task-mode” property of view
.
GDateTime *
gtd_task_list_view_get_default_date (GtdTaskListView *self);
Retrieves the current default date which new tasks are set to.
void gtd_task_list_view_set_default_date (GtdTaskListView *self,GDateTime *default_date);
Sets the current default date.
GdkRGBA *
gtd_task_list_view_get_color (GtdTaskListView *self);
Retrieves the custom color of self
.
void gtd_task_list_view_set_color (GtdTaskListView *self,GdkRGBA *color);
Sets the custom color of self
 to color
. If a custom color is set,
the tasklist's color is ignored. Passing NULL makes the tasklist's
color apply again.
“handle-subtasks” property“handle-subtasks” gboolean
Whether the list handles subtasks, or not.
Flags: Read / Write
Default value: TRUE
“show-completed” property“show-completed” gboolean
Whether completed tasks are visible or not.
Flags: Read / Write
Default value: FALSE
“show-due-date” property“show-due-date” gboolean
Whether due dates of the tasks are visible or not.
Flags: Read / Write
Default value: TRUE
“show-list-name” property“show-list-name” gboolean
Whether task rows show the list name at the end of the row.
Flags: Read / Write
Default value: FALSE
“show-new-task-row” property“show-new-task-row” gboolean
Whether the list shows the New Task row, or not.
Flags: Read / Write
Default value: TRUE