Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QTableViewPrivate Class Reference

#include <qtableview_p.h>

+ Inheritance diagram for QTableViewPrivate:
+ Collaboration diagram for QTableViewPrivate:

Public Types

enum class  SearchDirection { Increasing , Decreasing }
 

Public Member Functions

 QTableViewPrivate ()
 
void init ()
 
void clearConnections ()
 
void trimHiddenSelections (QItemSelectionRange *range) const
 
QRect intersectedRect (const QRect rect, const QModelIndex &topLeft, const QModelIndex &bottomRight) const override
 
bool isHidden (int row, int col) const
 
int visualRow (int logicalRow) const
 
int visualColumn (int logicalCol) const
 
int logicalRow (int visualRow) const
 
int logicalColumn (int visualCol) const
 
int accessibleTable2Index (const QModelIndex &index) const
 
int sectionSpanEndLogical (const QHeaderView *header, int logical, int span) const
 
int sectionSpanSize (const QHeaderView *header, int logical, int span) const
 
bool spanContainsSection (const QHeaderView *header, int logical, int spanLogical, int span) const
 
void drawAndClipSpans (const QRegion &area, QPainter *painter, const QStyleOptionViewItem &option, QBitArray *drawn, int firstVisualRow, int lastVisualRow, int firstVisualColumn, int lastVisualColumn)
 
void drawCell (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index)
 
int widthHintForIndex (const QModelIndex &index, int hint, const QStyleOptionViewItem &option) const
 
int heightHintForIndex (const QModelIndex &index, int hint, QStyleOptionViewItem &option) const
 
void setSpan (int row, int column, int rowSpan, int columnSpan)
 
QSpanCollection::Span span (int row, int column) const
 
int rowSpan (int row, int column) const
 
int columnSpan (int row, int column) const
 
bool hasSpans () const
 
int rowSpanHeight (int row, int span) const
 
int columnSpanWidth (int column, int span) const
 
int rowSpanEndLogical (int row, int span) const
 
int columnSpanEndLogical (int column, int span) const
 
bool isRowHidden (int row) const
 
bool isColumnHidden (int column) const
 
bool isCellEnabled (int row, int column) const
 
int nextActiveVisualRow (int rowToStart, int column, int limit, SearchDirection searchDirection) const
 
int nextActiveVisualColumn (int row, int columnToStart, int limit, SearchDirection searchDirection) const
 
QRect visualSpanRect (const QSpanCollection::Span &span) const
 
void selectRow (int row, bool anchor)
 
void selectColumn (int column, bool anchor)
 
void updateSpanInsertedRows (const QModelIndex &parent, int start, int end)
 
void updateSpanInsertedColumns (const QModelIndex &parent, int start, int end)
 
void updateSpanRemovedRows (const QModelIndex &parent, int start, int end)
 
void updateSpanRemovedColumns (const QModelIndex &parent, int start, int end)
 
void sortIndicatorChanged (int column, Qt::SortOrder order)
 
- Public Member Functions inherited from QAbstractItemViewPrivate
 QAbstractItemViewPrivate ()
 
virtual ~QAbstractItemViewPrivate ()
 
void init ()
 
virtual void rowsRemoved (const QModelIndex &parent, int start, int end)
 
virtual void rowsInserted (const QModelIndex &parent, int start, int end)
 
virtual void columnsAboutToBeRemoved (const QModelIndex &parent, int start, int end)
 
virtual void columnsRemoved (const QModelIndex &parent, int start, int end)
 
virtual void columnsInserted (const QModelIndex &parent, int start, int end)
 
virtual void modelDestroyed ()
 
virtual void layoutChanged ()
 
virtual void rowsMoved (const QModelIndex &source, int sourceStart, int sourceEnd, const QModelIndex &destination, int destinationStart)
 
virtual void columnsMoved (const QModelIndex &source, int sourceStart, int sourceEnd, const QModelIndex &destination, int destinationStart)
 
void headerDataChanged ()
 
void scrollerStateChanged ()
 
void delegateSizeHintChanged (const QModelIndex &index)
 
void fetchMore ()
 
bool shouldEdit (QAbstractItemView::EditTrigger trigger, const QModelIndex &index) const
 
bool shouldForwardEvent (QAbstractItemView::EditTrigger trigger, const QEvent *event) const
 
bool shouldAutoScroll (const QPoint &pos) const
 
void doDelayedItemsLayout (int delay=0)
 
void interruptDelayedItemsLayout () const
 
void updateGeometry ()
 
void startAutoScroll ()
 
void stopAutoScroll ()
 
bool droppingOnItself (QDropEvent *event, const QModelIndex &index)
 
QWidgeteditor (const QModelIndex &index, const QStyleOptionViewItem &options)
 
bool sendDelegateEvent (const QModelIndex &index, QEvent *event) const
 
bool openEditor (const QModelIndex &index, QEvent *event)
 
void updateEditorData (const QModelIndex &topLeft, const QModelIndex &bottomRight)
 
void selectAllInEditor (QWidget *w)
 
QItemSelectionModel::SelectionFlags multiSelectionCommand (const QModelIndex &index, const QEvent *event) const
 
QItemSelectionModel::SelectionFlags extendedSelectionCommand (const QModelIndex &index, const QEvent *event) const
 
QItemSelectionModel::SelectionFlags contiguousSelectionCommand (const QModelIndex &index, const QEvent *event) const
 
virtual void selectAll (QItemSelectionModel::SelectionFlags command)
 
void setHoverIndex (const QPersistentModelIndex &index)
 
void checkMouseMove (const QPersistentModelIndex &index)
 
void checkMouseMove (const QPoint &pos)
 
QItemSelectionModel::SelectionFlags selectionBehaviorFlags () const
 
virtual QItemViewPaintPairs draggablePaintPairs (const QModelIndexList &indexes, QRect *r) const
 
virtual void adjustViewOptionsForIndex (QStyleOptionViewItem *, const QModelIndex &) const
 
void releaseEditor (QWidget *editor, const QModelIndex &index=QModelIndex()) const
 
void executePostedLayout () const
 
void setDirtyRegion (const QRegion &visualRegion)
 
void scrollDirtyRegion (int dx, int dy)
 
void scrollContentsBy (int dx, int dy)
 
void updateDirtyRegion ()
 
void clearOrRemove ()
 
void checkPersistentEditorFocus ()
 
QPixmap renderToPixmap (const QModelIndexList &indexes, QRect *r) const
 
QPoint offset () const
 
const QEditorInfoeditorForIndex (const QModelIndex &index) const
 
bool hasEditor (const QModelIndex &index) const
 
QModelIndex indexForEditor (QWidget *editor) const
 
void addEditor (const QModelIndex &index, QWidget *editor, bool isStatic)
 
void removeEditor (QWidget *editor)
 
bool isAnimating () const
 
bool isIndexValid (const QModelIndex &index) const
 
bool isIndexSelectable (const QModelIndex &index) const
 
bool isIndexEnabled (const QModelIndex &index) const
 
virtual bool selectionAllowed (const QModelIndex &index) const
 
QPoint contentsOffset () const override
 
int delegateRefCount (const QAbstractItemDelegate *delegate) const
 
bool isPersistent (const QModelIndex &index) const
 
void doDelayedReset ()
 
virtual QRect visualRect (const QModelIndex &index) const
 

Public Attributes

bool showGrid
 
Qt::PenStyle gridStyle
 
int columnResizeTimerID
 
int rowResizeTimerID
 
QList< int > columnsToUpdate
 
QList< int > rowsToUpdate
 
QHeaderViewhorizontalHeader
 
QHeaderViewverticalHeader
 
QMetaObject::Connection selectionmodelConnection
 
std::array< QMetaObject::Connection, 4 > modelConnections
 
std::array< QMetaObject::Connection, 7 > verHeaderConnections
 
std::array< QMetaObject::Connection, 5 > horHeaderConnections
 
std::vector< QMetaObject::ConnectiondynHorHeaderConnections
 
bool sortingEnabled
 
bool geometryRecursionBlock
 
QPoint visualCursor
 
QSpanCollection spans
 
- Public Attributes inherited from QAbstractItemViewPrivate
QAbstractItemModelmodel
 
QPointer< QAbstractItemDelegateitemDelegate
 
QMap< int, QPointer< QAbstractItemDelegate > > rowDelegates
 
QMap< int, QPointer< QAbstractItemDelegate > > columnDelegates
 
QPointer< QItemSelectionModelselectionModel
 
QItemSelectionModel::SelectionFlag ctrlDragSelectionFlag
 
bool noSelectionOnMousePress
 
QAbstractItemView::SelectionMode selectionMode
 
QAbstractItemView::SelectionBehavior selectionBehavior
 
QEditorIndexHash editorIndexHash
 
QIndexEditorHash indexEditorHash
 
QSet< QWidget * > persistent
 
QWidgetcurrentlyCommittingEditor
 
QBasicTimer pressClosedEditorWatcher
 
QPersistentModelIndex lastEditedIndex
 
bool pressClosedEditor
 
bool waitForIMCommit
 
QPersistentModelIndex enteredIndex
 
QPersistentModelIndex pressedIndex
 
QPersistentModelIndex currentSelectionStartIndex
 
Qt::KeyboardModifiers pressedModifiers
 
QPoint pressedPosition
 
QPoint draggedPosition
 
bool pressedAlreadySelected
 
bool releaseFromDoubleClick
 
bool viewportEnteredNeeded
 
QAbstractItemView::State state
 
QAbstractItemView::State stateBeforeAnimation
 
QAbstractItemView::EditTriggers editTriggers
 
QAbstractItemView::EditTrigger lastTrigger
 
QPersistentModelIndex root
 
QPersistentModelIndex hover
 
bool tabKeyNavigation
 
QString keyboardInput
 
QElapsedTimer keyboardInputTime
 
bool autoScroll
 
QBasicTimer autoScrollTimer
 
int autoScrollMargin
 
int autoScrollCount
 
bool shouldScrollToCurrentOnShow
 
bool shouldClearStatusTip
 
bool alternatingColors
 
QSize iconSize
 
Qt::TextElideMode textElideMode
 
QRegion updateRegion
 
QPoint scrollDelayOffset
 
QBasicTimer updateTimer
 
QBasicTimer delayedEditing
 
QBasicTimer delayedAutoScroll
 
QBasicTimer delayedReset
 
QAbstractItemView::ScrollMode verticalScrollMode
 
QAbstractItemView::ScrollMode horizontalScrollMode
 
QItemSelection oldSelection
 
QModelIndex oldCurrent
 
bool currentIndexSet
 
bool wrapItemText
 
bool delayedPendingLayout
 
bool moveCursorUpdatedView
 
bool verticalScrollModeSet
 
bool horizontalScrollModeSet
 
std::array< QMetaObject::Connection, 14 > modelConnections
 
std::array< QMetaObject::Connection, 4 > scrollbarConnections
 

Detailed Description

Definition at line 104 of file qtableview_p.h.

Member Enumeration Documentation

◆ SearchDirection

Enumerator
Increasing 
Decreasing 

Definition at line 216 of file qtableview_p.h.

Constructor & Destructor Documentation

◆ QTableViewPrivate()

QTableViewPrivate::QTableViewPrivate ( )
inline

Definition at line 108 of file qtableview_p.h.

Member Function Documentation

◆ accessibleTable2Index()

int QTableViewPrivate::accessibleTable2Index ( const QModelIndex & index) const
inline

Definition at line 142 of file qtableview_p.h.

◆ clearConnections()

void QTableViewPrivate::clearConnections ( )

Definition at line 602 of file qtableview.cpp.

References connection, QObject::disconnect(), dynHorHeaderConnections, horHeaderConnections, modelConnections, selectionmodelConnection, and verHeaderConnections.

+ Here is the call graph for this function:

◆ columnSpan()

int QTableViewPrivate::columnSpan ( int row,
int column ) const
inline

Definition at line 187 of file qtableview_p.h.

Referenced by setSpan().

+ Here is the caller graph for this function:

◆ columnSpanEndLogical()

int QTableViewPrivate::columnSpanEndLogical ( int column,
int span ) const
inline

Definition at line 202 of file qtableview_p.h.

◆ columnSpanWidth()

int QTableViewPrivate::columnSpanWidth ( int column,
int span ) const
inline

Definition at line 196 of file qtableview_p.h.

Referenced by visualSpanRect().

+ Here is the caller graph for this function:

◆ drawAndClipSpans()

void QTableViewPrivate::drawAndClipSpans ( const QRegion & area,
QPainter * painter,
const QStyleOptionViewItem & option,
QBitArray * drawn,
int firstVisualRow,
int lastVisualRow,
int firstVisualColumn,
int lastVisualColumn )

Draws the spanning cells within rect area, and clips them off as preparation for the main drawing loop. drawn is a QBitArray of visualRowCountxvisualCoulumnCount which say if particular cell has been drawn

Definition at line 889 of file qtableview.cpp.

References QAbstractItemViewPrivate::alternatingColors, area(), drawCell(), QStyleOptionButton::features, horizontalHeader, QAbstractItemModel::index(), logicalColumn(), logicalRow(), QAbstractItemViewPrivate::model, opt, painter, rect, QStyleOption::rect, QAbstractItemViewPrivate::root, QAbstractItemViewPrivate::scrollDelayOffset, QHeaderView::sectionsMoved(), QPainter::setClipRegion(), showGrid, QSpanCollection::spans, spans, QSpanCollection::spansInRect(), verticalHeader, viewport(), visualColumn(), QHeaderView::visualIndex(), visualRow(), and visualSpanRect().

+ Here is the call graph for this function:

◆ drawCell()

void QTableViewPrivate::drawCell ( QPainter * painter,
const QStyleOptionViewItem & option,
const QModelIndex & index )

Draws a table cell.

Definition at line 1027 of file qtableview.cpp.

References QPalette::Disabled, QAbstractItemModel::flags(), focus, QAbstractItemViewPrivate::hover, QItemSelectionModel::isSelected(), Qt::ItemIsEnabled, QAbstractItemViewPrivate::model, QPalette::Normal, opt, painter, QStyleOption::palette, QStyle::PE_PanelItemViewRow, QAbstractItemViewPrivate::selectionModel, QPalette::setCurrentColorGroup(), QStyleOption::state, QStyle::State_Enabled, QStyle::State_HasFocus, QStyle::State_MouseOver, QStyle::State_Selected, and viewport().

Referenced by drawAndClipSpans().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ hasSpans()

bool QTableViewPrivate::hasSpans ( ) const
inline

Definition at line 190 of file qtableview_p.h.

References QSpanCollection::spans.

Referenced by heightHintForIndex(), and widthHintForIndex().

+ Here is the caller graph for this function:

◆ heightHintForIndex()

int QTableViewPrivate::heightHintForIndex ( const QModelIndex & index,
int hint,
QStyleOptionViewItem & option ) const

Get sizeHint height for single Index (providing existing hint and style option)

Definition at line 1092 of file qtableview.cpp.

References QSet< T >::contains(), QPointer< T >::data(), QAbstractItemViewPrivate::editor(), QAbstractItemViewPrivate::editorForIndex(), hasSpans(), QSize::height(), hint(), QWidget::maximumSize, QWidget::minimumSize, QAbstractItemViewPrivate::persistent, qBound(), qMax(), showGrid, QWidget::sizeHint, QSpanCollection::spanAt(), spans, visualSpanRect(), QEditorInfo::widget, QRect::width(), and QAbstractItemViewPrivate::wrapItemText.

+ Here is the call graph for this function:

◆ init()

void QTableViewPrivate::init ( )

Definition at line 575 of file qtableview.cpp.

References QAbstractItemView::AnyKeyPressed, QObject::connect(), QAbstractItemViewPrivate::editTriggers, Qt::Horizontal, Qt::NoFocus, QAbstractItemView::selectAll(), QHeaderView::setHighlightSections(), QHeaderView::setSectionsClickable(), QAbstractItemViewPrivate::tabKeyNavigation, and Qt::Vertical.

+ Here is the call graph for this function:

◆ intersectedRect()

QRect QTableViewPrivate::intersectedRect ( const QRect rect,
const QModelIndex & topLeft,
const QModelIndex & bottomRight ) const
overridevirtual

Reimplemented from QAbstractItemViewPrivate.

Definition at line 656 of file qtableview.cpp.

References QModelIndex::column(), horizontalHeader, i, QRect::intersected(), QRect::isNull(), rect, ret, QModelIndex::row(), QHeaderView::sectionSize(), QHeaderView::sectionsMoved(), QHeaderView::sectionViewportPosition(), and verticalHeader.

+ Here is the call graph for this function:

◆ isCellEnabled()

bool QTableViewPrivate::isCellEnabled ( int row,
int column ) const
inline

Definition at line 212 of file qtableview_p.h.

References QAbstractTableModel::index(), and model.

Referenced by nextActiveVisualColumn(), and nextActiveVisualRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isColumnHidden()

bool QTableViewPrivate::isColumnHidden ( int column) const
inline

Definition at line 209 of file qtableview_p.h.

References QHeaderView::isSectionHidden().

Referenced by nextActiveVisualColumn().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ isHidden()

bool QTableViewPrivate::isHidden ( int row,
int col ) const
inline

Definition at line 125 of file qtableview_p.h.

◆ isRowHidden()

bool QTableViewPrivate::isRowHidden ( int row) const
inline

Definition at line 206 of file qtableview_p.h.

References QHeaderView::isSectionHidden().

Referenced by nextActiveVisualRow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ logicalColumn()

int QTableViewPrivate::logicalColumn ( int visualCol) const
inline

Definition at line 138 of file qtableview_p.h.

Referenced by drawAndClipSpans(), nextActiveVisualColumn(), nextActiveVisualRow(), and widthHintForIndex().

+ Here is the caller graph for this function:

◆ logicalRow()

int QTableViewPrivate::logicalRow ( int visualRow) const
inline

Definition at line 135 of file qtableview_p.h.

Referenced by drawAndClipSpans(), nextActiveVisualColumn(), and nextActiveVisualRow().

+ Here is the caller graph for this function:

◆ nextActiveVisualColumn()

int QTableViewPrivate::nextActiveVisualColumn ( int row,
int columnToStart,
int limit,
SearchDirection searchDirection ) const

Searches for the next cell which is available for e.g. keyboard navigation The search is done by column

Definition at line 836 of file qtableview.cpp.

References Decreasing, Increasing, isCellEnabled(), isColumnHidden(), logicalColumn(), logicalRow(), and visualColumn().

+ Here is the call graph for this function:

◆ nextActiveVisualRow()

int QTableViewPrivate::nextActiveVisualRow ( int rowToStart,
int column,
int limit,
SearchDirection searchDirection ) const

Searches for the next cell which is available for e.g. keyboard navigation The search is done by row

Definition at line 804 of file qtableview.cpp.

References Decreasing, Increasing, isCellEnabled(), isRowHidden(), logicalColumn(), logicalRow(), and visualRow().

+ Here is the call graph for this function:

◆ rowSpan()

int QTableViewPrivate::rowSpan ( int row,
int column ) const
inline

Definition at line 184 of file qtableview_p.h.

Referenced by setSpan().

+ Here is the caller graph for this function:

◆ rowSpanEndLogical()

int QTableViewPrivate::rowSpanEndLogical ( int row,
int span ) const
inline

Definition at line 199 of file qtableview_p.h.

◆ rowSpanHeight()

int QTableViewPrivate::rowSpanHeight ( int row,
int span ) const
inline

Definition at line 193 of file qtableview_p.h.

Referenced by visualSpanRect().

+ Here is the caller graph for this function:

◆ sectionSpanEndLogical()

int QTableViewPrivate::sectionSpanEndLogical ( const QHeaderView * header,
int logical,
int span ) const

Returns the logical index of the last section that's part of the span.

Definition at line 752 of file qtableview.cpp.

References header(), and i.

Referenced by sectionSpanSize().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ sectionSpanSize()

int QTableViewPrivate::sectionSpanSize ( const QHeaderView * header,
int logical,
int span ) const

Returns the size of the span starting at logical index logical and spanning span sections.

Definition at line 769 of file qtableview.cpp.

References header(), and sectionSpanEndLogical().

+ Here is the call graph for this function:

◆ selectColumn()

◆ selectRow()

◆ setSpan()

void QTableViewPrivate::setSpan ( int row,
int column,
int rowSpan,
int columnSpan )

Sets the span for the cell at (row, column).

Definition at line 706 of file qtableview.cpp.

References QSpanCollection::addSpan(), columnSpan(), Q_UNLIKELY, qWarning, rowSpan(), sp, QSpanCollection::spanAt(), spans, and QSpanCollection::updateSpan().

+ Here is the call graph for this function:

◆ sortIndicatorChanged()

void QTableViewPrivate::sortIndicatorChanged ( int column,
Qt::SortOrder order )

Sort the model when the header sort indicator changed

Definition at line 1018 of file qtableview.cpp.

References QAbstractItemViewPrivate::model.

Referenced by QTableView::setSortingEnabled().

+ Here is the caller graph for this function:

◆ span()

QSpanCollection::Span QTableViewPrivate::span ( int row,
int column ) const

Gets the span information for the cell at (row, column).

Definition at line 739 of file qtableview.cpp.

References sp, QSpanCollection::spanAt(), and spans.

+ Here is the call graph for this function:

◆ spanContainsSection()

bool QTableViewPrivate::spanContainsSection ( const QHeaderView * header,
int logical,
int spanLogical,
int span ) const

Returns true if the section at logical index logical is part of the span starting at logical index spanLogical and spanning span sections; otherwise, returns false.

Definition at line 783 of file qtableview.cpp.

References header(), and i.

+ Here is the call graph for this function:

◆ trimHiddenSelections()

void QTableViewPrivate::trimHiddenSelections ( QItemSelectionRange * range) const

Trims away indices that are hidden in the treeview due to hidden horizontal or vertical sections.

Definition at line 622 of file qtableview.cpp.

References horizontalHeader, QAbstractItemModel::index(), QHeaderView::isSectionHidden(), QAbstractItemViewPrivate::model, Q_ASSERT, and verticalHeader.

+ Here is the call graph for this function:

◆ updateSpanInsertedColumns()

void QTableViewPrivate::updateSpanInsertedColumns ( const QModelIndex & parent,
int start,
int end )

Updates spans after column insertion.

Definition at line 988 of file qtableview.cpp.

References Q_UNUSED, spans, and QSpanCollection::updateInsertedColumns().

Referenced by QTableView::setModel().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateSpanInsertedRows()

void QTableViewPrivate::updateSpanInsertedRows ( const QModelIndex & parent,
int start,
int end )

Updates spans after row insertion.

Definition at line 978 of file qtableview.cpp.

References Q_UNUSED, spans, and QSpanCollection::updateInsertedRows().

Referenced by QTableView::setModel().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateSpanRemovedColumns()

void QTableViewPrivate::updateSpanRemovedColumns ( const QModelIndex & parent,
int start,
int end )

Updates spans after column removal.

Definition at line 1008 of file qtableview.cpp.

References Q_UNUSED, spans, and QSpanCollection::updateRemovedColumns().

Referenced by QTableView::setModel().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateSpanRemovedRows()

void QTableViewPrivate::updateSpanRemovedRows ( const QModelIndex & parent,
int start,
int end )

Updates spans after row removal.

Definition at line 998 of file qtableview.cpp.

References Q_UNUSED, spans, and QSpanCollection::updateRemovedRows().

Referenced by QTableView::setModel().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ visualColumn()

int QTableViewPrivate::visualColumn ( int logicalCol) const
inline

Definition at line 132 of file qtableview_p.h.

Referenced by drawAndClipSpans(), nextActiveVisualColumn(), and widthHintForIndex().

+ Here is the caller graph for this function:

◆ visualRow()

int QTableViewPrivate::visualRow ( int logicalRow) const
inline

Definition at line 129 of file qtableview_p.h.

Referenced by drawAndClipSpans(), and nextActiveVisualRow().

+ Here is the caller graph for this function:

◆ visualSpanRect()

QRect QTableViewPrivate::visualSpanRect ( const QSpanCollection::Span & span) const

Returns the visual rect for the given span.

Definition at line 863 of file qtableview.cpp.

References columnSpanWidth(), horizontalHeader, i, rowSpanHeight(), QHeaderView::sectionViewportPosition(), showGrid, and verticalHeader.

Referenced by drawAndClipSpans(), and heightHintForIndex().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ widthHintForIndex()

int QTableViewPrivate::widthHintForIndex ( const QModelIndex & index,
int hint,
const QStyleOptionViewItem & option ) const

Get sizeHint width for single Index (providing existing hint and style option)

Definition at line 1062 of file qtableview.cpp.

References QSet< T >::contains(), QPointer< T >::data(), QAbstractItemViewPrivate::editor(), QAbstractItemViewPrivate::editorForIndex(), hasSpans(), hint(), i, logicalColumn(), QWidget::maximumSize, QWidget::minimumSize, QAbstractItemViewPrivate::persistent, qBound(), qMax(), QWidget::sizeHint, QSpanCollection::spanAt(), spans, visualColumn(), QEditorInfo::widget, and QSize::width().

+ Here is the call graph for this function:

Member Data Documentation

◆ columnResizeTimerID

int QTableViewPrivate::columnResizeTimerID

Definition at line 160 of file qtableview_p.h.

◆ columnsToUpdate

QList<int> QTableViewPrivate::columnsToUpdate

Definition at line 162 of file qtableview_p.h.

◆ dynHorHeaderConnections

std::vector<QMetaObject::Connection> QTableViewPrivate::dynHorHeaderConnections

Definition at line 174 of file qtableview_p.h.

Referenced by clearConnections().

◆ geometryRecursionBlock

bool QTableViewPrivate::geometryRecursionBlock

Definition at line 177 of file qtableview_p.h.

◆ gridStyle

Qt::PenStyle QTableViewPrivate::gridStyle

Definition at line 159 of file qtableview_p.h.

◆ horHeaderConnections

std::array<QMetaObject::Connection, 5> QTableViewPrivate::horHeaderConnections

Definition at line 173 of file qtableview_p.h.

Referenced by clearConnections().

◆ horizontalHeader

◆ modelConnections

std::array<QMetaObject::Connection, 4> QTableViewPrivate::modelConnections

Definition at line 171 of file qtableview_p.h.

Referenced by clearConnections().

◆ rowResizeTimerID

int QTableViewPrivate::rowResizeTimerID

Definition at line 161 of file qtableview_p.h.

◆ rowsToUpdate

QList<int> QTableViewPrivate::rowsToUpdate

Definition at line 163 of file qtableview_p.h.

◆ selectionmodelConnection

QMetaObject::Connection QTableViewPrivate::selectionmodelConnection

Definition at line 170 of file qtableview_p.h.

Referenced by clearConnections().

◆ showGrid

bool QTableViewPrivate::showGrid

Definition at line 158 of file qtableview_p.h.

Referenced by drawAndClipSpans(), heightHintForIndex(), and visualSpanRect().

◆ sortingEnabled

bool QTableViewPrivate::sortingEnabled

Definition at line 176 of file qtableview_p.h.

Referenced by QTableWidgetPrivate::dataChanged(), and QTableWidgetPrivate::sort().

◆ spans

◆ verHeaderConnections

std::array<QMetaObject::Connection, 7> QTableViewPrivate::verHeaderConnections

Definition at line 172 of file qtableview_p.h.

Referenced by clearConnections().

◆ verticalHeader

QHeaderView* QTableViewPrivate::verticalHeader

◆ visualCursor

QPoint QTableViewPrivate::visualCursor

Definition at line 178 of file qtableview_p.h.


The documentation for this class was generated from the following files: