simon-git: putty (pre-0.77): Simon Tatham
Commits to Tartarus hosted VCS
tartarus-commits at lists.tartarus.org
Thu Feb 3 18:51:45 GMT 2022
TL;DR:
1e987101 GTK: fix font-size change when window maximised.
9427f969 GTK: fix junk in window margin with fixed-size windows.
Repository: https://git.tartarus.org/simon/putty.git
On the web: https://git.tartarus.org/?p=simon/putty.git
Branch updated: pre-0.77
Committer: Simon Tatham <anakin at pobox.com>
Date: 2022-02-03 18:51:45
commit 1e98710174920fcb6af277b0fb33efa362f23844
web diff https://git.tartarus.org/?p=simon/putty.git;a=commitdiff;h=1e98710174920fcb6af277b0fb33efa362f23844;hp=397f3bd2b3b30f3226e0c3c126559667f84d060c
Author: Simon Tatham <anakin at pobox.com>
Date: Thu Feb 3 17:48:21 2022 +0000
GTK: fix font-size change when window maximised.
If you maximise the terminal window and then press Ctrl-> or Ctrl-< to
change the font size, then the maximised window can't change size, so
what _should_ happen instead is that the terminal adjusts the number
of character cells to whatever the new font size will now permit in
the same size of window as before.
But in fact, the terminal size wasn't changing at all, because the
call to gtkwin_request_resize (called from change_font_size) detected
the maximised window and went straight to gtkwin_deny_term_resize,
which immediately called term_size() to tell the terminal it still had
the same size as before.
This commit switches gtkwin_deny_term_resize so that instead it calls
drawing_area_setup_simple(), which re-runs drawing_area_setup with the
same size the drawing area already had. This should work out the same
in the case where we're _not_ changing the font size, but now also
does the right thing when we are.
unix/window.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
commit 9427f9699d1072f4598753e77681b3a8b59a48a7
web diff https://git.tartarus.org/?p=simon/putty.git;a=commitdiff;h=9427f9699d1072f4598753e77681b3a8b59a48a7;hp=1e98710174920fcb6af277b0fb33efa362f23844
Author: Simon Tatham <anakin at pobox.com>
Date: Thu Feb 3 17:56:38 2022 +0000
GTK: fix junk in window margin with fixed-size windows.
When the window can't be resized for any reason, there will be extra
space inside the drawing area that's not part of our standard
width*font_width+2*window_border. We should include that in the
backing surface and make sure we erase it to the background colour,
otherwise it can end up containing unwanted visual junk.
An example is the same case described in the previous commit: maximise
the window and then start playing about with the font size. If you do
this while running a full-screen application that displays text in the
bottom line, it's easy to see that part of the previous display is
left over and not cleared when the new font size leaves more space at
the bottom than the old one.
unix/window.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)
More information about the tartarus-commits
mailing list