From a113f73e5f8ce89c3df5c42d55528404fc7a2294 Mon Sep 17 00:00:00 2001 From: Manuel Nickschas Date: Thu, 8 Sep 2016 01:31:19 +0200 Subject: [PATCH] Make Breeze the default icon theme Also fix some related UI issues. --- CMakeLists.txt | 12 ++++++------ INSTALL | 19 ++++++++++--------- src/common/main.cpp | 2 +- src/qtui/qtuiapplication.cpp | 4 ++-- .../settingspages/appearancesettingspage.cpp | 8 +++++--- .../settingspages/appearancesettingspage.ui | 6 +++--- 6 files changed, 27 insertions(+), 24 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 791ecb4f..e0315273 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -70,13 +70,13 @@ else() add_feature_info(WITH_KDE WITH_KDE "Integrate with the KDE Frameworks runtime environment") endif() -cmake_dependent_option(WITH_OXYGEN "Install Oxygen icon set (usually shipped with KDE)" ON "NOT WITH_KDE" OFF) -cmake_dependent_option(WITH_BREEZE "Install Breeze icon set (usually shipped with KDE)" OFF "NOT WITH_KDE" OFF) -cmake_dependent_option(WITH_BREEZE_DARK "Install Dark Breeze icon set (usually shipped with KDE)" OFF "NOT WITH_KDE" OFF) +cmake_dependent_option(WITH_BREEZE "Install Breeze icon theme (usually shipped with KDE)" ON "NOT WITH_KDE" OFF) +cmake_dependent_option(WITH_BREEZE_DARK "Install Dark Breeze icon theme (usually shipped with KDE)" OFF "NOT WITH_KDE" OFF) +cmake_dependent_option(WITH_OXYGEN "Install Oxygen icon theme (usually shipped with KDE)" OFF "NOT WITH_KDE" OFF) if (NOT WITH_KDE) - add_feature_info(WITH_OXYGEN WITH_OXYGEN "Install Oxygen icon set") - add_feature_info(WITH_BREEZE WITH_BREEZE "Install Breeze icon set. Alternative to Oxygen.") - add_feature_info(WITH_BREEZE_DARK WITH_BREEZE_DARK "Install Dark Breeze icon set. Alternative to Oxygen.") + add_feature_info(WITH_BREEZE WITH_BREEZE "Install Breeze icon theme") + add_feature_info(WITH_BREEZE_DARK WITH_BREEZE_DARK "Install Dark Breeze icon theme") + add_feature_info(WITH_OXYGEN WITH_OXYGEN "Install Oxygen icon theme") endif() if (WITH_OXYGEN) diff --git a/INSTALL b/INSTALL index 21d7d4dc..ba4a13f1 100644 --- a/INSTALL +++ b/INSTALL @@ -82,21 +82,22 @@ options here: -DWITH_KDE=ON Enable integration into KDE4 (with Qt4) or KDE Frameworks (with Qt5). --DWITH_OXYGEN=(ON|OFF) - Install the parts of the Oxygen icon set Quassel uses. Oxygen is the default - icon set for KDE4, and thus already available on systems where KDE4 is - installed. By default, WITH_OXYGEN is ON iff WITH_KDE is OFF. If you are +-DWITH_BREEZE=(ON|OFF) + Install the parts of the Breeze icon theme Quassel uses. Breeze is the default + icon theme for Plasma 5, and thus already available on systems where Plasma is + installed. By default, WITH_BREEZE is ON iff WITH_KDE is OFF. If you are sure that you have the icon set already installed on your system regardless, use this option to disable installing the bundled icons. --DWITH_BREEZE=(ON|OFF) - Alternative icon set to Oxygen. - By default, WITH_BREEZE is OFF. - -DWITH_BREEZE_DARK=(ON|OFF) - Alternative icon set to Oxygen. + Alternative icon theme to Breeze, optimized for dark desktop themes. By default, WITH_BREEZE_DARK is OFF. +-DWITH_OXYGEN=(ON|OFF) + Alternative icon theme to Breeze. Oxygen was the default theme in KDE 4, and + also the bundled icon theme in Quassel before version 0.13. + By default, WITH_OXYGEN is OFF. + -DWITH_WEBKIT=OFF Use Webkit for showing previews of webpages linked in the chat. Requires the QtWebkit module to be available, and increases the client's RAM usage diff --git a/src/common/main.cpp b/src/common/main.cpp index d9dcdc6f..12aaa29c 100644 --- a/src/common/main.cpp +++ b/src/common/main.cpp @@ -146,7 +146,7 @@ int main(int argc, char **argv) #ifndef BUILD_CORE // put client-only arguments here - cliParser->addOption("icontheme", 0, "Override the system icon theme ('oxygen' is recommended)", "theme"); + cliParser->addOption("icontheme", 0, "Override the system icon theme ('breeze' is recommended)", "theme"); cliParser->addOption("qss", 0, "Load a custom application stylesheet", "file.qss"); cliParser->addSwitch("debugbufferswitches", 0, "Enables debugging for bufferswitches"); cliParser->addSwitch("debugmodel", 0, "Enables debugging for models"); diff --git a/src/qtui/qtuiapplication.cpp b/src/qtui/qtuiapplication.cpp index 50c3c71e..6777a567 100644 --- a/src/qtui/qtuiapplication.cpp +++ b/src/qtui/qtuiapplication.cpp @@ -166,8 +166,8 @@ bool QtUiApplication::init() else if (QtUiSettings().value("IconTheme", QVariant("")).toString() != "") QIcon::setThemeName(QtUiSettings().value("IconTheme").toString()); else if (QIcon::themeName().isEmpty()) - // Some platforms don't set a default icon theme; chances are we can find our bundled Oxygen theme though - QIcon::setThemeName("oxygen"); + // Some platforms don't set a default icon theme; chances are we can find our bundled theme though + QIcon::setThemeName("breeze"); // session resume QtUi *gui = new QtUi(); diff --git a/src/qtui/settingspages/appearancesettingspage.cpp b/src/qtui/settingspages/appearancesettingspage.cpp index 6891c744..cf3cdfc0 100644 --- a/src/qtui/settingspages/appearancesettingspage.cpp +++ b/src/qtui/settingspages/appearancesettingspage.cpp @@ -101,17 +101,19 @@ void AppearanceSettingsPage::initLanguageComboBox() void AppearanceSettingsPage::initIconThemeComboBox() { + // TODO Replace by runtime detection #if defined WITH_OXYGEN || defined WITH_BREEZE || defined WITH_BREEZE_DARK -# if defined WITH_OXYGEN - ui.iconthemeComboBox->addItem(tr("Oxygen"), QVariant("oxygen")); -# endif # if defined WITH_BREEZE ui.iconthemeComboBox->addItem(tr("Breeze Light"), QVariant("breeze")); # endif # if defined WITH_BREEZE_DARK ui.iconthemeComboBox->addItem(tr("Breeze Dark"), QVariant("breezedark")); # endif +# if defined WITH_OXYGEN + ui.iconthemeComboBox->addItem(tr("Oxygen"), QVariant("oxygen")); +# endif #else + ui.iconthemeLabel->hide(); ui.iconthemeComboBox->hide(); #endif } diff --git a/src/qtui/settingspages/appearancesettingspage.ui b/src/qtui/settingspages/appearancesettingspage.ui index 0cc4f15d..5d8fa77c 100644 --- a/src/qtui/settingspages/appearancesettingspage.ui +++ b/src/qtui/settingspages/appearancesettingspage.ui @@ -68,16 +68,16 @@ - + - Icon Theme: + Icon theme: - Choose from the bundled Icon-Themes! May need restart... + Choose from the bundled icon themes! May need restart... -- 2.20.1