KIconColors Class
Sepecifies which colors will be used when recoloring icons as its stylesheet. More...
- Header:
#include <KIconColors> - CMake:
find_package(KF6 REQUIRED COMPONENTS IconThemes)
target_link_libraries(mytarget PRIVATE KF6::IconThemes)
List of all members, including inherited members
Deprecated members
Public Functions
- KIconColors()
- KIconColors(const QColor &color)
- KIconColors(const QPalette &palette)
- QColor accent() const
- QColor background() const
- QColor highlight() const
- QColor highlightedText() const
- QColor negativeText() const
- QColor neutralText() const
- QColor positiveText() const
- void setAccent(const QColor &color)
- void setBackground(const QColor &color)
- void setHighlight(const QColor &color)
- void setHighlightedText(const QColor &color)
- void setNegativeText(const QColor &color)
- void setNeutralText(const QColor &color)
- void setPositiveText(const QColor &color)
- void setText(const QColor &color)
- QColor text() const
Protected Functions
Detailed Description
KIconLoader supports re-coloring svg icons based on a set of colors. This class will define them.
See also KIconEngine, KDE::icon
Member Function Documentation
KIconColors::KIconColors()
Will fill the colors based on the default QPalette() constructor.
[explicit] KIconColors::KIconColors(const QColor &color)
Makes all the color properties be color.
[explicit] KIconColors::KIconColors(const QPalette &palette)
Uses palette to define text, highlight, highlightedText, accent and background.
The rest being positiveText, negativeText and neutralText are filled from KColorScheme(QPalette::Active, KColorScheme::Window);
QColor KIconColors::accent() const
See also setAccent()
QColor KIconColors::background() const
See also setBackground()
QColor KIconColors::highlight() const
See also setHighlight()
QColor KIconColors::highlightedText() const
See also setHighlightedText()
QColor KIconColors::negativeText() const
See also setNegativeText()
QColor KIconColors::neutralText() const
See also setNeutralText()
QColor KIconColors::positiveText() const
See also setPositiveText()
void KIconColors::setAccent(const QColor &color)
See also accent()
void KIconColors::setBackground(const QColor &color)
See also background()
void KIconColors::setHighlight(const QColor &color)
See also highlight()
void KIconColors::setHighlightedText(const QColor &color)
See also highlightedText()
void KIconColors::setNegativeText(const QColor &color)
See also negativeText()
void KIconColors::setNeutralText(const QColor &color)
See also neutralText()
void KIconColors::setPositiveText(const QColor &color)
See also positiveText()
void KIconColors::setText(const QColor &color)
See also text()
[protected] QString KIconColors::stylesheet(KIconLoader::States state) const
Returns a CSS stylesheet to be used SVG icon files. state defines the state we are rendering the stylesheet for
Specifies: .ColorScheme-Text, .ColorScheme-Background, .ColorScheme-Highlight, .ColorScheme-HighlightedText, .ColorScheme-PositiveText, .ColorScheme-NeutralText .ColorScheme-NegativeText, .ColorScheme-Accent
QColor KIconColors::text() const
See also setText()