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
qquickwindowsstyle_p.h
Go to the documentation of this file.
1// Copyright (C) 2021 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant reason:default
4
5#ifndef QQUICKWINDOWSSTYLE_P_H
6#define QQUICKWINDOWSSTYLE_P_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
20#include "private/qglobal_p.h"
21#include <QBasicTimer>
22
24
25class QPalette;
26
27namespace QQC2 {
28
31
33
35{
37public:
39 ~QWindowsStyle() override;
40
41 void drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPainter *p) const override;
42 void drawControl(ControlElement element, const QStyleOption *opt, QPainter *p) const override;
43 void drawComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, QPainter *p) const override;
44
45 QRect subElementRect(SubElement r, const QStyleOption *opt) const override;
46 QSize sizeFromContents(ContentsType ct, const QStyleOption *opt, const QSize &contentsSize) const override;
47
48 int pixelMetric(PixelMetric pm, const QStyleOption *option = nullptr) const override;
49
50 int styleHint(StyleHint hint, const QStyleOption *opt = nullptr,
51 QStyleHintReturn *returnData = nullptr) const override;
52
53 QPixmap standardPixmap(StandardPixmap standardPixmap, const QStyleOption *opt) const override;
54
55 QIcon standardIcon(StandardPixmap standardIcon, const QStyleOption *option = nullptr) const override;
56 void polish() override;
57
58protected:
59// bool eventFilter(QObject *o, QEvent *e) override;
61 void timerEvent(QTimerEvent * event) override;
62
63private:
67
68public Q_SLOTS:
69 void refreshPalette();
70};
71
72} // namespace QQC2
73
74QT_END_NAMESPACE
75
76#endif // QQUICKWINDOWSSTYLE_P_H
The QWindowsStyle class provides a Microsoft Windows-like look and feel.
QIcon standardIcon(StandardPixmap standardIcon, const QStyleOption *option=nullptr) const override
\reimp
void drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPainter *p) const override
\reimp
void drawComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, QPainter *p) const override
\reimp
QWindowsStyle(QWindowsStylePrivate &dd)
int pixelMetric(PixelMetric pm, const QStyleOption *option=nullptr) const override
\reimp
int styleHint(StyleHint hint, const QStyleOption *opt=nullptr, QStyleHintReturn *returnData=nullptr) const override
\reimp
void timerEvent(QTimerEvent *event) override
This event handler can be reimplemented in a subclass to receive timer events for the object.
QPixmap standardPixmap(StandardPixmap standardPixmap, const QStyleOption *opt) const override
\reimp
~QWindowsStyle() override
Destroys the QWindowsStyle object.
void drawControl(ControlElement element, const QStyleOption *opt, QPainter *p) const override
\reimp
QRect subElementRect(SubElement r, const QStyleOption *opt) const override
\reimp
QSize sizeFromContents(ContentsType ct, const QStyleOption *opt, const QSize &contentsSize) const override
\reimp
static QScreen * screenOf(const QWindow *w)