![]() |
Qt 6.x
The Qt SDK
|
The QQuickStyle class allows configuring the application style. More...
#include <qquickstyle.h>
Collaboration diagram for QQuickStyle:Static Public Member Functions | |
| static QString | name () |
| Returns the name of the application style. | |
| static void | setStyle (const QString &style) |
| Sets the application style to style. | |
| static void | setFallbackStyle (const QString &style) |
The QQuickStyle class allows configuring the application style.
\inmodule QtQuickControls2
QQuickStyle provides API for querying and configuring the application \l {Styling Qt Quick Controls}{styles} of Qt Quick Controls.
To create your own custom style, see \l {Creating a Custom Style}. Custom styles do not need to implement all controls. By default, the styling system uses the \l {Basic style} as a fallback for controls that a custom style does not provide. It is possible to specify a different fallback style to customize or extend one of the built-in styles.
Definition at line 13 of file qquickstyle.h.
|
static |
Returns the name of the application style.
-style command line argument. Therefore name() may not return a fully resolved value if called before constructing a QGuiApplication. Definition at line 425 of file qquickstyle.cpp.
Referenced by QtQuickControls2Plugin::registerTypes(), QQuickControlsTestUtils::StyleInfo::styleName(), styleUri(), and testStyles().
Here is the caller graph for this function:The fallback style can be also specified by setting the QT_QUICK_CONTROLS_FALLBACK_STYLE \l {Supported Environment Variables in Qt Quick Controls}{environment variable}.
Definition at line 465 of file qquickstyle.cpp.
References QTypeRevision::fromVersion(), QQmlMetaType::matchingModuleVersion(), QStringLiteral, and qWarning.
Here is the call graph for this function:Sets the application style to style.
Definition at line 438 of file qquickstyle.cpp.
References QTypeRevision::fromVersion(), QQmlMetaType::matchingModuleVersion(), qCDebug, QStringLiteral, and qWarning.
Referenced by QQuickStylePlugin::registerTypes(), runTests(), and QQuickControlsTestUtils::QQuickStyleHelper::updateStyle().
Here is the call graph for this function:
Here is the caller graph for this function: