[gtk/wip/jimmac/dropdown-styling] Adwaita: dropdown styling
- From: Jakub Steiner <jimmac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/jimmac/dropdown-styling] Adwaita: dropdown styling
- Date: Mon, 15 Jun 2020 19:11:49 +0000 (UTC)
commit 33196ef30fc20daeedc209382322aba0714be6bd
Author: Jakub Steiner <jimmac gmail com>
Date: Mon Jun 15 15:18:04 2020 +0200
Adwaita: dropdown styling
- selected item color
- offset dropdown form the parent control
- special styling for the top search entry (FIXME: minor aliasing)
Fixes (eventually) https://gitlab.gnome.org/GNOME/gtk/-/issues/2846
gtk/theme/Adwaita/_common.scss | 33 ++++++++++++++++++++++++++++++---
1 file changed, 30 insertions(+), 3 deletions(-)
---
diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss
index dca44ed351..70669838a3 100644
--- a/gtk/theme/Adwaita/_common.scss
+++ b/gtk/theme/Adwaita/_common.scss
@@ -1153,6 +1153,10 @@ combobox {
min-width: 16px;
}
+ > popover.menu.background > contents {
+ padding: 0;
+ }
+
// align menu labels with the button label
> popover.menu > contents modelbutton {
padding-left: 9px;
@@ -1171,12 +1175,35 @@ combobox {
button.combo { @extend %button_basic_drop_active; }
}
-}
-dropdown > popover listview > row {
- padding: 6px;
+ // newstyle
+ popover {
+ margin-top: 6px;
+ padding: 0;
+
+ listview {
+
+ margin: 8px 0;
+
+ &>row {
+ padding: 6px;
+
+ &:selected {
+ outline-color: $alt_focus_border_color;
+ color: $text-color;
+ background-color: $menu_selected_color;
+ }
+ }
+ }
+
+ .search { //drodowns with searchboxes on top
+ border-radius: $popover_radius $popover_radius 0 0;
+ margin-top: -1px; //paint over the menu borders
+ }
+ }
}
+
// the combo is a composite widget so the way we do button linking doesn't
// work, special case needed. See
// https://bugzilla.gnome.org/show_bug.cgi?id=733979
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]