Re: (no subject) GtkContainers
- From: Tristan Van Berkom <vantr touchtunes com>
- To: gtk-development itxolutions com
- Cc: gtk-app-devel-list gnome org
- Subject: Re: (no subject) GtkContainers
- Date: Wed, 09 Jun 2004 09:54:44 -0400
development said:
Hi guys.. 
I am developing an application in which a use GnomeCanvas object to draw a 
color scale. So far I managed how to do this, but now I need to delete those 
CanvasItems. I have been looking for a function that allows me to destroy 
the CanvasItem, I read that the correct one is gtk_object_destroy but the 
problem is that I could not find a way to get access to those CanvasItems. I 
know that  GtkObject has a parent property but I have not seen any 
gtk_object_get_children ..._child, etc. Also I have noticed that Glade 
implements a function whichs store children information using 
g_object_set_data. The big question is: Is there any function that allows me 
to have access to children objects? Should I implement my own way to store 
this information? 
Thanks in advance for any help...
    Any widget that contains another widget is a GtkContainer, it is
possible that (GTK_IS_BIN(GTK_CONTAINER(widget)) == TRUE), in that case
there is only one child which you can retrieve with `gtk_bin_get_child()'
but you should be able to retrieve it with `gtk_container_get_children()'
anyway, only you will have a one element `GList *' (assuming that GtkBin
behaves properly when you call its
`GTK_CONTAINER_GET_CLASS(gtk_bin)->get_children()' method.
I hope this is enlightening for you :-P
Cheers,
                                  -Tristan
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]