Re: Default Background Color

Andy Ma <[email protected]> Thu, 17 Feb 2005 13:20:42 -0800
Newsgroups gmane.comp.gnome.gtkmm,gmane.comp.gnome.gnomemm
Message-ID <[email protected]>
Besides using a RC file, can this set bg done in the code?
is using a RC file the only way?

On Thu, 17 Feb 2005 10:08:53 -0500 [email protected] wrote:
> >Hello,
> >
> >Does anybody know how to change the default background color of the=20
> >Gnome Canvas?
> >I'd like it to have a black background instead of the default grey col=
or.

> >I guess I can draw a black rectangle that covers the entire canvas
> but it'd
> >be nice if there is a proper way to do it.
>=20
> i do:
>=20
>   canvas->set_name ("MyNameForTheCanvas")
>=20
> and then in the applications' RC file:
>=20
> style "main_canvas_area"
> {
>	bg[NORMAL] =3D { 0.89, 0.88, 0.91 }
>	bg[ACTIVE] =3D { 0.89, 0.88, 0.91 }
>	bg[INSENSITIVE] =3D { 0.89, 0.88, 0.91 }
>	bg[SELECTED] =3D { 0.89, 0.88, 0.91 }
>	bg[PRELIGHT] =3D { 0.89, 0.88, 0.91 }
> }
>=20
> widget "*MyNameForTheCanvas" style "main_canvas_area"
>=20
> --p
>=20