diff --git a/gtk/gtkcolorswatch.c b/gtk/gtkcolorswatch.c index 5f7da4788e..921b8d9793 100644 --- a/gtk/gtkcolorswatch.c +++ b/gtk/gtkcolorswatch.c @@ -198,7 +198,7 @@ swatch_draw (GtkWidget *widget, rect.y = border.top + padding.top; gtk_style_context_save (context); - gtk_style_context_add_class (context, GTK_STYLE_CLASS_IMAGE); + gtk_style_context_add_class (context, "overlay"); gtk_render_background (context, cr, rect.x, rect.y, rect.width, rect.height); gtk_render_frame (context, cr, rect.x, rect.y, rect.width, rect.height); diff --git a/gtk/resources/theme/Adwaita/_common.scss b/gtk/resources/theme/Adwaita/_common.scss index 1ae19009f6..59f6315be5 100644 --- a/gtk/resources/theme/Adwaita/_common.scss +++ b/gtk/resources/theme/Adwaita/_common.scss @@ -2834,7 +2834,7 @@ GtkColorSwatch { &:only-child { border-radius: 5px; } - &.image, &.image:hover { + &.overlay, &.overlay:hover { /* turn off everything from regular color swatch */ border-width: 0px; border-radius: 50%; diff --git a/gtk/resources/theme/Adwaita/gtk-contained-dark.css b/gtk/resources/theme/Adwaita/gtk-contained-dark.css index 19f217675b..de7bf3482e 100644 --- a/gtk/resources/theme/Adwaita/gtk-contained-dark.css +++ b/gtk/resources/theme/Adwaita/gtk-contained-dark.css @@ -4192,18 +4192,18 @@ GtkColorSwatch { border-bottom-right-radius: 5px; } GtkColorSwatch:only-child { border-radius: 5px; } - GtkColorSwatch.image, GtkColorSwatch.image:hover { + GtkColorSwatch.overlay, GtkColorSwatch.overlay:hover { /* turn off everything from regular color swatch */ border-width: 0px; border-radius: 50%; box-shadow: none; background-image: none; } - GtkColorSwatch.image:selected, GtkColorSwatch.image:hover:selected { + GtkColorSwatch.overlay:selected, GtkColorSwatch.overlay:hover:selected { border-width: 2px; } - GtkColorSwatch.image:selected.color-light, GtkColorSwatch.image:selected.color-light:hover, GtkColorSwatch.image:hover:selected.color-light, GtkColorSwatch.image:hover:selected.color-light:hover { + GtkColorSwatch.overlay:selected.color-light, GtkColorSwatch.overlay:selected.color-light:hover, GtkColorSwatch.overlay:hover:selected.color-light, GtkColorSwatch.overlay:hover:selected.color-light:hover { color: rgba(0, 0, 0, 0.3); border-color: rgba(0, 0, 0, 0.3); } - GtkColorSwatch.image:selected.color-dark, GtkColorSwatch.image:selected.color-dark:hover, GtkColorSwatch.image:hover:selected.color-dark, GtkColorSwatch.image:hover:selected.color-dark:hover { + GtkColorSwatch.overlay:selected.color-dark, GtkColorSwatch.overlay:selected.color-dark:hover, GtkColorSwatch.overlay:hover:selected.color-dark, GtkColorSwatch.overlay:hover:selected.color-dark:hover { color: rgba(255, 255, 255, 0.5); border-color: rgba(255, 255, 255, 0.5); } @@ -4291,6 +4291,7 @@ GtkCalendar.header .menuitem.titlebutton.button:selected, .list-row:selected { color: #c9cbc9; } /* Decouple the font of context menus from their entry/textview */ +.touch-selection, .context-menu { font: initial; } diff --git a/gtk/resources/theme/Adwaita/gtk-contained.css b/gtk/resources/theme/Adwaita/gtk-contained.css index 318c463daa..75d295235f 100644 --- a/gtk/resources/theme/Adwaita/gtk-contained.css +++ b/gtk/resources/theme/Adwaita/gtk-contained.css @@ -4353,18 +4353,18 @@ GtkColorSwatch { border-bottom-right-radius: 5px; } GtkColorSwatch:only-child { border-radius: 5px; } - GtkColorSwatch.image, GtkColorSwatch.image:hover { + GtkColorSwatch.overlay, GtkColorSwatch.overlay:hover { /* turn off everything from regular color swatch */ border-width: 0px; border-radius: 50%; box-shadow: none; background-image: none; } - GtkColorSwatch.image:selected, GtkColorSwatch.image:hover:selected { + GtkColorSwatch.overlay:selected, GtkColorSwatch.overlay:hover:selected { border-width: 2px; } - GtkColorSwatch.image:selected.color-light, GtkColorSwatch.image:selected.color-light:hover, GtkColorSwatch.image:hover:selected.color-light, GtkColorSwatch.image:hover:selected.color-light:hover { + GtkColorSwatch.overlay:selected.color-light, GtkColorSwatch.overlay:selected.color-light:hover, GtkColorSwatch.overlay:hover:selected.color-light, GtkColorSwatch.overlay:hover:selected.color-light:hover { color: rgba(0, 0, 0, 0.3); border-color: rgba(0, 0, 0, 0.3); } - GtkColorSwatch.image:selected.color-dark, GtkColorSwatch.image:selected.color-dark:hover, GtkColorSwatch.image:hover:selected.color-dark, GtkColorSwatch.image:hover:selected.color-dark:hover { + GtkColorSwatch.overlay:selected.color-dark, GtkColorSwatch.overlay:selected.color-dark:hover, GtkColorSwatch.overlay:hover:selected.color-dark, GtkColorSwatch.overlay:hover:selected.color-dark:hover { color: rgba(255, 255, 255, 0.5); border-color: rgba(255, 255, 255, 0.5); } @@ -4453,6 +4453,7 @@ GtkCalendar.header .menuitem.titlebutton.button:selected, .list-row:selected { color: #fcfcfc; } /* Decouple the font of context menus from their entry/textview */ +.touch-selection, .context-menu { font: initial; }