Python PyQt4.QtCore.Qt 模块,Unchecked() 实例源码

我们从Python开源项目中,提取了以下6个代码示例,用于说明如何使用PyQt4.QtCore.Qt.Unchecked()

项目:segyviewer    作者:Statoil    | 项目源码 | 文件源码
def _initialize(self, indexes):
        self._indexes = indexes
        # set up initial min max values
        self.current_index = 0
        self.min_index = 0
        self.max_index = len(self._indexes) - 1

        self.index_s_box.update_view(self._indexes, self.current_index)

        self._min_spinbox.update_view(self._indexes, self.min_index)
        self._max_spinbox.update_view(self._indexes, self.max_index)

        self._min_spinbox.setMaximum(self.max_index - 1)
        self._max_spinbox.setMinimum(self.min_index + 1)

        self._max_active.setCheckState(Qt.Unchecked)
        self._min_active.setCheckState(Qt.Unchecked)

        self._update_label()
        self._min_max_value_changed()
项目:QGIS-CKAN-Browser    作者:BergWerkGIS    | 项目源码 | 文件源码
def window_loaded(self):
        try:
            self.util.msg_log('window_loaded')
            self.util.msg_log('before stop')
            self.timer.stop()
            self.timer = None
            self.util.msg_log('before get_groupds')
            ok, result = self.cc.get_groups()
            if ok is False:
                QApplication.restoreOverrideCursor()
                self.util.dlg_warning(result)
                return

            if not result:
                self.list_all_clicked()
            else:
                for entry in result:
                    item = QListWidgetItem(entry['display_name'])
                    item.setData(Qt.UserRole, entry)
                    #item.setCheckState(Qt.Checked)
                    item.setCheckState(Qt.Unchecked)
                    self.IDC_listGroup.addItem(item)
        finally:
            QApplication.restoreOverrideCursor()
项目:batch_gps_importer    作者:wondie    | 项目源码 | 文件源码
def on_fields_group_box_toggled(self):
        """
        A slot raised when the fields group box is checked or unchecked.
        Removes the selection from all fields when unchecked and selects all
        fields when checked.
        """
        for text, column in self.field_items.iteritems():
            items = self.exclude_fields_view.model().findItems(
                text, Qt.MatchExactly, column
            )
            for item in items:
                if self.exclude_fields_groupbox.isChecked():
                    item.setCheckState(Qt.Checked)
                else:
                    item.setCheckState(Qt.Unchecked)
项目:batch_gps_importer    作者:wondie    | 项目源码 | 文件源码
def on_fields_toggled(self, item):
        """
        A slot raised when a field is checked or unchecked.
        The field unchecked is added to excluded_fields list. If checked,
        the field will be removed from the excluded_list.
        :param item: The field item
        :type item: QStandardItem
        """
        if item.checkState() == Qt.Unchecked:
            self.excluded_fields.append(item.text())
        else:
            self.excluded_fields.remove(item.text())
项目:QGIS-CKAN-Browser    作者:BergWerkGIS    | 项目源码 | 文件源码
def resultitemchanged(self, new_item):
        self.IDC_textDetails.setText('')
        self.IDC_listRessources.clear()
        self.IDC_plainTextLink.clear()
        if new_item is None:
            return
        package = new_item.data(Qt.UserRole)
        self.cur_package = package
        if package is None:
            return
        self.IDC_textDetails.setText(
            u'{0}\n\n{1}\n{2}\n\n{3}'.format(
                package.get('notes', 'no notes'),
                package.get('author', 'no author'),
                package.get('author_email', 'no author_email'),
                package.get('license_id', 'no license_id')
            )
        )
        if package.get('num_resources', 0) > 0:
            for res in package['resources']:
                item = QListWidgetItem(u'{0}: {1}'.format(
                    res.get('format', 'no format')
                    , res.get('name', 'no name')
                ))
                item.setData(Qt.UserRole, res)
                item.setCheckState(Qt.Unchecked)
                self.IDC_listRessources.addItem(item)
项目:rexploit    作者:DaniLabs    | 项目源码 | 文件源码
def setCheckBoxVulnerableChecked(self, checked=True):
        """
        This function changes checkbox's state
        :param checked: True or False
        :return: None
        """
        if checked:
            self.checkBoxVulnerable.setCheckState(Qt.Checked)
        else:
            self.checkBoxVulnerable.setCheckState(Qt.Unchecked)