Re: doubt on assertion
- From: francex tiscali it
- To: gtk-list gnome org
- Subject: Re: doubt on assertion
- Date: Wed, 17 Mar 2004 13:09:37 +0100
Hi Nils,
> I have a doubt on this situation:
>
> gboolean visible[19]= {TRUE,....};
> extern GtkWidget *view;
>
> .....
>
> for (i = 0; i < 19; i++)
> {
> column = gtk_tr
>e_view_get_column (GTK_TREE_VIEW(view),i);
> gtk_tree_view_column_set_visible (GTK_TREE_VIEW_COLUMN(column),
> visible[i]);
> }
>
> Program works correctly but I got on shell:
>
> (app1:2816): Gtk-CRITICAL **: file gtktreeviewcolum
>.c: line 1558 (gtk_tree_view_column_set_visible):
> assertion `GTK_IS_TREE_VIEW_COLUMN (tree_column)' failed
> Why???
> Exactly what it says.
> Your line:
>column = gtk_tree_view_get_column (GTK_TREE_VIEW(vi
>w),i); Does NOT return a column.
> Why that is I cannot tell, perhaps you havn't added any columns at this
point ??
It's strange cos I have added columns!
partial code:
.....
for (i = 0; i < 19; i++)
{
cell = gtk_cell_renderer_text_new ();
column = gtk_tree_view_column_new_with_attributes(name_fields[i],
cell, "text", i, NULL);
gtk_tree_view_column_set_resizable(GTK_TREE_VIEW_COLUMN(column),
TRUE);
gtk_tree_view_append_column(GTK_TREE_VIEW(view), column);
}
gtk_widget_show (view);
......
Thanks,
France
__________________________________________________________________
ADSL Senza Canone 640Kbps:
attivala entro il 31 marzo e avrai GRATIS il costo di adesione,
quello di attivazione e il modem per tutto il 2004.
E per i primi 3 mesi navighi a 1,5 euro l'ora! Affrettati!
http://point.tiscali.it/adsl/prodotti/senzacanone/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]