(self)
Write config if not found and watch for keyboard events.
Write config if not found and watch for keyboard events.
Write config if not found and watch for keyboard events .
def start(self):
        """ Write config if not found and watch for keyboard events. """
        self._get_config()
        self.root.change_attributes(event_mask=X.KeyPressMask)
        self._bind_keys()
        for event in range(0, self.root.display.pending_events()):
            self.root.display.next_event()
        GLib.io_add_watch(self.root.display, GLib.IO_IN, self._check_event)
        print('PyGrid running. Press CTRL+C to cancel.')
        Gtk.main()
def start ( self ) : self . _get_config ( ) self . root . change_attributes ( event_mask = X . KeyPressMask ) self . _bind_keys ( ) for event in range ( 0 , self . root . display . pending_events ( ) ) : self . root . display . next_event ( ) GLib . io_add_watch ( self . root . display , GLib . IO_IN , self . _check_event ) print ( 'PyGrid running. Press CTRL+C to cancel.' ) Gtk . main ( )