[meld/ui-next: 32/35] filediff: Add an additional notebook child class to reset the background



commit 4c7c4a0e48d357447029444f0502a9f868720b13
Author: Kai Willadsen <kai willadsen gmail com>
Date:   Sat Feb 16 08:32:46 2019 +1000

    filediff: Add an additional notebook child class to reset the background
    
    Adwaita confusingly sets different background colours (white vs.
    transparent) depending on whether the notebook has more than one child.
    While in most cases this is probably fine, in our packing case where the
    status bar is inside the notebook, it gives the status bar a white
    background which looks extremely odd.
    
    The workaround here is to give the notebook child the base background
    colour.
    
    As an unexpected side effect, the lack of this background is what's been
    causing bad rendering of the DiffGrid's handles for literally years, so
    those now actually look like handles instead of lines.

 data/meld.css                 | 4 ++++
 meld/resources/ui/filediff.ui | 3 +++
 2 files changed, 7 insertions(+)
---
diff --git a/data/meld.css b/data/meld.css
index a027d79d..9d2076c3 100644
--- a/data/meld.css
+++ b/data/meld.css
@@ -29,6 +29,10 @@ action-gutter {
     background-color: @theme_bg_color;
 }
 
+.meld-notebook-child {
+    background-color: @theme_bg_color;
+}
+
 .meld-vc-console-pane {
     border-width: 1px 0 0 0;
     border-style: solid;
diff --git a/meld/resources/ui/filediff.ui b/meld/resources/ui/filediff.ui
index 8349d58a..a5b580b1 100644
--- a/meld/resources/ui/filediff.ui
+++ b/meld/resources/ui/filediff.ui
@@ -12,6 +12,9 @@
       <object class="DiffGrid" id="grid">
         <property name="visible">True</property>
         <property name="can_focus">False</property>
+        <style>
+          <class name="meld-notebook-child"/>
+        </style>
         <child>
           <object class="GtkToolbar" id="file_toolbar2">
             <property name="visible">True</property>


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