Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QGraphicsSceneBspTreeIndexPrivate Class Reference

#include <qgraphicsscenebsptreeindex_p.h>

+ Inheritance diagram for QGraphicsSceneBspTreeIndexPrivate:
+ Collaboration diagram for QGraphicsSceneBspTreeIndexPrivate:

Public Member Functions

 QGraphicsSceneBspTreeIndexPrivate (QGraphicsScene *scene)
 Constructs a private scene bsp index.
 
void purgeRemovedItems ()
 
void _q_updateIndex ()
 This method will update the BSP index by removing the items from the temporary unindexed list and add them in the indexedItems list.
 
void startIndexTimer (int interval=QGRAPHICSSCENE_INDEXTIMER_TIMEOUT)
 
void resetIndex ()
 
void _q_updateSortCache ()
 
void invalidateSortCache ()
 
void addItem (QGraphicsItem *item, bool recursive=false)
 
void removeItem (QGraphicsItem *item, bool recursive=false, bool moveToUnindexedItems=false)
 
QList< QGraphicsItem * > estimateItems (const QRectF &, Qt::SortOrder, bool b=false)
 
- Public Member Functions inherited from QGraphicsSceneIndexPrivate
 QGraphicsSceneIndexPrivate (QGraphicsScene *scene)
 Constructs a private scene index.
 
 ~QGraphicsSceneIndexPrivate ()
 Destructor of private scene index.
 
void init ()
 
void recursive_items_helper (QGraphicsItem *item, QRectF exposeRect, QGraphicsSceneIndexIntersector intersect, QList< QGraphicsItem * > *items, const QTransform &viewTransform, Qt::ItemSelectionMode mode, qreal parentOpacity, const void *intersectData) const
 
void items_helper (const QRectF &rect, QGraphicsSceneIndexIntersector intersect, QList< QGraphicsItem * > *items, const QTransform &viewTransform, Qt::ItemSelectionMode mode, Qt::SortOrder order, const void *intersectData) const
 
- Public Member Functions inherited from QObjectPrivate
void ensureExtraData ()
 
void setObjectNameWithoutBindings (const QString &name)
 
 QObjectPrivate (decltype(QObjectPrivateVersion) version=QObjectPrivateVersion)
 
virtual ~QObjectPrivate ()
 
void deleteChildren ()
 
void clearBindingStorage ()
 
void setParent_helper (QObject *)
 
void moveToThread_helper ()
 
void setThreadData_helper (QThreadData *currentData, QThreadData *targetData, QBindingStatus *status)
 
QObjectList receiverList (const char *signal) const
 
void ensureConnectionData ()
 
void addConnection (int signal, Connection *c)
 
int signalIndex (const char *signalName, const QMetaObject **meta=nullptr) const
 
bool isSignalConnected (uint signalIdx, bool checkDeclarative=true) const
 
bool maybeSignalConnected (uint signalIndex) const
 
bool isDeclarativeSignalConnected (uint signalIdx) const
 
void connectNotify (const QMetaMethod &signal)
 
void disconnectNotify (const QMetaMethod &signal)
 
void reinitBindingStorageAfterThreadMove ()
 
virtual std::string flagsForDumping () const
 
virtual void writeToDebugStream (QDebug &) const
 
QtPrivate::QPropertyAdaptorSlotObjectgetPropertyAdaptorSlotObject (const QMetaProperty &property)
 
- Public Member Functions inherited from QObjectData
 QObjectData ()=default
 
virtual ~QObjectData ()=0
 
const QMetaObjectdynamicMetaObject () const
 

Static Public Member Functions

static void climbTree (QGraphicsItem *item, int *stackingOrder)
 
static bool closestItemFirst_withCache (const QGraphicsItem *item1, const QGraphicsItem *item2)
 
static bool closestItemLast_withCache (const QGraphicsItem *item1, const QGraphicsItem *item2)
 
static void sortItems (QList< QGraphicsItem * > *itemList, Qt::SortOrder order, bool cached, bool onlyTopLevelItems=false)
 Sort a list of itemList in a specific order and use the cache if requested.
 
- Static Public Member Functions inherited from QGraphicsSceneIndexPrivate
static bool itemCollidesWithPath (const QGraphicsItem *item, const QPainterPath &path, Qt::ItemSelectionMode mode)
 
- Static Public Member Functions inherited from QObjectPrivate
static bool removeConnection (Connection *c)
 
static QObjectPrivateget (QObject *o)
 
static const QObjectPrivateget (const QObject *o)
 
template<typename Func1, typename Func2>
static QMetaObject::Connection connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection)
 
template<typename Func1, typename Func2>
static bool disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot)
 
static QMetaObject::Connection connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject)
 
static QMetaObject::Connection connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type)
 
static QMetaObject::Connection connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type)
 
static bool disconnect (const QObject *sender, int signal_index, void **slot)
 
static bool disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot)
 

Public Attributes

QGraphicsSceneBspTree bsp
 
QRectF sceneRect
 
int bspTreeDepth
 
QBasicTimer indexTimer
 
bool restartIndexTimer
 
bool regenerateIndex
 
int lastItemCount
 
QList< QGraphicsItem * > indexedItems
 
QList< QGraphicsItem * > unindexedItems
 
QList< QGraphicsItem * > untransformableItems
 
QList< int > freeItemIndexes
 
bool purgePending
 
QSet< QGraphicsItem * > removedItems
 
bool sortCacheEnabled
 
bool updatingSortCache
 
- Public Attributes inherited from QGraphicsSceneIndexPrivate
QGraphicsScenescene
 
- Public Attributes inherited from QObjectPrivate
ExtraDataextraData
 
QAtomicPointer< QThreadDatathreadData
 
QAtomicPointer< ConnectionDataconnections
 
union { 
 
   QObject *   currentChildBeingDeleted 
 
   QAbstractDeclarativeData *   declarativeData 
 
};  
 
QAtomicPointer< QtSharedPointer::ExternalRefCountDatasharedRefcount
 
- Public Attributes inherited from QObjectData
QObjectq_ptr
 
QObjectparent
 
QObjectList children
 
uint isWidget: 1
 
uint blockSig: 1
 
uint wasDeleted: 1
 
uint isDeletingChildren: 1
 
uint sendChildEvents: 1
 
uint receiveChildEvents: 1
 
uint isWindow: 1
 
uint deleteLaterCalled: 1
 
uint isQuickItem: 1
 
uint willBeWidget: 1
 
uint wasWidget: 1
 
uint receiveParentEvents: 1
 
uint unused: 20
 
QAtomicInt postedEvents
 
QDynamicMetaObjectDatametaObject
 
QBindingStorage bindingStorage
 

Additional Inherited Members

- Public Types inherited from QObjectPrivate
typedef void(* StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **)
 
using ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData>
 

Detailed Description

Definition at line 75 of file qgraphicsscenebsptreeindex_p.h.

Constructor & Destructor Documentation

◆ QGraphicsSceneBspTreeIndexPrivate()

QGraphicsSceneBspTreeIndexPrivate::QGraphicsSceneBspTreeIndexPrivate ( QGraphicsScene * scene)

Constructs a private scene bsp index.

Definition at line 62 of file qgraphicsscenebsptreeindex.cpp.

Member Function Documentation

◆ _q_updateIndex()

void QGraphicsSceneBspTreeIndexPrivate::_q_updateIndex ( )

This method will update the BSP index by removing the items from the temporary unindexed list and add them in the indexedItems list.

This will also update the growingItemsBoundingRect if needed. This will update the BSP implementation as well.

Definition at line 83 of file qgraphicsscenebsptreeindex.cpp.

◆ _q_updateSortCache()

void QGraphicsSceneBspTreeIndexPrivate::_q_updateSortCache ( )

Definition at line 228 of file qgraphicsscenebsptreeindex.cpp.

◆ addItem()

void QGraphicsSceneBspTreeIndexPrivate::addItem ( QGraphicsItem * item,
bool recursive = false )

Definition at line 265 of file qgraphicsscenebsptreeindex.cpp.

◆ climbTree()

void QGraphicsSceneBspTreeIndexPrivate::climbTree ( QGraphicsItem * item,
int * stackingOrder )
static

Definition at line 204 of file qgraphicsscenebsptreeindex.cpp.

◆ closestItemFirst_withCache()

static bool QGraphicsSceneBspTreeIndexPrivate::closestItemFirst_withCache ( const QGraphicsItem * item1,
const QGraphicsItem * item2 )
inlinestatic

Definition at line 112 of file qgraphicsscenebsptreeindex_p.h.

◆ closestItemLast_withCache()

static bool QGraphicsSceneBspTreeIndexPrivate::closestItemLast_withCache ( const QGraphicsItem * item1,
const QGraphicsItem * item2 )
inlinestatic

Definition at line 116 of file qgraphicsscenebsptreeindex_p.h.

◆ estimateItems()

QList< QGraphicsItem * > QGraphicsSceneBspTreeIndexPrivate::estimateItems ( const QRectF & rect,
Qt::SortOrder order,
bool b = false )

Definition at line 339 of file qgraphicsscenebsptreeindex.cpp.

◆ invalidateSortCache()

void QGraphicsSceneBspTreeIndexPrivate::invalidateSortCache ( )

Definition at line 255 of file qgraphicsscenebsptreeindex.cpp.

◆ purgeRemovedItems()

void QGraphicsSceneBspTreeIndexPrivate::purgeRemovedItems ( )

Removes stale pointers from all data structures.

Definition at line 149 of file qgraphicsscenebsptreeindex.cpp.

◆ removeItem()

void QGraphicsSceneBspTreeIndexPrivate::removeItem ( QGraphicsItem * item,
bool recursive = false,
bool moveToUnindexedItems = false )

Definition at line 296 of file qgraphicsscenebsptreeindex.cpp.

◆ resetIndex()

void QGraphicsSceneBspTreeIndexPrivate::resetIndex ( )

Definition at line 184 of file qgraphicsscenebsptreeindex.cpp.

◆ sortItems()

void QGraphicsSceneBspTreeIndexPrivate::sortItems ( QList< QGraphicsItem * > * itemList,
Qt::SortOrder order,
bool sortCacheEnabled,
bool onlyTopLevelItems = false )
static

Sort a list of itemList in a specific order and use the cache if requested.

Definition at line 375 of file qgraphicsscenebsptreeindex.cpp.

◆ startIndexTimer()

void QGraphicsSceneBspTreeIndexPrivate::startIndexTimer ( int interval = QGRAPHICSSCENE_INDEXTIMER_TIMEOUT)

Starts or restarts the timer used for reindexing unindexed items.

Definition at line 171 of file qgraphicsscenebsptreeindex.cpp.

Member Data Documentation

◆ bsp

QGraphicsSceneBspTree QGraphicsSceneBspTreeIndexPrivate::bsp

Definition at line 81 of file qgraphicsscenebsptreeindex_p.h.

◆ bspTreeDepth

int QGraphicsSceneBspTreeIndexPrivate::bspTreeDepth

Definition at line 83 of file qgraphicsscenebsptreeindex_p.h.

◆ freeItemIndexes

QList<int> QGraphicsSceneBspTreeIndexPrivate::freeItemIndexes

Definition at line 92 of file qgraphicsscenebsptreeindex_p.h.

◆ indexedItems

QList<QGraphicsItem *> QGraphicsSceneBspTreeIndexPrivate::indexedItems

Definition at line 89 of file qgraphicsscenebsptreeindex_p.h.

◆ indexTimer

QBasicTimer QGraphicsSceneBspTreeIndexPrivate::indexTimer

Definition at line 84 of file qgraphicsscenebsptreeindex_p.h.

◆ lastItemCount

int QGraphicsSceneBspTreeIndexPrivate::lastItemCount

Definition at line 87 of file qgraphicsscenebsptreeindex_p.h.

◆ purgePending

bool QGraphicsSceneBspTreeIndexPrivate::purgePending

Definition at line 94 of file qgraphicsscenebsptreeindex_p.h.

◆ regenerateIndex

bool QGraphicsSceneBspTreeIndexPrivate::regenerateIndex

Definition at line 86 of file qgraphicsscenebsptreeindex_p.h.

◆ removedItems

QSet<QGraphicsItem *> QGraphicsSceneBspTreeIndexPrivate::removedItems

Definition at line 95 of file qgraphicsscenebsptreeindex_p.h.

◆ restartIndexTimer

bool QGraphicsSceneBspTreeIndexPrivate::restartIndexTimer

Definition at line 85 of file qgraphicsscenebsptreeindex_p.h.

◆ sceneRect

QRectF QGraphicsSceneBspTreeIndexPrivate::sceneRect

Definition at line 82 of file qgraphicsscenebsptreeindex_p.h.

◆ sortCacheEnabled

bool QGraphicsSceneBspTreeIndexPrivate::sortCacheEnabled

Definition at line 103 of file qgraphicsscenebsptreeindex_p.h.

◆ unindexedItems

QList<QGraphicsItem *> QGraphicsSceneBspTreeIndexPrivate::unindexedItems

Definition at line 90 of file qgraphicsscenebsptreeindex_p.h.

◆ untransformableItems

QList<QGraphicsItem *> QGraphicsSceneBspTreeIndexPrivate::untransformableItems

Definition at line 91 of file qgraphicsscenebsptreeindex_p.h.

◆ updatingSortCache

bool QGraphicsSceneBspTreeIndexPrivate::updatingSortCache

Definition at line 104 of file qgraphicsscenebsptreeindex_p.h.


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