Re: list item




Nicolas Caillaud <Nicolas.Caillaud@mail.dotcom.fr> writes:

> I'm new to gtk, and I've a (little) problem, that should not be such for
> gtk's gurus. 
> I'm creating a list with GtkListItem, with text in it.
> How can I change the text of a GtkListItem without deleting it and
> inserting a new one ? I haven't seen anything about that, but I guess it
> is possible ....
> Any idea ?

If you have a list item, created with gtk_list_item_new_with_label(),
you can get access to the label widget with

  GTK_BIN(item)->child

And, can change the text in that label with:

  gtk_label_set (GTK_LABEL (GTK_BIN(item)->child), "some new text");

Hope this helps,
                                        Owen



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