[libadwaita/wip/exalm/combobox: 2/2] stylesheet: Make comboboxes and dropdowns less likely to stretch




commit 48f3152f29dc9eb53679e2c8aa498aa0b61786b2
Author: Alexander Mikhaylenko <alexm gnome org>
Date:   Mon May 9 00:25:39 2022 +0400

    stylesheet: Make comboboxes and dropdowns less likely to stretch
    
    Cell views are taller than labels, and e.g. 1.25 font scale is enough to
    make comboboxes 2px taller than normally. Give them 6px of extra buffer,
    enough for font scale 2.0.

 src/stylesheet/widgets/_dropdowns.scss | 8 ++++++++
 1 file changed, 8 insertions(+)
---
diff --git a/src/stylesheet/widgets/_dropdowns.scss b/src/stylesheet/widgets/_dropdowns.scss
index af178d27..7d7df3de 100644
--- a/src/stylesheet/widgets/_dropdowns.scss
+++ b/src/stylesheet/widgets/_dropdowns.scss
@@ -10,6 +10,14 @@ dropdown > button > box {
 
 dropdown,
 combobox {
+  // Since cell view is taller than a plain label, make sure
+  // the button doesn't get stretched with a larger font
+  button {
+    padding-top: 2px;
+    padding-bottom: 2px;
+    min-height: 30px;
+  }
+
   arrow {
     -gtk-icon-source: -gtk-icontheme('pan-down-symbolic');
     min-height: 16px;


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