Class: QgsFeatureListViewDelegate

class qgis.gui.QgsFeatureListViewDelegate(listModel: QgsFeatureListModel | None, parent: QObject | None = None)

Bases: PyQt5.QtWidgets.QItemDelegate

EditElement = 0
class Element

Bases: int

ICON_SIZE = 24
SelectionElement = 1
childEvent(self, a0: QChildEvent | None)
connectNotify(self, signal: QMetaMethod)
customEvent(self, a0: QEvent | None)
disconnectNotify(self, signal: QMetaMethod)
drawBackground(self, painter: QPainter | None, option: QStyleOptionViewItem, index: QModelIndex)
drawCheck(self, painter: QPainter | None, option: QStyleOptionViewItem, rect: QRect, state: Qt.CheckState)
drawDecoration(self, painter: QPainter | None, option: QStyleOptionViewItem, rect: QRect, pixmap: QPixmap)
drawDisplay(self, painter: QPainter | None, option: QStyleOptionViewItem, rect: QRect, text: str | None)
drawFocus(self, painter: QPainter | None, option: QStyleOptionViewItem, rect: QRect)
editButtonClicked

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.

Parameters:
  • name (str = ...)

  • revision (int = ...)

  • arguments (Sequence = ...)

Return type:

PYQT_SIGNAL

editorEvent(self, event: QEvent | None, model: QAbstractItemModel | None, option: QStyleOptionViewItem, index: QModelIndex) bool
eventFilter(self, object: QObject | None, event: QEvent | None) bool
isSignalConnected(self, signal: QMetaMethod) bool
paint(self, painter: QPainter | None, option: QStyleOptionViewItem, index: QModelIndex)
Parameters:
  • painter (Optional[QPainter])

  • option (QStyleOptionViewItem)

  • index (QModelIndex)

positionToElement(self, pos: QPoint) QgsFeatureListViewDelegate.Element
Parameters:

pos (QPoint)

Return type:

QgsFeatureListViewDelegate.Element

receivers(self, signal: PYQT_SIGNAL) int
sender(self) QObject | None
senderSignalIndex(self) int
setCurrentFeatureEdited(self, state: bool)
Parameters:

state (bool)

setEditSelectionModel(self, editSelectionModel: QItemSelectionModel | None)
Parameters:

editSelectionModel (Optional[QItemSelectionModel])

setFeatureSelectionModel(self, featureSelectionModel: QgsFeatureSelectionModel | None)
Parameters:

featureSelectionModel (Optional[QgsFeatureSelectionModel])

sizeHint(self, option: QStyleOptionViewItem, index: QModelIndex) QSize
Parameters:
  • option (QStyleOptionViewItem)

  • index (QModelIndex)

Return type:

QSize

timerEvent(self, a0: QTimerEvent | None)