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
QWidgetPrivate Class Reference

#include <qwidget_p.h>

Inherits QObjectPrivate.

Inherited by QAbstractButtonPrivate, QAbstractSliderPrivate, QAbstractSpinBoxPrivate, QCalendarWidgetPrivate, QCalendarWidgetPrivate, QColumnViewGripPrivate, QComboBoxPrivate, QDialogButtonBoxPrivate, QDialogPrivate, QDockWidgetPrivate, QFocusFramePrivate, QFocusFramePrivate, QFramePrivate, QGroupBoxPrivate, QGroupBoxPrivate, QKeySequenceEditPrivate, QLineEditPrivate, QMainWindowPrivate, QMainWindowPrivate, QMdiSubWindowPrivate, QMenuBarPrivate, QMenuPrivate, QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, QPrintPreviewWidgetPrivate, QPrintPreviewWidgetPrivate, QProgressBarPrivate, QProgressBarPrivate, QQuickWidgetPrivate, QRhiWidgetPrivate, QRubberBandPrivate, QRubberBandPrivate, QSizeGripPrivate, QSizeGripPrivate, QSplashScreenPrivate, QSplashScreenPrivate, QSplitterHandlePrivate, QStatusBarPrivate, QStatusBarPrivate, QSvgWidgetPrivate, QSvgWidgetPrivate, QTabBarPrivate, QTabWidgetPrivate, QTabWidgetPrivate, QToolBarPrivate, QWindowContainerPrivate, QWindowContainerPrivate, QWizardPagePrivate, and QWizardPagePrivate.

+ Collaboration diagram for QWidgetPrivate:

Classes

struct  TextureData
 

Public Types

enum  DrawWidgetFlag {
  DrawAsRoot = 0x01 , DrawPaintOnScreen = 0x02 , DrawRecursive = 0x04 , DrawInvisible = 0x08 ,
  DontSubtractOpaqueChildren = 0x10 , DontDrawOpaqueChildren = 0x20 , DontDrawNativeChildren = 0x40 , DontSetCompositionMode = 0x80 ,
  UseEffectRegionBounds = 0x100
}
 
enum  Direction { DirectionNorth = 0x01 , DirectionEast = 0x10 , DirectionSouth = 0x02 , DirectionWest = 0x20 }
 
enum class  WindowHandleMode { Direct , Closest , TopLevel }
 
enum  CloseMode { CloseNoEvent , CloseWithEvent , CloseWithSpontaneousEvent }
 
enum class  FocusDirection { Previous , Next }
 
enum class  FocusChainRemovalRule { EnsureFocusOut = 0x01 , AssertConsistency = 0x02 }
 
- Public Types inherited from QObjectPrivate
typedef void(*) StaticMetaCallFunction(QObject *, QMetaObject::Call, int, void **)
 
using ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData>
 

Public Member Functions

 QWidgetPrivate (int version=QObjectPrivateVersion)
 
 ~QWidgetPrivate ()
 
QWExtraextraData () const
 
QTLWExtratopData () const
 
QTLWExtramaybeTopData () const
 
QPaintersharedPainter () const
 
void setSharedPainter (QPainter *painter)
 
QWidgetRepaintManagermaybeRepaintManager () const
 
QRhirhi () const
 
QWindowwindowHandle (WindowHandleMode mode=WindowHandleMode::Direct) const
 
QWindow_q_closestWindowHandle () const
 
QScreenassociatedScreen () const
 
template<typename T >
void repaint (T t)
 
template<typename T >
void update (T t)
 
void init (QWidget *desktopWidget, Qt::WindowFlags f)
 
void create ()
 
void createRecursively ()
 
void createWinId ()
 
bool setScreenForPoint (const QPoint &pos)
 
bool setScreen (QScreen *screen)
 
void createTLExtra ()
 
void createExtra ()
 
void deleteExtra ()
 
void createSysExtra ()
 
void deleteSysExtra ()
 
void createTLSysExtra ()
 
void deleteTLSysExtra ()
 
void updateSystemBackground ()
 
void propagatePaletteChange ()
 
void setPalette_helper (const QPalette &)
 
void resolvePalette ()
 
QPalette naturalWidgetPalette (QPalette::ResolveMask inheritedMask) const
 
void setMask_sys (const QRegion &)
 
void raise_sys ()
 
void lower_sys ()
 
void stackUnder_sys (QWidget *)
 
QWidgetdeepestFocusProxy () const
 
void setFocus_sys ()
 
void updateFocusChild ()
 
void updateFont (const QFont &)
 
void setFont_helper (const QFont &font)
 
QFont localFont () const
 
void resolveFont ()
 
QFont naturalWidgetFont (uint inheritedMask) const
 
void setLayoutDirection_helper (Qt::LayoutDirection)
 
void resolveLayoutDirection ()
 
void setLocale_helper (const QLocale &l, bool forceUpdate=false)
 
void resolveLocale ()
 
void setStyle_helper (QStyle *newStyle, bool propagate)
 
void inheritStyle ()
 
void setUpdatesEnabled_helper (bool)
 
bool updateBrushOrigin (QPainter *, const QBrush &brush) const
 
void paintBackground (QPainter *, const QRegion &, DrawWidgetFlags flags=DrawAsRoot) const
 
bool isAboutToShow () const
 The graphicsEffect function returns a pointer to the widget's graphics effect.
 
QRegion prepareToRender (const QRegion &region, QWidget::RenderFlags renderFlags)
 
void render_helper (QPainter *painter, const QPoint &targetOffset, const QRegion &sourceRegion, QWidget::RenderFlags renderFlags)
 
void render (QPaintDevice *target, const QPoint &targetOffset, const QRegion &sourceRegion, QWidget::RenderFlags renderFlags)
 
void drawWidget (QPaintDevice *pdev, const QRegion &rgn, const QPoint &offset, DrawWidgetFlags flags, QPainter *sharedPainter=nullptr, QWidgetRepaintManager *repaintManager=nullptr)
 
void sendPaintEvent (const QRegion &toBePainted)
 
void paintSiblingsRecursive (QPaintDevice *pdev, const QObjectList &children, int index, const QRegion &rgn, const QPoint &offset, DrawWidgetFlags flags, QPainter *sharedPainter, QWidgetRepaintManager *repaintManager)
 
bool shouldPaintOnScreen () const
 
void paintOnScreen (const QRegion &rgn)
 
QRect clipRect () const
 
QRegion clipRegion () const
 
void setSystemClip (QPaintEngine *paintEngine, qreal devicePixelRatio, const QRegion &region)
 
void subtractOpaqueChildren (QRegion &rgn, const QRect &clipRect) const
 
void subtractOpaqueSiblings (QRegion &source, bool *hasDirtySiblingsAbove=nullptr, bool alsoNonOpaque=false) const
 
void clipToEffectiveMask (QRegion &region) const
 
void updateIsOpaque ()
 
void setOpaque (bool opaque)
 
void updateIsTranslucent ()
 
const QRegiongetOpaqueChildren () const
 
void setDirtyOpaqueRegion ()
 
bool close ()
 
bool handleClose (CloseMode mode)
 
void setWindowIcon_helper ()
 
void setWindowIcon_sys ()
 
void setWindowOpacity_sys (qreal opacity)
 
void adjustQuitOnCloseAttribute ()
 
void scrollChildren (int dx, int dy)
 
void moveRect (const QRect &, int dx, int dy)
 
void scrollRect (const QRect &, int dx, int dy)
 
void invalidateBackingStore_resizeHelper (const QPoint &oldPos, const QSize &oldSize)
 Invalidates the backing store when the widget is resized.
 
template<class T >
void invalidateBackingStore (const T &)
 
QRegion overlappedRegion (const QRect &rect, bool breakAfterFirst=false) const
 
bool isOverlapped (const QRect &rect) const
 
void syncBackingStore ()
 
void syncBackingStore (const QRegion &region)
 
bool shouldDiscardSyncRequest () const
 
void updateWidgetTransform (QEvent *event)
 
void reparentFocusWidgets (QWidget *oldtlw)
 
void setWinId (WId)
 
void showChildren (bool spontaneous)
 
void hideChildren (bool spontaneous)
 
void setParent_sys (QWidget *parent, Qt::WindowFlags)
 
void reparentWidgetWindows (QWidget *parentWithWindow, Qt::WindowFlags windowFlags={})
 
void reparentWidgetWindowChildren (QWidget *parentWithWindow)
 
void scroll_sys (int dx, int dy)
 
void scroll_sys (int dx, int dy, const QRect &r)
 
void deactivateWidgetCleanup ()
 
void setGeometry_sys (int, int, int, int, bool)
 
void fixPosIncludesFrame ()
 
void sendPendingMoveAndResizeEvents (bool recursive=false, bool disableUpdates=false)
 
void activateChildLayoutsRecursively ()
 
void show_recursive ()
 
void show_helper ()
 
void show_sys ()
 
void hide_sys ()
 
void hide_helper ()
 
bool isExplicitlyHidden () const
 
void _q_showIfNotHidden ()
 
virtual void setVisible (bool)
 
void setEnabled_helper (bool)
 
void updateFrameStrut ()
 
QRect frameStrut () const
 
void setWindowIconText_sys (const QString &cap)
 
void setWindowIconText_helper (const QString &cap)
 
void setWindowTitle_sys (const QString &cap)
 
void setWindowFilePath_sys (const QString &filePath)
 
void setCursor_sys (const QCursor &cursor)
 
void unsetCursor_sys ()
 
void setWindowTitle_helper (const QString &cap)
 
void setWindowFilePath_helper (const QString &filePath)
 
void setWindowModified_helper ()
 
virtual void setWindowFlags (Qt::WindowFlags windowFlags)
 
bool setMinimumSize_helper (int &minw, int &minh)
 
bool setMaximumSize_helper (int &maxw, int &maxh)
 
void setConstraints_sys ()
 
bool pointInsideRectAndMask (const QPointF &) const
 
QWidgetchildAt_helper (const QPointF &, bool) const
 
QWidgetchildAtRecursiveHelper (const QPointF &p, bool) const
 
void updateGeometry_helper (bool forceUpdate)
 
void getLayoutItemMargins (int *left, int *top, int *right, int *bottom) const
 
void setLayoutItemMargins (int left, int top, int right, int bottom)
 
void setLayoutItemMargins (QStyle::SubElement element, const QStyleOption *opt=nullptr)
 
void updateContentsRect ()
 
QMargins safeAreaMargins () const
 
virtual void aboutToDestroy ()
 
QWidgeteffectiveFocusWidget ()
 
void setModal_sys ()
 
void setRedirected (QPaintDevice *replacement, const QPoint &offset)
 
QPaintDeviceredirected (QPoint *offset) const
 
void restoreRedirected ()
 
void enforceNativeChildren ()
 
bool nativeChildrenForced () const
 
QRect effectiveRectFor (const QRegion &region) const
 
QRect effectiveRectFor (const QRect &rect) const
 
QSize adjustedSize () const
 
void handleSoftwareInputPanel (Qt::MouseButton button, bool clickCausedFocus)
 
void handleSoftwareInputPanel (bool clickCausedFocus=false)
 
void setWSGeometry ()
 
QPoint mapToWS (const QPoint &p) const
 
QPoint mapFromWS (const QPoint &p) const
 
QRect mapToWS (const QRect &r) const
 
QRect mapFromWS (const QRect &r) const
 
virtual QObjectfocusObject ()
 
virtual QPlatformBackingStoreRhiConfig rhiConfig () const
 
virtual TextureData texture () const
 
virtual QPlatformTextureList::Flags textureListFlags ()
 
virtual QImage grabFramebuffer ()
 
virtual void beginBackingStorePainting ()
 
virtual void endBackingStorePainting ()
 
virtual void beginCompose ()
 
virtual void endCompose ()
 
void setRenderToTexture ()
 
void setTextureChildSeen ()
 
virtual void initializeViewportFramebuffer ()
 
virtual void resizeViewportFramebuffer ()
 
virtual void resolveSamples ()
 
virtual bool isStereoEnabled ()
 
virtual bool toggleStereoTargetBuffer ()
 
std::string flagsForDumping () const override
 
QWidgetclosestParentWidgetWithWindowHandle () const
 
QWidgetnextPrevElementInFocusChain (FocusDirection direction) const
 
bool removeFromFocusChain (FocusChainRemovalRules rules=FocusChainRemovalRules(), FocusDirection direction=FocusDirection::Next)
 
bool insertIntoFocusChain (FocusDirection direction, QWidget *position)
 
bool insertIntoFocusChainBefore (QWidget *position)
 
bool insertIntoFocusChainAfter (QWidget *position)
 
void reparentFocusChildren (FocusDirection direction)
 
QWidgetdetermineLastFocusChild (QWidget *noFurtherThan)
 
void initFocusChain ()
 
bool isInFocusChain () const
 
bool isFocusChainConsistent () const
 
void setNetWmWindowTypes (bool skipIfMissing=false)
 
bool stealKeyboardGrab (bool grab)
 
bool stealMouseGrab (bool grab)
 
bool hasChildWithFocusPolicy (Qt::FocusPolicy policy, const QWidget *excludeChildrenOf=nullptr) const
 
- Public Member Functions inherited from QObjectPrivate
void ensureExtraData ()
 
 QObjectPrivate (int version=QObjectPrivateVersion)
 
virtual ~QObjectPrivate ()
 
void deleteChildren ()
 
void clearBindingStorage ()
 
void checkForIncompatibleLibraryVersion (int version) const
 
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 void writeToDebugStream (QDebug &) const
 
QtPrivate::QPropertyAdaptorSlotObjectgetPropertyAdaptorSlotObject (const QMetaProperty &property)
 
- Public Member Functions inherited from QObjectData
 QObjectData ()=default
 
virtual ~QObjectData ()=0
 
QMetaObjectdynamicMetaObject () const
 

Static Public Member Functions

static QWidgetPrivateget (QWidget *w)
 
static const QWidgetPrivateget (const QWidget *w)
 
static void checkRestoredGeometry (const QRect &availableGeometry, QRect *restoredGeometry, int frameHeight)
 
static void adjustFlags (Qt::WindowFlags &flags, QWidget *w=nullptr)
 
static QWidgetparentGraphicsView (const QWidget *widget)
 
static QRect screenGeometry (const QWidget *widget)
 
static QRect availableScreenGeometry (const QWidget *widget)
 
static QScreenscreen (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true)
 
static QRect screenGeometry (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true)
 
static QRect availableScreenGeometry (const QWidget *widget, const QPoint &globalPosition, bool hasPosition=true)
 
static void sendComposeStatus (QWidget *w, bool end)
 
static void setWidgetParentHelper (QObject *widgetAsObject, QObject *newParent)
 
static bool insertIntoFocusChain (const QWidgetList &toBeInserted, FocusDirection direction, QWidget *position)
 
static QWidgetList takeFromFocusChain (QWidget *from, QWidget *to, FocusDirection direction=FocusDirection::Next)
 
- 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

std::unique_ptr< QWExtraextra
 
QWidgetfocus_next
 
QWidgetfocus_prev
 
QWidgetfocus_child
 
QLayoutlayout
 
QRegionneedsFlush
 
QPaintDeviceredirectDev
 
QWidgetItemV2widgetItem
 
QPaintEngineextraPaintEngine
 
const QMetaObjectpolished
 
QGraphicsEffectgraphicsEffect
 
Qt::InputMethodHints imHints
 
QRegion opaqueChildren
 
QRegion dirty
 
uint directFontResolveMask
 
uint inheritedFontResolveMask
 
decltype(std::declval< QPalette >().resolveMask()) directPaletteResolveMask
 
QPalette::ResolveMask inheritedPaletteResolveMask
 
short leftmargin
 
short topmargin
 
short rightmargin
 
short bottommargin
 
signed char leftLayoutItemMargin
 
signed char topLayoutItemMargin
 
signed char rightLayoutItemMargin
 
signed char bottomLayoutItemMargin
 
Qt::HANDLE hd
 
QWidgetData data
 
QSizePolicy size_policy
 
QLocale locale
 
QPoint redirectOffset
 
QList< QAction * > actions
 
QMap< Qt::GestureType, Qt::GestureFlags > gestureContext
 
uint high_attributes [4]
 
QPalette::ColorRole fg_role: 8
 
QPalette::ColorRole bg_role: 8
 
uint dirtyOpaqueChildren: 1
 
uint isOpaque: 1
 
uint retainSizeWhenHiddenChanged: 1
 
uint inDirtyList: 1
 
uint isScrolled: 1
 
uint isMoved: 1
 
uint usesDoubleBufferedGLContext: 1
 
uint mustHaveWindowHandle: 1
 
uint renderToTexture: 1
 
uint textureChildSeen: 1
 
uint inheritsInputMethodHints: 1
 
uint renderToTextureReallyDirty: 1
 
uint usesRhiFlush: 1
 
uint childrenHiddenByWState: 1
 
uint childrenShownByExpose: 1
 
uint dontSetExplicitShowHide: 1
 
- 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
 

Static Public Attributes

static QWidgetMappermapper = nullptr
 
static QWidgetSetallWidgets = nullptr
 
static int instanceCounter = 0
 
static int maxInstances = 0
 

Detailed Description

Definition at line 179 of file qwidget_p.h.

Member Enumeration Documentation

◆ CloseMode

Enumerator
CloseNoEvent 
CloseWithEvent 
CloseWithSpontaneousEvent 

Definition at line 337 of file qwidget_p.h.

◆ Direction

Enumerator
DirectionNorth 
DirectionEast 
DirectionSouth 
DirectionWest 

Definition at line 200 of file qwidget_p.h.

◆ DrawWidgetFlag

Enumerator
DrawAsRoot 
DrawPaintOnScreen 
DrawRecursive 
DrawInvisible 
DontSubtractOpaqueChildren 
DontDrawOpaqueChildren 
DontDrawNativeChildren 
DontSetCompositionMode 
UseEffectRegionBounds 

Definition at line 186 of file qwidget_p.h.

◆ FocusChainRemovalRule

Enumerator
EnsureFocusOut 
AssertConsistency 

Definition at line 745 of file qwidget_p.h.

◆ FocusDirection

enum class QWidgetPrivate::FocusDirection
strong
Enumerator
Previous 
Next 

Definition at line 740 of file qwidget_p.h.

◆ WindowHandleMode

Enumerator
Direct 
Closest 
TopLevel 

Definition at line 227 of file qwidget_p.h.

Constructor & Destructor Documentation

◆ QWidgetPrivate()

QWidgetPrivate::QWidgetPrivate ( int version = QObjectPrivateVersion)
explicit

Definition at line 106 of file qwidget.cpp.

◆ ~QWidgetPrivate()

QWidgetPrivate::~QWidgetPrivate ( )

Definition at line 187 of file qwidget.cpp.

Member Function Documentation

◆ _q_closestWindowHandle()

QWindow * QWidgetPrivate::_q_closestWindowHandle ( ) const

Used by clients outside of widgets to get a handle to the closest QWindow without having to link to widgets.

Definition at line 1090 of file qwidget.cpp.

◆ _q_showIfNotHidden()

void QWidgetPrivate::_q_showIfNotHidden ( )

Definition at line 8429 of file qwidget.cpp.

◆ aboutToDestroy()

virtual void QWidgetPrivate::aboutToDestroy ( )
inlinevirtual

Definition at line 438 of file qwidget_p.h.

◆ activateChildLayoutsRecursively()

void QWidgetPrivate::activateChildLayoutsRecursively ( )

Definition at line 7983 of file qwidget.cpp.

◆ adjustedSize()

QSize QWidgetPrivate::adjustedSize ( ) const

Definition at line 8727 of file qwidget.cpp.

◆ adjustFlags()

void QWidgetPrivate::adjustFlags ( Qt::WindowFlags & flags,
QWidget * w = nullptr )
static

Definition at line 891 of file qwidget.cpp.

◆ adjustQuitOnCloseAttribute()

void QWidgetPrivate::adjustQuitOnCloseAttribute ( )

Definition at line 12471 of file qwidget.cpp.

◆ associatedScreen()

QScreen * QWidgetPrivate::associatedScreen ( ) const

Definition at line 1095 of file qwidget.cpp.

◆ availableScreenGeometry() [1/2]

static QRect QWidgetPrivate::availableScreenGeometry ( const QWidget * widget)
inlinestatic

Definition at line 474 of file qwidget_p.h.

◆ availableScreenGeometry() [2/2]

static QRect QWidgetPrivate::availableScreenGeometry ( const QWidget * widget,
const QPoint & globalPosition,
bool hasPosition = true )
inlinestatic

Definition at line 498 of file qwidget_p.h.

◆ beginBackingStorePainting()

virtual void QWidgetPrivate::beginBackingStorePainting ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 606 of file qwidget_p.h.

◆ beginCompose()

virtual void QWidgetPrivate::beginCompose ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 608 of file qwidget_p.h.

◆ checkRestoredGeometry()

void QWidgetPrivate::checkRestoredGeometry ( const QRect & availableGeometry,
QRect * restoredGeometry,
int frameHeight )
static

Check a if restoredGeometry fits into availableGeometry This method is used to verify that a widget is restored to a geometry, which fits into the target screen.

Parameters
frameHeightrepresents the height of the widget's title bar, which is expected to be on its top.

If the size of restoredGeometry exceeds availableGeometry, its height and width will be resized to be two pixels smaller than availableGeometry. An exact match would be full screen.

If at least one edge of restoredGeometry is outside availableGeometry, restoredGeometry will be moved \list

  • down if its top is off screen
  • up if its bottom is off screen
  • right if its left edge is off screen
  • left if its right edge is off screen \endlist

Definition at line 7421 of file qwidget.cpp.

◆ childAt_helper()

QWidget * QWidgetPrivate::childAt_helper ( const QPointF & p,
bool ignoreChildrenInDestructor ) const

Definition at line 10474 of file qwidget.cpp.

◆ childAtRecursiveHelper()

QWidget * QWidgetPrivate::childAtRecursiveHelper ( const QPointF & p,
bool ignoreChildrenInDestructor ) const

Definition at line 10484 of file qwidget.cpp.

◆ clipRect()

QRect QWidgetPrivate::clipRect ( ) const

Definition at line 1882 of file qwidget.cpp.

◆ clipRegion()

QRegion QWidgetPrivate::clipRegion ( ) const

Definition at line 1906 of file qwidget.cpp.

◆ clipToEffectiveMask()

void QWidgetPrivate::clipToEffectiveMask ( QRegion & region) const

Definition at line 2121 of file qwidget.cpp.

◆ close()

bool QWidgetPrivate::close ( )

Definition at line 8613 of file qwidget.cpp.

◆ closestParentWidgetWithWindowHandle()

QWidget * QWidgetPrivate::closestParentWidgetWithWindowHandle ( ) const

Returns the closest parent widget that has a QWindow window handle

Note
This behavior is different from nativeParentWidget(), which returns the closest parent that has a QWindow window handle with a created QPlatformWindow, and hence native window (winId).

Definition at line 1051 of file qwidget.cpp.

◆ create()

void QWidgetPrivate::create ( )

Definition at line 1280 of file qwidget.cpp.

◆ createExtra()

void QWidgetPrivate::createExtra ( )

Creates the widget extra data.

Definition at line 1645 of file qwidget.cpp.

◆ createRecursively()

void QWidgetPrivate::createRecursively ( )

Definition at line 1021 of file qwidget.cpp.

◆ createSysExtra()

void QWidgetPrivate::createSysExtra ( )

Definition at line 1674 of file qwidget.cpp.

◆ createTLExtra()

void QWidgetPrivate::createTLExtra ( )

Definition at line 1612 of file qwidget.cpp.

◆ createTLSysExtra()

void QWidgetPrivate::createTLSysExtra ( )

Definition at line 1414 of file qwidget.cpp.

◆ createWinId()

void QWidgetPrivate::createWinId ( )

Definition at line 2387 of file qwidget.cpp.

◆ deactivateWidgetCleanup()

void QWidgetPrivate::deactivateWidgetCleanup ( )

Definition at line 2323 of file qwidget.cpp.

◆ deepestFocusProxy()

QWidget * QWidgetPrivate::deepestFocusProxy ( ) const

A focus proxy can have its own focus proxy, which can have its own proxy, and so on. This helper function returns the widget that sits at the bottom of the proxy chain, and therefore the one that should normally get focus if this widget receives a focus request.

Definition at line 6634 of file qwidget.cpp.

◆ deleteExtra()

void QWidgetPrivate::deleteExtra ( )

Deletes the widget extra data.

Definition at line 1683 of file qwidget.cpp.

◆ deleteSysExtra()

void QWidgetPrivate::deleteSysExtra ( )

Definition at line 1700 of file qwidget.cpp.

◆ deleteTLSysExtra()

void QWidgetPrivate::deleteTLSysExtra ( )

Definition at line 1704 of file qwidget.cpp.

◆ determineLastFocusChild()

QWidget * QWidgetPrivate::determineLastFocusChild ( QWidget * noFurtherThan)
Returns
The last focus child of the widget, traversing the focus chain no further than
Parameters
noFurtherThan.

Definition at line 13707 of file qwidget.cpp.

◆ drawWidget()

void QWidgetPrivate::drawWidget ( QPaintDevice * pdev,
const QRegion & rgn,
const QPoint & offset,
DrawWidgetFlags flags,
QPainter * sharedPainter = nullptr,
QWidgetRepaintManager * repaintManager = nullptr )

Definition at line 5467 of file qwidget.cpp.

◆ effectiveFocusWidget()

QWidget * QWidgetPrivate::effectiveFocusWidget ( )
inline

Definition at line 440 of file qwidget_p.h.

◆ effectiveRectFor() [1/2]

QRect QWidgetPrivate::effectiveRectFor ( const QRect & rect) const
inline

Definition at line 545 of file qwidget_p.h.

◆ effectiveRectFor() [2/2]

QRect QWidgetPrivate::effectiveRectFor ( const QRegion & region) const
inline

Definition at line 540 of file qwidget_p.h.

◆ endBackingStorePainting()

virtual void QWidgetPrivate::endBackingStorePainting ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 607 of file qwidget_p.h.

◆ endCompose()

virtual void QWidgetPrivate::endCompose ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, and QRhiWidgetPrivate.

Definition at line 609 of file qwidget_p.h.

◆ enforceNativeChildren()

void QWidgetPrivate::enforceNativeChildren ( )
inline

Definition at line 520 of file qwidget_p.h.

◆ extraData()

QWExtra * QWidgetPrivate::extraData ( ) const
inline

Definition at line 858 of file qwidget_p.h.

◆ fixPosIncludesFrame()

void QWidgetPrivate::fixPosIncludesFrame ( )

Definition at line 7178 of file qwidget.cpp.

◆ flagsForDumping()

std::string QWidgetPrivate::flagsForDumping ( ) const
overridevirtual

Reimplemented from QObjectPrivate.

Definition at line 13249 of file qwidget.cpp.

◆ focusObject()

QObject * QWidgetPrivate::focusObject ( )
virtual

Definition at line 6869 of file qwidget.cpp.

◆ frameStrut()

QRect QWidgetPrivate::frameStrut ( ) const

Definition at line 12194 of file qwidget.cpp.

◆ get() [1/2]

static const QWidgetPrivate * QWidgetPrivate::get ( const QWidget * w)
inlinestatic

Definition at line 213 of file qwidget_p.h.

◆ get() [2/2]

static QWidgetPrivate * QWidgetPrivate::get ( QWidget * w)
inlinestatic

Definition at line 212 of file qwidget_p.h.

◆ getLayoutItemMargins()

void QWidgetPrivate::getLayoutItemMargins ( int * left,
int * top,
int * right,
int * bottom ) const

Definition at line 12419 of file qwidget.cpp.

◆ getOpaqueChildren()

const QRegion & QWidgetPrivate::getOpaqueChildren ( ) const

Definition at line 1994 of file qwidget.cpp.

◆ grabFramebuffer()

virtual QImage QWidgetPrivate::grabFramebuffer ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, QQuickWidgetPrivate, and QRhiWidgetPrivate.

Definition at line 605 of file qwidget_p.h.

◆ handleClose()

bool QWidgetPrivate::handleClose ( CloseMode mode)

For windows, this is called from the QWidgetWindow::handleCloseEvent implementation, which QWidget::close indirectly calls by closing the QWindow. mode will be CloseWithEvent if QWidgetWindow::handleCloseEvent is called indirectly by QWindow::close, and CloseWithSpontaneousEvent if the close event originates from the system (i.e. the user clicked the close button in the title bar).

QDialog calls this method directly in its hide() implementation, which might be called from the QDialog::closeEvent override. mode will be set to CloseNoEvent to prevent recursion.

For non-windows, this is called directly by QWidget::close, and mode will be CloseWithEvent.

The function is also called by the QWidget destructor, with mode set to CloseNoEvent.

Definition at line 8543 of file qwidget.cpp.

◆ handleSoftwareInputPanel() [1/2]

void QWidgetPrivate::handleSoftwareInputPanel ( bool clickCausedFocus = false)
inline

Definition at line 562 of file qwidget_p.h.

◆ handleSoftwareInputPanel() [2/2]

void QWidgetPrivate::handleSoftwareInputPanel ( Qt::MouseButton button,
bool clickCausedFocus )
inline

Definition at line 556 of file qwidget_p.h.

◆ hasChildWithFocusPolicy()

bool QWidgetPrivate::hasChildWithFocusPolicy ( Qt::FocusPolicy policy,
const QWidget * excludeChildrenOf = nullptr ) const
Returns
true, if a child with
Parameters
policyexists and isn't a child of
excludeChildrenOf.Return false otherwise.

Definition at line 13319 of file qwidget.cpp.

◆ hide_helper()

void QWidgetPrivate::hide_helper ( )

Definition at line 8177 of file qwidget.cpp.

◆ hide_sys()

void QWidgetPrivate::hide_sys ( )

Definition at line 8230 of file qwidget.cpp.

◆ hideChildren()

void QWidgetPrivate::hideChildren ( bool spontaneous)

Definition at line 8474 of file qwidget.cpp.

◆ inheritStyle()

void QWidgetPrivate::inheritStyle ( )

Definition at line 2713 of file qwidget.cpp.

◆ init()

void QWidgetPrivate::init ( QWidget * desktopWidget,
Qt::WindowFlags f )

Definition at line 939 of file qwidget.cpp.

◆ initFocusChain()

void QWidgetPrivate::initFocusChain ( )

Initialises the focus chain by making the widget point to itself.

Definition at line 13457 of file qwidget.cpp.

◆ initializeViewportFramebuffer()

virtual void QWidgetPrivate::initializeViewportFramebuffer ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 626 of file qwidget_p.h.

◆ insertIntoFocusChain() [1/2]

bool QWidgetPrivate::insertIntoFocusChain ( const QWidgetList & toBeInserted,
FocusDirection direction,
QWidget * position )
static

Convenience override to insert a QWidgetList

Parameters
toBeInsertedinto the focus chain before or after
position,dependingon
direction.
Returns
true, if the insertion has changed the focus chain, otherwise false.
Note
Parameters
toBeInsertedmust be a consistent focus chain.

Definition at line 13590 of file qwidget.cpp.

◆ insertIntoFocusChain() [2/2]

bool QWidgetPrivate::insertIntoFocusChain ( FocusDirection direction,
QWidget * position )

Inserts a widget into the focus chain before or after

Parameters
position,dependingon
direction.
Returns
true, if the insertion has changed the focus chain, otherwise false.

Definition at line 13539 of file qwidget.cpp.

◆ insertIntoFocusChainAfter()

bool QWidgetPrivate::insertIntoFocusChainAfter ( QWidget * position)
inline

Definition at line 761 of file qwidget_p.h.

◆ insertIntoFocusChainBefore()

bool QWidgetPrivate::insertIntoFocusChainBefore ( QWidget * position)
inline

Definition at line 759 of file qwidget_p.h.

◆ invalidateBackingStore()

template<class T >
template Q_AUTOTEST_EXPORT void QWidgetPrivate::invalidateBackingStore< QRect > ( const T & )

Invalidates the r (in widget's coordinates) of the backing store, i.e. all widgets intersecting with the region will be repainted when the backing store is synced.

Definition at line 115 of file qwidgetrepaintmanager.cpp.

◆ invalidateBackingStore_resizeHelper()

void QWidgetPrivate::invalidateBackingStore_resizeHelper ( const QPoint & oldPos,
const QSize & oldSize )

Invalidates the backing store when the widget is resized.

Static areas are never invalidated unless absolutely needed.

Definition at line 1207 of file qwidgetrepaintmanager.cpp.

◆ isAboutToShow()

bool QWidgetPrivate::isAboutToShow ( ) const

The graphicsEffect function returns a pointer to the widget's graphics effect.

If the widget has no graphics effect, \nullptr is returned.

Since
4.6
See also
setGraphicsEffect()

The setGraphicsEffect function is for setting the widget's graphics effect.

Sets effect as the widget's effect. If there already is an effect installed on this widget, QWidget will delete the existing effect before installing the new effect.

If effect is the installed effect on a different widget, setGraphicsEffect() will remove the effect from the widget and install it on this widget.

QWidget takes ownership of effect.

Note
This function will apply the effect on itself and all its children.
Graphics effects are not supported for OpenGL-based widgets, such as QGLWidget, QOpenGLWidget and QQuickWidget.
Since
4.6
See also
graphicsEffect()

Definition at line 5331 of file qwidget.cpp.

◆ isExplicitlyHidden()

bool QWidgetPrivate::isExplicitlyHidden ( ) const

Definition at line 8423 of file qwidget.cpp.

◆ isFocusChainConsistent()

bool QWidgetPrivate::isFocusChainConsistent ( ) const

A focus chain is consistent, when it is circular: Following the chain in either direction has to return to the beginning. This is why a newly constructed widget points to itself, when the focus chain has been initialized. A newly constructed widget is considered to have a consistent focus chain, while not being part of a focus chain.

The method always returns true, when the logging category "qt.widgets.focus" is disabled. When it is enabled, the method returns true early, if a widget is pointing to itself. It returns false, if one of the following is detected: \list

  • nullptr found in a previous/next pointer.
  • broken chain: widget A is B's previous, but B isn't A's next.
  • chain isn't closed: starting at A doesn't lead back to A. \endlist It return true, if none of the above is observed.
Note
The focus chain is checked only in forward direction. This is sufficient, because the check for a broken chain asserts consistent paths in both directions.

Definition at line 13785 of file qwidget.cpp.

◆ isInFocusChain()

bool QWidgetPrivate::isInFocusChain ( ) const
Returns
true, if the widget is part of a focus chain and false otherwise. A widget is considered to be part of a focus chain, neither FOCUS_NEXT, nor FOCUS_PREV are pointing to the widget itself.
Note
This method doesn't check the consistency of the focus chain. If multiple widgets have been removed from the focus chain by takeFromFocusChain(), isInFocusChain() will return true for all of those widgets, even if they represent an inconsistent focus chain.

Definition at line 13757 of file qwidget.cpp.

◆ isOverlapped()

bool QWidgetPrivate::isOverlapped ( const QRect & rect) const
inline

Definition at line 359 of file qwidget_p.h.

◆ isStereoEnabled()

virtual bool QWidgetPrivate::isStereoEnabled ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 636 of file qwidget_p.h.

◆ localFont()

QFont QWidgetPrivate::localFont ( ) const

Returns a font suitable for inheritance, where only locally set attributes are considered resolved.

Definition at line 4765 of file qwidget.cpp.

◆ lower_sys()

void QWidgetPrivate::lower_sys ( )

Definition at line 12098 of file qwidget.cpp.

◆ mapFromWS() [1/2]

QPoint QWidgetPrivate::mapFromWS ( const QPoint & p) const
inline

Definition at line 579 of file qwidget_p.h.

◆ mapFromWS() [2/2]

QRect QWidgetPrivate::mapFromWS ( const QRect & r) const
inline

Definition at line 585 of file qwidget_p.h.

◆ mapToWS() [1/2]

QPoint QWidgetPrivate::mapToWS ( const QPoint & p) const
inline

Definition at line 576 of file qwidget_p.h.

◆ mapToWS() [2/2]

QRect QWidgetPrivate::mapToWS ( const QRect & r) const
inline

Definition at line 582 of file qwidget_p.h.

◆ maybeRepaintManager()

QWidgetRepaintManager * QWidgetPrivate::maybeRepaintManager ( ) const
inline

Definition at line 904 of file qwidget_p.h.

◆ maybeTopData()

QTLWExtra * QWidgetPrivate::maybeTopData ( ) const
inline

Definition at line 869 of file qwidget_p.h.

◆ moveRect()

void QWidgetPrivate::moveRect ( const QRect & rect,
int dx,
int dy )

Definition at line 382 of file qwidgetrepaintmanager.cpp.

◆ nativeChildrenForced()

bool QWidgetPrivate::nativeChildrenForced ( ) const
inline

Definition at line 535 of file qwidget_p.h.

◆ naturalWidgetFont()

QFont QWidgetPrivate::naturalWidgetFont ( uint inheritedMask) const

Definition at line 4719 of file qwidget.cpp.

◆ naturalWidgetPalette()

QPalette QWidgetPrivate::naturalWidgetPalette ( QPalette::ResolveMask inheritedMask) const

Returns the palette that the widget w inherits from its ancestors and QApplication::palette. inheritedMask is the combination of the widget's ancestors palette request masks (i.e., which attributes from the parent widget's palette are implicitly imposed on this widget by the user). Note that this font does not take into account the palette set on w itself.

Definition at line 4572 of file qwidget.cpp.

◆ nextPrevElementInFocusChain()

QWidget * QWidgetPrivate::nextPrevElementInFocusChain ( FocusDirection direction) const
Returns
next or previous element in the focus chain, depending on
Parameters
direction,irrespectiveof focus proxies or widgets with Qt::NoFocus.

Definition at line 13409 of file qwidget.cpp.

◆ overlappedRegion()

QRegion QWidgetPrivate::overlappedRegion ( const QRect & rect,
bool breakAfterFirst = false ) const

Definition at line 1721 of file qwidget.cpp.

◆ paintBackground()

void QWidgetPrivate::paintBackground ( QPainter * painter,
const QRegion & rgn,
DrawWidgetFlags flags = DrawAsRoot ) const

Definition at line 2278 of file qwidget.cpp.

◆ paintOnScreen()

void QWidgetPrivate::paintOnScreen ( const QRegion & rgn)

Definition at line 1781 of file qwidget.cpp.

◆ paintSiblingsRecursive()

void QWidgetPrivate::paintSiblingsRecursive ( QPaintDevice * pdev,
const QObjectList & children,
int index,
const QRegion & rgn,
const QPoint & offset,
DrawWidgetFlags flags,
QPainter * sharedPainter,
QWidgetRepaintManager * repaintManager )

Definition at line 5736 of file qwidget.cpp.

◆ parentGraphicsView()

static QWidget * QWidgetPrivate::parentGraphicsView ( const QWidget * widget)
inlinestatic

Definition at line 451 of file qwidget_p.h.

◆ pointInsideRectAndMask()

bool QWidgetPrivate::pointInsideRectAndMask ( const QPointF & p) const
inline

Definition at line 888 of file qwidget_p.h.

◆ prepareToRender()

QRegion QWidgetPrivate::prepareToRender ( const QRegion & region,
QWidget::RenderFlags renderFlags )

Definition at line 5345 of file qwidget.cpp.

◆ propagatePaletteChange()

void QWidgetPrivate::propagatePaletteChange ( )

Propagate this widget's palette to all children, except style sheet widgets, and windows that don't enable window propagation (palettes don't normally propagate to windows).

Definition at line 1846 of file qwidget.cpp.

◆ raise_sys()

void QWidgetPrivate::raise_sys ( )

Definition at line 12048 of file qwidget.cpp.

◆ redirected()

QPaintDevice * QWidgetPrivate::redirected ( QPoint * offset) const
inline

Definition at line 510 of file qwidget_p.h.

◆ removeFromFocusChain()

bool QWidgetPrivate::removeFromFocusChain ( FocusChainRemovalRules rules = FocusChainRemovalRules(),
FocusDirection direction = FocusDirection::Next )

Removes a widget from the focus chain, respecting the flags set in

Parameters
rules.\list
  • EnsureFocusOut: If the widget has input focus, transfer focus to the next or previous widget in the focus chain, depending on
direction.
  • RemoveInconsistent: Remove the widget, even if its focus chain is inconsistent.
  • AssertConsistency: qFatal, if the focus chain is inconsistent. This is used in the QWidget destructor. \endlist
Returns
true if the widget has been removed, otherwise false.

Definition at line 13426 of file qwidget.cpp.

◆ render()

void QWidgetPrivate::render ( QPaintDevice * target,
const QPoint & targetOffset,
const QRegion & sourceRegion,
QWidget::RenderFlags renderFlags )

Definition at line 5664 of file qwidget.cpp.

◆ render_helper()

void QWidgetPrivate::render_helper ( QPainter * painter,
const QPoint & targetOffset,
const QRegion & sourceRegion,
QWidget::RenderFlags renderFlags )

Definition at line 5403 of file qwidget.cpp.

◆ repaint()

template<typename T >
void QWidgetPrivate::repaint ( T t)

Definition at line 11224 of file qwidget.cpp.

◆ reparentFocusChildren()

void QWidgetPrivate::reparentFocusChildren ( FocusDirection direction)

Reads QWidget children, which are not part of a focus chain yet. Inserts them into the focus chain before or after the widget, depending on

Parameters
directionand in the order of their creation. This is used, when QWidget::setParent() causes a widget to change toplevel windows.

Definition at line 13472 of file qwidget.cpp.

◆ reparentFocusWidgets()

void QWidgetPrivate::reparentFocusWidgets ( QWidget * oldtlw)

Moves the relevant subwidgets of this widget from the oldtlw's tab chain to that of the new parent, if there's anything to move and we're really moving

This function is called from QWidget::reparent() after the widget has been reparented.

See also
reparent()

Definition at line 7109 of file qwidget.cpp.

◆ reparentWidgetWindowChildren()

void QWidgetPrivate::reparentWidgetWindowChildren ( QWidget * parentWithWindow)

Definition at line 11059 of file qwidget.cpp.

◆ reparentWidgetWindows()

void QWidgetPrivate::reparentWidgetWindows ( QWidget * parentWithWindow,
Qt::WindowFlags windowFlags = {} )

Definition at line 11029 of file qwidget.cpp.

◆ resizeViewportFramebuffer()

virtual void QWidgetPrivate::resizeViewportFramebuffer ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 630 of file qwidget_p.h.

◆ resolveFont()

void QWidgetPrivate::resolveFont ( )

Determine which font is implicitly imposed on this widget by its ancestors and QApplication::font, resolve this against its own font (attributes from the implicit font are copied over). Then propagate this font to this widget's children.

Definition at line 4780 of file qwidget.cpp.

◆ resolveLayoutDirection()

void QWidgetPrivate::resolveLayoutDirection ( )

Definition at line 4872 of file qwidget.cpp.

◆ resolveLocale()

void QWidgetPrivate::resolveLocale ( )

Definition at line 5947 of file qwidget.cpp.

◆ resolvePalette()

void QWidgetPrivate::resolvePalette ( )

Determine which palette is inherited from this widget's ancestors and QApplication::palette, resolve this against this widget's palette (attributes from the inherited palette are copied over this widget's palette). Then propagate this palette to this widget's children.

Definition at line 4616 of file qwidget.cpp.

◆ resolveSamples()

virtual void QWidgetPrivate::resolveSamples ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 632 of file qwidget_p.h.

◆ restoreRedirected()

void QWidgetPrivate::restoreRedirected ( )
inline

Definition at line 517 of file qwidget_p.h.

◆ rhi()

QRhi * QWidgetPrivate::rhi ( ) const

Definition at line 1032 of file qwidget.cpp.

◆ rhiConfig()

virtual QPlatformBackingStoreRhiConfig QWidgetPrivate::rhiConfig ( ) const
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, QQuickWidgetPrivate, and QRhiWidgetPrivate.

Definition at line 590 of file qwidget_p.h.

◆ safeAreaMargins()

QMargins QWidgetPrivate::safeAreaMargins ( ) const

Definition at line 7707 of file qwidget.cpp.

◆ screen()

static QScreen * QWidgetPrivate::screen ( const QWidget * widget,
const QPoint & globalPosition,
bool hasPosition = true )
inlinestatic

Definition at line 479 of file qwidget_p.h.

◆ screenGeometry() [1/2]

static QRect QWidgetPrivate::screenGeometry ( const QWidget * widget)
inlinestatic

Definition at line 469 of file qwidget_p.h.

◆ screenGeometry() [2/2]

static QRect QWidgetPrivate::screenGeometry ( const QWidget * widget,
const QPoint & globalPosition,
bool hasPosition = true )
inlinestatic

Definition at line 493 of file qwidget_p.h.

◆ scroll_sys() [1/2]

void QWidgetPrivate::scroll_sys ( int dx,
int dy )

Definition at line 11114 of file qwidget.cpp.

◆ scroll_sys() [2/2]

void QWidgetPrivate::scroll_sys ( int dx,
int dy,
const QRect & r )

Definition at line 11155 of file qwidget.cpp.

◆ scrollChildren()

void QWidgetPrivate::scrollChildren ( int dx,
int dy )

Definition at line 199 of file qwidget.cpp.

◆ scrollRect()

void QWidgetPrivate::scrollRect ( const QRect & rect,
int dx,
int dy )

Definition at line 459 of file qwidgetrepaintmanager.cpp.

◆ sendComposeStatus()

void QWidgetPrivate::sendComposeStatus ( QWidget * w,
bool end )
static

Definition at line 12484 of file qwidget.cpp.

◆ sendPaintEvent()

void QWidgetPrivate::sendPaintEvent ( const QRegion & toBePainted)

Definition at line 5654 of file qwidget.cpp.

◆ sendPendingMoveAndResizeEvents()

void QWidgetPrivate::sendPendingMoveAndResizeEvents ( bool recursive = false,
bool disableUpdates = false )

Definition at line 7951 of file qwidget.cpp.

◆ setConstraints_sys()

void QWidgetPrivate::setConstraints_sys ( )

Definition at line 3934 of file qwidget.cpp.

◆ setCursor_sys()

void QWidgetPrivate::setCursor_sys ( const QCursor & cursor)

Definition at line 4995 of file qwidget.cpp.

◆ setDirtyOpaqueRegion()

void QWidgetPrivate::setDirtyOpaqueRegion ( )

Definition at line 1971 of file qwidget.cpp.

◆ setEnabled_helper()

void QWidgetPrivate::setEnabled_helper ( bool enable)

Definition at line 3384 of file qwidget.cpp.

◆ setFocus_sys()

void QWidgetPrivate::setFocus_sys ( )

Definition at line 6654 of file qwidget.cpp.

◆ setFont_helper()

void QWidgetPrivate::setFont_helper ( const QFont & font)
inline

Definition at line 276 of file qwidget_p.h.

◆ setGeometry_sys()

void QWidgetPrivate::setGeometry_sys ( int x,
int y,
int w,
int h,
bool isMove )

Definition at line 7246 of file qwidget.cpp.

◆ setLayoutDirection_helper()

void QWidgetPrivate::setLayoutDirection_helper ( Qt::LayoutDirection direction)

Definition at line 4854 of file qwidget.cpp.

◆ setLayoutItemMargins() [1/2]

void QWidgetPrivate::setLayoutItemMargins ( int left,
int top,
int right,
int bottom )

Definition at line 12431 of file qwidget.cpp.

◆ setLayoutItemMargins() [2/2]

void QWidgetPrivate::setLayoutItemMargins ( QStyle::SubElement element,
const QStyleOption * opt = nullptr )

Definition at line 12447 of file qwidget.cpp.

◆ setLocale_helper()

void QWidgetPrivate::setLocale_helper ( const QLocale & l,
bool forceUpdate = false )

Definition at line 5908 of file qwidget.cpp.

◆ setMask_sys()

void QWidgetPrivate::setMask_sys ( const QRegion & region)

Definition at line 13189 of file qwidget.cpp.

◆ setMaximumSize_helper()

bool QWidgetPrivate::setMaximumSize_helper ( int & maxw,
int & maxh )

Definition at line 3989 of file qwidget.cpp.

◆ setMinimumSize_helper()

bool QWidgetPrivate::setMinimumSize_helper ( int & minw,
int & minh )

Definition at line 3901 of file qwidget.cpp.

◆ setModal_sys()

void QWidgetPrivate::setModal_sys ( )

Definition at line 2826 of file qwidget.cpp.

◆ setNetWmWindowTypes()

void QWidgetPrivate::setNetWmWindowTypes ( bool skipIfMissing = false)

Definition at line 13268 of file qwidget.cpp.

◆ setOpaque()

void QWidgetPrivate::setOpaque ( bool opaque)

Definition at line 2200 of file qwidget.cpp.

◆ setPalette_helper()

void QWidgetPrivate::setPalette_helper ( const QPalette & palette)

Definition at line 4623 of file qwidget.cpp.

◆ setParent_sys()

void QWidgetPrivate::setParent_sys ( QWidget * parent,
Qt::WindowFlags f )

Definition at line 10922 of file qwidget.cpp.

◆ setRedirected()

void QWidgetPrivate::setRedirected ( QPaintDevice * replacement,
const QPoint & offset )
inline

Definition at line 503 of file qwidget_p.h.

◆ setRenderToTexture()

void QWidgetPrivate::setRenderToTexture ( )
inline

Definition at line 610 of file qwidget_p.h.

◆ setScreen()

bool QWidgetPrivate::setScreen ( QScreen * screen)

Ensures that the widget's QWindow is set to be on the given screen. Returns true if the screen was changed.

Definition at line 2437 of file qwidget.cpp.

◆ setScreenForPoint()

bool QWidgetPrivate::setScreenForPoint ( const QPoint & pos)

Ensures that the widget is set on the screen point is on. This is handy getting a correct size hint before a resize in e.g QMenu and QToolTip. Returns if the screen was changed.

Definition at line 2422 of file qwidget.cpp.

◆ setSharedPainter()

void QWidgetPrivate::setSharedPainter ( QPainter * painter)
inline

Definition at line 881 of file qwidget_p.h.

◆ setStyle_helper()

void QWidgetPrivate::setStyle_helper ( QStyle * newStyle,
bool propagate )

Definition at line 2666 of file qwidget.cpp.

◆ setSystemClip()

void QWidgetPrivate::setSystemClip ( QPaintEngine * paintEngine,
qreal devicePixelRatio,
const QRegion & region )

Definition at line 1943 of file qwidget.cpp.

◆ setTextureChildSeen()

void QWidgetPrivate::setTextureChildSeen ( )
inline

Definition at line 611 of file qwidget_p.h.

◆ setUpdatesEnabled_helper()

void QWidgetPrivate::setUpdatesEnabled_helper ( bool enable)

Definition at line 1817 of file qwidget.cpp.

◆ setVisible()

◆ setWidgetParentHelper()

void QWidgetPrivate::setWidgetParentHelper ( QObject * widgetAsObject,
QObject * newParent )
static

Definition at line 13241 of file qwidget.cpp.

◆ setWindowFilePath_helper()

void QWidgetPrivate::setWindowFilePath_helper ( const QString & filePath)

Definition at line 6298 of file qwidget.cpp.

◆ setWindowFilePath_sys()

void QWidgetPrivate::setWindowFilePath_sys ( const QString & filePath)

Definition at line 6314 of file qwidget.cpp.

◆ setWindowFlags()

void QWidgetPrivate::setWindowFlags ( Qt::WindowFlags flags)
virtual

Implemented in QWidgetPrivate so that QMdiSubWindowPrivate can reimplement it.

Reimplemented in QMdiSubWindowPrivate.

Definition at line 10590 of file qwidget.cpp.

◆ setWindowIcon_helper()

void QWidgetPrivate::setWindowIcon_helper ( )

Definition at line 6183 of file qwidget.cpp.

◆ setWindowIcon_sys()

void QWidgetPrivate::setWindowIcon_sys ( )

Definition at line 6228 of file qwidget.cpp.

◆ setWindowIconText_helper()

void QWidgetPrivate::setWindowIconText_helper ( const QString & cap)

Definition at line 6083 of file qwidget.cpp.

◆ setWindowIconText_sys()

void QWidgetPrivate::setWindowIconText_sys ( const QString & cap)

Definition at line 6090 of file qwidget.cpp.

◆ setWindowModified_helper()

void QWidgetPrivate::setWindowModified_helper ( )

Definition at line 11679 of file qwidget.cpp.

◆ setWindowOpacity_sys()

void QWidgetPrivate::setWindowOpacity_sys ( qreal opacity)

Definition at line 11632 of file qwidget.cpp.

◆ setWindowTitle_helper()

void QWidgetPrivate::setWindowTitle_helper ( const QString & cap)

Definition at line 6048 of file qwidget.cpp.

◆ setWindowTitle_sys()

void QWidgetPrivate::setWindowTitle_sys ( const QString & cap)

Definition at line 6055 of file qwidget.cpp.

◆ setWinId()

void QWidgetPrivate::setWinId ( WId id)

Definition at line 1592 of file qwidget.cpp.

◆ setWSGeometry()

void QWidgetPrivate::setWSGeometry ( )

Definition at line 221 of file qwidget.cpp.

◆ sharedPainter()

QPainter * QWidgetPrivate::sharedPainter ( ) const
inline

Definition at line 874 of file qwidget_p.h.

◆ shouldDiscardSyncRequest()

bool QWidgetPrivate::shouldDiscardSyncRequest ( ) const

Definition at line 662 of file qwidgetrepaintmanager.cpp.

◆ shouldPaintOnScreen()

bool QWidgetPrivate::shouldPaintOnScreen ( ) const

Definition at line 2146 of file qwidget.cpp.

◆ show_helper()

void QWidgetPrivate::show_helper ( )

Definition at line 8013 of file qwidget.cpp.

◆ show_recursive()

void QWidgetPrivate::show_recursive ( )

Makes the widget visible in the isVisible() meaning of the word. It is only called for toplevels or widgets with visible parents.

Definition at line 7933 of file qwidget.cpp.

◆ show_sys()

void QWidgetPrivate::show_sys ( )

Definition at line 8097 of file qwidget.cpp.

◆ showChildren()

void QWidgetPrivate::showChildren ( bool spontaneous)

Definition at line 8436 of file qwidget.cpp.

◆ stackUnder_sys()

void QWidgetPrivate::stackUnder_sys ( QWidget * )

Definition at line 12145 of file qwidget.cpp.

◆ stealKeyboardGrab()

bool QWidgetPrivate::stealKeyboardGrab ( bool grab)

Definition at line 12914 of file qwidget.cpp.

◆ stealMouseGrab()

bool QWidgetPrivate::stealMouseGrab ( bool grab)

Definition at line 12865 of file qwidget.cpp.

◆ subtractOpaqueChildren()

void QWidgetPrivate::subtractOpaqueChildren ( QRegion & rgn,
const QRect & clipRect ) const

Definition at line 2024 of file qwidget.cpp.

◆ subtractOpaqueSiblings()

void QWidgetPrivate::subtractOpaqueSiblings ( QRegion & source,
bool * hasDirtySiblingsAbove = nullptr,
bool alsoNonOpaque = false ) const

Definition at line 2035 of file qwidget.cpp.

◆ syncBackingStore() [1/2]

void QWidgetPrivate::syncBackingStore ( )

Definition at line 1762 of file qwidget.cpp.

◆ syncBackingStore() [2/2]

void QWidgetPrivate::syncBackingStore ( const QRegion & region)

Definition at line 1772 of file qwidget.cpp.

◆ takeFromFocusChain()

QWidgetList QWidgetPrivate::takeFromFocusChain ( QWidget * from,
QWidget * to,
FocusDirection direction = FocusDirection::Next )
static

Removes the part from the focus chain starting with

Parameters
fromand ending with
to,in

param direction.

Returns
removed part as a QWidgetList.

Definition at line 13676 of file qwidget.cpp.

◆ texture()

virtual TextureData QWidgetPrivate::texture ( ) const
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, QQuickWidgetPrivate, and QRhiWidgetPrivate.

Definition at line 598 of file qwidget_p.h.

◆ textureListFlags()

virtual QPlatformTextureList::Flags QWidgetPrivate::textureListFlags ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, QOpenGLWidgetPrivate, QQuickWidgetPrivate, and QRhiWidgetPrivate.

Definition at line 599 of file qwidget_p.h.

◆ toggleStereoTargetBuffer()

virtual bool QWidgetPrivate::toggleStereoTargetBuffer ( )
inlinevirtual

Reimplemented in QOpenGLWidgetPrivate, and QOpenGLWidgetPrivate.

Definition at line 637 of file qwidget_p.h.

◆ topData()

QTLWExtra * QWidgetPrivate::topData ( ) const
inline

Definition at line 863 of file qwidget_p.h.

◆ unsetCursor_sys()

void QWidgetPrivate::unsetCursor_sys ( )

Definition at line 5015 of file qwidget.cpp.

◆ update()

template<typename T >
void QWidgetPrivate::update ( T t)

Definition at line 11289 of file qwidget.cpp.

◆ updateBrushOrigin()

bool QWidgetPrivate::updateBrushOrigin ( QPainter * painter,
const QBrush & brush ) const

Definition at line 2261 of file qwidget.cpp.

◆ updateContentsRect()

void QWidgetPrivate::updateContentsRect ( )

Definition at line 7661 of file qwidget.cpp.

◆ updateFocusChild()

void QWidgetPrivate::updateFocusChild ( )

Definition at line 6674 of file qwidget.cpp.

◆ updateFont()

void QWidgetPrivate::updateFont ( const QFont & font)

Assign font to this widget, and propagate it to all children, except style sheet widgets (handled differently) and windows that don't enable window propagation. implicitMask is the union of all ancestor widgets' font request masks, and determines which attributes from this widget's font should propagate.

Definition at line 4796 of file qwidget.cpp.

◆ updateFrameStrut()

void QWidgetPrivate::updateFrameStrut ( )

Definition at line 12211 of file qwidget.cpp.

◆ updateGeometry_helper()

void QWidgetPrivate::updateGeometry_helper ( bool forceUpdate)

Definition at line 10511 of file qwidget.cpp.

◆ updateIsOpaque()

void QWidgetPrivate::updateIsOpaque ( )

Definition at line 2161 of file qwidget.cpp.

◆ updateIsTranslucent()

void QWidgetPrivate::updateIsTranslucent ( )

Definition at line 2208 of file qwidget.cpp.

◆ updateSystemBackground()

void QWidgetPrivate::updateSystemBackground ( )

Definition at line 4636 of file qwidget.cpp.

◆ updateWidgetTransform()

void QWidgetPrivate::updateWidgetTransform ( QEvent * event)

Definition at line 228 of file qwidget.cpp.

◆ windowHandle()

QWindow * QWidgetPrivate::windowHandle ( WindowHandleMode mode = WindowHandleMode::Direct) const

Definition at line 1060 of file qwidget.cpp.

Member Data Documentation

◆ actions

QList<QAction*> QWidgetPrivate::actions

Definition at line 710 of file qwidget_p.h.

◆ allWidgets

QWidgetSet * QWidgetPrivate::allWidgets = nullptr
static

Definition at line 662 of file qwidget_p.h.

◆ bg_role

QPalette::ColorRole QWidgetPrivate::bg_role

Definition at line 719 of file qwidget_p.h.

◆ bottomLayoutItemMargin

signed char QWidgetPrivate::bottomLayoutItemMargin

Definition at line 701 of file qwidget_p.h.

◆ bottommargin

short QWidgetPrivate::bottommargin

Definition at line 697 of file qwidget_p.h.

◆ childrenHiddenByWState

uint QWidgetPrivate::childrenHiddenByWState

Definition at line 735 of file qwidget_p.h.

◆ childrenShownByExpose

uint QWidgetPrivate::childrenShownByExpose

Definition at line 736 of file qwidget_p.h.

◆ data

QWidgetData QWidgetPrivate::data

Definition at line 705 of file qwidget_p.h.

◆ directFontResolveMask

uint QWidgetPrivate::directFontResolveMask

Definition at line 690 of file qwidget_p.h.

◆ directPaletteResolveMask

decltype(std::declval<QPalette>().resolveMask()) QWidgetPrivate::directPaletteResolveMask

Definition at line 692 of file qwidget_p.h.

◆ dirty

QRegion QWidgetPrivate::dirty

Definition at line 672 of file qwidget_p.h.

◆ dirtyOpaqueChildren

uint QWidgetPrivate::dirtyOpaqueChildren

Definition at line 720 of file qwidget_p.h.

◆ dontSetExplicitShowHide

uint QWidgetPrivate::dontSetExplicitShowHide

Definition at line 737 of file qwidget_p.h.

◆ extra

std::unique_ptr<QWExtra> QWidgetPrivate::extra

Definition at line 647 of file qwidget_p.h.

◆ extraPaintEngine

QPaintEngine* QWidgetPrivate::extraPaintEngine

Definition at line 655 of file qwidget_p.h.

◆ fg_role

QPalette::ColorRole QWidgetPrivate::fg_role

Definition at line 718 of file qwidget_p.h.

◆ focus_child

QWidget* QWidgetPrivate::focus_child

Definition at line 650 of file qwidget_p.h.

◆ focus_next

QWidget* QWidgetPrivate::focus_next

Definition at line 648 of file qwidget_p.h.

◆ focus_prev

QWidget* QWidgetPrivate::focus_prev

Definition at line 649 of file qwidget_p.h.

◆ gestureContext

QMap<Qt::GestureType, Qt::GestureFlags> QWidgetPrivate::gestureContext

Definition at line 713 of file qwidget_p.h.

◆ graphicsEffect

QGraphicsEffect* QWidgetPrivate::graphicsEffect

Definition at line 657 of file qwidget_p.h.

◆ hd

Qt::HANDLE QWidgetPrivate::hd

Definition at line 704 of file qwidget_p.h.

◆ high_attributes

uint QWidgetPrivate::high_attributes[4]

Definition at line 717 of file qwidget_p.h.

◆ imHints

Qt::InputMethodHints QWidgetPrivate::imHints

Definition at line 664 of file qwidget_p.h.

◆ inDirtyList

uint QWidgetPrivate::inDirtyList

Definition at line 723 of file qwidget_p.h.

◆ inheritedFontResolveMask

uint QWidgetPrivate::inheritedFontResolveMask

Definition at line 691 of file qwidget_p.h.

◆ inheritedPaletteResolveMask

QPalette::ResolveMask QWidgetPrivate::inheritedPaletteResolveMask

Definition at line 693 of file qwidget_p.h.

◆ inheritsInputMethodHints

uint QWidgetPrivate::inheritsInputMethodHints

Definition at line 731 of file qwidget_p.h.

◆ instanceCounter

int QWidgetPrivate::instanceCounter = 0
static

Definition at line 702 of file qwidget_p.h.

◆ isMoved

uint QWidgetPrivate::isMoved

Definition at line 725 of file qwidget_p.h.

◆ isOpaque

uint QWidgetPrivate::isOpaque

Definition at line 721 of file qwidget_p.h.

◆ isScrolled

uint QWidgetPrivate::isScrolled

Definition at line 724 of file qwidget_p.h.

◆ layout

QLayout* QWidgetPrivate::layout

Definition at line 651 of file qwidget_p.h.

◆ leftLayoutItemMargin

signed char QWidgetPrivate::leftLayoutItemMargin

Definition at line 698 of file qwidget_p.h.

◆ leftmargin

short QWidgetPrivate::leftmargin

Definition at line 694 of file qwidget_p.h.

◆ locale

QLocale QWidgetPrivate::locale

Definition at line 707 of file qwidget_p.h.

◆ mapper

QWidgetMapper * QWidgetPrivate::mapper = nullptr
static

Definition at line 661 of file qwidget_p.h.

◆ maxInstances

int QWidgetPrivate::maxInstances = 0
static

Definition at line 703 of file qwidget_p.h.

◆ mustHaveWindowHandle

uint QWidgetPrivate::mustHaveWindowHandle

Definition at line 727 of file qwidget_p.h.

◆ needsFlush

QRegion* QWidgetPrivate::needsFlush

Definition at line 652 of file qwidget_p.h.

◆ opaqueChildren

QRegion QWidgetPrivate::opaqueChildren

Definition at line 671 of file qwidget_p.h.

◆ polished

const QMetaObject* QWidgetPrivate::polished
mutable

Definition at line 656 of file qwidget_p.h.

◆ redirectDev

QPaintDevice* QWidgetPrivate::redirectDev

Definition at line 653 of file qwidget_p.h.

◆ redirectOffset

QPoint QWidgetPrivate::redirectOffset

Definition at line 708 of file qwidget_p.h.

◆ renderToTexture

uint QWidgetPrivate::renderToTexture

Definition at line 728 of file qwidget_p.h.

◆ renderToTextureReallyDirty

uint QWidgetPrivate::renderToTextureReallyDirty

Definition at line 733 of file qwidget_p.h.

◆ retainSizeWhenHiddenChanged

uint QWidgetPrivate::retainSizeWhenHiddenChanged

Definition at line 722 of file qwidget_p.h.

◆ rightLayoutItemMargin

signed char QWidgetPrivate::rightLayoutItemMargin

Definition at line 700 of file qwidget_p.h.

◆ rightmargin

short QWidgetPrivate::rightmargin

Definition at line 696 of file qwidget_p.h.

◆ size_policy

QSizePolicy QWidgetPrivate::size_policy

Definition at line 706 of file qwidget_p.h.

◆ textureChildSeen

uint QWidgetPrivate::textureChildSeen

Definition at line 729 of file qwidget_p.h.

◆ topLayoutItemMargin

signed char QWidgetPrivate::topLayoutItemMargin

Definition at line 699 of file qwidget_p.h.

◆ topmargin

short QWidgetPrivate::topmargin

Definition at line 695 of file qwidget_p.h.

◆ usesDoubleBufferedGLContext

uint QWidgetPrivate::usesDoubleBufferedGLContext

Definition at line 726 of file qwidget_p.h.

◆ usesRhiFlush

uint QWidgetPrivate::usesRhiFlush

Definition at line 734 of file qwidget_p.h.

◆ widgetItem

QWidgetItemV2* QWidgetPrivate::widgetItem

Definition at line 654 of file qwidget_p.h.


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