aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAqua-sama <aqua@iserlohn-fortress.net>2018-12-16 12:37:19 +0100
committerAqua-sama <aqua@iserlohn-fortress.net>2018-12-16 12:37:19 +0100
commit8c344780ab1f4c8f1d6291732ab0da7f64fb2d74 (patch)
tree66f5b3a459420dbaf78a4bdd2d500adc09778689
parentAdd restore last tab shortcut (diff)
downloadsmolbote-8c344780ab1f4c8f1d6291732ab0da7f64fb2d74.tar.xz
Add browser.iconTheme
-rw-r--r--lib/configuration/configuration.cpp1
-rw-r--r--src/main.cpp4
2 files changed, 5 insertions, 0 deletions
diff --git a/lib/configuration/configuration.cpp b/lib/configuration/configuration.cpp
index 9a1c3b8..952f4b2 100644
--- a/lib/configuration/configuration.cpp
+++ b/lib/configuration/configuration.cpp
@@ -38,6 +38,7 @@ Configuration::Configuration(int argc, char **argv, const std::string &path, QOb
{
configuration_desc.add_options()
("browser.stylesheet", po::value<std::string>())
+ ("browser.iconTheme", po::value<std::string>(), "Icon theme")
("browser.locale", po::value<std::string>(), "Set Qt localization.")
("browser.translation", po::value<std::string>(), "Set application localization.")
diff --git a/src/main.cpp b/src/main.cpp
index 04ce57a..11db0d7 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -108,6 +108,10 @@ int main(int argc, char **argv)
delete locale;
}
+ if(auto iconTheme = config->value<QString>("browser.iconTheme")) {
+ QIcon::setThemeName(iconTheme.value());
+ }
+
#ifdef CONFIG_USEBREAKPAD
const std::string crashpath = config->value<std::string>("browser.crash.path").value_or("/tmp");
assert(!crashpath.empty());