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

Mouse does not work in Windows Terminal #332

Closed
pviotti opened this issue Feb 28, 2020 · 15 comments
Closed

Mouse does not work in Windows Terminal #332

pviotti opened this issue Feb 28, 2020 · 15 comments
Labels

Comments

@pviotti
Copy link

pviotti commented Feb 28, 2020

When executing the example projects included in the repo on PowerShell or cmd in the Windows Terminal (this, here is the code) some anomalies happen:

  • mouse is not tracked
  • mouse click on menus does not work
  • the element of the ListView (?) overflow

image

OS: Windows 10 1909
Terminal.Gui version: 0.24.0 (dev)

@BDisp
Copy link
Collaborator

BDisp commented Feb 28, 2020

I already checked and it's a very odd behavior indeed

@odalet
Copy link

odalet commented Feb 29, 2020

Same behavior when running the sample inside WSL inside Windows Terminal:
image

However, the thumb in the vertical scroll bar is correctly rendered (whereas it is not in a standard command prompt):
image

Well, that may be a problem with Consolas (missing support for fallback characters?); once I change my command prompt font from Consolas to Fira Code, everything is fine:
image

@TylerLeonhardt
Copy link

Mouse support isn't supported in Windows Terminal but it's being worked on - confirmed:

https://twitter.com/cinnamon_msft/status/1237253970759782401?s=19

@tig
Copy link
Collaborator

tig commented Mar 11, 2020

@tig
Copy link
Collaborator

tig commented May 21, 2020

Confirmed mouse is still not working in Windows Terminal 1.0 or Windows Terminal (Preview) Version: 1.0.1402.0.

@tig tig changed the title Some anomalies when executing on Windows Terminal Mouse does not work in Windows Terminal May 21, 2020
@BDisp
Copy link
Collaborator

BDisp commented May 21, 2020

This really is a setback.

@tig
Copy link
Collaborator

tig commented Jun 13, 2020

This is the Windows Terminal bug, for clarity: microsoft/terminal#376

@tig tig added the 1.0 label Sep 28, 2020
@tig tig added this to the v1.0 milestone Sep 28, 2020
@tig
Copy link
Collaborator

tig commented Dec 27, 2020

Until this is fixed in Windows Terminal, there's nothing we can do about it.

For now I vote we do NOT make this a ship-blocker for 1.0.

I'm removing the 1.0 label. If you disagree please reply with why.

@tig tig removed the 1.0 label Dec 27, 2020
@tig
Copy link
Collaborator

tig commented Apr 16, 2021

New info:

microsoft/terminal#376 (comment)

Supposedly if we use VT-Style mouse support this will work today.

Are we using VT-Style or Win32? (I will try to look later today)

@BDisp
Copy link
Collaborator

BDisp commented Apr 16, 2021

Are we using VT-Style or Win32? (I will try to look later today)

Yes, in the NetDriver.

@tig
Copy link
Collaborator

tig commented Apr 16, 2021

Woot. I just did UICatalog -usc and mouse works in Windows Terminal 1.7+.

However netDriver is SO. DAMN. SLOW.

I wonder if it's possible to modify WindowsDriver to use VT-style mouse support while still using the console APIs for everything else?

@BDisp
Copy link
Collaborator

BDisp commented Apr 16, 2021

However netDriver is SO. DAMN. SLOW.

Yes, unfortunately.

I wonder if it's possible to modify WindowsDriver to use VT-style mouse support while still using the console APIs for everything else?

Yes, maybe it's a possibility.

@tig tig removed this from the v1.0 milestone Apr 28, 2021
@tig
Copy link
Collaborator

tig commented May 27, 2021

As of Windows Terminal Preview 1.9, the mouse works with WindowsDriver!

It has some minor issues (double click seems too sensitive). But separate issues should be opened for those.

Closing this.

@tig tig closed this as completed May 27, 2021
@BDisp
Copy link
Collaborator

BDisp commented May 27, 2021

I saw that's working yesterday, but not mouse movement. I hope they fix that too.

@BDisp
Copy link
Collaborator

BDisp commented May 27, 2021

Also the Enter key doesn't' work in the NetDriver, because they aren't exposing the Key property, from ConsoleKeyInfo. So, Key = 0 instead of "Enter". So, reading from KeyChar = 13 '\r', is interpreted as Ctrl+M.

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

No branches or pull requests

5 participants