Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qwindowsstyle_p.h
Go to the documentation of this file.
1// Copyright (C) 2016 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
4#ifndef QWINDOWSSTYLE_P_H
5#define QWINDOWSSTYLE_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtWidgets/private/qtwidgetsglobal_p.h>
19#include <QtWidgets/qcommonstyle.h>
20
22
23
24#if QT_CONFIG(style_windows)
25
26class QWindowsStylePrivate;
27
28class Q_WIDGETS_EXPORT QWindowsStyle : public QCommonStyle
29{
31public:
32 QWindowsStyle();
33 ~QWindowsStyle();
34
35 void polish(QApplication*) override;
36 void unpolish(QApplication*) override;
37
38 void polish(QWidget*) override;
39 void unpolish(QWidget*) override;
40
41 void polish(QPalette &) override;
42
43 void drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPainter *p,
44 const QWidget *w = nullptr) const override;
45 void drawControl(ControlElement element, const QStyleOption *opt, QPainter *p,
46 const QWidget *w = nullptr) const override;
47 QRect subElementRect(SubElement r, const QStyleOption *opt, const QWidget *widget = nullptr) const override;
48 void drawComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, QPainter *p,
49 const QWidget *w = nullptr) const override;
50 QSize sizeFromContents(ContentsType ct, const QStyleOption *opt,
51 const QSize &contentsSize, const QWidget *widget = nullptr) const override;
52
53 int pixelMetric(PixelMetric pm, const QStyleOption *option = nullptr, const QWidget *widget = nullptr) const override;
54
55 int styleHint(StyleHint hint, const QStyleOption *opt = nullptr, const QWidget *widget = nullptr,
56 QStyleHintReturn *returnData = nullptr) const override;
57
58 QPixmap standardPixmap(StandardPixmap standardPixmap, const QStyleOption *opt,
59 const QWidget *widget = nullptr) const override;
60
61 QIcon standardIcon(StandardPixmap standardIcon, const QStyleOption *option = nullptr,
62 const QWidget *widget = nullptr) const override;
63
64protected:
65 bool eventFilter(QObject *o, QEvent *e) override;
66 QWindowsStyle(QWindowsStylePrivate &dd);
67
68private:
69 Q_DISABLE_COPY_MOVE(QWindowsStyle)
70 Q_DECLARE_PRIVATE(QWindowsStyle)
71};
72
73#endif // style_windows
74
76
77#endif // QWINDOWSSTYLE_P_H
The QApplication class manages the GUI application's control flow and main settings.
The QCommonStyle class encapsulates the common Look and Feel of a GUI.
\inmodule QtCore
Definition qcoreevent.h:45
The QIcon class provides scalable icons in different modes and states.
Definition qicon.h:20
\inmodule QtCore
Definition qobject.h:103
The QPainter class performs low-level painting on widgets and other paint devices.
Definition qpainter.h:46
The QPalette class contains color groups for each widget state.
Definition qpalette.h:19
Returns a copy of the pixmap that is transformed using the given transformation transform and transfo...
Definition qpixmap.h:27
\inmodule QtCore\reentrant
Definition qrect.h:30
\inmodule QtCore
Definition qsize.h:25
\variable QStyleOptionGraphicsItem::exposedRect
\variable QStyleOptionMenuItem::menuItemType
The QStyleOption class stores the parameters used by QStyle functions.
The QWidget class is the base class of all user interface objects.
Definition qwidget.h:99
QOpenGLWidget * widget
[1]
drawPrimitive(PE_IndicatorCheckBox, &subopt, p, widget)
QStyleOptionButton opt
p drawControl(QStyle::CE_CheckBox, opt)
Combined button and popup list for selecting options.
GLfloat GLfloat GLfloat w
[0]
GLboolean r
[2]
GLfloat GLfloat p
[1]
GLuint GLenum option
static QT_BEGIN_NAMESPACE QVariant hint(QPlatformIntegration::StyleHint h)
#define Q_OBJECT