Reported window size includes window padding/unusable space #4265
Unanswered
mierak
asked this question in
Feature Requests, Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Executing tcgetwinsize in ghostty v1.0.0 includes the window-padding (non usable space) in its pixel dimensions. Other terminals do not seem to exhibit this behavior.
For example, executing
python -c "import fcntl, termios, array; buf = array.array('H', [0,0,0,0]); fcntl.ioctl(1, termios.TIOCGWINSZ, buf); print(buf)"inside ghostty and kitty of identical sizes returns(rows, columns, width_px, height_px):ghostty:
array('H', [24, 133, 1200, 545])kitty:
array('H', [23, 133, 1197, 529])As you can see, the width is perfectly divisible by column count -
1197/133 = 9- in kitty(and foot, wezterm, didnt test others).But in ghostty this results in a decimal number -
1200/133 = 9.02255639098.Beta Was this translation helpful? Give feedback.
All reactions