microsoft / microsoft/terminal
Exiting from Full Screen mode incorrectly restores window size
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 105k
- Forks
- 9.6k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 29
Description
Version 10.0.17763.253
Start cmd.exe
Enter command mode 80, 25
Go to window menu - Properties - Layout
Check that Window Size is 80 x 25 indeed
Close Properties
Press Alt+Enter twice to enter and exit full screen
Go to window menu - Properties - Layout
Check Window Size again. This time it's not 80 x 25, but 78 x 24.
This happens because exiting full screen restores the original outer window size (with the title, borders etc., say, 802 x 532px), however:
- Entering full screen increases the buffer size (which is fine)
- Exiting full screen doesn't change the buffer size (which is also fine)
- The console window now has to display scrollbars (also fine), but since it's outer size is the same it has to display them at the expense of console viewport area.
This causes an issue in an app that automatically syncs buffer size with window size - after every switch to full screen and back window size gets smaller, the app reduces the buffer size accordingly, eventually going down to nothing.
Also, even if an app doesn't do anything like that, reducing the viewport size can make some (potentially important) information invisible.
Please consider preserving the console viewport size and increasing the outer window size to make room for scrollbars.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue using cmd.exe, mode 80, 25, the Properties > Layout dialog, and Alt+Enter twice. Trace the full-screen exit sizing behavior and verify that the 80 x 25 console viewport remains intact while the outer window grows enough for scrollbars; no source file or test is named in the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100