problem with modify_fg



Hello,

I am using Gtkmm, and I am new to it and to Gtk.
I'v got a Gtk::Label widget, and I'm trying to change it's forground color, but it remain black. Here is the code where I try to change the color of the widget, which has been inilized earlier in the program, and has already been displayed.

Gdk::Color color;
color.set_rgb(0,0,255);
m_label->modify_fg(Gtk::STATE_NORMAL, color);
m_label->modify_fg(Gtk::STATE_ACTIVE, color);
m_label->modify_fg(Gtk::STATE_INSENSITIVE, color);
m_label->modify_fg(Gtk::STATE_PRELIGHT, color);
m_label->modify_fg(Gtk::STATE_SELECTED, color);

Thanks,

Oded.




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