buffalo_panel.app.gui.TypeDelegate
- class buffalo_panel.app.gui.TypeDelegate[source]
Bases:
QStyledItemDelegateDelegate to show specialized editors (Combo Boxes) in the tree view.
Methods
blockSignals(self, b)childEvent(self, a0)children(self)connectNotify(self, signal)createEditor(parent, option, index)Create a Qt editor matching the schema metadata for one field.
customEvent(self, a0)deleteLater(self)destroyEditor(self, editor, index)disconnect(-> bool)disconnectNotify(self, signal)displayText(self, value, locale)dumpObjectInfo(self)dumpObjectTree(self)dynamicPropertyNames(self)editorEvent(self, event, model, option, index)event(self, a0)eventFilter(self, object, event)findChild(-> QObjectT)findChildren(...)handleEditorEvent(self, object, event)helpEvent(self, event, view, option, index)inherits(self, classname)initStyleOption(self, option, index)installEventFilter(self, a0)isQmlExposed(self)isQuickItemType(self)isSignalConnected(self, signal)isWidgetType(self)isWindowType(self)itemEditorFactory(self)killTimer(self, id)metaObject(self)moveToThread(self, thread)objectName(self)paint(self, painter, option, index)parent(self)property(self, name)pyqtConfigure(...)Each keyword argument is either the name of a Qt property or a Qt signal.
receivers(self, signal)removeEventFilter(self, a0)sender(self)senderSignalIndex(self)setEditorData(editor, index)Populate the editor with the current data from the model.
setItemEditorFactory(self, factory)setModelData(editor, model, index)Validate and transfer data from the editor back to the model.
setObjectName(self, name)setParent(self, a0)setProperty(self, name, value)signalsBlocked(self)sizeHint(self, option, index)startTimer(self, interval[, timerType])thread(self)timerEvent(self, a0)tr(sourceText[, disambiguation, n])updateEditorGeometry(self, editor, option, index)- createEditor(parent, option, index)[source]
Create a Qt editor matching the schema metadata for one field.
Dispatches specialized editors (like QComboBox for enums) based on the item’s metadata role or specific field names like ‘airfoil’.
- Parameters:
parent (
QtWidgets.QWidget | None) – The parent widget for the editor.option (
QtWidgets.QStyleOptionViewItem) – Style options for the item being edited.index (
QtCore.QModelIndex) – The model index of the item.
- Returns:
The created editor widget, or None if the field is read-only.
- Return type:
QtWidgets.QWidget | None
- setEditorData(editor, index)[source]
Populate the editor with the current data from the model.
- Parameters:
editor (
QtWidgets.QWidget | None) – The editor widget.index (
QtCore.QModelIndex) – The index of the item being edited.
- setModelData(editor, model, index)[source]
Validate and transfer data from the editor back to the model.
- Parameters:
editor (
QtWidgets.QWidget | None) – The editor widget.model (
QtCore.QAbstractItemModel | None) – The target model.index (
QtCore.QModelIndex) – The index of the item being updated.
- classmethod blockSignals(self, b: bool) bool
- classmethod childEvent(self, a0: QChildEvent | None)
- classmethod children(self) list[QObject]
- classmethod connectNotify(self, signal: QMetaMethod)
- classmethod customEvent(self, a0: QEvent | None)
- classmethod deleteLater(self)
- classmethod destroyEditor(self, editor: QWidget | None, index: QModelIndex)
- classmethod disconnect(a0: QMetaObject.Connection) bool
- classmethod disconnect(self) None
- classmethod disconnectNotify(self, signal: QMetaMethod)
- classmethod displayText(self, value: Any, locale: QLocale) str
- classmethod dumpObjectInfo(self)
- classmethod dumpObjectTree(self)
- classmethod dynamicPropertyNames(self) list[QByteArray]
- classmethod editorEvent(self, event: QEvent | None, model: QAbstractItemModel | None, option: QStyleOptionViewItem, index: QModelIndex) bool
- classmethod event(self, a0: QEvent | None) bool
- classmethod eventFilter(self, object: QObject | None, event: QEvent | None) bool
- classmethod findChild(self, type: type[QObjectT], name: str | None = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObjectT
- classmethod findChild(self, types: tuple[type[QObjectT], ...], name: str | None = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) QObjectT
- classmethod findChildren(self, type: type[QObjectT], name: str | None = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) list[QObjectT]
- classmethod findChildren(self, types: tuple[type[QObjectT], ...], name: str | None = '', options: Qt.FindChildOption = Qt.FindChildrenRecursively) list[QObjectT]
- classmethod findChildren(self, type: type[QObjectT], re: QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) list[QObjectT]
- classmethod findChildren(self, types: tuple[type[QObjectT], ...], re: QRegularExpression, options: Qt.FindChildOption = Qt.FindChildrenRecursively) list[QObjectT]
- classmethod handleEditorEvent(self, object: QObject | None, event: QEvent | None) bool
- classmethod helpEvent(self, event: QHelpEvent | None, view: QAbstractItemView | None, option: QStyleOptionViewItem, index: QModelIndex) bool
- classmethod inherits(self, classname: str) bool
- classmethod initStyleOption(self, option: QStyleOptionViewItem | None, index: QModelIndex)
- classmethod installEventFilter(self, a0: QObject | None)
- classmethod isQmlExposed(self) bool
- classmethod isQuickItemType(self) bool
- classmethod isSignalConnected(self, signal: QMetaMethod) bool
- classmethod isWidgetType(self) bool
- classmethod isWindowType(self) bool
- classmethod itemEditorFactory(self) QItemEditorFactory | None
- classmethod killTimer(self, id: int)
- classmethod metaObject(self) QMetaObject | None
- classmethod moveToThread(self, thread: QThread | None)
- classmethod objectName(self) str
- classmethod paint(self, painter: QPainter | None, option: QStyleOptionViewItem, index: QModelIndex)
- classmethod parent(self) QObject | None
- classmethod property(self, name: str) Any
- classmethod pyqtConfigure(...)
Each keyword argument is either the name of a Qt property or a Qt signal. For properties the property is set to the given value which should be of an appropriate type. For signals the signal is connected to the given value which should be a callable.
- classmethod receivers(self, signal: PYQT_SIGNAL) int
- classmethod removeEventFilter(self, a0: QObject | None)
- classmethod sender(self) QObject | None
- classmethod senderSignalIndex(self) int
- classmethod setItemEditorFactory(self, factory: QItemEditorFactory | None)
- classmethod setObjectName(self, name: QByteArray | bytes | bytearray | memoryview | str | None)
- classmethod setParent(self, a0: QObject | None)
- classmethod setProperty(self, name: str, value: Any) bool
- classmethod signalsBlocked(self) bool
- classmethod sizeHint(self, option: QStyleOptionViewItem, index: QModelIndex) QSize
- classmethod startTimer(self, interval: int, timerType: Qt.TimerType = Qt.CoarseTimer) int
- classmethod thread(self) QThread | None
- classmethod timerEvent(self, a0: QTimerEvent | None)
- classmethod tr(sourceText: str, disambiguation: str = None, n: int = -1) str
- classmethod updateEditorGeometry(self, editor: QWidget | None, option: QStyleOptionViewItem, index: QModelIndex)