class MainWindow(gtk.Window): """Main Window for asma""" def __init__(self): """init""" gtk.Window.__init__(self) self.asma = Asma() self._set_style() self._create_ui() self._listen_signals() def _set_style(self): self.set_title("Asma") self.set_default_size(648, 400) self.set_icon_name("asma") def _create_ui(self): self.add(self.asma) self.asma.show() def _listen_signals(self): self.connect("destroy", gtk.main_quit) def run(self, args): """runs program with args Arguments: - `args`: sys.argv """ self.show() gtk.main()
def __init__(self): """init""" gtk.Window.__init__(self) self.asma = Asma() self._set_style() self._create_ui() self._listen_signals()