After changing the background color of an EventBox to blue, I would like to change it back to it's original color. I get the original color (before I change the color to blue) with

ebox = gtk.EventBox()
bgColor = ebox.get_style().copy().bg[gtk.STATE_NORMAL]

If I immediately follow this with

ebox.modify_bg(gtk.STATE_NORMAL, bgColor)

I will get a slightly different color from what it was originally. The color picker in the GIMP tells me that the original color is #dddbde, and the new color is #dcdad5.

Is there some way to get the exact background color that is being displayed?

I am using Gtk version 2.2.4 and pyGtk version 2.0.0.

Thanks,

Gary
_______________________________________________
pygtk mailing list   [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to