ETableSortInfo

ETableSortInfo

Synopsis

struct              ETableSortInfo;
void                e_table_sort_info_freeze            (ETableSortInfo *info);
void                e_table_sort_info_thaw              (ETableSortInfo *info);
guint               e_table_sort_info_grouping_get_count
                                                        (ETableSortInfo *info);
void                e_table_sort_info_grouping_truncate (ETableSortInfo *info,
                                                         gint length);
struct              ETableSortColumn;
ETableSortColumn    e_table_sort_info_grouping_get_nth  (ETableSortInfo *info,
                                                         gint n);
void                e_table_sort_info_grouping_set_nth  (ETableSortInfo *info,
                                                         gint n,
                                                         ETableSortColumn column);
guint               e_table_sort_info_sorting_get_count (ETableSortInfo *info);
void                e_table_sort_info_sorting_truncate  (ETableSortInfo *info,
                                                         gint length);
ETableSortColumn    e_table_sort_info_sorting_get_nth   (ETableSortInfo *info,
                                                         gint n);
void                e_table_sort_info_sorting_set_nth   (ETableSortInfo *info,
                                                         gint n,
                                                         ETableSortColumn column);
ETableSortInfo *    e_table_sort_info_new               (void);
void                e_table_sort_info_load_from_node    (ETableSortInfo *info,
                                                         xmlNode *node,
                                                         gdouble state_version);
xmlNode *           e_table_sort_info_save_to_node      (ETableSortInfo *info,
                                                         xmlNode *parent);
ETableSortInfo *    e_table_sort_info_duplicate         (ETableSortInfo *info);
void                e_table_sort_info_set_can_group     (ETableSortInfo *info,
                                                         gboolean can_group);
gboolean            e_table_sort_info_get_can_group     (ETableSortInfo *info);

Object Hierarchy

  GObject
   +----ETableSortInfo

Signals

  "group-info-changed"                             : Run Last
  "sort-info-changed"                              : Run Last

Description

Details

struct ETableSortInfo

struct ETableSortInfo;

e_table_sort_info_freeze ()

void                e_table_sort_info_freeze            (ETableSortInfo *info);

This functions allows the programmer to cluster various changes to the ETableSortInfo (grouping and sorting) without having the object emit "group_info_changed" or "sort_info_changed" signals on each change.

To thaw, invoke the e_table_sort_info_thaw() function, which will trigger any signals that might have been queued.

info :

The ETableSortInfo object

e_table_sort_info_thaw ()

void                e_table_sort_info_thaw              (ETableSortInfo *info);

This functions allows the programmer to cluster various changes to the ETableSortInfo (grouping and sorting) without having the object emit "group_info_changed" or "sort_info_changed" signals on each change.

This function will flush any pending signals that might be emited by this object.

info :

The ETableSortInfo object

e_table_sort_info_grouping_get_count ()

guint               e_table_sort_info_grouping_get_count
                                                        (ETableSortInfo *info);

info :

The ETableSortInfo object

Returns :

the number of grouping criteria in the object.

e_table_sort_info_grouping_truncate ()

void                e_table_sort_info_grouping_truncate (ETableSortInfo *info,
                                                         gint length);

This routine can be used to reduce or grow the number of grouping criteria in the object.

info :

The ETableSortInfo object

lenght :

position where the truncation happens.

struct ETableSortColumn

struct ETableSortColumn {
	guint column : 31;
	guint ascending : 1;
};

e_table_sort_info_grouping_get_nth ()

ETableSortColumn    e_table_sort_info_grouping_get_nth  (ETableSortInfo *info,
                                                         gint n);

info :

The ETableSortInfo object

n :

Item information to fetch.

Returns :

the description of the n-th grouping criteria in the info object.

e_table_sort_info_grouping_set_nth ()

void                e_table_sort_info_grouping_set_nth  (ETableSortInfo *info,
                                                         gint n,
                                                         ETableSortColumn column);

Sets the grouping criteria for index n to be given by column (a column number and whether it is ascending or descending).

info :

The ETableSortInfo object

n :

Item information to fetch.

column :

new values for the grouping

e_table_sort_info_sorting_get_count ()

guint               e_table_sort_info_sorting_get_count (ETableSortInfo *info);

e_table_sort_info_sorting_truncate ()

void                e_table_sort_info_sorting_truncate  (ETableSortInfo *info,
                                                         gint length);

This routine can be used to reduce or grow the number of sort criteria in the object.

info :

The ETableSortInfo object

lenght :

position where the truncation happens.

e_table_sort_info_sorting_get_nth ()

ETableSortColumn    e_table_sort_info_sorting_get_nth   (ETableSortInfo *info,
                                                         gint n);

Sets the sorting criteria for index n to be given by column (a column number and whether it is ascending or descending).

info :

The ETableSortInfo object

n :

Item information to fetch.

column :

new values for the sorting

e_table_sort_info_sorting_set_nth ()

void                e_table_sort_info_sorting_set_nth   (ETableSortInfo *info,
                                                         gint n,
                                                         ETableSortColumn column);

e_table_sort_info_new ()

ETableSortInfo *    e_table_sort_info_new               (void);

This creates a new e_table_sort_info object that contains no grouping and no sorting defined as of yet. This object is used to keep track of multi-level sorting and multi-level grouping of the ETable.

Returns :

A new ETableSortInfo object

e_table_sort_info_load_from_node ()

void                e_table_sort_info_load_from_node    (ETableSortInfo *info,
                                                         xmlNode *node,
                                                         gdouble state_version);

This loads the state for the ETableSortInfo object info from the xml node node.

info :

The ETableSortInfo object

node :

pointer to the xmlNode that describes the sorting and grouping information

e_table_sort_info_save_to_node ()

xmlNode *           e_table_sort_info_save_to_node      (ETableSortInfo *info,
                                                         xmlNode *parent);

This function is used

info :

The ETableSortInfo object

parent :

xmlNode that will be hosting the saved state of the info object.

Returns :

the node that has been appended to parent as a child containing the sorting and grouping information for this ETableSortInfo object.

e_table_sort_info_duplicate ()

ETableSortInfo *    e_table_sort_info_duplicate         (ETableSortInfo *info);

e_table_sort_info_set_can_group ()

void                e_table_sort_info_set_can_group     (ETableSortInfo *info,
                                                         gboolean can_group);

e_table_sort_info_get_can_group ()

gboolean            e_table_sort_info_get_can_group     (ETableSortInfo *info);

Signal Details

The "group-info-changed" signal

void                user_function                      (ETableSortInfo *etablesortinfo,
                                                        gpointer        user_data)           : Run Last

The "sort-info-changed" signal

void                user_function                      (ETableSortInfo *etablesortinfo,
                                                        gpointer        user_data)           : Run Last