Replace goto.png with a themeable svg image
Some checks failed
Build / Initialization (push) Has been cancelled
Build / Code Format Validation (push) Has been cancelled
Build / Linux (Qt6) (push) Has been cancelled
Build / Linux (Qt6 + 7zip) (push) Has been cancelled
Build / macOS (Qt6 Universal) (push) Has been cancelled
Build / Windows x64 (Qt6) (push) Has been cancelled
Build / Windows ARM64 (Qt6) (push) Has been cancelled
Build / Docker amd64 Image (push) Has been cancelled
Build / Docker arm64 Image (push) Has been cancelled
Build / Publish Dev Builds (push) Has been cancelled
Build / Publish Release (push) Has been cancelled
Build / Publish YACReader10 Pre-release Builds (push) Has been cancelled

This commit is contained in:
luisangelsm
2026-03-17 19:35:30 +01:00
parent b49446c246
commit 83e1b88c2c
10 changed files with 46 additions and 5 deletions

View File

@ -1,4 +1,7 @@
{
"dialogIcons": {
"iconColor": "#404040"
},
"goToFlowWidget": {
"editBackgroundColor": "#55000000",
"editBorderColor": "#77000000",

View File

@ -1,4 +1,7 @@
{
"dialogIcons": {
"iconColor": "#cccccc"
},
"goToFlowWidget": {
"editBackgroundColor": "#55000000",
"editBorderColor": "#77000000",

View File

@ -1,4 +1,7 @@
{
"dialogIcons": {
"iconColor": "#404040"
},
"goToFlowWidget": {
"editBackgroundColor": "#22000000",
"editBorderColor": "#33000000",

View File

@ -182,6 +182,7 @@ struct ShortcutsIconsTheme {
struct DialogIconsTheme {
QIcon findFolderIcon;
QPixmap goToDialogIcon;
};
struct Theme {

View File

@ -56,6 +56,10 @@ struct ShortcutsIconsParams {
QColor iconColor; // Main icon color (replaces #f0f)
};
struct DialogIconsParams {
QColor iconColor; // Main icon color (replaces #f0f)
};
struct TranslatorParams {
TranslatorThemeTemplates t;
@ -79,6 +83,7 @@ struct ThemeParams {
HelpAboutDialogTheme helpAboutDialogParams;
WhatsNewDialogParams whatsNewDialogParams;
ShortcutsIconsParams shortcutsIconsParams;
DialogIconsParams dialogIconsParams;
TranslatorParams translatorParams;
};
@ -340,6 +345,11 @@ Theme makeTheme(const QJsonObject &json)
p.shortcutsIconsParams.iconColor = colorFromJson(s, "iconColor", p.shortcutsIconsParams.iconColor);
}
if (json.contains("dialogIcons")) {
const auto o = json["dialogIcons"].toObject();
p.dialogIconsParams.iconColor = colorFromJson(o, "iconColor", p.dialogIconsParams.iconColor);
}
if (json.contains("translator")) {
const auto t = json["translator"].toObject();
auto &tp = p.translatorParams;