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>.
|
Enumerations | |
enum | WidgetSizePolicy { SizeLarge = 0 , SizeSmall = 1 , SizeMini = 2 , SizeDefault = -1 } |
Functions | |
static bool | usePixmapCache (const QStyleOption *opt) |
QString | uniqueName (const QString &key, const QStyleOption *option, const QSize &size, qreal dpr) |
Q_WIDGETS_EXPORT qreal | dpi (const QStyleOption *option) |
Q_WIDGETS_EXPORT qreal | dpiScaled (qreal value, qreal dpi) |
Q_WIDGETS_EXPORT qreal | dpiScaled (qreal value, const QPaintDevice *device) |
Q_WIDGETS_EXPORT qreal | dpiScaled (qreal value, const QStyleOption *option) |
void | drawBorderPixmap (const QPixmap &pixmap, QPainter *painter, const QRect &rect, int left, int top, int right, int bottom) |
QColor | backgroundColor (const QPalette &pal, const QWidget *widget) |
WidgetSizePolicy | widgetSizePolicy (const QWidget *widget, const QStyleOption *opt) |
Variables | |
static const qreal | qstyleBaseDpi = 96 |
Enumerator | |
---|---|
SizeLarge | |
SizeSmall | |
SizeMini | |
SizeDefault |
Definition at line 65 of file qstylehelper_p.h.
Q_WIDGETS_EXPORT QColor QStyleHelper::backgroundColor | ( | const QPalette & | pal, |
const QWidget * | widget ) |
Definition at line 411 of file qstylehelper.cpp.
References QPalette::Base, QPalette::color(), QWidget::palette, QObject::parent(), QWidget::parentWidget(), Q_UNUSED, and widget.
Referenced by QQC2_NAMESPACE::QMacStyle::drawComplexControl(), and QMacStyle::drawComplexControl().
Q_WIDGETS_EXPORT qreal QStyleHelper::dpi | ( | const QStyleOption * | option | ) |
Definition at line 66 of file qstylehelper.cpp.
References Qt::AA_Use96Dpi, qstyleBaseDpi, qt_defaultDpiX(), and QCoreApplication::testAttribute().
Referenced by dpiScaled(), dpiScaled(), QCommonStyle::sizeFromContents(), and QCommonStyle::subControlRect().
Q_WIDGETS_EXPORT qreal QStyleHelper::dpiScaled | ( | qreal | value, |
const QPaintDevice * | device ) |
Definition at line 93 of file qstylehelper.cpp.
References device, and dpiScaled().
Q_WIDGETS_EXPORT qreal QStyleHelper::dpiScaled | ( | qreal | value, |
const QStyleOption * | option ) |
Definition at line 98 of file qstylehelper.cpp.
References dpi(), and dpiScaled().
Definition at line 88 of file qstylehelper.cpp.
References dpi(), and qstyleBaseDpi.
Referenced by dpiScaled(), dpiScaled(), QWindowsVistaStyle::drawControl(), QCommonStyle::pixelMetric(), QWindows11Style::pixelMetric(), QWindowsVistaStyle::pixelMetric(), QQC2_NAMESPACE::QMacStyle::pixelMetric(), QMacStyle::pixelMetric(), QCommonStyle::sizeFromContents(), QWindowsVistaStyle::sizeFromContents(), QCommonStyle::subControlRect(), and QWindowsVistaStyle::subControlRect().
Q_WIDGETS_EXPORT void QStyleHelper::drawBorderPixmap | ( | const QPixmap & | pixmap, |
QPainter * | painter, | ||
const QRect & | rect, | ||
int | left, | ||
int | top, | ||
int | right, | ||
int | bottom ) |
Definition at line 354 of file qstylehelper.cpp.
References QPainter::drawPixmap(), painter, pixmap, and rect.
QString QStyleHelper::uniqueName | ( | const QString & | key, |
const QStyleOption * | option, | ||
const QSize & | size, | ||
qreal | dpr ) |
Definition at line 35 of file qstylehelper.cpp.
References QAbstractSpinBox::buttonSymbols, dpr(), QAbstractSpinBox::frame, spinBox, QAbstractSpinBox::stepEnabled(), and usePixmapCache().
Referenced by QCommonStyle::drawPrimitive().
|
inlinestatic |
Definition at line 28 of file qstylehelper.cpp.
References opt, QStyleOption::styleObject, QWidget::testAttribute(), Qt::WA_StyleSheetTarget, and widget.
Referenced by uniqueName().
Q_WIDGETS_EXPORT WidgetSizePolicy QStyleHelper::widgetSizePolicy | ( | const QWidget * | widget, |
const QStyleOption * | opt ) |
Definition at line 423 of file qstylehelper.cpp.
References opt, QWidget::parentWidget(), SizeDefault, SizeLarge, SizeMini, SizeSmall, QStyleOption::state, QStyle::State_Mini, QStyle::State_Small, QWidget::testAttribute(), Qt::WA_MacMiniSize, Qt::WA_MacNormalSize, Qt::WA_MacSmallSize, and widget.
Referenced by QMacStylePrivate::aquaSizeConstrain(), cocoaControlType(), QMacStyle::drawControl(), QQC2_NAMESPACE::getControlSize(), getControlSize(), and QStyleOption::initFrom().
|
static |
Definition at line 63 of file qstylehelper.cpp.
Referenced by dpi(), and dpiScaled().