blob: 98797d6a3cbd69a15b3798d6628e0e015245efbd (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
// Copyright (c) 2015-2021 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef BITCOIN_QT_PLATFORMSTYLE_H
#define BITCOIN_QT_PLATFORMSTYLE_H
#include <QIcon>
#include <QPixmap>
#include <QString>
/* Coin network-specific GUI style information */
class PlatformStyle
{
public:
/** Get style associated with provided platform name, or 0 if not known */
static const PlatformStyle *instantiate(const QString &platformId);
const QString &getName() const { return name; }
bool getImagesOnButtons() const { return imagesOnButtons; }
bool getUseExtraSpacing() const { return useExtraSpacing; }
QColor TextColor() const;
QColor SingleColor() const;
/** Colorize an image (given filename) with the icon color */
QImage SingleColorImage(const QString& filename) const;
/** Colorize an icon (given filename) with the icon color */
QIcon SingleColorIcon(const QString& filename) const;
/** Colorize an icon (given object) with the icon color */
QIcon SingleColorIcon(const QIcon& icon) const;
/** Colorize an icon (given object) with the text color */
QIcon TextColorIcon(const QIcon& icon) const;
private:
PlatformStyle(const QString &name, bool imagesOnButtons, bool colorizeIcons, bool useExtraSpacing);
QString name;
bool imagesOnButtons;
bool colorizeIcons;
bool useExtraSpacing;
};
#endif // BITCOIN_QT_PLATFORMSTYLE_H
|