lists.zerezo.com
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
***BOGO*** Gtk color API
- Date: Sat, 29 Mar 2008 03:14:52 -0500
- From: "nisha jain" <jain61@xxxxxxxxx>
- Subject: ***BOGO*** Gtk color API
Hi All,
I have requirement of making boxes filled with colors without any functionality.
To acheive this i am using the labels and trying to fill them with colors
as doing it with other widgets i am not able to figure out...
I am using following code to acheive it but i am not getting any output...
GtkWidgets *labels[2];
GtkWidget color;
for(i = 0; i<2; i++)
{
labels[i] = gtk_label_new("");
}
gdk_color_parse("red", &color);
gtk_widget_modify_bg(GTK_WIDGET(labels[0]), GTK_STATE_NORMAL, &color);
gdk_color_parse("green", &color);
gtk_widget_modify_bg(GTK_WIDGET(labels[1]), GTK_STATE_NORMAL, &color);
I am trying to pack these in a box but that is not working though i am not getting any errors.
Please let me know if some one has similar functionality in any application? How i can acheive this?
Regards,
Nisha
_______________________________________________
gtk-devel-list mailing list
gtk-devel-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-devel-list