Skip to content

PythonQt.QtGui.QStandardItem · declarations 001

Back to PythonQt.QtGui.QStandardItem

accessibleDescription

accessibleDescription() -> str

X.accessibleDescription() -> str

Supplemental documentation: Qt 5 reference:

QString QStandardItem::accessibleDescription() const

Returns the item's accessible description.

The accessible description is used by assistive technologies (i.e. for users who cannot use conventional means of interaction).

See also setAccessibleDescription() and accessibleText().

Upstream PySide2 reference signatures (binding differences may apply):

accessibleDescription(self) -> str

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#accessibleDescription

accessibleText

accessibleText() -> str

X.accessibleText() -> str

Supplemental documentation: Qt 5 reference:

QString QStandardItem::accessibleText() const

Returns the item's accessible text.

The accessible text is used by assistive technologies (i.e. for users who cannot use conventional means of interaction).

See also setAccessibleText() and accessibleDescription().

Upstream PySide2 reference signatures (binding differences may apply):

accessibleText(self) -> str

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#accessibleText

appendColumn

appendColumn(items: Any) -> None

X.appendColumn(items)

Supplemental documentation: Qt 5 reference:

void QStandardItem::appendColumn(const QList\<QStandardItem *> \&items)

Appends a column containing items. If necessary, the row count is increased to the size of items.

See also insertColumn().

Upstream PySide2 reference signatures (binding differences may apply):

appendColumn(self, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#appendColumn

appendRow

appendRow(item: Any) -> None

X.appendRow(item)

Supplemental documentation: Qt 5 reference:

void QStandardItem::appendRow(const QList\<QStandardItem *> \&items)

Appends a row containing items. If necessary, the column count is increased to the size of items.

See also insertRow().

void QStandardItem::appendRow(QStandardItem *item)

This is an overloaded function.

Appends a row containing item.

When building a list or a tree that has only one column, this function provides a convenient way to append a single new item.

Upstream PySide2 reference signatures (binding differences may apply):

appendRow(self, item: PySide2.QtGui.QStandardItem) -> None
appendRow(self, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#appendRow

appendRows

appendRows(items: Any) -> None

X.appendRows(items)

Supplemental documentation: Qt 5 reference:

void QStandardItem::appendRows(const QList\<QStandardItem *> \&items)

Appends rows containing items. The column count will not change.

See also insertRow().

Upstream PySide2 reference signatures (binding differences may apply):

appendRows(self, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#appendRows

background

background() -> Any

X.background() -> PythonQt.QtGui.QBrush

Supplemental documentation: Qt 5 reference:

QBrush QStandardItem::background() const

Returns the brush used to render the item's background.

See also foreground() and setBackground().

Upstream PySide2 reference signatures (binding differences may apply):

background(self) -> PySide2.QtGui.QBrush

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#background

checkState

checkState() -> Any

X.checkState()

Supplemental documentation: Qt 5 reference:

Qt::CheckState QStandardItem::checkState() const

Returns the checked state of the item.

See also setCheckState() and isCheckable().

Upstream PySide2 reference signatures (binding differences may apply):

checkState(self) -> PySide2.QtCore.Qt.CheckState

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#checkState

child

child(row: int, column: int) -> Any

X.child(row, column) -> PythonQt.QtGui.QStandardItem

Supplemental documentation: Qt 5 reference:

QStandardItem *QStandardItem::child(int row, int column \= 0) const

Returns the child item at (row, column) if one has been set; otherwise returns nullptr.

See also setChild(), takeChild(), and parent().

Upstream PySide2 reference signatures (binding differences may apply):

child(self, row: int, column: int=...) -> PySide2.QtGui.QStandardItem

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#child

clone

clone() -> Any

X.clone() -> PythonQt.QtGui.QStandardItem

Supplemental documentation: Qt 5 reference:

[virtual] QStandardItem *QStandardItem::clone() const

Returns a copy of this item. The item's children are not copied.

When subclassing QStandardItem, you can reimplement this function to provide QStandardItemModel with a factory that it can use to create new items on demand.

See also QStandardItemModel::setItemPrototype() and operator\=().

Upstream PySide2 reference signatures (binding differences may apply):

clone(self) -> PySide2.QtGui.QStandardItem

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#clone

column

column() -> int

X.column() -> int

Supplemental documentation: Qt 5 reference:

int QStandardItem::column() const

Returns the column where the item is located in its parent's child table, or -1 if the item has no parent.

See also row() and parent().

Upstream PySide2 reference signatures (binding differences may apply):

column(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#column

columnCount

columnCount() -> int

X.columnCount() -> int

Supplemental documentation: Qt 5 reference:

int QStandardItem::columnCount() const

Returns the number of child item columns that the item has.

See also setColumnCount() and rowCount().

Upstream PySide2 reference signatures (binding differences may apply):

columnCount(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#columnCount

data

data(role: int) -> Any

X.data(role) -> object

Supplemental documentation: Qt 5 reference:

[virtual] QVariant QStandardItem::data(int role \= Qt::UserRole + 1) const

Returns the item's data for the given role, or an invalid QVariant if there is no data for the role.

If you reimplement this function, your reimplementation should call the base implementation for roles you don't handle, otherwise getting flags, e.g. by calling flags(), isCheckable(), isEditable() etc., will not work.

Note: The default implementation treats Qt::EditRole and Qt::DisplayRole as referring to the same data.

See also setData().

Upstream PySide2 reference signatures (binding differences may apply):

data(self, role: int=...) -> typing.Any

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#data

emitDataChanged

emitDataChanged() -> None

X.emitDataChanged()

Supplemental documentation: Qt 5 reference:

[protected] void QStandardItem::emitDataChanged()

Causes the model associated with this item to emit a dataChanged() signal for this item.

You normally only need to call this function if you have subclassed QStandardItem and reimplemented data() and/or setData().

This function was introduced in Qt 4.4.

See also setData().

Upstream PySide2 reference signatures (binding differences may apply):

emitDataChanged(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#emitDataChanged

flags

flags() -> Any

X.flags()

Supplemental documentation: Qt 5 reference:

Qt::ItemFlags QStandardItem::flags() const

Returns the item flags for the item.

The item flags determine how the user can interact with the item.

By default, items are enabled, editable, selectable, checkable, and can be used both as the source of a drag and drop operation and as a drop target.

See also setFlags().

Upstream PySide2 reference signatures (binding differences may apply):

flags(self) -> PySide2.QtCore.Qt.ItemFlags

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#flags

font

font() -> Any

X.font() -> PythonQt.QtGui.QFont

Supplemental documentation: Qt 5 reference:

QFont QStandardItem::font() const

Returns the font used to render the item's text.

See also setFont().

Upstream PySide2 reference signatures (binding differences may apply):

font(self) -> PySide2.QtGui.QFont

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#font

foreground

foreground() -> Any

X.foreground() -> PythonQt.QtGui.QBrush

Supplemental documentation: Qt 5 reference:

QBrush QStandardItem::foreground() const

Returns the brush used to render the item's foreground (e.g. text).

See also setForeground() and background().

Upstream PySide2 reference signatures (binding differences may apply):

foreground(self) -> PySide2.QtGui.QBrush

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#foreground

hasChildren

hasChildren() -> bool

X.hasChildren() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::hasChildren() const

Returns true if this item has any children; otherwise returns false.

See also rowCount(), columnCount(), and child().

Upstream PySide2 reference signatures (binding differences may apply):

hasChildren(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#hasChildren

icon

icon() -> Any

X.icon() -> PythonQt.QtGui.QIcon

Supplemental documentation: Qt 5 reference:

QIcon QStandardItem::icon() const

Returns the item's icon.

See also setIcon() and iconSize.

Upstream PySide2 reference signatures (binding differences may apply):

icon(self) -> PySide2.QtGui.QIcon

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#icon

index

index() -> Any

X.index() -> PythonQt.QtCore.QModelIndex

Supplemental documentation: Qt 5 reference:

QModelIndex QStandardItem::index() const

Returns the QModelIndex associated with this item.

When you need to invoke item functionality in a QModelIndex-based API (e.g. QAbstractItemView), you can call this function to obtain an index that corresponds to the item's location in the model.

If the item is not associated with a model, an invalid QModelIndex is returned.

See also model() and QStandardItemModel::itemFromIndex().

Upstream PySide2 reference signatures (binding differences may apply):

index(self) -> PySide2.QtCore.QModelIndex

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#index

insertColumn

insertColumn(column: int, items: Any) -> None

X.insertColumn(column, items)

Supplemental documentation: Qt 5 reference:

void QStandardItem::insertColumn(int column, const QList\<QStandardItem *> \&items)

Inserts a column at column containing items. If necessary, the row count is increased to the size of items.

See also insertColumns() and insertRow().

Upstream PySide2 reference signatures (binding differences may apply):

insertColumn(self, column: int, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#insertColumn

insertColumns

insertColumns(column: int, count: int) -> None

X.insertColumns(column, count)

Supplemental documentation: Qt 5 reference:

void QStandardItem::insertColumns(int column, int count)

Inserts count columns of child items at column column.

See also insertColumn() and insertRows().

Upstream PySide2 reference signatures (binding differences may apply):

insertColumns(self, column: int, count: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#insertColumns

insertRow

insertRow(row: int, item: Any) -> None

X.insertRow(row, item)

Supplemental documentation: Qt 5 reference:

void QStandardItem::insertRow(int row, const QList\<QStandardItem *> \&items)

Inserts a row at row containing items. If necessary, the column count is increased to the size of items.

See also insertRows() and insertColumn().

void QStandardItem::insertRow(int row, QStandardItem *item)

This is an overloaded function.

Inserts a row at row containing item.

When building a list or a tree that has only one column, this function provides a convenient way to insert a single new item.

Upstream PySide2 reference signatures (binding differences may apply):

insertRow(self, row: int, item: PySide2.QtGui.QStandardItem) -> None
insertRow(self, row: int, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#insertRow

insertRows

insertRows(row: int, items: Any) -> None

X.insertRows(row, items)

Supplemental documentation: Qt 5 reference:

void QStandardItem::insertRows(int row, const QList\<QStandardItem *> \&items)

Inserts items at row. The column count won't be changed.

See also insertRow() and insertColumn().

void QStandardItem::insertRows(int row, int count)

Inserts count rows of child items at row row.

See also insertRow() and insertColumns().

Upstream PySide2 reference signatures (binding differences may apply):

insertRows(self, row: int, count: int) -> None
insertRows(self, row: int, items: typing.Sequence[PySide2.QtGui.QStandardItem]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#insertRows

isAutoTristate

isAutoTristate() -> bool

X.isAutoTristate() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isAutoTristate() const

Returns whether the item is tristate and is controlled by QTreeWidget.

The default value is false.

This function was introduced in Qt 5.6.

See also setAutoTristate(), isCheckable(), and checkState().

Upstream PySide2 reference signatures (binding differences may apply):

isAutoTristate(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isAutoTristate

isCheckable

isCheckable() -> bool

X.isCheckable() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isCheckable() const

Returns whether the item is user-checkable.

The default value is false.

See also setCheckable(), checkState(), isUserTristate(), and isAutoTristate().

Upstream PySide2 reference signatures (binding differences may apply):

isCheckable(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isCheckable

isDragEnabled

isDragEnabled() -> bool

X.isDragEnabled() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isDragEnabled() const

Returns whether the item is drag enabled. An item that is drag enabled can be dragged by the user.

The default value is true.

Note that item dragging must be enabled in the view for dragging to work; see QAbstractItemView::dragEnabled.

See also setDragEnabled(), isDropEnabled(), and flags().

Upstream PySide2 reference signatures (binding differences may apply):

isDragEnabled(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isDragEnabled

isDropEnabled

isDropEnabled() -> bool

X.isDropEnabled() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isDropEnabled() const

Returns whether the item is drop enabled. When an item is drop enabled, it can be used as a drop target.

The default value is true.

See also setDropEnabled(), isDragEnabled(), and flags().

Upstream PySide2 reference signatures (binding differences may apply):

isDropEnabled(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isDropEnabled

isEditable

isEditable() -> bool

X.isEditable() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isEditable() const

Returns whether the item can be edited by the user.

When an item is editable (and enabled), the user can edit the item by invoking one of the view's edit triggers; see QAbstractItemView::editTriggers.

The default value is true.

See also setEditable() and flags().

Upstream PySide2 reference signatures (binding differences may apply):

isEditable(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isEditable

isEnabled

isEnabled() -> bool

X.isEnabled() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isEnabled() const

Returns whether the item is enabled.

When an item is enabled, the user can interact with it. The possible types of interaction are specified by the other item flags, such as isEditable() and isSelectable().

The default value is true.

See also setEnabled() and flags().

Upstream PySide2 reference signatures (binding differences may apply):

isEnabled(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isEnabled

isSelectable

isSelectable() -> bool

X.isSelectable() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isSelectable() const

Returns whether the item is selectable by the user.

The default value is true.

See also setSelectable() and flags().

Upstream PySide2 reference signatures (binding differences may apply):

isSelectable(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isSelectable

isTristate

isTristate() -> bool

X.isTristate() -> bool

Upstream PySide2 reference signatures (binding differences may apply):

isTristate(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isTristate

isUserTristate

isUserTristate() -> bool

X.isUserTristate() -> bool

Supplemental documentation: Qt 5 reference:

bool QStandardItem::isUserTristate() const

Returns whether the item is tristate; that is, if it's checkable with three separate states and the user can cycle through all three states.

The default value is false.

This function was introduced in Qt 5.6.

See also setUserTristate(), isCheckable(), and checkState().

Upstream PySide2 reference signatures (binding differences may apply):

isUserTristate(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#isUserTristate

model

model() -> Any

X.model() -> PythonQt.QtGui.QStandardItemModel

Supplemental documentation: Qt 5 reference:

QStandardItemModel *QStandardItem::model() const

Returns the QStandardItemModel that this item belongs to.

If the item is not a child of another item that belongs to the model, this function returns nullptr.

See also index().

Upstream PySide2 reference signatures (binding differences may apply):

model(self) -> PySide2.QtGui.QStandardItemModel

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#model

parent

parent() -> Any

X.parent() -> PythonQt.QtGui.QStandardItem

Supplemental documentation: Qt 5 reference:

QStandardItem *QStandardItem::parent() const

Returns the item's parent item, or nullptr if the item has no parent.

Note: For toplevel items parent() returns nullptr. To receive toplevel item's parent use QStandardItemModel::invisibleRootItem() instead.

See also child() and QStandardItemModel::invisibleRootItem().

Upstream PySide2 reference signatures (binding differences may apply):

parent(self) -> PySide2.QtGui.QStandardItem

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#parent

read

read(*args: Any, **kwargs: Any) -> None

X.read(in)

Supplemental documentation: Qt 5 reference:

[virtual] void QStandardItem::read(QDataStream \&in)

Reads the item from stream in. Only the data and flags of the item are read, not the child items.

See also write().

Upstream PySide2 reference signatures (binding differences may apply):

read(self, in_: PySide2.QtCore.QDataStream) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#read

removeColumn

removeColumn(column: int) -> None

X.removeColumn(column)

Supplemental documentation: Qt 5 reference:

void QStandardItem::removeColumn(int column)

Removes the given column. The items that were in the column are deleted.

See also takeColumn(), removeColumns(), and removeRow().

Upstream PySide2 reference signatures (binding differences may apply):

removeColumn(self, column: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#removeColumn

removeColumns

removeColumns(column: int, count: int) -> None

X.removeColumns(column, count)

Supplemental documentation: Qt 5 reference:

void QStandardItem::removeColumns(int column, int count)

Removes count columns at column column. The items that were in those columns are deleted.

See also removeColumn() and removeRows().

Upstream PySide2 reference signatures (binding differences may apply):

removeColumns(self, column: int, count: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#removeColumns

removeRow

removeRow(row: int) -> None

X.removeRow(row)

Supplemental documentation: Qt 5 reference:

void QStandardItem::removeRow(int row)

Removes the given row. The items that were in the row are deleted.

See also takeRow(), removeRows(), and removeColumn().

Upstream PySide2 reference signatures (binding differences may apply):

removeRow(self, row: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#removeRow

removeRows

removeRows(row: int, count: int) -> None

X.removeRows(row, count)

Supplemental documentation: Qt 5 reference:

void QStandardItem::removeRows(int row, int count)

Removes count rows at row row. The items that were in those rows are deleted.

See also removeRow() and removeColumn().

Upstream PySide2 reference signatures (binding differences may apply):

removeRows(self, row: int, count: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#removeRows

row

row() -> int

X.row() -> int

Supplemental documentation: Qt 5 reference:

int QStandardItem::row() const

Returns the row where the item is located in its parent's child table, or -1 if the item has no parent.

See also column() and parent().

Upstream PySide2 reference signatures (binding differences may apply):

row(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qstandarditem.html#row