Skip to content

PythonQt.QtGui.QTreeView · declarations 002

Back to PythonQt.QtGui.QTreeView

isHeaderHidden

isHeaderHidden() -> bool

X.isHeaderHidden() -> bool

Upstream PySide2 reference signatures (binding differences may apply):

isHeaderHidden(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#isHeaderHidden

isIndexHidden

isIndexHidden(index: Any) -> bool

X.isIndexHidden(index) -> bool

Supplemental documentation: Qt 5 reference:

[override virtual protected] bool QTreeView::isIndexHidden(const QModelIndex \&index) const

Reimplements: QAbstractItemView::isIndexHidden(const QModelIndex \&index) const.

Upstream PySide2 reference signatures (binding differences may apply):

isIndexHidden(self, index: PySide2.QtCore.QModelIndex) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#isIndexHidden

isRowHidden

isRowHidden(row: int, parent: Any) -> bool

X.isRowHidden(row, parent) -> bool

Supplemental documentation: Qt 5 reference:

bool QTreeView::isRowHidden(int row, const QModelIndex \&parent) const

Returns true if the item in the given row of the parent is hidden; otherwise returns false.

See also setRowHidden() and isColumnHidden().

Upstream PySide2 reference signatures (binding differences may apply):

isRowHidden(self, row: int, parent: PySide2.QtCore.QModelIndex) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#isRowHidden

isSortingEnabled

isSortingEnabled() -> bool

X.isSortingEnabled() -> bool

Upstream PySide2 reference signatures (binding differences may apply):

isSortingEnabled(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#isSortingEnabled

itemsExpandable instance-attribute

itemsExpandable: bool

Qt 5 reference:

itemsExpandable : bool

This property holds whether the items are expandable by the user.

This property holds whether the user can expand and collapse items interactively.

By default, this property is true.

Access functions:

bool itemsExpandable() const
void setItemsExpandable(bool enable)

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#itemsExpandable

keyPressEvent

keyPressEvent(event: Any) -> None

X.keyPressEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::keyPressEvent(QKeyEvent *event)

Reimplements: QAbstractItemView::keyPressEvent(QKeyEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

keyPressEvent(self, event: PySide2.QtGui.QKeyEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#keyPressEvent

keyboardSearch

keyboardSearch(search: str) -> None

X.keyboardSearch(search)

Supplemental documentation: Qt 5 reference:

Reimplements: QAbstractItemView::keyboardSearch(const QString \&search).

Upstream PySide2 reference signatures (binding differences may apply):

keyboardSearch(self, search: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#keyboardSearch

mouseDoubleClickEvent

mouseDoubleClickEvent(event: Any) -> None

X.mouseDoubleClickEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::mouseDoubleClickEvent(QMouseEvent *event)

Reimplements: QAbstractItemView::mouseDoubleClickEvent(QMouseEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

mouseDoubleClickEvent(self, event: PySide2.QtGui.QMouseEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#mouseDoubleClickEvent

mouseMoveEvent

mouseMoveEvent(event: Any) -> None

X.mouseMoveEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::mouseMoveEvent(QMouseEvent *event)

Reimplements: QAbstractItemView::mouseMoveEvent(QMouseEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

mouseMoveEvent(self, event: PySide2.QtGui.QMouseEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#mouseMoveEvent

mousePressEvent

mousePressEvent(event: Any) -> None

X.mousePressEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::mousePressEvent(QMouseEvent *event)

Reimplements: QAbstractItemView::mousePressEvent(QMouseEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

mousePressEvent(self, event: PySide2.QtGui.QMouseEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#mousePressEvent

mouseReleaseEvent

mouseReleaseEvent(event: Any) -> None

X.mouseReleaseEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::mouseReleaseEvent(QMouseEvent *event)

Reimplements: QAbstractItemView::mouseReleaseEvent(QMouseEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

mouseReleaseEvent(self, event: PySide2.QtGui.QMouseEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#mouseReleaseEvent

moveCursor

moveCursor(cursorAction: Any, modifiers: Any) -> Any

X.moveCursor(cursorAction, modifiers) -> PythonQt.QtCore.QModelIndex

Supplemental documentation: Qt 5 reference:

[override virtual protected] QModelIndex QTreeView::moveCursor(QAbstractItemView::CursorAction cursorAction, Qt::KeyboardModifiers modifiers)

Reimplements: QAbstractItemView::moveCursor(QAbstractItemView::CursorAction cursorAction, Qt::KeyboardModifiers modifiers).

Move the cursor in the way described by cursorAction, using the information provided by the button modifiers.

Upstream PySide2 reference signatures (binding differences may apply):

moveCursor(self, cursorAction: PySide2.QtWidgets.QAbstractItemView.CursorAction, modifiers: PySide2.QtCore.Qt.KeyboardModifiers) -> PySide2.QtCore.QModelIndex

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#moveCursor

objectNameChanged

objectNameChanged(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QTreeView.objectNameChanged; argument details are not documented.

paintEvent

paintEvent(event: Any) -> None

X.paintEvent(event)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::paintEvent(QPaintEvent *event)

Reimplements: QAbstractScrollArea::paintEvent(QPaintEvent *event).

Upstream PySide2 reference signatures (binding differences may apply):

paintEvent(self, event: PySide2.QtGui.QPaintEvent) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#paintEvent

pressed

pressed(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QTreeView.pressed; argument details are not documented.

reset

reset() -> None

X.reset()

Supplemental documentation: Qt 5 reference:

[override virtual] void QTreeView::reset()

Reimplements: QAbstractItemView::reset().

Upstream PySide2 reference signatures (binding differences may apply):

reset(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#reset

resetIndentation

resetIndentation() -> None

X.resetIndentation()

Upstream PySide2 reference signatures (binding differences may apply):

resetIndentation(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#resetIndentation

resizeColumnToContents

resizeColumnToContents(column: int) -> None

X.resizeColumnToContents(column)

Supplemental documentation: Qt 5 reference:

[slot] void QTreeView::resizeColumnToContents(int column)

Resizes the column given to the size of its contents.

See also columnWidth(), setColumnWidth(), sizeHintForColumn(), and QHeaderView::resizeContentsPrecision().

Upstream PySide2 reference signatures (binding differences may apply):

resizeColumnToContents(self, column: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#resizeColumnToContents

rootIsDecorated instance-attribute

rootIsDecorated: bool

Qt 5 reference:

rootIsDecorated : bool

This property holds whether to show controls for expanding and collapsing top-level items

Items with children are typically shown with controls to expand and collapse them, allowing their children to be shown or hidden. If this property is false, these controls are not shown for top-level items. This can be used to make a single level tree structure appear like a simple list of items.

By default, this property is true.

Access functions:

bool rootIsDecorated() const
void setRootIsDecorated(bool show)

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#rootIsDecorated

rowHeight

rowHeight(index: Any) -> int

X.rowHeight(index) -> int

Supplemental documentation: Qt 5 reference:

[protected] int QTreeView::rowHeight(const QModelIndex \&index) const

Returns the height of the row indicated by the given index.

This function was introduced in Qt 4.3.

See also indexRowSizeHint().

Upstream PySide2 reference signatures (binding differences may apply):

rowHeight(self, index: PySide2.QtCore.QModelIndex) -> int

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#rowHeight

scrollContentsBy

scrollContentsBy(dx: int, dy: int) -> None

X.scrollContentsBy(dx, dy)

Supplemental documentation: Qt 5 reference:

[override virtual protected] void QTreeView::scrollContentsBy(int dx, int dy)

Reimplements: QAbstractScrollArea::scrollContentsBy(int dx, int dy).

Scrolls the contents of the tree view by (dx, dy).

Upstream PySide2 reference signatures (binding differences may apply):

scrollContentsBy(self, dx: int, dy: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#scrollContentsBy

scrollTo

scrollTo(index: Any, hint: Any) -> None

X.scrollTo(index, hint)

Supplemental documentation: Qt 5 reference:

[override virtual] void QTreeView::scrollTo(const QModelIndex \&index, QAbstractItemView::ScrollHint hint \= EnsureVisible)

Reimplements: QAbstractItemView::scrollTo(const QModelIndex \&index, QAbstractItemView::ScrollHint hint).

Scroll the contents of the tree view until the given model item index is visible. The hint parameter specifies more precisely where the item should be located after the operation. If any of the parents of the model item are collapsed, they will be expanded to ensure that the model item is visible.

Upstream PySide2 reference signatures (binding differences may apply):

scrollTo(self, index: PySide2.QtCore.QModelIndex, hint: PySide2.QtWidgets.QAbstractItemView.ScrollHint=...) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#scrollTo

selectAll

selectAll() -> None

X.selectAll()

Supplemental documentation: Qt 5 reference:

[override virtual] void QTreeView::selectAll()

Reimplements: QAbstractItemView::selectAll().

Upstream PySide2 reference signatures (binding differences may apply):

selectAll(self) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#selectAll

selectedIndexes

selectedIndexes() -> tuple

X.selectedIndexes() -> tuple

Supplemental documentation: Qt 5 reference:

[override virtual protected] QModelIndexList QTreeView::selectedIndexes() const

Reimplements: QAbstractItemView::selectedIndexes() const.

Upstream PySide2 reference signatures (binding differences may apply):

selectedIndexes(self) -> typing.List[int]

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#selectedIndexes

setAllColumnsShowFocus

setAllColumnsShowFocus(enable: bool) -> None

X.setAllColumnsShowFocus(enable)

Upstream PySide2 reference signatures (binding differences may apply):

setAllColumnsShowFocus(self, enable: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setAllColumnsShowFocus

setAnimated

setAnimated(enable: bool) -> None

X.setAnimated(enable)

Upstream PySide2 reference signatures (binding differences may apply):

setAnimated(self, enable: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setAnimated

setAutoExpandDelay

setAutoExpandDelay(delay: int) -> None

X.setAutoExpandDelay(delay)

Upstream PySide2 reference signatures (binding differences may apply):

setAutoExpandDelay(self, delay: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setAutoExpandDelay

setColumnHidden

setColumnHidden(column: int, hide: bool) -> None

X.setColumnHidden(column, hide)

Supplemental documentation: Qt 5 reference:

void QTreeView::setColumnHidden(int column, bool hide)

If hide is true the column is hidden, otherwise the column is shown.

See also isColumnHidden(), hideColumn(), and setRowHidden().

Upstream PySide2 reference signatures (binding differences may apply):

setColumnHidden(self, column: int, hide: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setColumnHidden

setColumnWidth

setColumnWidth(column: int, width: int) -> None

X.setColumnWidth(column, width)

Supplemental documentation: Qt 5 reference:

void QTreeView::setColumnWidth(int column, int width)

Sets the width of the given column to the width specified.

This function was introduced in Qt 4.2.

See also columnWidth() and resizeColumnToContents().

Upstream PySide2 reference signatures (binding differences may apply):

setColumnWidth(self, column: int, width: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setColumnWidth

setExpanded

setExpanded(index: Any, expand: bool) -> None

X.setExpanded(index, expand)

Supplemental documentation: Qt 5 reference:

void QTreeView::setExpanded(const QModelIndex \&index, bool expanded)

Sets the item referred to by index to either collapse or expanded, depending on the value of expanded.

See also expanded(), expand(), and isExpanded().

Upstream PySide2 reference signatures (binding differences may apply):

setExpanded(self, index: PySide2.QtCore.QModelIndex, expand: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setExpanded

setExpandsOnDoubleClick

setExpandsOnDoubleClick(enable: bool) -> None

X.setExpandsOnDoubleClick(enable)

Upstream PySide2 reference signatures (binding differences may apply):

setExpandsOnDoubleClick(self, enable: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setExpandsOnDoubleClick

setFirstColumnSpanned

setFirstColumnSpanned(row: int, parent: Any, span: bool) -> None

X.setFirstColumnSpanned(row, parent, span)

Supplemental documentation: Qt 5 reference:

void QTreeView::setFirstColumnSpanned(int row, const QModelIndex \&parent, bool span)

If span is true the item in the first column in the row with the given parent is set to span all columns, otherwise all items on the row are shown.

This function was introduced in Qt 4.3.

See also isFirstColumnSpanned().

Upstream PySide2 reference signatures (binding differences may apply):

setFirstColumnSpanned(self, row: int, parent: PySide2.QtCore.QModelIndex, span: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setFirstColumnSpanned

setHeader

setHeader(header: Any) -> None

X.setHeader(header)

Supplemental documentation: Qt 5 reference:

void QTreeView::setHeader(QHeaderView *header)

Sets the header for the tree view, to the given header.

The view takes ownership over the given header and deletes it when a new header is set.

See also QAbstractItemModel::headerData().

Upstream PySide2 reference signatures (binding differences may apply):

setHeader(self, header: PySide2.QtWidgets.QHeaderView) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setHeader

setHeaderHidden

setHeaderHidden(hide: bool) -> None

X.setHeaderHidden(hide)

Upstream PySide2 reference signatures (binding differences may apply):

setHeaderHidden(self, hide: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setHeaderHidden

setIndentation

setIndentation(i: int) -> None

X.setIndentation(i)

Upstream PySide2 reference signatures (binding differences may apply):

setIndentation(self, i: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setIndentation

setItemsExpandable

setItemsExpandable(enable: bool) -> None

X.setItemsExpandable(enable)

Upstream PySide2 reference signatures (binding differences may apply):

setItemsExpandable(self, enable: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setItemsExpandable

setModel

setModel(model: Any) -> None

X.setModel(model)

Supplemental documentation: Qt 5 reference:

[override virtual] void QTreeView::setModel(QAbstractItemModel *model)

Reimplements: QAbstractItemView::setModel(QAbstractItemModel *model).

Upstream PySide2 reference signatures (binding differences may apply):

setModel(self, model: PySide2.QtCore.QAbstractItemModel) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setModel

setRootIndex

setRootIndex(index: Any) -> None

X.setRootIndex(index)

Supplemental documentation: Qt 5 reference:

[override virtual] void QTreeView::setRootIndex(const QModelIndex \&index)

Reimplements: QAbstractItemView::setRootIndex(const QModelIndex \&index).

Upstream PySide2 reference signatures (binding differences may apply):

setRootIndex(self, index: PySide2.QtCore.QModelIndex) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setRootIndex

setRootIsDecorated

setRootIsDecorated(show: bool) -> None

X.setRootIsDecorated(show)

Upstream PySide2 reference signatures (binding differences may apply):

setRootIsDecorated(self, show: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setRootIsDecorated

setRowHidden

setRowHidden(row: int, parent: Any, hide: bool) -> None

X.setRowHidden(row, parent, hide)

Supplemental documentation: Qt 5 reference:

void QTreeView::setRowHidden(int row, const QModelIndex \&parent, bool hide)

If hide is true the row with the given parent is hidden, otherwise the row is shown.

See also isRowHidden() and setColumnHidden().

Upstream PySide2 reference signatures (binding differences may apply):

setRowHidden(self, row: int, parent: PySide2.QtCore.QModelIndex, hide: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qtreeview.html#setRowHidden