|qmake:||QT += gui|
|QPaintEvent(const QRegion &paintRegion)|
|QPaintEvent(const QRect &paintRect)|
|const QRect &||rect() const|
|const QRegion &||region() const|
- 6 public functions inherited from QEvent
- 2 protected variables inherited from QEvent
Additional Inherited Members
- 1 property inherited from QEvent
- 1 public variable inherited from QEvent
- 1 static public member inherited from QEvent
The QPaintEvent class contains event parameters for paint events.
Paint events are sent to widgets that need to update themselves, for instance when part of a widget is exposed because a covering widget was moved.
The event contains a region() that needs to be updated, and a rect() that is the bounding rectangle of that region. Both are provided because many widgets cannot make much use of region(), and rect() can be much faster than region().boundingRect().
Painting is clipped to region() during the processing of a paint event. This clipping is performed by Qt's paint system and is independent of any clipping that may be applied to a QPainter used to draw on the paint device.
Member Function Documentation
QPaintEvent::QPaintEvent(const QRegion &paintRegion)
Constructs a paint event object with the region that needs to be updated. The region is specified by paintRegion.
QPaintEvent::QPaintEvent(const QRect &paintRect)
Constructs a paint event object with the rectangle that needs to be updated. The region is specified by paintRect.
const QRect &QPaintEvent::rect() const
Returns the rectangle that needs to be updated.
const QRegion &QPaintEvent::region() const
Returns the region that needs to be updated.
© 2018 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.