Add and Initialize Icon Themes
authorromibi <romibi@bluewin.ch>
Fri, 15 Jul 2016 19:35:44 +0000 (21:35 +0200)
committerManuel Nickschas <sputnick@quassel-irc.org>
Wed, 7 Sep 2016 22:32:03 +0000 (00:32 +0200)
CMakeLists.txt
INSTALL
icons/CMakeLists.txt
src/CMakeLists.txt
src/common/main.cpp

index 8293af0..791ecb4 100644 (file)
@@ -71,8 +71,22 @@ else()
 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)
 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.")
+endif()
+
+if (WITH_OXYGEN)
+    add_definitions(-DWITH_OXYGEN)
+endif()
+if (WITH_BREEZE)
+    add_definitions(-DWITH_BREEZE)
+endif()
+if (WITH_BREEZE_DARK)
+    add_definitions(-DWITH_BREEZE_DARK)
 endif()
 
 # For this, the feature info is added after we know if QtWebkit is installed
diff --git a/INSTALL b/INSTALL
index 39f4054..21d7d4d 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -89,6 +89,14 @@ options here:
     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.
+    By default, WITH_BREEZE_DARK 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
index 1a25353..4ae47d5 100644 (file)
@@ -17,18 +17,42 @@ if (WANT_MONO OR WANT_QTCLIENT)
             message(STATUS "Embedding bundled Oxygen icons")
             set(ICON_RCS ${ICON_RCS} ${CMAKE_CURRENT_SOURCE_DIR}/oxygen.qrc)
         endif()
+        if (WITH_BREEZE)
+            message(STATUS "Embedding bundled Breeze icons")
+            set(ICON_RCS ${ICON_RCS} ${CMAKE_CURRENT_SOURCE_DIR}/breeze.qrc)
+        endif()
+        if (WITH_BREEZE_DARK)
+            message(STATUS "Embedding bundled Breeze Dark icons")
+            set(ICON_RCS ${ICON_RCS} ${CMAKE_CURRENT_SOURCE_DIR}/breezedark.qrc)
+        endif()
     else()
         install(DIRECTORY hicolor DESTINATION ${CMAKE_INSTALL_ICONDIR})
         if (WITH_OXYGEN)
             message(STATUS "Installing bundled Oxygen icons")
             install(DIRECTORY oxygen DESTINATION ${CMAKE_INSTALL_DATADIR}/quassel/icons)
         endif()
+        if (WITH_BREEZE)
+            message(STATUS "Installing bundled Breeze icons")
+            install(DIRECTORY breeze DESTINATION ${CMAKE_INSTALL_DATADIR}/quassel/icons)
+        endif()
+        if (WITH_BREEZE_DARK)
+            message(STATUS "Installing bundled Breeze Dark icons")
+            install(DIRECTORY breezedark DESTINATION ${CMAKE_INSTALL_DATADIR}/quassel/icons)
+        endif()
     endif()
 
     if (NOT WITH_OXYGEN)
         message(STATUS "Not installing bundled Oxygen icons")
     endif()
 
+    if (NOT WITH_BREEZE)
+        message(STATUS "Not installing bundled Breeze icons")
+    endif()
+
+    if (NOT WITH_BREEZE_DARK)
+        message(STATUS "Not installing bundled Breeze Dark icons")
+    endif()
+
     set(CLIENT_RCS ${CLIENT_RCS} ${ICON_RCS} PARENT_SCOPE)
 endif()
 
index 84da476..dc16334 100644 (file)
@@ -26,9 +26,6 @@ include_directories(BEFORE ${CMAKE_CURRENT_BINARY_DIR}) # for version.gen
 if (EMBED_DATA)
     add_definitions(-DEMBED_DATA)
 endif()
-if (WITH_OXYGEN)
-    add_definitions(-DWITH_OXYGEN)
-endif()
 
 # For KAboutData
 if (WITH_KF5)
index 01d9d82..d9dcdc6 100644 (file)
@@ -100,6 +100,12 @@ int main(int argc, char **argv)
 #   ifdef WITH_OXYGEN
     Q_INIT_RESOURCE(oxygen);
 #   endif
+#   ifdef WITH_BREEZE
+    Q_INIT_RESOURCE(breeze);
+#   endif
+#   ifdef WITH_BREEZE_DARK
+    Q_INIT_RESOURCE(breezedark);
+#   endif
 # endif
 #endif