def flags(self, index): """ return the item flags """ if not index.isValid(): return Qt.ItemIsEnabled return Qt.ItemFlags(QAbstractTableModel.flags(self, index))
def flags(self, index): ans = QAbstractTableModel.flags(self, index) return ans | Qt.ItemIsUserCheckable
def flags(self, index): col = index.column() ans = QAbstractTableModel.flags(self, index) if col == 0: return ans | Qt.ItemIsUserCheckable return Qt.ItemIsEditable | ans
def flags(self, index): if index.column() == 3: return QAbstractTableModel.flags(self, index) | Qt.ItemIsUserCheckable else: return QAbstractTableModel.flags(self, index) | Qt.ItemIsEditable
def flags(self, index): flags = QAbstractTableModel.flags(self, index) if index.isValid(): if index.row() == 0: flags |= Qt.ItemIsDropEnabled return flags
def flags(self, index): flags = QAbstractTableModel.flags(self, index) flags |= Qt.ItemIsEditable return flags