Re: Naming / Labelling Widgets



On Wed, 2006-04-05 at 14:50 -0600, Richard Plana wrote:
> Hi,
> 
> Is there a way to name / label and identify a widget? I'm pretty new
> to Gtk programming and right now, once I've created my GtkWidget
> hierarchy, there seems to be very little light support to traversing
> it. For certain, each widget has a generic method for getting its
> parent and children, but some widgets support non-linear placement
> (like tables). Yet there seems to be no method to accessing
> specialized container contents.
> 
> The generic serialized method for accessing children is okay, I
> suppose, but it's made a bit difficult for me by the fact that I can't
> seem to label widgets (much more read back those labels). Do functions
> exists that would help me with what I'm doing? Or should I just
> hardcode a widget's numeric index and update that index if the widget
> structure should change?

its sound to me as if you are coming from a different GUI toolkit and
are attempting to apply a programming model used there to GTK, when in
fact a different model would be more appropriate. i've been using GTK
for 7 years, and i simply never do anything like what you're describing.
what problem are you trying to solve? btw, i do use gtk_widget_set_name
() a lot but that is because it allows me to use RC files for style
settings, nothing more.

--p





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