From 82f04f12f89071340ff31a864804280bf31d3eed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ant=C3=B3nio=20Fernandes?= Date: Mon, 28 Feb 2022 14:30:42 +0000 Subject: css: Don't use shadow bur for thumbnails Gaussian blur has high performance impact. Overlap plain shadows with varying offsets and opacity to achieve an identical visual result at low performance cost. Fixes https://gitlab.gnome.org/GNOME/nautilus/-/issues/2161 --- src/resources/css/Adwaita.css | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/src/resources/css/Adwaita.css b/src/resources/css/Adwaita.css index 4991979cf..1135871be 100644 --- a/src/resources/css/Adwaita.css +++ b/src/resources/css/Adwaita.css @@ -13,10 +13,12 @@ } .nautilus-canvas-item.thumbnail { - -gtk-icon-shadow: 0px 1px 2px @borders, - 1px 0px 0px alpha(@borders, 0.25), - -1px 0px 0px alpha(@borders, 0.25), - 0px 2px 0px alpha(@borders, 0.5); + -gtk-icon-shadow: 0px -1px alpha(@borders, 0.2), + 2px 0px alpha(@borders, 0.2), + -2px 0px alpha(@borders, 0.2), + 0px 3px alpha(@borders, 0.2), + 1px 2px alpha(@borders, 0.4), + -1px 2px alpha(@borders, 0.4); } .nautilus-canvas-item.dim-label { @@ -195,10 +197,12 @@ entry.search > * { } .nautilus-list-view.thumbnail { - -gtk-icon-shadow: 0px 1px 2px @borders, - 1px 0px 0px alpha(@borders, 0.25), - -1px 0px 0px alpha(@borders, 0.25), - 0px 2px 0px alpha(@borders, 0.5); + -gtk-icon-shadow: 0px -1px alpha(@borders, 0.2), + 2px 0px alpha(@borders, 0.2), + -2px 0px alpha(@borders, 0.2), + 0px 3px alpha(@borders, 0.2), + 1px 2px alpha(@borders, 0.4), + -1px 2px alpha(@borders, 0.4); } .search-information { -- cgit v1.2.1