GTK4 builds did not honor set lines=... / set columns=... after the window was realized, and font changes left the editor blank until forced refresh.
Two related issues in src/gui_gtk4.c:
gui_mch_set_shellsize() only called gtk_window_set_default_size(). In GTK4 that mostly affects the initial show; once realized, window managers such as xfwm4 on X11 ignore further updates because gui.drawarea has no natural size to drive a grow. Push the requested size with a temporary gtk_widget_set_size_request() on the drawing area, then clear it on idle so the user can still shrink the window manually.
After the drawing area is resized, drawarea_resize_cb() destroys and recreates the backing cairo surface filled with the background color. The follow-up gui_resize_shell() skips shell_resized() when Rows/Columns are unchanged (typical for font changes that keep the same cell count), so the fresh surface stayed blank. Set gui.force_redraw before calling gui_resize_shell() to guarantee a full redraw.
Fixes #20307
https://github.com/vim/vim/pull/20317
(1 file)
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you are subscribed to this thread.![]()