2007-02-27 13:41:51 +01:00
|
|
|
import hippo
|
|
|
|
import gtk
|
|
|
|
|
|
|
|
class Window(gtk.Window):
|
|
|
|
def __init__(self, window_type=gtk.WINDOW_TOPLEVEL):
|
|
|
|
gtk.Window.__init__(self, window_type)
|
|
|
|
|
|
|
|
self._canvas = hippo.Canvas()
|
|
|
|
self.add(self._canvas)
|
|
|
|
self._canvas.show()
|
|
|
|
|
2007-02-27 13:56:00 +01:00
|
|
|
self._canvas.connect_after('realize', self._window_realize_cb)
|
|
|
|
|
2007-02-27 13:41:51 +01:00
|
|
|
def set_root(self, root):
|
|
|
|
self._canvas.set_root(root)
|
|
|
|
|
2007-02-27 13:56:00 +01:00
|
|
|
def _window_realize_cb(self, canvas):
|
|
|
|
canvas.window.set_back_pixmap(None, False)
|