Hi Art,
I don't think you should get the same gtk.gdk.Color object returned from:
da.get_style().bg[gtk.STATE_NORMAL]
even twice in a row. A new gtk.gdk.Color object is created each time. I assume that the rgb values are the same though.
John
Art Haas wrote:
Hi.
I'm sure this can be done and I'm just overlooking something. I set the background color of a gtk.DrawingArea widget like so ...
da = gtk.DrawingArea() color = gtk.gdk.color_parse('#ff3355') # any color will do da.modify_bg(gtk.STATE_NORMAL, color)
In a callback I'd like to retreive the color, so I thought this would work ...
color = da.get_style().bg[gtk.STATE_NORMAL]
This doesn't seem to work though, and I can't seem to find the magic call sequence so the same color object is printed when using ``. The get_modifier_style() method doesn't work either.
What am I missing? Just how can one find the color set by modify_bg()?
Thanks in advance.
Art Haas
_______________________________________________ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
