12#if QT_CONFIG(accessibility)
16#include "private/qabstractbutton_p.h"
112 q->setCheckable(
true);
113 q->setMouseTracking(
true);
134 if (
d->tristate &&
d->noChange)
200 if (
d->tristate &&
d->noChange)
215#if QT_CONFIG(accessibility)
216 bool noChange =
d->noChange;
224 d->blockRefresh =
true;
226 d->blockRefresh =
false;
228 if (
state !=
d->publishedState) {
229 d->publishedState =
state;
233#if QT_CONFIG(accessibility)
234 if (noChange !=
d->noChange) {
236 s.checkStateMixed =
true;
237 QAccessibleStateChangeEvent
event(
this,
s);
238 QAccessible::updateAccessibility(&
event);
250 if (
d->sizeHint.isValid())
295 if (hit !=
d->hovering) {
323 if (
state !=
d->publishedState) {
324 d->publishedState =
state;
362#include "moc_qcheckbox.cpp"
Qt::CheckState publishedState
The QCheckBox widget provides a checkbox with a text label.
void setTristate(bool y=true)
QSize minimumSizeHint() const override
\reimp
QSize sizeHint() const override
\reimp
QCheckBox(QWidget *parent=nullptr)
Constructs a checkbox with the given parent, but with no text.
void setCheckState(Qt::CheckState state)
Sets the checkbox's check state to state.
void mouseMoveEvent(QMouseEvent *) override
\reimp
virtual void initStyleOption(QStyleOptionButton *option) const
Initializes option with the values from this QCheckBox.
void checkStateSet() override
\reimp
Qt::CheckState checkState() const
Returns the checkbox's check state.
void paintEvent(QPaintEvent *) override
\reimp
void nextCheckState() override
\reimp
bool hitButton(const QPoint &pos) const override
\reimp
void stateChanged(Qt::CheckState)
bool event(QEvent *e) override
\reimp
\reentrant \inmodule QtGui
bool isNull() const
Returns true if the icon is empty; otherwise returns false.
The QPaintEvent class contains event parameters for paint events.
\inmodule QtCore\reentrant
\inmodule QtCore\reentrant
bool contains(const QRect &r, bool proper=false) const noexcept
This is an overloaded member function, provided for convenience. It differs from the above function o...
constexpr QSize size() const noexcept
Returns the size of the rectangle.
The QSizePolicy class is a layout attribute describing horizontal and vertical resizing policy.
constexpr int height() const noexcept
Returns the height.
constexpr int width() const noexcept
Returns the width.
\macro QT_RESTRICTED_CAST_FROM_ASCII
The QStylePainter class is a convenience class for drawing QStyle elements inside a widget.
virtual QSize sizeFromContents(ContentsType ct, const QStyleOption *opt, const QSize &contentsSize, const QWidget *w=nullptr) const =0
Returns the size of the element described by the specified option and type, based on the provided con...
virtual QRect itemTextRect(const QFontMetrics &fm, const QRect &r, int flags, bool enabled, const QString &text) const
Returns the area within the given rectangle in which to draw the provided text according to the speci...
virtual QRect subElementRect(SubElement subElement, const QStyleOption *option, const QWidget *widget=nullptr) const =0
Returns the sub-area for the given element as described in the provided style option.
Combined button and popup list for selecting options.
constexpr const T & qMax(const T &a, const T &b)
GLdouble GLdouble GLdouble GLdouble q
IUIAutomationTreeWalker __RPC__deref_out_opt IUIAutomationElement ** parent