diff options
author | lukefromdc <[email protected]> | 2025-08-08 03:39:28 -0400 |
---|---|---|
committer | Luke from DC <[email protected]> | 2025-08-08 07:43:40 +0000 |
commit | d3977a7f55d56c24f8f53e5ac481c469dbd59eef (patch) | |
tree | bf16acd48590761254dbf3414ce9b8af0fa9e053 | |
parent | 8634b87ff36933acf072393486a422670330f7e7 (diff) | |
download | mate-terminal-d3977a7f55d56c24f8f53e5ac481c469dbd59eef.tar.bz2 mate-terminal-d3977a7f55d56c24f8f53e5ac481c469dbd59eef.tar.xz |
-rw-r--r-- | src/terminal-window.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/terminal-window.c b/src/terminal-window.c index fd50df7..92ea108 100644 --- a/src/terminal-window.c +++ b/src/terminal-window.c @@ -3467,6 +3467,7 @@ terminal_window_update_geometry (TerminalWindow *window) int char_width, char_height; int chrome_width, chrome_height; int csd_width = 0, csd_height = 0; + gboolean suppress_hints = FALSE; if (priv->active_screen == NULL) return; @@ -3530,14 +3531,25 @@ terminal_window_update_geometry (TerminalWindow *window) * until we've been redrawn at least once. Don't resize the window * until we've done that. */ _terminal_debug_print (TERMINAL_DEBUG_GEOMETRY, "not realized yet\n"); + + suppress_hints = TRUE; + } + +#ifdef GDK_WINDOWING_X11 + // On X11 it would make the window to rescale without font size granularity. + if (GDK_IS_X11_DISPLAY (gdk_display_get_default ())) { + suppress_hints = FALSE; } - else if (char_width != priv->old_char_width || +#endif + + if (!suppress_hints && ( + char_width != priv->old_char_width || char_height != priv->old_char_height || padding.left + padding.right != priv->old_padding_width || padding.top + padding.bottom != priv->old_padding_height || chrome_width != priv->old_chrome_width || chrome_height != priv->old_chrome_height || - widget != GTK_WIDGET (priv->old_geometry_widget)) + widget != GTK_WIDGET (priv->old_geometry_widget))) { hints.base_width = chrome_width + csd_width; hints.base_height = chrome_height + csd_height; |