Re: [gtk-list] Re: [OT] How to change button label ?!





On Wed, 18 Aug 1999, Sven Anders wrote:

> 
> On Tue, 17 Aug 1999, Tom Gilbert wrote:
> 
> > * Sven Anders (anderss@fmi.uni-passau.de) [99081721:53]:
> >
> > > I'm missing one question in the FAQ:
> > > 
> > >  How to change a button's label after it's creation ?!
> > > 
> > 
> > I use gtk_label_set_text( GTK_LABEL(label), "New text" );
> 
> But, who do I get to the label ?
> I have only the button !
> (I'm using glade and I dont want to edit the source code glade emit.)
> 

This should do it for ya:

  gtk_label_set_text( GTK_LABEL( GTK_BIN(button)->child ), "New text" );
 

Ted Roth



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