2 * Bittorrent Client using Qt and libtorrent.
3 * Copyright (C) 2023-2024 Vladimir Golovnev <glassez@yandex.ru>
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * as published by the Free Software Foundation; either version 2
8 * of the License, or (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
20 * In addition, as a special exception, the copyright holders give permission to
21 * link this program with the OpenSSL project's "OpenSSL" library (or with
22 * modified versions of it that use the same license as the "OpenSSL" library),
23 * and distribute the linked executables. You must obey the GNU General Public
24 * License in all respects for all of the code used other than "OpenSSL". If
25 * you modify file(s), you may extend this exception to your version of the
26 * file(s), but you are not obligated to do so. If you do not wish to do so,
27 * delete this exception statement from your version.
38 #include "base/global.h"
41 inline const QString CONFIG_FILE_NAME
= u
"config.json"_s
;
42 inline const QString STYLESHEET_FILE_NAME
= u
"stylesheet.qss"_s
;
43 inline const QString KEY_COLORS
= u
"colors"_s
;
44 inline const QString KEY_COLORS_LIGHT
= u
"colors.light"_s
;
45 inline const QString KEY_COLORS_DARK
= u
"colors.dark"_s
;
53 inline QHash
<QString
, UIThemeColor
> defaultUIThemeColors()
56 {u
"Log.TimeStamp"_s
, {Color::Primer::Light::fgSubtle
, Color::Primer::Dark::fgSubtle
}},
57 {u
"Log.Normal"_s
, {{}, {}}},
58 {u
"Log.Info"_s
, {Color::Primer::Light::accentFg
, Color::Primer::Dark::accentFg
}},
59 {u
"Log.Warning"_s
, {Color::Primer::Light::severeFg
, Color::Primer::Dark::severeFg
}},
60 {u
"Log.Critical"_s
, {Color::Primer::Light::dangerFg
, Color::Primer::Dark::dangerFg
}},
61 {u
"Log.BannedPeer"_s
, {Color::Primer::Light::dangerFg
, Color::Primer::Dark::dangerFg
}},
63 {u
"RSS.ReadArticle"_s
, {{}, {}}},
64 {u
"RSS.UnreadArticle"_s
, {{}, {}}},
66 {u
"TransferList.Downloading"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
67 {u
"TransferList.StalledDownloading"_s
, {Color::Primer::Light::successEmphasis
, Color::Primer::Dark::successEmphasis
}},
68 {u
"TransferList.DownloadingMetadata"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
69 {u
"TransferList.ForcedDownloadingMetadata"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
70 {u
"TransferList.ForcedDownloading"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
71 {u
"TransferList.Uploading"_s
, {Color::Primer::Light::accentFg
, Color::Primer::Dark::accentFg
}},
72 {u
"TransferList.StalledUploading"_s
, {Color::Primer::Light::accentEmphasis
, Color::Primer::Dark::accentEmphasis
}},
73 {u
"TransferList.ForcedUploading"_s
, {Color::Primer::Light::accentFg
, Color::Primer::Dark::accentFg
}},
74 {u
"TransferList.QueuedDownloading"_s
, {Color::Primer::Light::scaleYellow6
, Color::Primer::Dark::scaleYellow6
}},
75 {u
"TransferList.QueuedUploading"_s
, {Color::Primer::Light::scaleYellow6
, Color::Primer::Dark::scaleYellow6
}},
76 {u
"TransferList.CheckingDownloading"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
77 {u
"TransferList.CheckingUploading"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
78 {u
"TransferList.CheckingResumeData"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
79 {u
"TransferList.StoppedDownloading"_s
, {Color::Primer::Light::fgMuted
, Color::Primer::Dark::fgMuted
}},
80 {u
"TransferList.StoppedUploading"_s
, {Color::Primer::Light::doneFg
, Color::Primer::Dark::doneFg
}},
81 {u
"TransferList.Moving"_s
, {Color::Primer::Light::successFg
, Color::Primer::Dark::successFg
}},
82 {u
"TransferList.MissingFiles"_s
, {Color::Primer::Light::dangerFg
, Color::Primer::Dark::dangerFg
}},
83 {u
"TransferList.Error"_s
, {Color::Primer::Light::dangerFg
, Color::Primer::Dark::dangerFg
}}
87 inline QSet
<QString
> defaultUIThemeIcons()
90 u
"application-exit"_s
,
95 u
"checked-completed"_s
,
111 u
"filter-inactive"_s
,
114 u
"folder-documents"_s
,
132 u
"network-connect"_s
,
141 u
"preferences-advanced"_s
,
142 u
"preferences-bittorrent"_s
,
143 u
"preferences-desktop"_s
,
144 u
"preferences-webui"_s
,
145 u
"qbittorrent-tray"_s
,
146 u
"qbittorrent-tray-dark"_s
,
147 u
"qbittorrent-tray-light"_s
,
151 u
"rss_read_article"_s
,
152 u
"rss_unread_article"_s
,
166 u
"torrent-creator"_s
,
169 u
"torrent-start-forced"_s
,
172 u
"tracker-warning"_s
,
176 u
"view-categories"_s
,
179 u
"view-statistics"_s
,