当前位置: 首页>>代码示例>>Python>>正文


Python HIGHBox.__init__方法代码示例

本文整理汇总了Python中zenmapGUI.higwidgets.higboxes.HIGHBox.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python HIGHBox.__init__方法的具体用法?Python HIGHBox.__init__怎么用?Python HIGHBox.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在zenmapGUI.higwidgets.higboxes.HIGHBox的用法示例。


在下文中一共展示了HIGHBox.__init__方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: from zenmapGUI.higwidgets.higboxes import HIGHBox [as 别名]
# 或者: from zenmapGUI.higwidgets.higboxes.HIGHBox import __init__ [as 别名]
    def __init__(self):
        """Initialize Scan Toolbar, including Events, and packing all
        of the GUI elements in layout"""
        HIGHBox.__init__(self)

        self._create_target()
        self._create_profile()

        self.scan_button = gtk.Button(_("Scan"))
        #self.scan_button = HIGButton(_("Scan "), gtk.STOCK_MEDIA_PLAY)
        self.cancel_button = gtk.Button(_("Cancel"))
        #self.cancel_button = HIGButton(_("Cancel "), gtk.STOCK_CANCEL)

        self._pack_noexpand_nofill(self.target_label)
        self._pack_expand_fill(self.target_entry)

        self._pack_noexpand_nofill(self.profile_label)
        self._pack_expand_fill(self.profile_entry)

        self._pack_noexpand_nofill(self.scan_button)
        self._pack_noexpand_nofill(self.cancel_button)

        # Skip over the dropdown arrow so you can tab to the profile entry.
        self.target_entry.set_focus_chain((self.target_entry.child,))

        self.target_entry.child.connect('activate',
                        lambda x: self.profile_entry.grab_focus())
        self.profile_entry.child.connect('activate',
                        lambda x: self.scan_button.clicked())
开发者ID:Abhikos,项目名称:nmap,代码行数:31,代码来源:ScanToolbar.py

示例2: __init__

# 需要导入模块: from zenmapGUI.higwidgets.higboxes import HIGHBox [as 别名]
# 或者: from zenmapGUI.higwidgets.higboxes.HIGHBox import __init__ [as 别名]
    def __init__(self):
        HIGHBox.__init__(self)
        self.information_label = gtk.Label()
        self.entry = gtk.Entry()

        self.pack_start(self.information_label, False)
        self.information_label.show()

        label = gtk.Label(_("Host Filter:"))
        self.pack_start(label, False)
        label.show()

        self.pack_start(self.entry, True, True)
        self.entry.show()

        help_button = gtk.Button()
        icon = gtk.Image()
        icon.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
        help_button.add(icon)
        help_button.connect("clicked", self._help_button_clicked)
        self.pack_start(help_button, False)
        help_button.show_all()

        self.entry.connect("changed", lambda x: self.emit("changed"))
开发者ID:0x00evil,项目名称:nmap,代码行数:26,代码来源:FilterBar.py


注:本文中的zenmapGUI.higwidgets.higboxes.HIGHBox.__init__方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。