Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
The QPaintEvent class contains event parameters for paint events. More...
#include <qevent.h>
Public Member Functions | |
QPaintEvent (const QRegion &paintRegion) | |
Constructs a paint event object with the region that needs to be updated. | |
QPaintEvent (const QRect &paintRect) | |
Constructs a paint event object with the rectangle that needs to be updated. | |
const QRect & | rect () const |
Returns the rectangle that needs to be updated. | |
const QRegion & | region () const |
Returns the region that needs to be updated. | |
Public Member Functions inherited from QEvent | |
QEvent (Type type) | |
Constructs an event object of type type. | |
virtual | ~QEvent () |
Destroys the event. | |
Type | type () const |
Returns the event type. | |
bool | spontaneous () const |
Returns true if the event originated outside the application (a system event); otherwise returns false . | |
virtual void | setAccepted (bool accepted) |
bool | isAccepted () const |
void | accept () |
Sets the accept flag of the event object, the equivalent of calling setAccepted(true). | |
void | ignore () |
Clears the accept flag parameter of the event object, the equivalent of calling setAccepted(false). | |
bool | isInputEvent () const noexcept |
bool | isPointerEvent () const noexcept |
bool | isSinglePointEvent () const noexcept |
virtual QEvent * | clone () const |
Creates and returns an identical copy of this event. | |
Protected Attributes | |
QRect | m_rect |
QRegion | m_region |
bool | m_erased |
Protected Attributes inherited from QEvent | |
quint16 | t |
The QPaintEvent class contains event parameters for paint events.
\inmodule QtGui
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().
|
explicit |
Constructs a paint event object with the region that needs to be updated.
The region is specified by paintRegion.
Definition at line 1624 of file qevent.cpp.
|
explicit |
Constructs a paint event object with the rectangle that needs to be updated.
The region is specified by paintRect.
Definition at line 1632 of file qevent.cpp.
|
inline |
Returns the rectangle that needs to be updated.
|
inline |
Returns the region that needs to be updated.