Maui::PlatformTheme
#include <Maui/PlatformTheme>
Public Types | |
enum | ColorGroup { Disabled = QPalette::Disabled , Active = QPalette::Active , Inactive = QPalette::Inactive , Normal = QPalette::Normal , ColorGroupCount } |
enum | ColorSet { View = 0 , Window , Button , Selection , Tooltip , Complementary , Header , ColorSetCount } |
Public Types inherited from QObject | |
typedef | QObjectList |
Signals | |
void | colorGroupChanged (Maui::PlatformTheme::ColorGroup colorGroup) |
void | colorsChanged () |
void | colorSetChanged (Maui::PlatformTheme::ColorSet colorSet) |
void | inheritChanged (bool inherit) |
void | paletteChanged (const QPalette &pal) |
Static Public Member Functions | |
static PlatformTheme * | qmlAttachedProperties (QObject *object) |
Static Public Member Functions inherited from QObject | |
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type) |
QMetaObject::Connection | connect (const QObject *sender, PointerToMemberFunction signal, Functor functor) |
bool | disconnect (const QMetaObject::Connection &connection) |
bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method) |
bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method) |
bool | disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method) |
QString | tr (const char *sourceText, const char *disambiguation, int n) |
Protected Member Functions | |
bool | event (QEvent *event) override |
void | setActiveBackgroundColor (const QColor &color) |
void | setActiveTextColor (const QColor &color) |
void | setAlternateBackgroundColor (const QColor &color) |
void | setBackgroundColor (const QColor &color) |
void | setDisabledTextColor (const QColor &color) |
void | setFocusColor (const QColor &color) |
void | setHighlightColor (const QColor &color) |
void | setHighlightedTextColor (const QColor &color) |
void | setHoverColor (const QColor &color) |
void | setLinkBackgroundColor (const QColor &color) |
void | setLinkColor (const QColor &color) |
void | setNegativeBackgroundColor (const QColor &color) |
void | setNegativeTextColor (const QColor &color) |
void | setNeutralBackgroundColor (const QColor &color) |
void | setNeutralTextColor (const QColor &color) |
void | setPositiveBackgroundColor (const QColor &color) |
void | setPositiveTextColor (const QColor &color) |
void | setSupportsIconColoring (bool support) |
void | setTextColor (const QColor &color) |
void | setVisitedLinkBackgroundColor (const QColor &color) |
void | setVisitedLinkColor (const QColor &color) |
Protected Member Functions inherited from QObject | |
virtual void | childEvent (QChildEvent *event) |
virtual void | connectNotify (const QMetaMethod &signal) |
virtual void | customEvent (QEvent *event) |
virtual void | disconnectNotify (const QMetaMethod &signal) |
bool | isSignalConnected (const QMetaMethod &signal) const const |
int | receivers (const char *signal) const const |
QObject * | sender () const const |
int | senderSignalIndex () const const |
virtual void | timerEvent (QTimerEvent *event) |
Detailed Description
This class is the base for color management in Maui, different platforms can reimplement this class to integrate with system platform colors of a given platform.
Definition at line 30 of file platformtheme.h.
Member Enumeration Documentation
◆ ColorGroup
enum Maui::PlatformTheme::ColorGroup |
Definition at line 190 of file platformtheme.h.
◆ ColorSet
Enumerator | |
---|---|
Window | Color set for item views, usually the lightest of all. |
Button | Default Color set for windows and "chrome" areas. |
Selection | Color set used by buttons. |
Tooltip | Color set used by selectged areas. |
Complementary | Color set used by tooltips. |
Header | Color set meant to be complementary to Window: usually is a dark theme for light themes. |
ColorSetCount | Color set to be used by heading areas of applications, such as toolbars. |
Definition at line 177 of file platformtheme.h.
Property Documentation
◆ activeBackgroundColor
|
readwrite |
Background for areas that are active or requesting attention.
Definition at line 130 of file platformtheme.h.
◆ activeTextColor
|
readwrite |
Foreground for areas that are active or requesting attention.
Definition at line 80 of file platformtheme.h.
◆ alternateBackgroundColor
|
readwrite |
The generic background color Alternate background; for example, for use in lists.
This color may be the same as BackgroundNormal, especially in sets other than View and Window.
Definition at line 119 of file platformtheme.h.
◆ backgroundColor
|
readwrite |
The generic background color.
Definition at line 111 of file platformtheme.h.
◆ colorGroup
|
readwrite |
This enumeration describes the color group used to generate the colors.
The enum value is based upon QPalette::CpolorGroup and has the same values. It's redefined here in order to make it work with QML
- Since
- 4.43
Definition at line 50 of file platformtheme.h.
◆ colorSet
|
readwrite |
This enumeration describes the color set for which a color is being selected.
Color sets define a color "environment", suitable for drawing all parts of a given region. Colors from different sets should not be combined.
Definition at line 42 of file platformtheme.h.
◆ disabledTextColor
|
readwrite |
Foreground color for disabled areas, usually a mid-gray.
Definition at line 69 of file platformtheme.h.
◆ focusColor
|
readwrite |
A decoration color that indicates active focus.
Definition at line 166 of file platformtheme.h.
◆ highlightColor
|
readwrite |
The background color for selected areas.
Definition at line 125 of file platformtheme.h.
◆ highlightedTextColor
|
readwrite |
Color for text that has been highlighted, often is a light color while normal text is dark.
Definition at line 74 of file platformtheme.h.
◆ hoverColor
|
readwrite |
A decoration color that indicates mouse hovering.
Definition at line 171 of file platformtheme.h.
◆ inherit
|
readwrite |
If true, the colorSet will be inherited from the colorset of a theme of one of the ancestor items default: true.
Definition at line 57 of file platformtheme.h.
◆ linkBackgroundColor
|
readwrite |
Background color for links.
Definition at line 136 of file platformtheme.h.
◆ linkColor
|
readwrite |
Color for links.
Definition at line 85 of file platformtheme.h.
◆ negativeBackgroundColor
|
readwrite |
Background color for negative areas, such as critical errors and destructive actions.
Definition at line 147 of file platformtheme.h.
◆ negativeTextColor
|
readwrite |
Foreground color for negative areas, such as critical error text.
Definition at line 95 of file platformtheme.h.
◆ neutralBackgroundColor
|
readwrite |
Background color for neutral areas, such as warnings (but not critical)
Definition at line 153 of file platformtheme.h.
◆ neutralTextColor
|
readwrite |
Foreground color for neutral areas, such as warning texts (but not critical)
Definition at line 100 of file platformtheme.h.
◆ palette
|
read |
Definition at line 174 of file platformtheme.h.
◆ positiveBackgroundColor
|
readwrite |
Background color for positive areas, such as success messages and trusted content.
Definition at line 159 of file platformtheme.h.
◆ positiveTextColor
|
readwrite |
Success messages, trusted content.
Definition at line 105 of file platformtheme.h.
◆ textColor
|
readwrite |
Color for normal foregrounds, usually text, but not limited to it, anything that should be painted with a clear contrast should use this color.
Definition at line 64 of file platformtheme.h.
◆ visitedLinkBackgroundColor
|
readwrite |
Background color for visited links, usually a bit darker than linkBackgroundColor.
Definition at line 141 of file platformtheme.h.
◆ visitedLinkColor
|
readwrite |
Color for visited links, usually a bit darker than linkColor.
Definition at line 90 of file platformtheme.h.
Constructor & Destructor Documentation
◆ PlatformTheme()
|
explicit |
Definition at line 375 of file platformtheme.cpp.
◆ ~PlatformTheme()
|
override |
Definition at line 387 of file platformtheme.cpp.
Member Function Documentation
◆ activeBackgroundColor()
QColor Maui::PlatformTheme::activeBackgroundColor | ( | ) | const |
Definition at line 476 of file platformtheme.cpp.
◆ activeTextColor()
QColor Maui::PlatformTheme::activeTextColor | ( | ) | const |
Definition at line 471 of file platformtheme.cpp.
◆ alternateBackgroundColor()
QColor Maui::PlatformTheme::alternateBackgroundColor | ( | ) | const |
Definition at line 466 of file platformtheme.cpp.
◆ backgroundColor()
QColor Maui::PlatformTheme::backgroundColor | ( | ) | const |
Definition at line 461 of file platformtheme.cpp.
◆ colorGroup()
PlatformTheme::ColorGroup Maui::PlatformTheme::colorGroup | ( | ) | const |
Definition at line 419 of file platformtheme.cpp.
◆ colorSet()
PlatformTheme::ColorSet Maui::PlatformTheme::colorSet | ( | ) | const |
Definition at line 405 of file platformtheme.cpp.
◆ disabledTextColor()
QColor Maui::PlatformTheme::disabledTextColor | ( | ) | const |
Definition at line 446 of file platformtheme.cpp.
◆ event()
|
overrideprotectedvirtual |
Reimplemented from QObject.
Definition at line 780 of file platformtheme.cpp.
◆ focusColor()
QColor Maui::PlatformTheme::focusColor | ( | ) | const |
Definition at line 531 of file platformtheme.cpp.
◆ highlightColor()
QColor Maui::PlatformTheme::highlightColor | ( | ) | const |
Definition at line 451 of file platformtheme.cpp.
◆ highlightedTextColor()
QColor Maui::PlatformTheme::highlightedTextColor | ( | ) | const |
Definition at line 456 of file platformtheme.cpp.
◆ hoverColor()
QColor Maui::PlatformTheme::hoverColor | ( | ) | const |
Definition at line 536 of file platformtheme.cpp.
◆ iconFromTheme()
|
virtual |
Definition at line 758 of file platformtheme.cpp.
◆ inherit()
bool Maui::PlatformTheme::inherit | ( | ) | const |
Definition at line 424 of file platformtheme.cpp.
◆ linkBackgroundColor()
QColor Maui::PlatformTheme::linkBackgroundColor | ( | ) | const |
Definition at line 486 of file platformtheme.cpp.
◆ linkColor()
QColor Maui::PlatformTheme::linkColor | ( | ) | const |
Definition at line 481 of file platformtheme.cpp.
◆ negativeBackgroundColor()
QColor Maui::PlatformTheme::negativeBackgroundColor | ( | ) | const |
Definition at line 506 of file platformtheme.cpp.
◆ negativeTextColor()
QColor Maui::PlatformTheme::negativeTextColor | ( | ) | const |
Definition at line 501 of file platformtheme.cpp.
◆ neutralBackgroundColor()
QColor Maui::PlatformTheme::neutralBackgroundColor | ( | ) | const |
Definition at line 516 of file platformtheme.cpp.
◆ neutralTextColor()
QColor Maui::PlatformTheme::neutralTextColor | ( | ) | const |
Definition at line 511 of file platformtheme.cpp.
◆ palette()
QPalette Maui::PlatformTheme::palette | ( | ) | const |
Definition at line 743 of file platformtheme.cpp.
◆ positiveBackgroundColor()
QColor Maui::PlatformTheme::positiveBackgroundColor | ( | ) | const |
Definition at line 526 of file platformtheme.cpp.
◆ positiveTextColor()
QColor Maui::PlatformTheme::positiveTextColor | ( | ) | const |
Definition at line 521 of file platformtheme.cpp.
◆ qmlAttachedProperties()
|
static |
Definition at line 775 of file platformtheme.cpp.
◆ setActiveBackgroundColor()
|
protected |
Definition at line 577 of file platformtheme.cpp.
◆ setActiveTextColor()
|
protected |
Definition at line 572 of file platformtheme.cpp.
◆ setAlternateBackgroundColor()
|
protected |
Definition at line 557 of file platformtheme.cpp.
◆ setBackgroundColor()
|
protected |
Definition at line 552 of file platformtheme.cpp.
◆ setColorGroup()
void Maui::PlatformTheme::setColorGroup | ( | PlatformTheme::ColorGroup | colorGroup | ) |
Definition at line 410 of file platformtheme.cpp.
◆ setColorSet()
void Maui::PlatformTheme::setColorSet | ( | PlatformTheme::ColorSet | colorSet | ) |
Definition at line 396 of file platformtheme.cpp.
◆ setCustomActiveBackgroundColor()
Definition at line 678 of file platformtheme.cpp.
◆ setCustomActiveTextColor()
Definition at line 673 of file platformtheme.cpp.
◆ setCustomAlternateBackgroundColor()
Definition at line 658 of file platformtheme.cpp.
◆ setCustomBackgroundColor()
Definition at line 653 of file platformtheme.cpp.
◆ setCustomDisabledTextColor()
Definition at line 648 of file platformtheme.cpp.
◆ setCustomFocusColor()
Definition at line 738 of file platformtheme.cpp.
◆ setCustomHighlightColor()
Definition at line 663 of file platformtheme.cpp.
◆ setCustomHighlightedTextColor()
Definition at line 668 of file platformtheme.cpp.
◆ setCustomHoverColor()
Definition at line 733 of file platformtheme.cpp.
◆ setCustomLinkBackgroundColor()
Definition at line 688 of file platformtheme.cpp.
◆ setCustomLinkColor()
Definition at line 683 of file platformtheme.cpp.
◆ setCustomNegativeBackgroundColor()
Definition at line 708 of file platformtheme.cpp.
◆ setCustomNegativeTextColor()
Definition at line 703 of file platformtheme.cpp.
◆ setCustomNeutralBackgroundColor()
Definition at line 718 of file platformtheme.cpp.
◆ setCustomNeutralTextColor()
Definition at line 713 of file platformtheme.cpp.
◆ setCustomPositiveBackgroundColor()
Definition at line 728 of file platformtheme.cpp.
◆ setCustomPositiveTextColor()
Definition at line 723 of file platformtheme.cpp.
◆ setCustomTextColor()
Definition at line 643 of file platformtheme.cpp.
◆ setCustomVisitedLinkBackgroundColor()
Definition at line 698 of file platformtheme.cpp.
◆ setCustomVisitedLinkColor()
Definition at line 693 of file platformtheme.cpp.
◆ setDisabledTextColor()
|
protected |
Definition at line 547 of file platformtheme.cpp.
◆ setFocusColor()
|
protected |
Definition at line 637 of file platformtheme.cpp.
◆ setHighlightColor()
|
protected |
Definition at line 562 of file platformtheme.cpp.
◆ setHighlightedTextColor()
|
protected |
Definition at line 567 of file platformtheme.cpp.
◆ setHoverColor()
|
protected |
Definition at line 632 of file platformtheme.cpp.
◆ setInherit()
void Maui::PlatformTheme::setInherit | ( | bool | inherit | ) |
Definition at line 429 of file platformtheme.cpp.
◆ setLinkBackgroundColor()
|
protected |
Definition at line 587 of file platformtheme.cpp.
◆ setLinkColor()
|
protected |
Definition at line 582 of file platformtheme.cpp.
◆ setNegativeBackgroundColor()
|
protected |
Definition at line 607 of file platformtheme.cpp.
◆ setNegativeTextColor()
|
protected |
Definition at line 602 of file platformtheme.cpp.
◆ setNeutralBackgroundColor()
|
protected |
Definition at line 617 of file platformtheme.cpp.
◆ setNeutralTextColor()
|
protected |
Definition at line 612 of file platformtheme.cpp.
◆ setPositiveBackgroundColor()
|
protected |
Definition at line 627 of file platformtheme.cpp.
◆ setPositiveTextColor()
|
protected |
Definition at line 622 of file platformtheme.cpp.
◆ setSupportsIconColoring()
|
protected |
Definition at line 770 of file platformtheme.cpp.
◆ setTextColor()
|
protected |
Definition at line 542 of file platformtheme.cpp.
◆ setVisitedLinkBackgroundColor()
|
protected |
Definition at line 597 of file platformtheme.cpp.
◆ setVisitedLinkColor()
|
protected |
Definition at line 592 of file platformtheme.cpp.
◆ supportsIconColoring()
bool Maui::PlatformTheme::supportsIconColoring | ( | ) | const |
Definition at line 765 of file platformtheme.cpp.
◆ textColor()
QColor Maui::PlatformTheme::textColor | ( | ) | const |
Definition at line 441 of file platformtheme.cpp.
◆ visitedLinkBackgroundColor()
QColor Maui::PlatformTheme::visitedLinkBackgroundColor | ( | ) | const |
Definition at line 496 of file platformtheme.cpp.
◆ visitedLinkColor()
QColor Maui::PlatformTheme::visitedLinkColor | ( | ) | const |
Definition at line 491 of file platformtheme.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:12:43 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.