5#include <QtWidgets/private/qtwidgetsglobal_p.h>
6#include <QtCore/qpoint.h>
7#include <QtCore/qstring.h>
8#include <QtGui/qpaintdevice.h>
9#include <QtGui/qpolygon.h>
10#include <QtCore/qstringbuilder.h>
11#include <QtGui/qaccessible.h>
12#include <QtGui/qpainter.h>
13#include <QtGui/qguiapplication.h>
14#include <QtWidgets/qwidget.h>
16#ifndef QSTYLEHELPER_P_H
17#define QSTYLEHELPER_P_H
30#include <private/qhexstring_p.h>
38class QStyleOptionSlider;
59 int left = 0,
int top = 0,
int right = 0,
61#if QT_CONFIG(accessibility)
75 return widget ? widget->devicePixelRatio()
76 : qApp->devicePixelRatio();
82 Q_ASSERT(painter && painter->device());
83 return painter->device()->devicePixelRatio();
\inmodule QtCore\reentrant
static qreal getDpr(const QPainter *painter)
static qreal getDpr(const QWidget *widget)
Q_WIDGETS_EXPORT void drawBorderPixmap(const QPixmap &pixmap, QPainter *painter, const QRect &rect, int left=0, int top=0, int right=0, int bottom=0)
static void qDrawWinShades(QPainter *p, int x, int y, int w, int h, const QColor &c1, const QColor &c2, const QColor &c3, const QColor &c4, const QBrush *fill)
QVarLengthArray< QPainter::PixmapFragment, 16 > QPixmapFragmentsArray
Q_WIDGETS_EXPORT void qDrawPlainRect(QPainter *p, int x, int y, int w, int h, const QColor &, int lineWidth=1, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawShadeRect(QPainter *p, int x, int y, int w, int h, const QPalette &pal, bool sunken=false, int lineWidth=1, int midLineWidth=0, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawWinPanel(QPainter *p, const QRect &r, const QPalette &pal, bool sunken=false, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawShadePanel(QPainter *p, int x, int y, int w, int h, const QPalette &pal, bool sunken=false, int lineWidth=1, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawWinButton(QPainter *p, int x, int y, int w, int h, const QPalette &pal, bool sunken=false, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawShadeRect(QPainter *p, const QRect &r, const QPalette &pal, bool sunken=false, int lineWidth=1, int midLineWidth=0, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawWinButton(QPainter *p, const QRect &r, const QPalette &pal, bool sunken=false, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawPlainRect(QPainter *p, const QRect &r, const QColor &, int lineWidth=1, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawShadeLine(QPainter *p, const QPoint &p1, const QPoint &p2, const QPalette &pal, bool sunken=true, int lineWidth=1, int midLineWidth=0)
Q_WIDGETS_EXPORT void qDrawShadePanel(QPainter *p, const QRect &r, const QPalette &pal, bool sunken=false, int lineWidth=1, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawShadeLine(QPainter *p, int x1, int y1, int x2, int y2, const QPalette &pal, bool sunken=true, int lineWidth=1, int midLineWidth=0)
Q_WIDGETS_EXPORT void qDrawPlainRoundedRect(QPainter *p, int x, int y, int w, int h, qreal rx, qreal ry, const QColor &, int lineWidth=1, const QBrush *fill=nullptr)
Q_WIDGETS_EXPORT void qDrawWinPanel(QPainter *p, int x, int y, int w, int h, const QPalette &pal, bool sunken=false, const QBrush *fill=nullptr)
The QTileRules class provides the rules used to draw a pixmap or image split into nine segments.