From 05eb46511fd1bc2b7fe8b24a8770d3b76b31474e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20G=C3=B6llnitz?= Date: Wed, 11 Jun 2025 06:02:18 +0200 Subject: [PATCH] week-view: add border around scrolled main area for distiction from toolbar MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Currently, at the top there is an always visible border which, due to having the same colour as the drop shadow, slightly interferes with how the drop shadow looks, while more severely, the bottom bar's start is not easily distinguishable from the week grid's end, as there is no border at all. Styling the scrolled content itself with a border elegantly solves these two issues, because now a drop shadow is drawn when scrolling in a direction is possible, and a border is drawn otherwise. Closes: https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/1406 Signed-off-by: Markus Göllnitz Part-of: --- src/gui/views/gcal-week-view.blp | 6 ++++-- src/theme/style.css | 5 +++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/gui/views/gcal-week-view.blp b/src/gui/views/gcal-week-view.blp index 47979e42..613cbcf0 100644 --- a/src/gui/views/gcal-week-view.blp +++ b/src/gui/views/gcal-week-view.blp @@ -36,8 +36,6 @@ template $GcalWeekView: Box { } } - Separator {} - ScrolledWindow scrolled_window { hexpand: true; vexpand: true; @@ -74,6 +72,10 @@ template $GcalWeekView: Box { vexpand: true; event-activated => $on_event_activated(template); } + + styles [ + "week-main-content", + ] } } } diff --git a/src/theme/style.css b/src/theme/style.css index 7a926ec4..54d47e57 100644 --- a/src/theme/style.css +++ b/src/theme/style.css @@ -186,6 +186,11 @@ weekhourbar > label { color: rgb(from var(--window-fg-color) r g b / 15%); } +.week-main-content { + border: 0 solid var(--border-color); + border-width: 1px 0; +} + weekgrid > widget.now-strip { background-color: rgb(from var(--accent-bg-color) r g b / 80%); margin: 0 0 0 1px;