tree.css 9.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359
  1. /* This Source Code Form is subject to the terms of the Mozilla Public
  2. * License, v. 2.0. If a copy of the MPL was not distributed with this
  3. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  4. /* ===== tree.css ===================================================
  5. == Styles used by the XUL outline element.
  6. ======================================================================= */
  7. @import url("chrome://icons/skin/icon-theme-default.css");
  8. @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
  9. /* ::::: tree ::::: */
  10. tree {
  11. margin: 0px 4px;
  12. border: 2px solid;
  13. -moz-border-top-colors: ThreeDShadow ThreeDDarkShadow;
  14. -moz-border-right-colors: ThreeDHighlight ThreeDLightShadow;
  15. -moz-border-bottom-colors: ThreeDHighlight ThreeDLightShadow;
  16. -moz-border-left-colors: ThreeDShadow ThreeDDarkShadow;
  17. background-color: -moz-Field;
  18. color: -moz-FieldText;
  19. -moz-appearance: listbox;
  20. }
  21. /* ::::: tree rows ::::: */
  22. treechildren::-moz-tree-row {
  23. border: 1px solid transparent;
  24. min-height: 18px;
  25. height: 1.3em;
  26. }
  27. treechildren:not(.autocomplete-treebody)::-moz-tree-row(multicol, odd) {
  28. background-color: -moz-oddtreerow;
  29. }
  30. treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected) {
  31. background-color: -moz-cellhighlight;
  32. }
  33. treechildren:not(.autocomplete-treebody)::-moz-tree-row(selected, focus) {
  34. background-color: Highlight;
  35. }
  36. treechildren::-moz-tree-row(current, focus) {
  37. border: 1px dotted Highlight;
  38. }
  39. treechildren::-moz-tree-row(selected, current, focus) {
  40. border: 1px dotted #F3D982;
  41. }
  42. tree[seltype="cell"] > treechildren::-moz-tree-row,
  43. tree[seltype="text"] > treechildren::-moz-tree-row {
  44. border: none;
  45. background-color: transparent;
  46. }
  47. /* ::::: tree cells ::::: */
  48. treechildren::-moz-tree-cell {
  49. padding: 0px 2px 0px 2px;
  50. }
  51. tree[seltype="cell"] > treechildren::-moz-tree-cell-text,
  52. tree[seltype="text"] > treechildren::-moz-tree-cell-text,
  53. treechildren::-moz-tree-cell-text {
  54. color: inherit;
  55. }
  56. treechildren::-moz-tree-cell-text(selected) {
  57. color: -moz-cellhighlighttext;
  58. }
  59. tree[seltype="cell"] > treechildren::-moz-tree-cell {
  60. border: 1px solid transparent;
  61. padding: 0px 1px 0px 1px;
  62. }
  63. tree[seltype="text"] > treechildren::-moz-tree-cell-text {
  64. border: 1px solid transparent;
  65. padding: 0px 1px 1px 1px;
  66. }
  67. tree[seltype="cell"] > treechildren::-moz-tree-cell(active, selected) {
  68. background-color: -moz-cellhighlight;
  69. }
  70. tree[seltype="cell"] > treechildren::-moz-tree-cell-text(active, selected) {
  71. color: -moz-cellhighlighttext;
  72. }
  73. tree[seltype="text"] > treechildren::-moz-tree-cell-text(active, selected) {
  74. background-color: -moz-cellhighlight;
  75. color: -moz-cellhighlighttext;
  76. }
  77. treechildren::-moz-tree-cell-text(selected, focus) {
  78. color: HighlightText;
  79. }
  80. tree[seltype="cell"] > treechildren::-moz-tree-cell(active, selected, focus) {
  81. background-color: Highlight;
  82. }
  83. tree[seltype="text"] > treechildren::-moz-tree-cell-text(active, selected, focus) {
  84. background-color: Highlight;
  85. }
  86. tree[seltype="cell"] > treechildren::-moz-tree-cell-text(active, selected, focus) {
  87. color: HighlightText;
  88. }
  89. tree[seltype="text"] > treechildren::-moz-tree-cell-text(active, selected, focus) {
  90. color: HighlightText;
  91. }
  92. tree[seltype="cell"] > treechildren::-moz-tree-cell(active, current, focus) {
  93. border: 1px dotted #000000;
  94. }
  95. tree[seltype="text"] > treechildren::-moz-tree-cell-text(active, current, focus) {
  96. border: 1px dotted #000000;
  97. }
  98. tree[seltype="cell"] > treechildren::-moz-tree-cell(active, selected, current, focus) {
  99. border: 1px dotted #C0C0C0;
  100. }
  101. tree[seltype="text"] > treechildren::-moz-tree-cell-text(active, selected, current, focus) {
  102. border: 1px dotted #C0C0C0;
  103. }
  104. /* ::::: lines connecting cells ::::: */
  105. tree[seltype="cell"] > treechildren::-moz-tree-line,
  106. tree[seltype="text"] > treechildren::-moz-tree-line,
  107. treechildren::-moz-tree-line {
  108. border: 1px dotted ThreeDShadow;
  109. }
  110. tree[seltype="cell"] > treechildren::-moz-tree-line(active, selected, focus),
  111. treechildren::-moz-tree-line(selected, focus) {
  112. border: 1px dotted HighlightText;
  113. }
  114. /* ::::: tree separator ::::: */
  115. treechildren::-moz-tree-separator {
  116. border-top: 1px solid ThreeDShadow;
  117. border-bottom: 1px solid ThreeDHighlight;
  118. }
  119. /* ::::: drop feedback ::::: */
  120. tree[seltype="cell"] > treechildren::-moz-tree-cell-text(primary, dropOn),
  121. tree[seltype="text"] > treechildren::-moz-tree-cell-text(primary, dropOn),
  122. treechildren::-moz-tree-cell-text(primary, dropOn) {
  123. background-color: Highlight;
  124. color: HighlightText;
  125. }
  126. treechildren::-moz-tree-drop-feedback {
  127. background-color: Highlight;
  128. width: 50px;
  129. height: 2px;
  130. margin-inline-start: 5px;
  131. }
  132. /* ::::: tree progress meter ::::: */
  133. treechildren::-moz-tree-progressmeter {
  134. margin: 2px 4px;
  135. padding: 1px;
  136. border: 1px solid;
  137. border-top-color: ThreeDShadow;
  138. border-right-color: ThreeDHighlight;
  139. border-bottom-color: ThreeDHighlight;
  140. border-left-color: ThreeDShadow;
  141. background-color: -moz-Dialog;
  142. color: ThreeDShadow;
  143. }
  144. treechildren::-moz-tree-progressmeter(progressUndetermined) {
  145. opacity: 0.5;
  146. }
  147. treechildren::-moz-tree-cell-text(progressmeter) {
  148. margin: 2px 4px;
  149. }
  150. /* ::::: tree columns ::::: */
  151. treecol,
  152. treecolpicker {
  153. -moz-appearance: treeheadercell;
  154. -moz-box-align: center;
  155. -moz-box-pack: center;
  156. border: 2px solid;
  157. -moz-border-top-colors: ThreeDHighlight ThreeDLightShadow;
  158. -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow;
  159. -moz-border-bottom-colors: ThreeDDarkShadow ThreeDShadow;
  160. -moz-border-left-colors: ThreeDHighlight ThreeDLightShadow;
  161. background-color: -moz-Dialog;
  162. color: -moz-DialogText;
  163. padding: 0px 2px;
  164. }
  165. treecol:hover,
  166. treecolpicker:hover {
  167. color: -moz-buttonhovertext;
  168. }
  169. .treecol-image {
  170. padding: 0px 1px;
  171. }
  172. .treecol-text {
  173. margin: 0px !important;
  174. }
  175. treecol[hideheader="true"] {
  176. -moz-appearance: none;
  177. border: none;
  178. padding: 0;
  179. }
  180. /* ..... internal box ..... */
  181. treecol:hover:active,
  182. treecolpicker:hover:active {
  183. color: ButtonText;
  184. border: 2px solid;
  185. -moz-border-top-colors: ThreeDShadow -moz-Dialog;
  186. -moz-border-right-colors: ThreeDShadow transparent;
  187. -moz-border-bottom-colors: ThreeDShadow transparent;
  188. -moz-border-left-colors: ThreeDShadow -moz-Dialog;
  189. padding-top: 0px;
  190. padding-bottom: 0px;
  191. padding-inline-start: 3px;
  192. padding-inline-end: 1px;
  193. }
  194. .treecol-image:hover:active {
  195. padding: 0px;
  196. padding-inline-start: 2px;
  197. }
  198. treecol:hover:active .treecol-text {
  199. margin: 1px 0px -1px 0px !important;
  200. }
  201. /* ::::: column drag and drop styles ::::: */
  202. treecol[dragging="true"] {
  203. -moz-border-top-colors: ThreeDDarkShadow transparent !important;
  204. -moz-border-right-colors: ThreeDDarkShadow transparent!important;
  205. -moz-border-bottom-colors: ThreeDDarkShadow transparent !important;
  206. -moz-border-left-colors: ThreeDDarkShadow transparent !important;
  207. background-color: ThreeDShadow !important;
  208. color: ThreeDHighlight !important;
  209. }
  210. treecol[insertafter="true"]:-moz-locale-dir(ltr),
  211. treecol[insertbefore="true"]:-moz-locale-dir(rtl) {
  212. -moz-border-right-colors: ThreeDDarkShadow ThreeDShadow;
  213. }
  214. treecol[insertafter="true"]:-moz-locale-dir(rtl),
  215. treecol[insertbefore="true"]:-moz-locale-dir(ltr) {
  216. -moz-border-left-colors: ThreeDDarkShadow ThreeDShadow;
  217. }
  218. treechildren::-moz-tree-column(insertbefore) {
  219. -moz-border-start: 1px solid ThreeDShadow;
  220. }
  221. treechildren::-moz-tree-column(insertafter) {
  222. -moz-border-end: 1px solid ThreeDShadow;
  223. }
  224. /* ::::: sort direction indicator ::::: */
  225. .treecol-sortdirection {
  226. -moz-appearance: treeheadersortarrow;
  227. }
  228. /* ::::: column picker ::::: */
  229. .tree-columnpicker-icon {
  230. list-style-image: url("chrome://global/skin/tree/columnpicker.gif");
  231. }
  232. /* ::::: twisty ::::: */
  233. treechildren::-moz-tree-twisty {
  234. -moz-appearance: treetwisty;
  235. padding-inline-end: 4px;
  236. padding-top: 1px;
  237. width: 9px; /* The image's width is 9 pixels */
  238. list-style-image: url("chrome://global/skin/tree/twisty-clsd.png");
  239. }
  240. treechildren::-moz-tree-twisty(open) {
  241. -moz-appearance: treetwistyopen;
  242. width: 9px; /* The image's width is 9 pixels */
  243. list-style-image: url("chrome://global/skin/tree/twisty-open.png");
  244. }
  245. treechildren::-moz-tree-indentation {
  246. width: 18px;
  247. }
  248. /* ::::: gridline style ::::: */
  249. treechildren.gridlines::-moz-tree-cell {
  250. border-right: 1px solid transparent !important;
  251. border-bottom: 1px solid transparent !important;
  252. }
  253. treechildren.gridlines::-moz-tree-row {
  254. border: none;
  255. }
  256. /* ::::: editable tree ::::: */
  257. treechildren::-moz-tree-row(selected, editing) {
  258. background-color: transparent;
  259. border: none;
  260. }
  261. treechildren::-moz-tree-cell-text(selected, editing) {
  262. color: inherit;
  263. }
  264. .tree-input {
  265. -moz-appearance: none;
  266. border: 1px solid Highlight;
  267. -moz-border-top-colors: Highlight;
  268. -moz-border-bottom-colors: Highlight;
  269. -moz-border-left-colors: Highlight;
  270. -moz-border-right-colors: Highlight;
  271. margin: 0;
  272. margin-inline-start: -4px;
  273. padding: 1px;
  274. }
  275. menupopup[anonid="popup"] > menuitem[anonid="menuitem"] {
  276. list-style-image: var(--icon-document-revert-16);
  277. -moz-binding: url("chrome://global/content/bindings/menu.xml#menuitem-iconic");
  278. }
  279. menupopup[anonid="popup"] > menuitem[anonid="menuitem"][disabled] {
  280. list-style-image: var(--icon-document-revert-16-dis);
  281. }