python类VPaned()的实例源码

main.py 文件源码 项目:apart-gtk 作者: alexheretic 项目源码 文件源码 阅读 23 收藏 0 点赞 0 评论 0
def __init__(self,
                 core: ApartCore,
                 sources: List[Dict[str, Any]],
                 z_options: List[str]):
        Gtk.Box.__init__(self)
        self.core = core

        right_panes = Gtk.VPaned(expand=True)
        self.main_view = MainView(core, z_options)
        self.info_view = ClonePartInfo(sources, core, self.main_view)
        right_panes.pack1(self.info_view, shrink=False)
        right_panes.pack2(self.main_view, shrink=False)

        self.side_bar_box = Gtk.EventBox()
        self.side_bar_box.add(Gtk.StackSidebar(stack=self.info_view))
        self.side_bar_box.connect('button-press-event', self.side_bar_click)

        self.paned = Gtk.Paned(expand=True)
        self.paned.pack1(self.side_bar_box, shrink=False)
        self.paned.pack2(right_panes, shrink=False)

        self.add(self.paned)


问题


面经


文章

微信
公众号

扫码关注公众号