Skip to content
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

Screen scrambled when pressing Alt-F9 under Windows 11 22H2 #551

Closed
TheChatty opened this issue Oct 7, 2022 · 11 comments
Closed

Screen scrambled when pressing Alt-F9 under Windows 11 22H2 #551

TheChatty opened this issue Oct 7, 2022 · 11 comments

Comments

@TheChatty
Copy link

TheChatty commented Oct 7, 2022

Far Manager version

3.0.6037.2930 x64

OS version

11.0.22622.730

Other software

When you maximize with Win+Arrow Up - it works.
When you maximize with Alt-F9 screen looks scrambled.

image

Steps to reproduce

  • Install Windows 11 22H2
  • Install Far 3.0.x up to 6037.290
  • Press Alt-F9

Expected behavior

Window maximized, screen not scrambled

Actual behavior

Window size remains, screen is scrambled

@TheChatty TheChatty added the bug label Oct 7, 2022
@alabuzhev
Copy link
Contributor

Far calls GetLargestConsoleWindowSize when you press Alt+F9 and that API is broken in Windows Terminal.

Maybe we will come up with a workaround one day, but so far it is what it is.

@TheChatty
Copy link
Author

TheChatty commented Oct 7, 2022

Since Win+Arrow Up is working... could this be a workaround? Simply maximize the window?

Is there a way to use the former (Windows 11 21H2) terminal window? Because what also bugs me is when I press Ctrl-V I'm asked if I'm sure I want to insert (by Windows) and then the pasting happens real slow...

@alabuzhev
Copy link
Contributor

Since Win+Arrow Up is working... could this be a workaround? Simply maximize the window?

Unfortunately, no. Windows Terminal prevents console apps from accessing its window (because its developers believe it is the right thing to do), so we cannot do anything with it.

I think I can come with a workaround to at least not scramble the screen though. 6038.

@alabuzhev
Copy link
Contributor

Is there a way to use the former (Windows 11 21H2) terminal window?

It is somewhere in settings.

@TheChatty
Copy link
Author

Since window size doesn't change with Alt-F9 it would be best to simply ignore this.

@TheChatty
Copy link
Author

TheChatty commented Oct 7, 2022

I found that setting. But what works even better: Change your launching short to
C:\Windows\System32\conhost.exe "C:\Program Files\Far Manager\Far.exe"

Even Alt-F9 is working ;-)

And when I try to paste something... you guess it, it's just there in a blink of an eye.

@alabuzhev
Copy link
Contributor

alabuzhev commented Oct 7, 2022

when I press Ctrl-V I'm asked if I'm sure I want to insert (by Windows) and then the pasting happens real slow...

It can be disabled somewhere in terminal settings too as far as I remember, as well as intercepting of other keys.

@TheChatty
Copy link
Author

TheChatty commented Oct 7, 2022

My suggestion is to ask the user during installation on 22H2 systems whether he wants a console or terminal app. I‘d make the former the default. If you don‘t want to ask make it default right away. 😉

@alabuzhev
Copy link
Contributor

That's an interesting idea.
We might have to do that if the number of various terminal-related bug reports becomes unbearable.

@alabuzhev
Copy link
Contributor

Alt+F9 should work from 6039 onward. Sort of.

@TheChatty
Copy link
Author

With v3.0.6039.2932 pressing Alt-F9 looks the same as pressing Win+ArrowUp - and it works. No more scrambled terminal.

Nevertheless I'll stick with conhost - at least for Far Manager.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants