From f2d47ee53aff238cf142d60e3ca06d4deb91f75f Mon Sep 17 00:00:00 2001 From: Jehan Date: Fri, 9 Aug 2024 00:15:03 +0200 Subject: [PATCH] app: fix too big canvas with small display. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I was testing with a 2560×1440 display, yet with ×2 scale factor, which is kinda equivalent with 1280×720 for scaled dimensions code. And so anyway the default size request for an empty canvas was far too big (bigger than the work area in fact). I'm now using small default. As for the 3:1 ratio comment, not sure about it, since shell_width is in fact changed to -1, so it feels very specific to someone's setup. But anyway… I left the comment. --- app/display/gimpdisplayshell.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/display/gimpdisplayshell.c b/app/display/gimpdisplayshell.c index 83ece443d5..1ab68ca33d 100644 --- a/app/display/gimpdisplayshell.c +++ b/app/display/gimpdisplayshell.c @@ -472,9 +472,11 @@ gimp_display_shell_constructed (GObject *object) /* These values are arbitrary. The width is determined by the * menubar and the height is chosen to give a window aspect * ratio of roughly 3:1 (as requested by the UI team). + * It must be smaller than the minimal supported display + * dimension (1280x720 a.k.a. 720p). */ image_width = GIMP_DEFAULT_IMAGE_WIDTH; - image_height = GIMP_DEFAULT_IMAGE_HEIGHT / 3; + image_height = GIMP_DEFAULT_IMAGE_HEIGHT / 4; } shell->dot_for_dot = config->default_dot_for_dot;