You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

362 lines
6.9 KiB

  1. /*
  2. * see here for theming tutorial
  3. * https://ubuntu-mate.community/t/enabling-the-gtk-inspector-to-find-css-values-for-theme-styles/20150
  4. */
  5. /* CHEATSHEET
  6. *
  7. * MANIPULATE COLORS
  8. *
  9. * mix(color1, color2, number)
  10. * mix(green, red, 0.5)
  11. * lighter(color)
  12. * darker(color)
  13. * shade(color, number)
  14. * alpha(color, number)
  15. * theme label that are descendants of window
  16. * window label {}
  17. * theme entries that are DIRECT children of notebook
  18. * notebook > entry {}
  19. * theme notebooks and anything within
  20. * notebook {}
  21. * theme any widget within a box
  22. * box * {}
  23. * theme any widget named main-entry
  24. * #main-entry
  25. * theme label named title-label
  26. * label#title-label {}
  27. * theme all widgets with the style class 'entry'
  28. * .entry {}
  29. * theme entry of GtkSpinButton
  30. * spinbutton entry {}
  31. * theme labels in the first notebook tab
  32. * notebook tab:first-child label {}
  33. * theme pressed buttons
  34. * button:active {}
  35. * theme buttons with mouse pointer over it
  36. * button:hover {}
  37. * theme insensitive widgets
  38. * *:disabled {}
  39. * theme checkbuttons that are checked
  40. * checkbutton:checked {}
  41. * theme focused labels
  42. * label:focus {}
  43. * theme inconsistent checkbuttons
  44. * checkbutton:indeterminate {}
  45. * SELECTORS
  46. * * any node
  47. * E any node with name E
  48. * E.class any E node with given style class
  49. * E#id any E node with given ID
  50. * E:nth-child({nth-child}) any E node which is the nth child of its parent node
  51. * E:nth-last-child({nth-child}) any E node which is the nth child of its parent node, counting from the end
  52. * E:first-child any E node which is the first child of its parent node
  53. * E:last-child any E node which is the last child of its parent node
  54. * E:only-child any E node which is the only child of its parent node
  55. * E:link, E:visited any E node which represents a hyperlink, not yet visited / visited
  56. * E:active, E:hover, E:focus any E node which is part of a widget with the corresponding state
  57. * E:disabled any E node which is part of a widget which is disabled
  58. * E:checked any E node which is part of a widget (e.g. radio of checkbutton) which is checked
  59. * E:indeterminate any E node which is part of a widget (e.g. radio or checkbutton) which is in an indeterminate state
  60. * E:backdrop, E:selected any E node which is part of a widget with the corresponding state
  61. * E:not({selector}) any E node which does not match the simple selector
  62. * E:dir(ltr), E:dir(rtl) any E node that has the corresponding text direction
  63. * E:drop(active) any E node that is an active drop target for a current DND operation
  64. * E F any F node which is a descendent of an E node
  65. * E > F any F node which is a child of an E node
  66. * E ~ F any F node which is preceded by an E node
  67. * E + F any F node which is immediately preceded by an E node
  68. * APPS
  69. *
  70. * Thunar .thunar
  71. * transmission-gtk .tr-workarea
  72. */
  73. /*************
  74. * base states
  75. *************/
  76. * {
  77. color: @fg_color;
  78. background: @bg_color;
  79. }
  80. *:selected:selected,
  81. *:selected:focus {
  82. background: @acc1_color;
  83. color: @bg_color;
  84. }
  85. *:hover {
  86. color: @acc1_color;
  87. background: @bg_color;
  88. }
  89. *.progressbar {
  90. background: darker(@acc1_color);
  91. }
  92. treeview:hover {
  93. color: @acc1_color;
  94. background: @bg_color;
  95. }
  96. /* transmission-gtk needs a different approach */
  97. .tr-workarea treeview:hover {
  98. background: @acc1_color;
  99. color: @bg_color; /* only working when hovering over a selected row */
  100. }
  101. .tr-workarea treeview.view:disabled {
  102. color: mix(@fg_color, @bg_color, 0.5);
  103. }
  104. treeview:selected {
  105. color: @bg_color;
  106. background: @acc1_color;
  107. }
  108. treeview.progressbar:hover,
  109. treeview.progressbar:selected {
  110. background: darker(@acc1_color);
  111. }
  112. /* trough is the empty area in the progress bar */
  113. progressbar trough,
  114. treeview.view.trough {
  115. background: @bg_color;
  116. }
  117. menuitem:hover > label{
  118. color: @acc1_color;
  119. }
  120. menuitem:disabled > label {
  121. color: mix(@fg_color, @bg_color, 0.5);
  122. }
  123. /*
  124. menu {
  125. background: @bg_color;
  126. padding: 0.4em 0.4em;
  127. }
  128. menu menuitem {
  129. background: @bg_color;
  130. color: @fg_color;
  131. padding: 0.4em;
  132. margin: 1px;
  133. }
  134. menuitem:hover {
  135. background: @acc1_color;
  136. color: @bg_color;
  137. }
  138. menuitem:hover > *,
  139. combobox menuitem:hover * {
  140. color: @bg_color;
  141. }
  142. */
  143. /*
  144. * NEEDS TO BE INTEGRATED!
  145. *:backdrop:backdrop,
  146. *:disabled:disabled {
  147. color: mix(@fg_color, @bg_color, 0.4);
  148. -gtk-icon-effect: dim;
  149. }
  150. box {
  151. background: @bg_color;
  152. color: @fg_color;
  153. }
  154. label {
  155. color: @fg_color;
  156. }
  157. entry {
  158. padding: 3px;
  159. border-width: 1px;
  160. background-color: @bg_color;
  161. color: @fg_color;
  162. }
  163. entry:backdrop,
  164. entry:disabled {
  165. background: shade(@bg_color, 0.94);
  166. }
  167. slider:focus,
  168. switch:focus slider,
  169. spinbutton:focus,
  170. notebook:focus tab:checked,
  171. radio:focus,
  172. check:focus,
  173. entry:focus,
  174. button:focus {
  175. border-color: @acc2_color;
  176. }
  177. switch:checked {
  178. background: @acc1_color;
  179. color: @bg_color;
  180. }
  181. switch {
  182. background: @acc1_color;
  183. color: @bg_color;
  184. }
  185. button,
  186. switch slider {
  187. background: @bg_color;
  188. color: @fg_color;
  189. border-radius: 0px;
  190. padding: 1px;
  191. border-width: 0px;
  192. border-color: transparent;
  193. }
  194. combobox {
  195. border-color: #00ff00;
  196. color: #ff0000;
  197. box-shadow: #0000ff;
  198. }
  199. button.flat {
  200. background: none;
  201. border-color: transparent;
  202. }
  203. button:hover,
  204. button:focus,
  205. switch:hover slider,
  206. switch:focus slider {
  207. }
  208. button:backdrop,
  209. button:disabled,
  210. switch:backdrop slider,
  211. switch:disabled slider {
  212. background: @bg_color;
  213. }
  214. radio,
  215. check {
  216. background-color: @bg_color;
  217. border-color: @fg_color;
  218. }
  219. radio:hover,
  220. check:hover {
  221. border-color: @fg_color;
  222. color: @fg_color;
  223. }
  224. headerbar {
  225. color: @fg_color;
  226. background: @bg_color;
  227. }
  228. list {
  229. background: @bg_color;
  230. color: @fg_color;
  231. }
  232. menubar,
  233. actionbar,
  234. toolbar,
  235. placessidebar list {
  236. background: @bg_color;
  237. color: @fg_color;
  238. }
  239. toolbar {
  240. padding: 1px;
  241. }
  242. actionbar {
  243. padding: 0.5em;
  244. border-top-width: 1px;
  245. }
  246. .inline-toolbar {
  247. padding: 0.5em;
  248. border-width: 0 1px 1px;
  249. }
  250. actionbar button,
  251. toolbar button {
  252. padding: 3px;
  253. }
  254. menu separator {
  255. background-color: @acc2_color;
  256. margin: 0.2em;
  257. min-width: 1px;
  258. min-height: 1px;
  259. }
  260. notebook,
  261. notebook tab:checked {
  262. background: @acc1_color;
  263. color: @bg_color;
  264. }
  265. notebook tab,
  266. notebook header {
  267. background: @bg_color;
  268. }
  269. notebook tab:active {
  270. background-color: #ff0000;
  271. }
  272. popover.background,
  273. toolbar.osd {
  274. background: #ff0000;
  275. }
  276. popover modelbutton {
  277. background: #00ff00;
  278. }
  279. popover modelbutton:hover {
  280. background: #0000ff;
  281. }
  282. * {
  283. outline-color: #0000ff;
  284. outline-style: solid;
  285. outline-offset: 0px;
  286. outline-width: 0px;
  287. -gtk-outline-radius: 0px;
  288. }
  289. */