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


Python Qt.WindowContextHelpButtonHint方法代码示例

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


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

示例1: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent, dialog, **kwargs):
            super(FIRSTUI.Dialog, self).__init__(parent)
            self.parent = parent
            self.data = None


            self.ui = dialog(**kwargs)
            self.ui.setupUi(self)

            self.should_show = self.ui.should_show

            self.accepted.connect(self.success_callback)
            self.rejected.connect(self.reject_callback)
            self.setWindowFlags(self.windowFlags() & ~Qt.WindowContextHelpButtonHint)

            self.hide_attempts = 0
            self.timer = QtCore.QTimer()
            self.timer.timeout.connect(self.__hide)
            self.timer.start(500) 
开发者ID:vrtadmin,项目名称:FIRST-plugin-ida,代码行数:21,代码来源:first.py

示例2: progress_dialog

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def progress_dialog(message):
    prgr_dialog = QProgressDialog()
    prgr_dialog.setFixedSize(300, 50)
    prgr_dialog.setAutoFillBackground(True)
    prgr_dialog.setWindowModality(Qt.WindowModal)
    prgr_dialog.setWindowTitle('Please wait')
    prgr_dialog.setLabelText(message)
    prgr_dialog.setSizeGripEnabled(False)
    prgr_dialog.setSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
    prgr_dialog.setWindowFlag(Qt.WindowContextHelpButtonHint, False)
    prgr_dialog.setWindowFlag(Qt.WindowCloseButtonHint, False)
    prgr_dialog.setModal(True)
    prgr_dialog.setCancelButton(None)
    prgr_dialog.setRange(0, 0)
    prgr_dialog.setMinimumDuration(0)
    prgr_dialog.setAutoClose(False)
    return prgr_dialog 
开发者ID:iGio90,项目名称:Dwarf,代码行数:19,代码来源:utils.py

示例3: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None):
        super().__init__(parent=parent)
        self._title = "Dwarf"
        self.setWindowFlag(Qt.WindowContextHelpButtonHint, False)
        self.setWindowFlag(Qt.WindowCloseButtonHint, True)

    # ************************************************************************
    # **************************** Properties ********************************
    # ************************************************************************ 
开发者ID:iGio90,项目名称:Dwarf,代码行数:11,代码来源:dwarf_dialog.py

示例4: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None, aw = None):
        super(ArtisanDialog,self).__init__(parent)
        self.aw = aw # the Artisan application window
        
        # IMPORTANT NOTE: if dialog items have to be access after it has been closed, this Qt.WA_DeleteOnClose attribute 
        # has to be set to False explicitly in its initializer (like in comportDlg) to avoid the early GC and one might
        # want to use a dialog.deleteLater() call to explicitly have the dialog and its widgets GCe
        # or rather use sip.delete(dialog) if the GC via .deleteLater() is prevented by a link to a parent object (parent not None)
        self.setAttribute(Qt.WA_DeleteOnClose, True)

#        if platf == 'Windows':
# setting those Windows flags could be the reason for some instabilities on Windows
#            windowFlags = self.windowFlags()
#        #windowFlags &= ~Qt.WindowContextHelpButtonHint # remove help button
#        #windowFlags &= ~Qt.WindowMaximizeButtonHint # remove maximise button
#        #windowFlags &= ~Qt.WindowMinMaxButtonsHint  # remove min/max combo
#        #windowFlags |= Qt.WindowMinimizeButtonHint  # Add minimize  button
#        windowFlags |= Qt.WindowSystemMenuHint  # Adds a window system menu, and possibly a close button
#            windowFlags |= Qt.WindowMinMaxButtonsHint  # add min/max combo
#            self.setWindowFlags(windowFlags)

        # configure standard dialog buttons
        self.dialogbuttons = QDialogButtonBox(QDialogButtonBox.Ok | QDialogButtonBox.Cancel,Qt.Horizontal)
        self.dialogbuttons.button(QDialogButtonBox.Ok).setDefault(True)
        self.dialogbuttons.button(QDialogButtonBox.Ok).setAutoDefault(True)
        self.dialogbuttons.button(QDialogButtonBox.Cancel).setDefault(False)
        self.dialogbuttons.button(QDialogButtonBox.Cancel).setAutoDefault(False)
        self.dialogbuttons.button(QDialogButtonBox.Ok).setFocusPolicy(Qt.StrongFocus) # to add to tab focus switch
        if self.aw.locale not in self.aw.qtbase_locales:
            self.dialogbuttons.button(QDialogButtonBox.Ok).setText(QApplication.translate("Button","OK", None))
            self.dialogbuttons.button(QDialogButtonBox.Cancel).setText(QApplication.translate("Button","Cancel",None))
        # add additional CMD-. shortcut to close the dialog
        self.dialogbuttons.button(QDialogButtonBox.Cancel).setShortcut(QKeySequence("Ctrl+."))
        # add additional CMD-W shortcut to close this dialog (ESC on Mac OS X)
        cancelAction = QAction(self, triggered=lambda _:self.dialogbuttons.rejected.emit())
        try:
            cancelAction.setShortcut(QKeySequence.Cancel)
        except:
            pass
        self.dialogbuttons.button(QDialogButtonBox.Cancel).addActions([cancelAction]) 
开发者ID:artisan-roaster-scope,项目名称:artisan,代码行数:42,代码来源:dialogs.py

示例5: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None):
        super(AboutDialog, self).__init__(parent)
        self.setupUi(self)
        self.setWindowFlags(self.windowFlags() ^ Qt.WindowContextHelpButtonHint) 
开发者ID:xiongyihui,项目名称:pqcom,代码行数:6,代码来源:main.py

示例6: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None, device='local'):
        super(DeviceWindow, self).__init__(parent=parent)

        self.spawn_list = None
        self.proc_list = None
        self.desktop_geom = None
        self._dev_bar = None

        self.setSizeGripEnabled(False)
        self.setSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
        self.setWindowFlag(Qt.WindowContextHelpButtonHint, False)
        self.setWindowFlag(Qt.WindowCloseButtonHint, True)
        self.setModal(True)

        self.device_type = device

        try:
            if device == 'local':
                self.device = frida.get_local_device()
                self.title = 'Local Session'
            elif device == 'usb':  # TODO: change
                self.title = 'Android Session'
                self.device = None
            elif device == 'ios':
                self.title = 'iOS Session'
                self.device = frida.get_usb_device()
            elif device == 'remote':
                self.title = 'Remote Session'
                self.device = frida.get_remote_device()
            else:
                self.device = frida.get_local_device()
        except frida.TimedOutError:
            self.device = None
            print('Frida TimedOutError: No Device')

        self.updated_frida_version = ''
        self.updated_frida_assets_url = {}

        self.frida_update_thread = None
        self.devices_thread = None

        self.setup_ui() 
开发者ID:iGio90,项目名称:Dwarf,代码行数:44,代码来源:device_window.py

示例7: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None):
        super(WelcomeDialog, self).__init__(parent=parent)

        self._prefs = parent.prefs

        self._sub_titles = [
            ['duck', 'dumb', 'doctor', 'dutch', 'dark', 'dirty', 'debugging'],
            ['warriors', 'wardrobes', 'waffles', 'wishes', 'worcestershire'],
            ['are', 'aren\'t', 'ain\'t', 'appears to be'],
            ['rich', 'real', 'riffle', 'retarded', 'rock'],
            [
                'as fuck', 'fancy', 'fucked', 'front-ended', 'falafel',
                'french fries'
            ],
        ]

        self._update_thread = None

        # setup size and remove/disable titlebuttons
        self.desktop_geom = qApp.desktop().availableGeometry()
        self.setFixedSize(self.desktop_geom.width() * .45,
                          self.desktop_geom.height() * .4)
        self.setGeometry(
            QStyle.alignedRect(Qt.LeftToRight, Qt.AlignCenter, self.size(),
                               qApp.desktop().availableGeometry()))
        self.setSizeGripEnabled(False)
        self.setSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
        self.setWindowFlag(Qt.WindowContextHelpButtonHint, False)
        self.setWindowFlag(Qt.WindowCloseButtonHint, True)
        self.setModal(True)

        self._recent_list_model = QStandardItemModel(0, 2)
        self._recent_list_model.setHeaderData(0, Qt.Horizontal, 'Type')
        self._recent_list_model.setHeaderData(1, Qt.Horizontal, 'Path')

        self._recent_list = DwarfListView(self)
        self._recent_list.setModel(self._recent_list_model)

        self._recent_list.header().setSectionResizeMode(0, QHeaderView.ResizeToContents)
        self._recent_list.header().setSectionResizeMode(1, QHeaderView.Stretch)

        # setup ui elements
        self.setup_ui()

        random.seed(a=None, version=2)

        self._base_path = getattr(sys, '_MEIPASS', os.path.dirname(os.path.abspath(__file__)))
        path_to_gitignore = os.path.join(self._base_path, os.pardir, os.pardir, '.gitignore')
        is_git_version = os.path.exists(path_to_gitignore)

        if is_git_version and os.path.isfile(path_to_gitignore):
            self.update_commits_thread = DwarfCommitsThread(parent)
            self.update_commits_thread.on_update_available.connect(
                self._on_dwarf_isupdate)
            self.update_commits_thread.start()

        # center
        self.setGeometry(
            QStyle.alignedRect(Qt.LeftToRight, Qt.AlignCenter, self.size(),
                               qApp.desktop().availableGeometry())) 
开发者ID:iGio90,项目名称:Dwarf,代码行数:62,代码来源:welcome_window.py

示例8: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, parent=None, ptr=None):
        super(AddWatchpointDialog, self).__init__(parent=parent)

        self.setWindowTitle('Add Watchpoint')
        self.setSizeGripEnabled(False)
        self.setSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed)
        self.setWindowFlag(Qt.WindowContextHelpButtonHint, False)
        self.setWindowFlag(Qt.WindowCloseButtonHint, True)
        self.setWindowFlag(Qt.MSWindowsFixedSizeDialogHint, True)

        v_box = QVBoxLayout()
        label = QLabel('Please insert a Pointer')
        v_box.addWidget(label)

        self.text_field = InputDialogTextEdit(self)
        self.text_field.setPlaceholderText(
            'Module.findExportByName(\'target\', \'export\')')
        if ptr:
            self.text_field.setPlainText(ptr)
        v_box.addWidget(self.text_field)

        self.acc_read = QCheckBox('Read')
        self.acc_read.setChecked(True)
        self.acc_write = QCheckBox('Write')
        self.acc_write.setChecked(True)
        self.acc_execute = QCheckBox('Execute')
        self.singleshot = QCheckBox('SingleShot')

        h_box = QHBoxLayout()
        h_box.addWidget(self.acc_read)
        h_box.addWidget(self.acc_write)
        h_box.addWidget(self.acc_execute)
        v_box.addLayout(h_box)
        v_box.addWidget(self.singleshot)

        h_box = QHBoxLayout()
        self._ok_button = QPushButton('OK')
        self._ok_button.clicked.connect(self.accept)
        self._cancel_button = QPushButton('Cancel')
        self._cancel_button.clicked.connect(self.close)
        h_box.addWidget(self._ok_button)
        h_box.addWidget(self._cancel_button)
        v_box.addLayout(h_box)
        self.setLayout(v_box)

    # pylint: disable=invalid-name 
开发者ID:iGio90,项目名称:Dwarf,代码行数:48,代码来源:watchpoints.py

示例9: __init__

# 需要导入模块: from PyQt5.QtCore import Qt [as 别名]
# 或者: from PyQt5.QtCore.Qt import WindowContextHelpButtonHint [as 别名]
def __init__(self, organizer, parent = None):
        self.__modListInfo = {}
        self.__profilesInfo = {}
        self.__organizer = organizer

        super(PluginWindow, self).__init__(parent)

        self.resize(500, 500)
        self.setWindowIcon(QtGui.QIcon(':/deorder/syncModOrder'))
        self.setWindowFlags(self.windowFlags() & ~Qt.WindowContextHelpButtonHint)

        # Vertical Layout
        verticalLayout = QtWidgets.QVBoxLayout()

        # Vertical Layout -> Merged Mod List (TODO: Better to use QTreeView and model?)
        self.profileList = QtWidgets.QTreeWidget()

        self.profileList.setColumnCount(1)
        self.profileList.setRootIsDecorated(False)

        self.profileList.header().setVisible(True)
        self.profileList.headerItem().setText(0, self.__tr("Profile name"))

        self.profileList.setContextMenuPolicy(Qt.CustomContextMenu)
        self.profileList.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self.profileList.customContextMenuRequested.connect(self.openProfileMenu)

        verticalLayout.addWidget(self.profileList)

        # Vertical Layout -> Button Layout
        buttonLayout = QtWidgets.QHBoxLayout()

        # Vertical Layout -> Button Layout -> Refresh Button
        refreshButton = QtWidgets.QPushButton(self.__tr("&Refresh"), self)
        refreshButton.setIcon(QtGui.QIcon(':/MO/gui/refresh'))
        refreshButton.clicked.connect(self.refreshProfileList)
        buttonLayout.addWidget(refreshButton)

        # Vertical Layout -> Button Layout -> Close Button
        closeButton = QtWidgets.QPushButton(self.__tr("&Close"), self)
        closeButton.clicked.connect(self.close)
        buttonLayout.addWidget(closeButton)

        verticalLayout.addLayout(buttonLayout)

        # Vertical Layout
        self.setLayout(verticalLayout)

        # Build lookup dictionary of all profiles
        self.__profileInfo = self.getProfileInfo()

        # Build lookup dictionary of mods in current profile
        self.__modListInfo = self.getModListInfoByPath(os.path.join(self.__organizer.profilePath(), 'modlist.txt'))

        self.refreshProfileList() 
开发者ID:deorder,项目名称:mo2-plugins,代码行数:57,代码来源:syncModOrder.py


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