-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
one line moved up when maximizing Terminal #13961
Comments
Some cursory notes:
|
This has been annoying me recently, so I tried to find out what was causing the issue, and it looks to me like it might be the XAML framework that is giving us the wrong size. When I minimize the terminal, I receive a height in the I don't know if this is something we can fix, but as a workaround, I've discovered that you can prevent it from triggering a scroll just by tweaking the window padding. The idea is to adjust the available height so that the maximized size and minimized size both round down to the same number of rows. As an example on my system, using device pixels, the original panel height was 1857, which allowed for 50 rows with a 37 pixel cell height. The minimized height was 1841, which only allowed for 49 rows. It was that difference in row count that caused it to scroll up a line. But after adjusting the padding, I was able to get the base height down to 1846, which results in a minimized height of 1830. Since both of those can fit 49 rows with a 37 pixel cell height, there is no longer a change in row count when minimizing and maximizing, so it doesn't trigger a scroll. The amount of padding you need to add will obviously depend on your screen size and font size, but if you're desperate enough to fix the issue, you can just keep adjusting the padding 1 pixel at a time until it eventually works (hopefully). |
Closes: #13961 This PR changes the window styling we use under the minimized state. We now retain the active window styling so the content's height doesn't change when switching between minimized and maximized states. ## Validation Steps Performed - Open Terminal and go into Maximized mode. - Click on the Minimize button. - No `SizeChanged` event in `ControlCore`. - Click on the WT icon in the taskbar to restore it. - No `SizeChanged` event in `ControlCore`.
Closes: #13961 This PR changes the window styling we use under the minimized state. We now retain the active window styling so the content's height doesn't change when switching between minimized and maximized states. ## Validation Steps Performed - Open Terminal and go into Maximized mode. - Click on the Minimize button. - No `SizeChanged` event in `ControlCore`. - Click on the WT icon in the taskbar to restore it. - No `SizeChanged` event in `ControlCore`. (cherry picked from commit 11c4aa4) Service-Card-Id: 92350318 Service-Version: 1.19
Closes: #13961 This PR changes the window styling we use under the minimized state. We now retain the active window styling so the content's height doesn't change when switching between minimized and maximized states. ## Validation Steps Performed - Open Terminal and go into Maximized mode. - Click on the Minimize button. - No `SizeChanged` event in `ControlCore`. - Click on the WT icon in the taskbar to restore it. - No `SizeChanged` event in `ControlCore`. (cherry picked from commit 11c4aa4) Service-Card-Id: 92350319 Service-Version: 1.20
Windows Terminal version
1.14.2281.0
Windows build number
10.0.19042.1526
Other Software
No response
Steps to reproduce
Make Terminal in maximized status and prompt in the last line
Then just minimize and maximize by click Taskbar twice
It is obviously a line moved up.
Then just type some char
Repeat above steps
Expected Behavior
The prompt still in the last line , not automatically (wrongly) move up one line after maximize.
Actual Behavior
It moves up one line.
The text was updated successfully, but these errors were encountered: