简体   繁体   中英

Python Window Resize

Using Python + PyGTK. Is there a signal/event way of checking for a window resize? If so then what is the easiest way of implementing and using this signal.

a gtk.Window is also a gtk.Container , so it answers to the check-resize signal.

Here's minimal sample code:

import gtk

def changed(window):
    print 'I have resized.'

w = gtk.Window()
w.connect('check-resize', changed)
w.show()
gtk.main()

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM