Raven Core  3.0.0
P2P Digital Currency
platformstyle.h
Go to the documentation of this file.
1 // Copyright (c) 2015 The Bitcoin Core developers
2 // Copyright (c) 2017-2019 The Raven Core developers
3 // Distributed under the MIT software license, see the accompanying
4 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 
6 #ifndef RAVEN_QT_PLATFORMSTYLE_H
7 #define RAVEN_QT_PLATFORMSTYLE_H
8 
9 #include <QIcon>
10 #include <QPixmap>
11 #include <QString>
12 
13 extern bool darkModeEnabled;
14 
15 /* Coin network-specific GUI style information */
17 {
18 public:
20  static const PlatformStyle *instantiate(const QString &platformId);
21 
22  const QString &getName() const { return name; }
23 
24  bool getImagesOnButtons() const { return imagesOnButtons; }
25  bool getUseExtraSpacing() const { return useExtraSpacing; }
26 
27  QColor TextColor() const;
28  QColor ToolBarSelectedTextColor() const;
29  QColor ToolBarNotSelectedTextColor() const;
30  QColor SingleColor() const;
31  QColor MainBackGroundColor() const;
32  QColor TopWidgetBackGroundColor() const;
33  QColor WidgetBackGroundColor() const;
34  QColor SendEntriesBackGroundColor() const;
35  QColor ShadowColor() const;
36  QColor LightBlueColor() const;
37  QColor DarkBlueColor() const;
38  QColor LightOrangeColor() const;
39  QColor DarkOrangeColor() const;
40 
41 
43  QImage SingleColorImage(const QString& filename) const;
44 
46  QIcon SingleColorIcon(const QString& filename) const;
47 
49  QIcon SingleColorIcon(const QIcon& icon) const;
50 
52  QIcon SingleColorIcon(const QIcon& icon, const QColor& color) const;
53 
55  QIcon SingleColorIconOnOff(const QString& filenameOn, const QString& filenameOff) const;
56 
58  QIcon TextColorIcon(const QString& filename) const;
59 
61  QIcon TextColorIcon(const QIcon& icon) const;
62 
64  QIcon OrangeColorIcon(const QString& filename) const;
65 
67  QIcon OrangeColorIcon(const QIcon& icon) const;
68 
69 private:
70  PlatformStyle(const QString &name, bool imagesOnButtons, bool colorizeIcons, bool useExtraSpacing);
71 
72  QString name;
76  QColor singleColor;
77  QColor textColor;
78  /* ... more to come later */
79 };
80 
81 #endif // RAVEN_QT_PLATFORMSTYLE_H
82 
QColor DarkOrangeColor() const
bool getUseExtraSpacing() const
Definition: platformstyle.h:25
PlatformStyle(const QString &name, bool imagesOnButtons, bool colorizeIcons, bool useExtraSpacing)
QColor TopWidgetBackGroundColor() const
QIcon SingleColorIcon(const QString &filename) const
Colorize an icon (given filename) with the icon color.
QIcon SingleColorIconOnOff(const QString &filenameOn, const QString &filenameOff) const
Set icon with two states on and off.
QIcon OrangeColorIcon(const QString &filename) const
Colorize an icon (given filename) with the color dark orange.
QIcon TextColorIcon(const QString &filename) const
Colorize an icon (given filename) with the text color.
QColor singleColor
Definition: platformstyle.h:76
QColor DarkBlueColor() const
QColor MainBackGroundColor() const
QColor ShadowColor() const
QColor ToolBarNotSelectedTextColor() const
QColor SingleColor() const
QColor LightOrangeColor() const
QColor textColor
Definition: platformstyle.h:77
QColor WidgetBackGroundColor() const
static const PlatformStyle * instantiate(const QString &platformId)
Get style associated with provided platform name, or 0 if not known.
QImage SingleColorImage(const QString &filename) const
Colorize an image (given filename) with the icon color.
const QString & getName() const
Definition: platformstyle.h:22
bool darkModeEnabled
bool imagesOnButtons
Definition: platformstyle.h:73
QColor SendEntriesBackGroundColor() const
QColor TextColor() const
bool useExtraSpacing
Definition: platformstyle.h:75
bool getImagesOnButtons() const
Definition: platformstyle.h:24
QColor LightBlueColor() const
QColor ToolBarSelectedTextColor() const
const char * platformId