Details
enum GtkTreeViewColumnSizing
typedef enum
{
GTK_TREE_VIEW_COLUMN_GROW_ONLY,
GTK_TREE_VIEW_COLUMN_AUTOSIZE,
GTK_TREE_VIEW_COLUMN_FIXED
} GtkTreeViewColumnSizing; |
struct GtkTreeViewColumn
struct GtkTreeViewColumn; |
gtk_tree_view_column_pack_start ()
gtk_tree_view_column_pack_end ()
gtk_tree_view_column_clear ()
Unsets all the mappings on all renderers on the tree_column.
gtk_tree_view_column_get_cell_renderers ()
Returns a newly-allocated GList of all the cell renderers in the column,
in no particular order. The list must be freed with g_list_free().
gtk_tree_view_column_add_attribute ()
Adds an attribute mapping to the list in tree_column. The column is the
column of the model to get a value from, and the attribute is the
parameter on cell_renderer to be set from the value. So for example
if column 2 of the model contains strings, you could have the
"text" attribute of a GtkCellRendererText get its values from
column 2.
gtk_tree_view_column_set_attributes ()
Sets the attributes in the list as the attributes of tree_column.
The attributes should be in attribute/column order, as in
gtk_tree_view_column_add_attribute(). All existing attributes
are removed, and replaced with the new attributes.
gtk_tree_view_column_set_cell_data_func ()
Sets the GtkTreeViewColumnFunc to use for the column. This
function is used instead of the standard attributes mapping for
setting the column value, and should set the value of tree_column's
cell renderer as appropriate. func may be NULL to remove an
older one.
gtk_tree_view_column_set_spacing ()
void gtk_tree_view_column_set_spacing
(GtkTreeViewColumn *tree_column,
gint spacing); |
Sets the spacing field of tree_column, which is the number of pixels to
place between cell renderers packed into it.
gtk_tree_view_column_get_spacing ()
Returns the spacing of tree_column.
gtk_tree_view_column_set_visible ()
void gtk_tree_view_column_set_visible
(GtkTreeViewColumn *tree_column,
gboolean visible); |
Sets the visibility of tree_column.
gtk_tree_view_column_get_visible ()
Returns TRUE if tree_column is visible.
gtk_tree_view_column_set_resizable ()
void gtk_tree_view_column_set_resizable
(GtkTreeViewColumn *tree_column,
gboolean resizable); |
gtk_tree_view_column_get_resizable ()
gtk_tree_view_column_set_sizing ()
Sets the growth behavior of tree_column to type.
gtk_tree_view_column_get_sizing ()
Returns the current type of tree_column.
gtk_tree_view_column_get_width ()
Returns the current size of tree_column in pixels.
gtk_tree_view_column_get_fixed_width ()
Gets the fixed width of the column. This value is only meaning may not be
the actual width of the column on the screen, just what is requested.
gtk_tree_view_column_set_fixed_width ()
void gtk_tree_view_column_set_fixed_width
(GtkTreeViewColumn *tree_column,
gint fixed_width); |
Sets the size of the column in pixels. This is meaningful only if the sizing
type is GTK_TREE_VIEW_COLUMN_FIXED. In this case, the value is discarded
as the size of the column is based on the calculated width of the column. The
width is clamped to the min/max width for the column.
gtk_tree_view_column_set_min_width ()
void gtk_tree_view_column_set_min_width
(GtkTreeViewColumn *tree_column,
gint min_width); |
Sets the minimum width of the tree_column. If min_width is -1, then the
minimum width is unset.
gtk_tree_view_column_get_min_width ()
Returns the minimum width in pixels of the tree_column, or -1 if no minimum
width is set.
gtk_tree_view_column_set_max_width ()
void gtk_tree_view_column_set_max_width
(GtkTreeViewColumn *tree_column,
gint max_width); |
Sets the maximum width of the tree_column. If max_width is -1, then the
maximum width is unset. Note, the column can actually be wider than max
width if it's the last column in a view. In this case, the column expands to
fill any extra space.
gtk_tree_view_column_get_max_width ()
Returns the maximum width in pixels of the tree_column, or -1 if no maximum
width is set.
gtk_tree_view_column_clicked ()
Emits the "clicked" signal on the column. This function will only work if
tree_column is clickable.
gtk_tree_view_column_set_title ()
void gtk_tree_view_column_set_title (GtkTreeViewColumn *tree_column,
const gchar *title); |
Sets the title of the tree_column. If a custom widget has been set, then
this value is ignored.
gtk_tree_view_column_get_title ()
G_CONST_RETURN gchar* gtk_tree_view_column_get_title
(GtkTreeViewColumn *tree_column); |
Returns the title of the widget. This value should not be modified.
gtk_tree_view_column_set_clickable ()
void gtk_tree_view_column_set_clickable
(GtkTreeViewColumn *tree_column,
gboolean clickable); |
Sets the header to be active if active is TRUE. When the header is active,
then it can take keyboard focus, and can be clicked.
gtk_tree_view_column_get_clickable ()
Returns TRUE if the user can click on the header for the column.
gtk_tree_view_column_set_widget ()
Sets the widget in the header to be widget. If widget is NULL, then the
header button is set with a GtkLabel set to the title of tree_column.
gtk_tree_view_column_get_widget ()
Returns the GtkWidget in the button in the column header. If a custom
widget has not been set, then this will be a GtkAlignment with a GtkLabel
in it.
gtk_tree_view_column_set_alignment ()
void gtk_tree_view_column_set_alignment
(GtkTreeViewColumn *tree_column,
gfloat xalign); |
Sets the alignment of the title or custom widget inside the column header.
The alignment determines its location inside the button -- 0.0 for left, 0.5
for center, 1.0 for right.
gtk_tree_view_column_get_alignment ()
Returns the current x alignment of tree_column. This value can range
between 0.0 and 1.0.
gtk_tree_view_column_set_reorderable ()
void gtk_tree_view_column_set_reorderable
(GtkTreeViewColumn *tree_column,
gboolean reorderable); |
gtk_tree_view_column_get_reorderable ()
gtk_tree_view_column_set_sort_column_id ()
void gtk_tree_view_column_set_sort_column_id
(GtkTreeViewColumn *tree_column,
gint sort_column_id); |
Sets the logical sort_column_id that this column sorts on when this column
is selected for sorting. Doing so makes the column header clickable.
gtk_tree_view_column_set_sort_indicator ()
void gtk_tree_view_column_set_sort_indicator
(GtkTreeViewColumn *tree_column,
gboolean setting); |
Call this function with a setting of TRUE to display an arrow in
the header button indicating the column is sorted. Call
gtk_tree_view_column_set_sort_order() to change the direction of
the arrow.
gtk_tree_view_column_set_sort_order ()
Changes the appearance of the sort indicator.
This does not actually sort the model. Use
gtk_tree_view_column_set_sort_column_id() if you want automatic sorting
support. This function is primarily for custom sorting behavior, and should
be used in conjunction with gtk_tree_sortable_set_sort_column() to do
that. For custom models, the mechanism will vary.
The sort indicator changes direction to indicate normal sort or reverse sort.
Note that you must have the sort indicator enabled to see anything when
calling this function; see gtk_tree_view_column_set_sort_indicator().
gtk_tree_view_column_cell_set_cell_data ()
Sets the cell renderer based on the tree_model and tree_node. That is, for
every attribute mapping in tree_column, it will get a value from the set
column on the tree_node, and use that value to set the attribute on the cell
renderer. This is used primarily by the GtkTreeView.
gtk_tree_view_column_cell_get_size ()
void gtk_tree_view_column_cell_get_size
(GtkTreeViewColumn *tree_column,
GdkRectangle *cell_area,
gint *x_offset,
gint *y_offset,
gint *width,
gint *height); |
Obtains the width and height needed to render the column. This is used
primarily by the GtkTreeView.
gtk_tree_view_column_cell_render ()
Renders the cell contained by tree_column. This is used primarily by the
GtkTreeView.
gtk_tree_view_column_cell_focus ()
gboolean gtk_tree_view_column_cell_focus (GtkTreeViewColumn *tree_column,
gint direction); |
gtk_tree_view_column_cell_draw_focus ()
gtk_tree_view_column_cell_is_visible ()
gtk_tree_view_column_cell_set_dirty ()