On this page

Qt Labs StyleKit

StyleKit is a declarative styling system for Qt Quick Controls, built on top of Qt Quick Templates. It lets you define a complete visual style for all your controls from a single Style object, including support for themes, state-based styling, and transitions. StyleKit handles the underlying template implementation automatically, letting you focus purely on visual aspects such as colors, dimensions, borders, and shadows.

A key strength of StyleKit is its hierarchical property system: set a property once on a base type like abstractButton, and it automatically applies to all button-like controls. Override it where needed for specific controls or states. Changes to your style are instantly reflected across all controls, ensuring consistency while still allowing fine-grained customization.

For controls that need custom behavior beyond what StyleKit provides, you can still implement custom templates and integrate them seamlessly alongside StyleKit-styled controls.

Key Features

  • Declarative Styling - An easy-to-use QML API that lets you focus on design over implementation
  • Hierarchical Fallbacks - All properties propagate. Set them once, override where needed
  • State-Based Styling - Design separate appearances for hovered, pressed, focused, etc.
  • Animated Transitions - Define smooth animations between states
  • Theme Support - Design light and dark themes, and any number of custom themes
  • Variations - Design multiple variations of the same controls
  • Palette and Font Integration - Configure control palettes and fonts using QML

Using the Module in your Project

The QML types of the module are available through the QtQuick.labs.StyleKit import. To use the types, add the following import statement to your .qml file:

import Qt.labs.StyleKit

Articles and Guides

Examples

QML Types

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.