View Single Post
daperl's Avatar
Posts: 2,427 | Thanked: 2,986 times | Joined on Dec 2007
#3
My opinion is that every widget inherits its pango context from its container parent. I don't think it makes a copy. But if it does, I would just make a recursive call starting at the top level window.

Maybe use the gtk.Container.get_children() call

The pseudo code might look something like this:

Code:
window.changePango(window)

def changePango (self, child):
    if child is a container:
        for subChild in child.get_children():
            changePango (subChild)
    else:
        change the child's pango context
If a child doesn't make a copy, just change the toplevel window's pango context and then maybe call the toplevel window's check_resize().

Check gtk.Container for more info.
__________________
N9: Go white or go home

Last edited by daperl; 2009-06-09 at 19:28.
 

The Following 3 Users Say Thank You to daperl For This Useful Post: