Re: -----Why this error info turn up?



Bob Zhao wrote:

Thanks indeed,
the method works

I feel that is very strange.
I already define label as

Widget label[12];

at the beginning of the file.

except that they're not Widgets; they're GtkWidgets. you also really want to be using an array of pointers, thus:

GtkWidget *label[12];

then you can do, for example:

label[3] = gtk_label_new("foobar");

and you won't need the explicit GTK_WIDGET() cast when passing to functions expecting a GtkWidget.

   -brian



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]