[vim/vim] GTK4: the shell becomes smaller than requested (PR #21006)

1 view
Skip to first unread message

h_east

unread,
7:10 AM (5 hours ago) 7:10 AM
to vim/vim, Subscribed
Problem:  With the GTK4 GUI the shell loses a few columns on every resize,
          and the window can also be made smaller than asked for when the
          compositor does not report which monitor it is on.
Solution: Account for the width of the client side decorations, like is
          already done for the height, and fall back to the first monitor
          instead of assuming an 800x600 screen.

related: #20920

Note that I could not verify this locally: on my machine the decorations have
no width, so the shrinking does not reproduce. The GTK4 CI job added in
9.2.0931 is the only place where it shows up, so that job is the check for
this change.

What that job shows, e.g. in run 31428173009: within a single gvim session the
terminal opened by RunVimInTerminal() gets narrower on every call, while the
number of rows stays correct.

Test_popupwin_cursorline_1   75 columns (passed)
Test_popupwin_cursorline_2   74
Test_popupwin_cursorline_3   72
Test_popupwin_cursorline_4   72
Test_popupwin_cursorline_5   70
Test_popupwin_cursorline_6   70
Test_popupwin_cursorline_7   68
Test_popupwin_cursorline_8   66

All of them expect 75 columns, and every one of these dumps has the expected
number of rows. The height is already compensated with "gui.decor_height",
the width had no equivalent.


You can view, comment on, or merge this pull request online at:

  https://github.com/vim/vim/pull/21006

Commit Summary

  • 73b05b6 GTK4: the shell becomes smaller than requested

File Changes

(4 files)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/pull/21006@github.com>

Reply all
Reply to author
Forward
0 new messages