Re: setting background and foreground colors
- From: Yann Leydier <yann leydier info>
- To: gtkmm-list gnome org
- Subject: Re: setting background and foreground colors
- Date: Fri, 28 Jan 2011 10:11:30 +0100
It seems that you're mixing Gtkmm and Gdk.
You should try something like that :
Gdk::Color my_blue;
viewer->modify_bg(Gtk::STATE_NORMAL, my_blue);
yann
On 27/01/11 21:23, Charles Seedle wrote:
I got this particular piece of code to compile but it doesn’t change the
colors. Any ideas ?
Randy Seedle
Glib::RefPtr<Gdk::Window> win = viewer->get_root_window();
Glib::RefPtr<Gdk::GC> some_gc = Gdk::GC::create(win);
GdkColor my_blue;
GdkColor my_gray;
my_gray.red = 0xc900;
my_gray.green = 0xca00;
my_gray.blue = 0xc800;
my_blue.red = 0x0000;
my_blue.green = 0x7200;
my_blue.blue = 0xc800;
gtk_widget_modify_bg( GTK_WIDGET(&win), GTK_STATE_NORMAL, &my_blue );
gtk_widget_modify_fg( GTK_WIDGET(&win), GTK_STATE_NORMAL, &my_gray );
_______________________________________________
gtkmm-list mailing list
gtkmm-list gnome org
http://mail.gnome.org/mailman/listinfo/gtkmm-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]