![]() | ![]() | ![]() | ![]() |
#define E_TABLE_HEADER_TYPE ETableHeader; ETableHeader* e_table_header_new (void); void e_table_header_add_column (ETableHeader *eth, ETableCol *tc, int pos); ETableCol* e_table_header_get_column (ETableHeader *eth, int column); int e_table_header_count (ETableHeader *eth); int e_table_header_index (ETableHeader *eth, int col); int e_table_header_get_index_at (ETableHeader *eth, int x_offset); ETableCol** e_table_header_get_columns (ETableHeader *eth); int e_table_header_get_selected (ETableHeader *eth); int e_table_header_total_width (ETableHeader *eth); void e_table_header_move (ETableHeader *eth, int source_index, int target_index); void e_table_header_remove (ETableHeader *eth, int idx); void e_table_header_set_size (ETableHeader *eth, int idx, int size); void e_table_header_set_selection (ETableHeader *eth, gboolean allow_selection); int e_table_header_col_diff (ETableHeader *eth, int start_col, int end_col); void e_table_header_calc_widths (ETableHeader *eth); GList* e_table_header_get_selected_indexes (ETableHeader *eth);
"structure-change" void user_function (ETableHeader *etableheader, gpointer user_data); "dimension-change" void user_function (ETableHeader *etableheader, gint arg1, gpointer user_data); "request-width" gint user_function (ETableHeader *etableheader, gint arg1, gpointer user_data);
void e_table_header_add_column (ETableHeader *eth, ETableCol *tc, int pos);
This function adds the tc
ETableCol definition into the eth
ETableHeader
at position pos
. This is the way you add new ETableCols to the
ETableHeader. The header will assume ownership of the tc
; you should not
unref it after you add it.
This function will emit the "structure_change" signal on the eth
object.
The ETableCol is assumed
eth : | the table header to add the column to. |
tc : | the ETableCol definition |
pos : | position where the ETableCol will go. |
ETableCol* e_table_header_get_column (ETableHeader *eth, int column);
eth : | the ETableHeader to query |
column : | the column inside the |
Returns : | The ETableCol at |
int e_table_header_count (ETableHeader *eth);
eth : | the ETableHeader to query |
Returns : | the number of columns in this ETableHeader. |
int e_table_header_index (ETableHeader *eth, int col);
ETableHeaders contain the visual list of columns that the user will view. The visible columns will typically map to different columns in the ETableModel (because the user reordered the data for example).
Returns: the column in the model that the col
column
in the ETableHeader points to. */
int
e_table_header_index (ETableHeader *eth, int col)
{
g_return_val_if_fail (eth != NULL, -1);
g_return_val_if_fail (E_IS_TABLE_HEADER (eth), -1);
g_return_val_if_fail (col >= 0 && col < eth->col_count, -1);
return eth->columns [col]->col_idx; }
/**
e_table_header_get_index_at:
eth
: the ETableHeader to query
x_offset
: a pixel count from the beginning of the ETableHeader
This will return the ETableHeader column that would contain
the x_offset
pixel.
eth : | the ETableHeader to query |
col : | the column to fetch. |
Returns : | the column that contains pixel |
int e_table_header_get_index_at (ETableHeader *eth, int x_offset);
eth : | |
x_offset : | |
Returns : |
|
ETableCol** e_table_header_get_columns (ETableHeader *eth);
eth : | The ETableHeader to query |
Returns : | A NULL terminated array of the ETableCols
contained in the ETableHeader |
int e_table_header_get_selected (ETableHeader *eth);
eth : | The ETableHeader to query |
Returns : | The number of selected columns in the |
int e_table_header_total_width (ETableHeader *eth);
eth : | The ETableHeader to query |
Returns : | the number of pixels used by the |
void e_table_header_move (ETableHeader *eth, int source_index, int target_index);
This function moves the column source_index
to target_index
inside the eth
ETableHeader. The signals "dimension_change"
and "structure_change" will be emmited
eth : | The ETableHeader to operate on. |
source_index : | the source column to move. |
target_index : | the target location for the column |
void e_table_header_remove (ETableHeader *eth, int idx);
Removes the column at idx
position in the ETableHeader eth
.
This emmits the "structure_change" signal on the eth
object.
eth : | The ETableHeader to operate on. |
idx : | the index to the column to be removed. |
void e_table_header_set_size (ETableHeader *eth, int idx, int size);
eth : | |
idx : | |
size : |
|
void e_table_header_set_selection (ETableHeader *eth, gboolean allow_selection);
eth : | |
allow_selection : |
|
int e_table_header_col_diff (ETableHeader *eth, int start_col, int end_col);
Computes the number of pixels between the columns start_col
and
end_col
.
eth : | the ETableHeader to query. |
start_col : | the starting column |
end_col : | the ending column. |
Returns : | the number of pixels between |
GList* e_table_header_get_selected_indexes (ETableHeader *eth);
eth : | |
Returns : |
|
void user_function (ETableHeader *etableheader, gpointer user_data);
etableheader : | the object which received the signal. |
user_data : | user data set when the signal handler was connected. |
void user_function (ETableHeader *etableheader, gint arg1, gpointer user_data);
etableheader : | the object which received the signal. |
arg1 : | |
user_data : | user data set when the signal handler was connected. |
gint user_function (ETableHeader *etableheader, gint arg1, gpointer user_data);
etableheader : | the object which received the signal. |
arg1 : | |
user_data : | user data set when the signal handler was connected. |
Returns : |
<<< ETableSpecification | ETableGroupContainer >>> |