Beispiel #1
0
    def __init__(self, win):
        super(Worksheet, self).__init__()
        self.win = win
        self.app = win.app
        self.connection = None
        self.editor = Editor(self)
        self.editor_context = EditorContext(self)
        self.results = Results(self)

        sw = Gtk.ScrolledWindow()
        sw.add(self.editor)

        sw_context = Gtk.ScrolledWindow()
        sw_context.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC)
        sw_context.add(self.editor_context)

        self._context_paned = Gtk.HPaned()
        if self.app.args.experimental:
            self._context_paned.add1(sw_context)
        self._context_paned.add2(sw)
        self._context_paned.set_position(200)
        self.add1(self._context_paned)

        self.add2(self.results)

        self.connect('realize', self.on_map_event)
        self.connect('size-allocate', self.on_size_allocate)
        self.app.connection_manager.connect('connection-deleted',
                                            self.on_connection_deleted)
Beispiel #2
0
    def __init__(self, win):
        super(Worksheet, self).__init__()
        self.win = win
        self.app = win.app
        self.connection = None
        self.editor = Editor(self)
        self.results = Results(self)

        sw = Gtk.ScrolledWindow()
        sw.add(self.editor)
        self.add1(sw)

        self.add2(self.results)

        self.connect('realize', self.on_map_event)
        self.app.connection_manager.connect(
            'connection-deleted', self.on_connection_deleted)