Re: Why gtk_bin_get_child() does not work?

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

 



On 2006-07-08 02:26:46 AM, Micah Carrick wrote:
> This should work:
> 
> GtkWidget *radio
> 
> /*
> More code here to get or create 'radio' as
> a GtkRadioButton widget
> */
> 
> gtk_label_set_markup(GTK_LABEL(GTK_BIN(radio)->child),
> "<b>hello</b>");

Can't see how accessing the child member directly is going to help  
anything. I suspect his problem is that using  
gtk_radio_button_new(NULL) creates a button without a child. The  
solution would seem to be either to use  
gtk_radio_button_new_with_label("xxx") and then modify the generated  
label or create his own label and add it to the button with  
gtk_container_add().

Cheers,

Ali.
_______________________________________________

gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux