> But i don't know how to change first column background just in the
> data.
There are two ways. If you need to have individual colors for each row
you would define a column that you use to store your background color
in for every entry of your GtkListStore. Let's say you define a column
as COLUMN_BACKGROUND like this:
enum {
...
COLUMN_BACKGROUND,
...
N_COLUMNS
};
Then you could do the following:
gtk_list_store_append(store, );
gtk_list_store_set(store, ,
...
COLUMN_BACKGROUND, "#ff00ff",
-1);
GtkTreeViewColumn *first_column;
first_column = gtk_tree_view_column_new_with_attributes(
"First Column", first_column_renderer,
...
"cell-background", COLUMN_BACKGROUND,
NULL);
The other ways is to set it directly on the cell renderer:
GtkCellRenderer* first_renderer;
first_renderer = gtk_cell_renderer_text_new();
g_object_set(first_renderer,
...
"cell-background", "#ff00ff",
NULL);
Hope that helps.
Cheers,
--Tilo
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list