Customize comboboxes look
authorunc0rr
Tue, 05 Aug 2008 22:15:32 +0000
changeset 1154 03cc0ab9c013
parent 1153 825931b81ad4
child 1155 ffd0a34171f1
Customize comboboxes look
QTfrontend/hedgewars.qrc
QTfrontend/main.cpp
QTfrontend/res/dropdown.png
--- a/QTfrontend/hedgewars.qrc	Tue Aug 05 21:12:26 2008 +0000
+++ b/QTfrontend/hedgewars.qrc	Tue Aug 05 22:15:32 2008 +0000
@@ -26,5 +26,6 @@
     <file>res/LocalPlay.png</file>
     <file>res/NetworkPlay.png</file>
     <file>res/Settings.png</file>
+    <file>res/dropdown.png</file>
 </qresource>
 </RCC>
--- a/QTfrontend/main.cpp	Tue Aug 05 21:12:26 2008 +0000
+++ b/QTfrontend/main.cpp	Tue Aug 05 22:15:32 2008 +0000
@@ -55,28 +55,62 @@
 
 	qApp->setStyleSheet
 		(QString(
-				".HWForm{"
+			".HWForm{"
 				"background-image: url(\":/res/Background.png\");"
 				"background-position: bottom center;"
 				"background-repeat: repeat-x;"
 				"background-color: #870c8f;"
 				"}"
-//				"PageMain > QPushButton{"
-				"QPushButton{"
+
+			"QPushButton{"
 				"border: solid;"
 				"border-width: 4px;"
 				"border-radius: 8px;"
 				"border-color: orange;"
 				"background-origin: content;"
 				"}"
-//				"PageMain > QPushButton:hover{"
 				"QPushButton:hover{"
 				"border-color: yellow;"
 				"}"
-//				"PageMain > QPushButton:pressed{"
 				"QPushButton:pressed{"
 				"border-color: white;"
 				"}"
+
+			"QComboBox{"
+				"border: solid;"
+				"border-width: 4px;"
+				"border-radius: 16px;"
+				"border-color: orange;"
+				"background-color: #0d0544;"
+				"color: orange;"
+				"font: bold 14px;"
+				"padding: 3px;"
+//				"text-align: center;"
+				"}"
+			"QComboBox:hover{"
+				"border-color: yellow;"
+				"}"
+			"QComboBox:pressed{"
+				"border-color: white;"
+				"}"
+			"QComboBox::drop-down{"
+				"border: transparent;"
+				"width: 25px;"
+				"}"
+			"QComboBox::down-arrow {"
+				"background-image: url(\":/res/dropdown.png\");"
+				"height: 16px;"
+				"width: 16px;"
+				"}"
+			"QComboBox QAbstractItemView{"
+				"border: solid transparent;"
+				"border-width: 4px;"
+				//"border-radius: 12px;"
+				"border-color: orange;"
+				"background-color: #0d0544;"
+				"color: orange;"
+				"font: bold 14px;"
+				"}"
 			)
 		);
 
Binary file QTfrontend/res/dropdown.png has changed