[gtk/wip/jimmac/vte-bg-color-gtk3] Adwaita: add public color for text views




commit c09b9904c87c232bba78cf96553afad3cde21c29
Author: Jakub Steiner <jimmac gmail com>
Date:   Fri Aug 7 18:55:04 2020 +0200

     Adwaita: add public color for text views
    
    - define @text_view_bg to complement @theme_text_color for high
      contrast legible text views.
    
    Fixes https://gitlab.gnome.org/GNOME/vte/-/issues/226

 gtk/theme/Adwaita/_colors-public.scss    | 3 +++
 gtk/theme/Adwaita/gtk-contained-dark.css | 3 +++
 gtk/theme/Adwaita/gtk-contained.css      | 3 +++
 3 files changed, 9 insertions(+)
---
diff --git a/gtk/theme/Adwaita/_colors-public.scss b/gtk/theme/Adwaita/_colors-public.scss
index 8ccc3413cc..3b638e2bf6 100644
--- a/gtk/theme/Adwaita/_colors-public.scss
+++ b/gtk/theme/Adwaita/_colors-public.scss
@@ -112,5 +112,8 @@ read if you used those and something break with a version upgrade you're on your
 
 //FIXME this is really an API
 
+/* content view background such as thumbnails view in Photos or Boxes */
 @define-color content_view_bg #{"" + $base_color};
 
+/* Very contrasty background for text views (@theme_text_color foreground) */
+@define-color text_view_bg #{"" + if($variant == 'light', $base_color, darken($base_color,6%))};
diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css
index 02615f1329..41ec427393 100644
--- a/gtk/theme/Adwaita/gtk-contained-dark.css
+++ b/gtk/theme/Adwaita/gtk-contained-dark.css
@@ -2017,4 +2017,7 @@ read if you used those and something break with a version upgrade you're on your
 @define-color wm_button_active_color_a shade(#353535, 0.85);
 @define-color wm_button_active_color_b shade(#353535, 0.89);
 @define-color wm_button_active_color_c shade(#353535, 0.9);
+/* content view background such as thumbnails view in Photos or Boxes */
 @define-color content_view_bg #2d2d2d;
+/* Very contrasty background for text views (@theme_text_color foreground) */
+@define-color text_view_bg #1e1e1e;
diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css
index 868695f5b5..92705e082b 100644
--- a/gtk/theme/Adwaita/gtk-contained.css
+++ b/gtk/theme/Adwaita/gtk-contained.css
@@ -2033,4 +2033,7 @@ read if you used those and something break with a version upgrade you're on your
 @define-color wm_button_active_color_a shade(#f6f5f4, 0.85);
 @define-color wm_button_active_color_b shade(#f6f5f4, 0.89);
 @define-color wm_button_active_color_c shade(#f6f5f4, 0.9);
+/* content view background such as thumbnails view in Photos or Boxes */
 @define-color content_view_bg #ffffff;
+/* Very contrasty background for text views (@theme_text_color foreground) */
+@define-color text_view_bg #ffffff;


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