Re: gtk_tree_view_column_set_cell_data_func gives GTK-CRITICAL error
- From: James Steward <jamessteward optusnet com au>
- To: Tadej BorovÅak <tadeboro gmail com>
- Cc: gtk app devel list <gtk-app-devel-list gnome org>
- Subject: Re: gtk_tree_view_column_set_cell_data_func gives GTK-CRITICAL error
- Date: Thu, 01 Dec 2011 07:33:04 +1100
On 30/11/11 20:04, Tadej BorovÅak wrote:
Hi.
2011/11/30 James Steward<jamessteward optusnet com au>:
col = gtk_tree_view_insert_column_with_attributes (
GTK_TREE_VIEW (view),
-1,
"Title",
renderer,
"text", i,
"strikethrough", j,
"background", k,
"background-set", TRUE,
NULL);
gtk_tree_view_column_set_cell_data_func(
gtk_tree_view_get_column(GTK_TREE_VIEW(view), col),
renderer,
render_float,
GINT_TO_POINTER(i),
NULL);
IIRC, gtk_tree_view_insert_column_with_attributes() returns number of
columns and gtk_tree_view_get_column() expects to get column number
where first column is 0. So you may be off-by-one in your call to
gtk_tree_view_column_set_cell_data_func().
Well spotted! Thanks very much.
Regards,
James.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]