Hi

I do
void ChangeColor(  GtkWidget *hCtrl,ULONG hColor) // color in rgb format
{
  GtkWidget *label ;
 GdkColor fColor ;

  if (GTK_IS_BUTTON(hCtrl) )
     label = gtk_bin_get_child(GTK_BIN(hCtrl));
  hwg_parse_color( hColor, &fColor );
  gtk_widget_modify_fg(label,GTK_STATE_NORMAL,&fColor);
}

----- Original Message ----- 
From: "Lukasz Gromotowicz" <[EMAIL PROTECTED]>
To: <gtk-app-devel-list@gnome.org>
Sent: Monday, May 12, 2008 1:12 PM
Subject: text color on the button


> Hi all,
>
> I can not find anywhere the complete description of how to change the 
> color
> on the button label. I know I have to access the label which is on the
> button and then set the color with "gtk_widget_modify_fg()", but how can I
> get this label? I have created the button using gtk_button_new_with_label.
>
> Could anyone help me please?
>
> Best regards,
> LUK
> _______________________________________________
> gtk-app-devel-list mailing list
> gtk-app-devel-list@gnome.org
> http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
> 

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to