basicwidget.qss 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279
  1. QWidget#widget
  2. {
  3. background: transparent;
  4. border-bottom: 1px solid #E9E9E9;
  5. }
  6. QLabel
  7. {
  8. font-weight: 400;
  9. font-size: 14px;
  10. color: #3A3F63;
  11. }
  12. QLabel#label_tip
  13. {
  14. font-weight: 400;
  15. font-size: 14px;
  16. color: rgba(58,63,99,0.8);
  17. line-height: 21px;
  18. text-align: left;
  19. font-style: normal;
  20. }
  21. /* ==========================================================
  22. * QLineEdit
  23. * ========================================================== */
  24. QLineEdit
  25. {
  26. background: #FFFFFF;
  27. border-radius: 4px;
  28. border: 1px solid #E6E9F4;
  29. padding-left: 12px;
  30. font-weight: 400;
  31. font-size: 14px;
  32. color: #3A3F63;
  33. }
  34. QLineEdit:hover,QLineEdit:focus
  35. {
  36. border: 1px solid #4458FE;
  37. }
  38. QLineEdit:enabled[Warn=true]
  39. {
  40. border: 1px solid #D21F21;
  41. }
  42. QLineEdit:!enabled
  43. {
  44. background: #F5F5F5;
  45. color:rgba(58,63,99,0.65);
  46. }
  47. /* ==========================================================
  48. * QPushButton
  49. * ========================================================== */
  50. QPushButton
  51. {
  52. font-weight: 500;
  53. font-size: 14px;
  54. text-align: center;
  55. }
  56. /* QPushButton#pBtn_close
  57. {
  58. background: transparent;
  59. border-radius: 4px;
  60. qproperty-icon: url(:/ICON/ICON/Close_Light.png);
  61. qproperty-iconSize: 20px 20px;
  62. }
  63. QPushButton#pBtn_close[Hover = true]
  64. {
  65. background: transparent;
  66. border-radius: 4px;
  67. qproperty-icon: url(:/ICON/ICON/Close_pass.png);
  68. qproperty-iconSize: 20px 20px;
  69. border: 1px solid #4458FE;
  70. } */
  71. /********* 普通椭圆按钮三种状态效果 *********/
  72. /* QPushButton#pBtn_cancel, #pBtn_saveTotemplate
  73. {
  74. background: transparent;
  75. color: #3A3F63;
  76. border: 1px solid #E6E9F4;
  77. border-radius: 16px;
  78. }
  79. QPushButton#pBtn_cancel:hover, #pBtn_saveTotemplate:hover
  80. {
  81. background: transparent;
  82. color: #4458FE;
  83. border: 1px solid #4458FE;
  84. border-radius: 16px;
  85. } */
  86. /********* 带有底色椭圆按钮三种状态效果 *********/
  87. /* QPushButton#pBtn_ok
  88. {
  89. color:white;
  90. background: qlineargradient( x0:1,x1:1,y1:0,y2:0,stop:1 #4F8AFF,stop:0 #4B5EFF);
  91. border-radius: 16px;
  92. }
  93. QPushButton#pBtn_ok:hover
  94. {
  95. color:white;
  96. background: qlineargradient( x0:1,x1:1,y1:0,y2:0,stop:0 #5D73FF,stop:1 #6092FF);
  97. border-radius: 16px;
  98. } */
  99. /********* 普通方框按钮三种状态效果 *********/
  100. QPushButton#pBtn_compareItem, #pBtn_restore
  101. {
  102. background: transparent;
  103. color: #3A3F63;
  104. border: 1px solid #E6E9F4;
  105. border-radius: 4px;
  106. }
  107. QPushButton#pBtn_compareItem:hover, #pBtn_restore:hover
  108. {
  109. background: transparent;
  110. color: #4458FE;
  111. border: 1px solid #4458FE;
  112. border-radius: 4px;
  113. }
  114. /********* 带有底色方框按钮三种状态效果 *********/
  115. /* QPushButton#pBtn_addPlan
  116. {
  117. color:white;
  118. background: qlineargradient( x0:1,x1:1,y1:0,y2:0,stop:1 #4F8AFF,stop:0 #4B5EFF);
  119. border-radius: 4px;
  120. }
  121. QPushButton#pBtn_addPlan:hover
  122. {
  123. color:white;
  124. background: qlineargradient( x0:1,x1:1,y1:0,y2:0,stop:0 #5D73FF,stop:1 #6092FF);
  125. border-radius: 4px;
  126. } */
  127. /* ==========================================================
  128. * QComboBox(这个是在用的)
  129. * ========================================================== */
  130. QComboBox:enabled
  131. {
  132. background-color:#FFFFFF;
  133. border: 1px solid #E6E9F4;
  134. border-radius: 4px;
  135. font-size:14px;
  136. font-weight: 400;
  137. color:#3A3F63;
  138. padding-left: 12px;
  139. }
  140. /* 不能编辑的时候的样式,setEnable(false) */
  141. QComboBox:!enabled
  142. {
  143. background:rgba(0,0,0,0.04);
  144. border: 1px solid #E6E9F4;
  145. border-radius: 4px;
  146. font-size:14px;
  147. font-weight: 400;
  148. color:rgba(58,63,99,0.65);
  149. padding-left: 12px;
  150. }
  151. QComboBox:hover
  152. {
  153. border: 1px solid #4458FE;
  154. border-radius: 4px;
  155. background:transparent;
  156. }
  157. /* 下拉箭头所在的位置方框 */
  158. QComboBox::drop-down
  159. {
  160. width: 24px;
  161. border: none;
  162. }
  163. /* 下拉箭头图标 */
  164. QComboBox::down-arrow
  165. {
  166. image: url(:/icon/down_arrow.png);
  167. height:16px;
  168. width:16px;
  169. }
  170. /* 下拉条样式,就是view,整个下拉窗体的样式 */
  171. QComboBox QAbstractItemView
  172. {
  173. background-color: #FFFFFF;
  174. margin: 12px;
  175. outline:0px;
  176. font-size:14px;
  177. color: #3A3F63;
  178. border-radius: 4px;
  179. }
  180. /* 使下面两句生效,需要加上如下语句 */
  181. /* m_comBoxDev->setView(new QListView()); */
  182. QComboBox QAbstractItemView::item
  183. {
  184. background-color: #FFFFFF;
  185. border-radius:4px;
  186. color: #3A3F63;
  187. padding-left: 12px;
  188. height: 32px;
  189. }
  190. QComboBox QAbstractItemView::item:hover
  191. {
  192. border-radius:4px;
  193. background-color: #EEF2FF;
  194. }
  195. /******** combobox 滚动条 *********/
  196. /*主体部分*/
  197. QComboBox QScrollBar::vertical
  198. {
  199. width:8px;
  200. background:transparent;
  201. border:none;
  202. border-radius:5px;
  203. }
  204. /*滑块主体*/
  205. QComboBox QScrollBar::handle::vertical
  206. {
  207. width: 8px;
  208. background: #E2E2E2;
  209. border-radius: 3px;
  210. min-width: 8px;
  211. }
  212. QComboBox QScrollBar::handle::vertical::hover
  213. {
  214. background:transparent;
  215. }
  216. /*上箭头*/
  217. QComboBox QScrollBar::add-line::vertical
  218. {
  219. border:none;
  220. }
  221. /*下箭头*/
  222. QComboBox QScrollBar::sub-line::vertical
  223. {
  224. border:none;
  225. }
  226. /* ==========================================================
  227. * QCheckBox
  228. * ========================================================== */
  229. QCheckBox
  230. {
  231. font-weight: 400;
  232. font-size: 14px;
  233. color: #3A3F63;
  234. }
  235. QCheckBox::indicator
  236. {
  237. width: 16px;
  238. height: 16px;
  239. }
  240. QCheckBox::indicator:unchecked
  241. {
  242. image: url(:/icon/unchecked.png);
  243. }
  244. QCheckBox::indicator:checked
  245. {
  246. image: url(:/icon/checked.png);
  247. }