From 5f86b88c3bb1c3819a62e41b8335a340a1ca2a2b Mon Sep 17 00:00:00 2001 From: Georges Basile Stavracas Neto Date: Tue, 6 Aug 2024 16:12:03 -0300 Subject: [PATCH] views/month: Increase overflow popover min width Makes it so that it's at least 1.25 the width of a day cell, and at most 1.5 of that. Closes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/1166 --- src/gui/views/gcal-month-view.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/gui/views/gcal-month-view.c b/src/gui/views/gcal-month-view.c index e9a367e2..af5d245d 100644 --- a/src/gui/views/gcal-month-view.c +++ b/src/gui/views/gcal-month-view.c @@ -159,7 +159,9 @@ allocate_overflow_popover (GcalMonthView *self, &popover_height, NULL, NULL); - popover_width = CLAMP (popover_nat_width, popover_min_width, cell_allocation.width * 1.5); + popover_width = CLAMP (popover_nat_width, + MAX (popover_min_width, cell_allocation.width * 1.25), + cell_allocation.width * 1.5); popover_height = CLAMP (popover_height, cell_allocation.height * 1.5, height); popover_allocation = (GtkAllocation) {