Debian Codegraph @

src/librssguard/miscellaneous/skinfactory.h

raw symbols SCIP
1 // For license of this file, see <project-root-folder>/LICENSE.md.cxx . . $ `<file>/src/librssguard/miscellaneous/skinfactory.h`/
2
3 #ifndef SKINFACTORY_H
4 #define SKINFACTORY_Hcxx . . $ `src/librssguard/miscellaneous/skinfactory.h:4:9`!
5
6 #include "core/message.h"cxx . . $ `<file>/src/librssguard/core/message.h`/
7 #include "gui/webviewers/webviewer.h"cxx . . $ `<file>/src/librssguard/gui/webviewers/webviewer.h`/
8
9 #include <QColor>
10 #include <QFont>
11 #include <QHash>
12 #include <QMetaType>
13 #include <QObject>
14 #include <QPalette>
15 #include <QStringList>
16 #include <QVariant>
17
18 class RootItemcxx . . $ RootItem#;
19
20 class SkinEnumscxx . . $ SkinEnums# : public QObjectcxx . . $ QObject# {
21 Q_OBJECTcxx . . $ QMetaObject#Call#
22
23 public:
24 enum class PaletteColorscxx . . $ SkinEnums#PaletteColors# {
25 // Paint foreground of some interesting items (feeds with new articles, etc.).
26 FgInterestingcxx . . $ SkinEnums#PaletteColors#FgInteresting. = 1,
27
28 // Paint foreground of some interesting items WHEN SELECTED (feeds with new articles, etc.).
29 FgSelectedInterestingcxx . . $ SkinEnums#PaletteColors#FgSelectedInteresting. = 2,
30
31 // Paint foreground of some errored items (feeds with error, etc.).
32 FgErrorcxx . . $ SkinEnums#PaletteColors#FgError. = 4,
33
34 // Paint foreground of some errored items WHEN SELECTED (feeds with error, etc.).
35 FgSelectedErrorcxx . . $ SkinEnums#PaletteColors#FgSelectedError. = 8,
36
37 // OK-ish color (background of list with test results of article filter).
38 Allrightcxx . . $ SkinEnums#PaletteColors#Allright. = 16,
39
40 // Foreground color of items with new articles.
41 FgNewMessagescxx . . $ SkinEnums#PaletteColors#FgNewMessages. = 32,
42
43 // Foreground color of selected items with new articles.
44 FgSelectedNewMessagescxx . . $ SkinEnums#PaletteColors#FgSelectedNewMessages. = 64,
45
46 // Foreground color of disabled items.
47 FgDisabledFeedcxx . . $ SkinEnums#PaletteColors#FgDisabledFeed. = 128
48 };
49
50 static QStringcxx . . $ QString# palleteColorTextcxx . . $ SkinEnums#palleteColorText(cb6efd9004cff0cb).(PaletteColorscxx . . $ SkinEnums#PaletteColors# col);
51
52 Q_ENUMcxx . . $ qt_getEnumMetaObject(39e452ddcb3482c2).(PaletteColors)
53 };
54
55 struct RSSGUARD_DLLSPECcxx . . $ `<built-in>:525:9`! Skincxx . . $ Skin# {
56 QStringcxx . . $ QString# m_skinFoldercxx . . $ Skin#m_skinFolder.;
57 QStringcxx . . $ QString# m_baseNamecxx . . $ Skin#m_baseName.;
58 QStringcxx . . $ QString# m_visibleNamecxx . . $ Skin#m_visibleName.;
59 QStringcxx . . $ QString# m_authorcxx . . $ Skin#m_author.;
60 QStringcxx . . $ QString# m_versioncxx . . $ Skin#m_version.;
61 QStringcxx . . $ QString# m_descriptioncxx . . $ Skin#m_description.;
62 QStringcxx . . $ QString# m_rawDatacxx . . $ Skin#m_rawData.;
63 QStringcxx . . $ QString# m_rawForcedDatacxx . . $ Skin#m_rawForcedData.;
64 QStringcxx . . $ QString# m_adblockedcxx . . $ Skin#m_adblocked.;
65 QStringcxx . . $ QString# m_layoutMarkupWrappercxx . . $ Skin#m_layoutMarkupWrapper.;
66 QStringcxx . . $ QString# m_enclosureImageMarkupcxx . . $ Skin#m_enclosureImageMarkup.;
67 QStringcxx . . $ QString# m_layoutMarkupcxx . . $ Skin#m_layoutMarkup.;
68 QStringcxx . . $ QString# m_enclosureMarkupcxx . . $ Skin#m_enclosureMarkup.;
69 QHashcxx . . $ QHash#<SkinEnumscxx . . $ SkinEnums#::PaletteColorscxx . . $ SkinEnums#PaletteColors#, QColorcxx . . $ QColor#> m_colorPalettecxx . . $ Skin#m_colorPalette.;
70 QStringListcxx . . $ QStringList# m_forcedStylescxx . . $ Skin#m_forcedStyles.;
71 bool m_forcedSkinColorscxx . . $ Skin#m_forcedSkinColors.;
72 QMultiHashcxx . . $ QMultiHash#<QPalettecxx . . $ QPalette#::ColorGroupcxx . . $ QPalette#ColorGroup#, QPaircxx . . $ QPair#<QPalettecxx . . $ QPalette#::ColorRolecxx . . $ QPalette#ColorRole#, QPaircxx . . $ QPair#<QColorcxx . . $ QColor#, Qtcxx . . $ Qt/::BrushStylecxx . . $ Qt/BrushStyle#>>> m_stylePalettecxx . . $ Skin#m_stylePalette.;
73
74 QVariantcxx . . $ QVariant# colorForModelcxx . . $ Skin#colorForModel(b703ae9a1ce5301d).(SkinEnumscxx . . $ SkinEnums#::PaletteColorscxx . . $ SkinEnums#PaletteColors# type,
75 bool use_skin_colors,
76 bool ignore_custom_colors = false) const;
77 QPalettecxx . . $ QPalette# extractPalettecxx . . $ Skin#extractPalette(e5fe513100f8bd45).() const;
78 };
79
80 uintcxx . . $ uint# qHashcxx . . $ qHash(73416132edef71d6).(const SkinEnumscxx . . $ SkinEnums#::PaletteColorscxx . . $ SkinEnums#PaletteColors#& key);
81
82 Q_DECLARE_METATYPEcxx . . $ Skin#(Skin)
83
84 class RSSGUARD_DLLSPECcxx . . $ `<built-in>:525:9`! SkinFactorycxx . . $ SkinFactory# : public QObjectcxx . . $ QObject# {
85 Q_OBJECTcxx . . $ `<external>/4830994369567095248/qtmetamacros.h:133:9`!
86
87 public:
88 explicit SkinFactorycxx . . $ SkinFactory#SkinFactory(749de1b6ae65bddd).(QObjectcxx . . $ QObject#* parent = nullptr);
89 virtual ~cxx . . $ SkinFactory#`~SkinFactory`(ced63f7c635d850d).SkinFactorycxx . . $ SkinFactory#() = default;
90
91 // Loads skin name from settings and sets it as active.
92 void loadCurrentSkincxx . . $ SkinFactory#loadCurrentSkin(b0b38cda41d4ede4).(bool lite, bool replace_existing_qss);
93 Skincxx . . $ Skin# currentSkincxx . . $ SkinFactory#currentSkin(f1ebc492f3942f20).() const;
94
95 // Gets color for model from active skin.
96 QVariantcxx . . $ QVariant# colorForModelcxx . . $ SkinFactory#colorForModel(4e684f27212d3c52).(SkinEnumscxx . . $ SkinEnums#::PaletteColorscxx . . $ SkinEnums#PaletteColors# type, bool ignore_custom_colors = false) const;
97
98 bool isStyleGoodForAlternativeStylePalettecxx . . $ SkinFactory#isStyleGoodForAlternativeStylePalette(f3b39adf77d9c36c).(const QStringcxx . . $ QString#& style_name) const;
99
100 // Returns the name of the skin, that should be activated
101 // after application restart.
102 QStringcxx . . $ QString# selectedSkinNamecxx . . $ SkinFactory#selectedSkinName(6ef7b6c27b00b43d).() const;
103
104 QStringcxx . . $ QString# adBlockedPagecxx . . $ SkinFactory#adBlockedPage(e9cecc7c907e7d19).(const QStringcxx . . $ QString#& url, const QStringcxx . . $ QString#& filter);
105
106 PreparedHtmlcxx . . $ PreparedHtml# prepareHtmlcxx . . $ SkinFactory#prepareHtml(58000ba8dd36147c).(const QStringcxx . . $ QString#& inner_html, const QUrlcxx . . $ QUrl#& base_url);
107 PreparedHtmlcxx . . $ PreparedHtml# generateHtmlOfArticlescxx . . $ SkinFactory#generateHtmlOfArticles(e95722fdaa1a1d02).(const QListcxx . . $ QList#<Messagecxx . . $ Message#>& messages, RootItemcxx . . $ RootItem#* root, int desired_width) const;
108
109 // Gets skin about a particular skin.
110 Skincxx . . $ Skin# skinInfocxx . . $ SkinFactory#skinInfo(384eb71cba31a432).(const QStringcxx . . $ QString#& skin_name, bool lite, bool* ok = nullptr) const;
111
112 // Returns list of installed skins.
113 QListcxx . . $ QList#<Skincxx . . $ Skin#> installedSkinscxx . . $ SkinFactory#installedSkins(6e0bfb6e3ecd787).() const;
114
115 // Sets the desired skin as the active one if it exists.
116 void setCurrentSkinNamecxx . . $ SkinFactory#setCurrentSkinName(3520e46b33348bf6).(const QStringcxx . . $ QString#& skin_name);
117
118 QStringcxx . . $ QString# customSkinBaseFoldercxx . . $ SkinFactory#customSkinBaseFolder(6ef7b6c27b00b43d).() const;
119 bool styleIsFrozencxx . . $ SkinFactory#styleIsFrozen(50ce9a9e25b4a850).() const;
120 QStringcxx . . $ QString# currentStylecxx . . $ SkinFactory#currentStyle(6ef7b6c27b00b43d).() const;
121
122 private:
123 // Loads the skin from given skin_data.
124 void loadSkinFromDatacxx . . $ SkinFactory#loadSkinFromData(b0c7cdc1e1f5fb7e).(const Skincxx . . $ Skin#& skin, bool replace_existing_qss);
125
126 QStringcxx . . $ QString# loadSkinFilecxx . . $ SkinFactory#loadSkinFile(70ba761955aa2ec1).(const QStringcxx . . $ QString#& skin_folder,
127 bool lite,
128 const QStringcxx . . $ QString#& file_name,
129 const QStringcxx . . $ QString#& base_folder) const;
130
131 // Holds name of the current skin.
132 Skincxx . . $ Skin# m_currentSkincxx . . $ SkinFactory#m_currentSkin.;
133 QStringcxx . . $ QString# m_currentStylecxx . . $ SkinFactory#m_currentStyle.;
134 bool m_styleIsFrozencxx . . $ SkinFactory#m_styleIsFrozen.;
135 bool m_useSkinColorscxx . . $ SkinFactory#m_useSkinColors.;
136 };
137
138 inline Skincxx . . $ Skin# SkinFactorycxx . . $ SkinFactory#::currentSkincxx . . $ SkinFactory#currentSkin(f1ebc492f3942f20).() const {
139 return m_currentSkincxx . . $ SkinFactory#m_currentSkin.;
140 }
141
142 #endif // SKINFACTORY_H