[gtk+] Adwaita: color treeview tree/grid lines



commit 8a7bd5cc001e86c45d4b187c6ebbd26c1bdef406
Author: Lapo Calamandrei <calamandrei gmail com>
Date:   Wed Oct 15 20:41:19 2014 +0200

    Adwaita: color treeview tree/grid lines
    
    Tree lines are visible now, unfortunatelly grid lines do not react
    to selected state so they are way too bright.

 gtk/resources/theme/Adwaita/_common.scss           |   16 +++++++++++-----
 gtk/resources/theme/Adwaita/gtk-contained-dark.css |    9 +++++++--
 gtk/resources/theme/Adwaita/gtk-contained.css      |    9 +++++++--
 3 files changed, 25 insertions(+), 9 deletions(-)
---
diff --git a/gtk/resources/theme/Adwaita/_common.scss b/gtk/resources/theme/Adwaita/_common.scss
index b7963a5..34b69a5 100644
--- a/gtk/resources/theme/Adwaita/_common.scss
+++ b/gtk/resources/theme/Adwaita/_common.scss
@@ -1247,17 +1247,23 @@ GtkComboBox {
 /**************
  * Tree Views *
  **************/
-GtkTreeView.view { // treeview grid lines and expanders, unfortunatelly
-                   // the tree lines color can't be set
+GtkTreeView.view {
   -GtkTreeView-grid-line-width: 1;
   -GtkTreeView-grid-line-pattern: '';
   -GtkTreeView-tree-line-width: 1;
   -GtkTreeView-tree-line-pattern: '';
   -GtkTreeView-expander-size: 16;
-  border-color: $bg_color; // this is actually the line color
-  // :selected is ignored hence no style for it
+
+  border-left-color: mix($fg_color, $base_color, 0.5); // this is actually the tree lines color,
+  border-top-color: $bg_color;                         // while this is the grid lines color, better then 
nothing
+
+  &:selected, &:backdrop:selected {
+    border-left-color: mix($selected_fg_color, $selected_bg_color, 0.5);
+    border-top-color: transparentize($fg_color, 0.9); // doesn't work unfortunatelly
+  }
   &:backdrop {
-    border-color: $backdrop_bg_color;
+    border-left-color: mix($backdrop_fg_color, $backdrop_bg_color, 0.5);
+    border-top: $backdrop_bg_color;
   }
   &.expander {
     -gtk-icon-source: -gtk-icontheme('pan-end-symbolic');
diff --git a/gtk/resources/theme/Adwaita/gtk-contained-dark.css 
b/gtk/resources/theme/Adwaita/gtk-contained-dark.css
index 07e44d7..707f8a0 100644
--- a/gtk/resources/theme/Adwaita/gtk-contained-dark.css
+++ b/gtk/resources/theme/Adwaita/gtk-contained-dark.css
@@ -1892,9 +1892,14 @@ GtkTreeView.view {
   -GtkTreeView-tree-line-width: 1;
   -GtkTreeView-tree-line-pattern: '';
   -GtkTreeView-expander-size: 16;
-  border-color: #393f3f; }
+  border-left-color: rgba(238, 238, 236, 0.5);
+  border-top-color: #393f3f; }
+  GtkTreeView.view:selected, GtkTreeView.view:backdrop:selected {
+    border-left-color: rgba(255, 255, 255, 0.5);
+    border-top-color: rgba(238, 238, 236, 0.1); }
   GtkTreeView.view:backdrop {
-    border-color: #393f3f; }
+    border-left-color: rgba(201, 203, 201, 0.5);
+    border-top: #393f3f; }
   GtkTreeView.view.expander {
     -gtk-icon-source: -gtk-icontheme("pan-end-symbolic");
     color: #b2b2b1; }
diff --git a/gtk/resources/theme/Adwaita/gtk-contained.css b/gtk/resources/theme/Adwaita/gtk-contained.css
index eed31a9..1d73d90 100644
--- a/gtk/resources/theme/Adwaita/gtk-contained.css
+++ b/gtk/resources/theme/Adwaita/gtk-contained.css
@@ -1884,9 +1884,14 @@ GtkTreeView.view {
   -GtkTreeView-tree-line-width: 1;
   -GtkTreeView-tree-line-pattern: '';
   -GtkTreeView-expander-size: 16;
-  border-color: #ededed; }
+  border-left-color: rgba(46, 52, 54, 0.5);
+  border-top-color: #ededed; }
+  GtkTreeView.view:selected, GtkTreeView.view:backdrop:selected {
+    border-left-color: rgba(255, 255, 255, 0.5);
+    border-top-color: rgba(46, 52, 54, 0.1); }
   GtkTreeView.view:backdrop {
-    border-color: #ededed; }
+    border-left-color: rgba(84, 89, 90, 0.5);
+    border-top: #ededed; }
   GtkTreeView.view.expander {
     -gtk-icon-source: -gtk-icontheme("pan-end-symbolic");
     color: #6c7072; }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]