fix bug 107 - no sort up or down arow in (mail) tree views
[themes.git] / EarlyBlue / global / tree.css
index d531214a3c90724053767ea144e8e826406f08b3..3f5fa29dfe1e7e231a8dfe941b8697cb45fd96aa 100644 (file)
@@ -20,6 +20,8 @@
  *
  * Contributor(s):
  *   Robert Kaiser <KaiRo@KaiRo.at>
+ *   Joe Hewitt (hewitt@netscape.com)
+ *   Dean Tessman (dean_tessman@hotmail.com)
  *
  * Alternatively, the contents of this file may be used under the terms of
  * either the GNU General Public License Version 2 or later (the "GPL"), or
 
 @namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul");
 
-/******** Tree widget **********/ 
-
-/** basic tree ****************************************************
- *  basic tree widget for use in main windows where no decoration
- *  is required.
- **/
-tree 
-  {
-    border                : 1px inset #CCD0DD;
-    margin                : 1px 3px 2px 3px;
-    background-color      : white;
-    color                 : #000000;
-  }
-
-.tree-container-treerows[dragover="true"][dragdroptree="true"]
-  {
-  }  
-  
-.tree-container-treerows
-  {
-  }  
-
-.tree-container-treerows[dragdroptree="true"]
-  {
-  }  
-  
-treeitem[selected="true"] > treerow
-  {
-    color                 : white;
-    background-color      : #336699;
-  }
-
-treeitem 
-  {
-    list-style-image      : none;
-  }
-  
-treerow 
-  {
-    border                : 1px solid transparent;
-  }
-  
-treehead > treeitem > treerow,
-treehead > treerow 
-  {
-    border                : none;
-  }
-  
-treecell 
-  { 
-    padding               : 0px 0px 1px 2px;
-    white-space           : nowrap;
-  } 
-
-tree:focus > treechildren treeitem[selected="true"] > treerow,
-treeitem[dd-dropon="true"] > treerow
-  {
-    color                 : white;
-    background-color      : #336699;
-  }
-
-tree:focus > treechildren treeitem[selected="true"][current="true"] > treerow
-  {
-    border                : 1px dotted #9999CC;
-  }
-
-.treecell-header-image 
-  {
-    list-style-image      : inherit;
-  }
-  
-.treecell-header,
-.treecell-inset-header,
-.treecell-header-image
-  { 
-    border                : 1px outset #CCD0DD;
-    padding               : 0px;
-    background-color      : #CCD0DD;
-    color                 : #000000;
-  }
-
-.treecell-header-box,
-.treecell-header-image-box 
-  {
-  }  
-
-.treecell-header-box
-  {
-    padding               : 0px 4px 0px 4px;
-  }
-
-.treecell-header-text
-  {
-    margin                : 0px;
-  }
-
-.treecell-header-image-box 
-  {
-    padding               : 0px 1px 0px 1px;
-  }
-  
-.treecell-header:hover:active,
-.treecell-header-image:hover:active,
-.treecell-inset-header:hover:active 
-  {
-    border                : 1px inset #CCD0DD;
-  }
-
-.treecell-header:hover:active > .treecell-header-box,
-.treecell-inset-header:hover:active > .treecell-header-box,
-.treecell-header-image:hover:active > .treecell-header-image-box
-  {
-    border-top            : 1px solid transparent;
-    border-right          : none;
-    border-bottom         : none;
-    border-left           : 1px solid transparent;
-  }
-  
-.treecell-header:hover:active > .treecell-header-box,
-.treecell-inset-header:hover:active > .treecell-header-box
-  {
-    padding               : 1px 4px 0px 5px;
-  }
-  
-.treecell-header-image:hover:active > .treecell-header-image-box
-  {
-    padding               : 1px 1px 0px 2px;
-  }
-
-.treecell-image 
-  {
-    padding               : 0px;
-  }
-    
-/* slimline sidebar treeheaders */  
-.treecell-header.treecell-header-sidebarpanel,
-.treecell-inset-header.treecell-header-sidebarpanel
-  {
-    padding               : 0px 1px 1px 3px;
-  }
-
-.treecell-header-sidebarpanel > .treecell-header-box
-  {
-  }
-/** class="propertylist" ******************************************
- *  class for cells in grid-formatted property lists.
- **/
-treecell.propertylist 
-  {
-    border-right          : 1px solid #CCD0DD;
-    border-bottom         : 1px solid #CCD0DD;
-    padding-left          : 5px;
-  }
-
-.tree-cell-primary-icon,
-.tree-cell-primary-icon-inline-edit-folder
-  {
-    list-style-image      : inherit;
-    padding-right         : 2px;
-  }
-
-.tree-cell-icon 
-  {
-    list-style-image      : inherit;
-    padding-right         : 2px;
-  }
-
-.tree-cell-twisty 
-  {
-    list-style-image      : url("chrome://global/skin/tree/twisty-closed.gif");
-    -moz-user-focus       : ignore;
-    padding-right         : 2px;
-  }
-
-.treecell-indent > .tree-cell-primary-icon 
-  {
-    padding-left          : 11px;
-  }
-
-treeitem[container="true"] > treerow > .treecell-indent > .tree-cell-primary-icon 
-  {
-    padding-left          : 0px;
-  }
-
-.tree-cell-twisty[disabled="true"] 
-  {
-    list-style-image      : none;
-  }
-
-treeitem[container="true"][open="true"] > treerow > treecell > .tree-cell-twisty 
-  {
-    list-style-image      : url("chrome://global/skin/tree/twisty-open.gif");
-  }
-
-treeitem[empty="true"] > treerow > treecell > .tree-cell-twisty {               
-    visibility            : hidden;
-}   
-
-/* tree header with sort direction indicators */
-
-.tree-header-sortdirection 
-  {
-    list-style-image      : none;
-  }
-
-.sortDirectionIndicator[sortDirection="ascending"]  > .treecell-header-box > .tree-header-sortdirection 
-  {
-    list-style-image      : url("chrome://global/skin/tree/sort-asc.gif");
-  }
-
-.sortDirectionIndicator[sortDirection="descending"] > .treecell-header-box > .tree-header-sortdirection 
-  {
-    list-style-image      : url("chrome://global/skin/tree/sort-desc.gif");
-  }
-
-/* column selection popup menu icon */
-
-.treecell-popup-icon
-  {
-    list-style-image      : url("chrome://global/skin/tree/columnpicker.gif");
-  }
-
-/* Inline Editable Treecells */
-
-treerow[mode="inline-edit"] 
-  {
-    border-top            : none !important;
-    border-bottom         : none !important;
-    background-color      : transparent !important;
-  }
-
-.inline-edit-cell-box
-  {
-    margin-left           : 2px;
-  }
-
-.inline-edit-cell-box[mode="edit"] 
-  {
-    margin-left           : 0px;
-  }
-
-.inline-edit-cell-box[mode="edit"] 
-  {
-    margin                : 0px;
-  }
+/* ===== tree.css =======================================================
+  == Styles used by the XUL tree element.
+  ======================================================================= */
+
+/* ::::: tree ::::: */
+
+tree {
+  border-spacing: 0px;
+  border: 1px inset #CCD0DD;
+  background-color: #FFFFFF;
+  color: #000000;
+}
+
+/* ::::: tree focusring ::::: */
+
+/* deactivated, looks too bad for me in EarlyBlue
+.focusring > .tree-rows > .tree-bodybox {
+  border: 1px solid transparent;
+}
+
+.focusring:focus > .tree-rows > .tree-bodybox {
+  border: 1px solid #000000;
+}
+*/
+
+/* ::::: tree rows ::::: */
+
+treechildren::-moz-tree-row {
+  border: 1px solid transparent;
+  background-color: transparent;
+  min-height: 18px;
+  height: 1.3em;
+}
+
+treechildren::-moz-tree-row(selected) {
+  background-color: #808080;
+}
+
+treechildren::-moz-tree-row(selected, focus) {
+  background-color: #336699;
+}
+
+treechildren::-moz-tree-row(current, focus) {
+  border: 1px dotted #9999CC;
+}
+
+treechildren::-moz-tree-row(selected, current, focus) {
+  border: 1px dotted #666699;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-row {
+  border: none;
+  background-color: transparent;
+}
+
+/* ::::: tree cells ::::: */
+
+treechildren::-moz-tree-cell {
+  padding: 0px 2px 0px 2px;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text,
+treechildren::-moz-tree-cell-text {
+  color: inherit;
+}
+
+treechildren::-moz-tree-cell-text(selected) {
+  color: #FFFFFF;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary) {
+  border: 1px solid transparent;
+  padding: 0px 1px 1px 1px;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary, selected) {
+  background-color: #808080;
+  color: #FFFFFF;
+}
+
+treechildren::-moz-tree-cell-text(selected, focus) {
+  color: #FFFFFF;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary, selected, focus) {
+  background-color: #336699;
+  color: #FFFFFF;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary, current, focus) {
+  border: 1px dotted #9999CC;
+}
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary, selected, current, focus) {
+  border: 1px dotted #666699;
+}
+
+/* ::::: lines connecting cells ::::: */
+
+tree[selstyle="primary"] > treechildren::-moz-tree-line,
+treechildren::-moz-tree-line {
+  visibility: hidden;
+}
+
+/*
+treechildren::-moz-tree-line {
+  border: 1px dotted grey;
+}
+
+treechildren::-moz-tree-line(selected, focus) {
+  border: 1px dotted black;
+}
+*/
+
+/* ::::: tree separator ::::: */
+
+treechildren::-moz-tree-separator {
+  margin-top: 1px;
+  border: 1px outset #CCD0DD;
+  height: 2px;
+}
+
+/* ::::: drop feedback ::::: */
+
+tree[selstyle="primary"] > treechildren::-moz-tree-cell-text(primary, dropOn),
+treechildren::-moz-tree-cell-text(dropOn) {
+  background-color: #336699;
+  color: #FFFFFF;
+}
+
+treechildren::-moz-tree-drop-feedback {
+  background-color: #336699;
+  width: 50px;
+  height: 2px;
+  margin-left: 5px;
+}
+
+treechildren::-moz-tree-drop-feedback(selected) {
+  background-color: #FFFFFF;
+}
+
+/* ::::: tree checkbox ::::: */
+
+treechildren::-moz-tree-checkbox {
+  list-style-image: url("chrome://global/skin/tree/checkbox.gif");
+}
+
+treechildren::-moz-tree-checkbox(checked) {
+  list-style-image: url("chrome://global/skin/tree/checkbox-checked.gif");
+}
+
+/* ::::: tree progress meter ::::: */
+
+treechildren::-moz-tree-progressmeter {
+  margin: 0px 0px;
+  border: 1px inset #CCD0DD;
+  background-color: #999999;
+  color: #6699CC;
+}
+
+treechildren::-moz-tree-progressmeter(progressUndetermined) {
+  list-style-image: url("chrome://global/skin/progressmeter/progressmeter-busy.gif");
+  background-color: #CCD0DD;
+}
+
+treechildren::-moz-tree-cell-text(progressmeter) {
+  margin: 2px 4px;
+}
+
+/* ::::: tree columns ::::: */
+
+treecol {
+  -moz-box-align: center;
+  -moz-box-pack: center;
+  border: 1px outset #CCD0DD;
+  background-color: #CCD0DD;
+  color: #000000;
+  padding: 1px 4px;
+}
+
+treecolpicker {
+  -moz-box-align: center;
+  -moz-box-pack: center;
+  border: 1px solid transparent;
+  background-color: #CCD0DD;
+  padding: 1px 0px;
+}
+
+.treecol-image {
+  padding: 1px;
+}
+
+.treecol-text {
+  margin: 0px !important;
+  padding: 0px !important;
+}
+
+treecol[hideheader="true"] {
+  border: none;
+  padding: 0;
+}
+
+/* ..... internal box ..... */
+
+treecol:hover:active {
+  border: 1px solid #666699;
+  padding: 2px 3px 0px 5px;
+}
+
+treecolpicker:hover:active {
+  border: 1px solid #666699;
+}
+
+.treecol-image:hover:active {
+  padding: 2px 0px 0px 2px;
+}
+
+/* ::::: column drag and drop styles ::::: */
+
+treecol[dragging="true"] {
+  border: 1px solid transparent;
+  background-color: #336699;
+  color: #000000;
+}
+
+treecol[insertafter="true"] {
+  border-right: 1px solid #000000;
+}
+
+treecol[insertbefore="true"] {
+  border-left: 1px solid #000000;
+}
+
+treechildren::-moz-tree-column(insertbefore) {
+  border-left: 1px solid #000000;
+}
+
+treechildren::-moz-tree-column(insertafter) {
+  border-right: 1px solid #000000;
+}
+
+/* ::::: sort direction indicator :::::  */
+
+.treecol-sortdirection {
+  list-style-image: none;
+  width: 8px;  /* The image's width is 7 pixels */
+}
+
+.treecol-sortdirection[sortDirection="ascending"] {
+  list-style-image: url("chrome://global/skin/tree/sort-asc.gif");
+}
+
+.treecol-sortdirection[sortDirection="descending"] {
+  list-style-image: url("chrome://global/skin/tree/sort-dsc.gif");
+}
+
+/* ::::: column picker :::::  */
+
+.tree-columnpicker-icon {
+  list-style-image: url("chrome://global/skin/tree/columnpicker.gif");
+}
+
+/* ::::: twisty :::::  */
+
+treechildren::-moz-tree-twisty {
+  padding-right: 2px;
+  padding-top: 1px;
+  width: 11px; /* The image's width is 11 pixels */
+  list-style-image: url("chrome://global/skin/tree/twisty-closed.gif");
+}
+
+treechildren::-moz-tree-twisty(open) {
+  width: 11px; /* The image's width is 11 pixels */
+  list-style-image: url("chrome://global/skin/tree/twisty-open.gif");
+}
+
+treechildren::-moz-tree-indentation {
+  width: 11px;
+}
+
+/* ::::: gridline style ::::: */
+
+treechildren.gridlines::-moz-tree-cell {
+  border-right: 1px solid green;
+  border-bottom: 1px solid green;
+}
+
+treechildren.gridlines::-moz-tree-row {
+  border: none;
+}
+
+/* ::::: alternating background ::::: */
+
+treechildren[alternatingbackground="true"]::-moz-tree-row(odd) {
+  background-color: #F5F7FF;
+}
+
+treechildren[alternatingbackground="true"]::-moz-tree-row(odd, selected) {
+  background-color: #A0A0A0;
+}
+
+treechildren[alternatingbackground="true"]::-moz-tree-row(odd, selected, focus) {
+  background-color: #6699CC;
+}