> But how can I obtain the window's position within the root
> window (and for that matter, the dimensions of the root window)?  

I figured out the answers to these -- self.get_window().x and
self.get_window().y and screen_width(), screen_height().  

But now I'm really stuck.  Quite simply, I want to be able to change
the colours of individual buttons.  For any one GtkButton 'but',

but.get_style().bg_gc[STATE_NORMAL].foreground = \
         _gtk.gdk_color_alloc(but._o,60000,0,0)

will make *all* of my buttons red.  (Obviously I'd use a colour
selection dialog to obtain the colour; this is just testing code.)
What (I think) I really want to set is

but.get_style().bg[STATE_NORMAL]

which also returns the colour of the button.  However, there is only a
getattr method for it in gtkmodule; no setattr, so I get no result
from assigning a gdkcolor to it.  Am I completely on the wrong track?
How should I really be going about this?

(I know in general you shouldn't override the current theme, but I
only intend to do it at the user's behest -- the app consists only of
a large number of buttons and the user should be able to colour-code
them in order to find them quickly.)

-Rob

To unsubscribe: echo "unsubscribe" | mail [EMAIL PROTECTED]

Reply via email to