bindiff.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:bokken 作者: thestr4ng3r 项目源码 文件源码
def __init__(self):
        GObject.GObject.__init__(self)

        # XDotWidget
        xdotwidget = self.xdotwidget = xdot.DotWidget()
        # Toolbar
        uimanager = Gtk.UIManager()
        actiongroup = Gtk.ActionGroup('Actions')
        actiongroup.add_actions((
            ('ZoomIn', Gtk.STOCK_ZOOM_IN, None, None, None, self.xdotwidget.on_zoom_in),
            ('ZoomOut', Gtk.STOCK_ZOOM_OUT, None, None, None, self.xdotwidget.on_zoom_out),
            ('ZoomFit', Gtk.STOCK_ZOOM_FIT, None, None, None, self.xdotwidget.on_zoom_fit),
            ('Zoom100', Gtk.STOCK_ZOOM_100, None, None, None, self.xdotwidget.on_zoom_100),
        ))
        uimanager.insert_action_group(actiongroup, 0)
        uimanager.add_ui_from_string(self.ui)
        toolbar = uimanager.get_widget('/ToolBar')
        toolbar.set_icon_size(Gtk.IconSize.SMALL_TOOLBAR)
        toolbar.set_style(Gtk.ToolbarStyle.ICONS)
        toolbar.set_show_arrow(False)
        label = self.label = Gtk.Label()
        hbox = Gtk.HBox(False, 5)
        hbox.pack_start(toolbar, False, True, 0)
        hbox.pack_start(label, False, True, 0)
        self.pack_start(hbox, False, True, 0)
        self.pack_start(xdotwidget, True, True, 0)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号