ggerganov / imtui

ImTui: Immediate Mode Text-based User Interface C++ Library
https://imtui.ggerganov.com
MIT License
2.94k stars 123 forks source link

ncurses example is not working (cannot click on things) #2

Closed WSSDude closed 4 years ago

WSSDude commented 4 years ago

I'm unable to click on anything in ncurses example. It just selects text (even title says that, it changes from <path_to_exe> to Select <path_to_exe>). Right-click or pressing some key resets select mode, but there is no way for me to make example application work unfortunately.

I'm compiling with MSYS2 64-bit with MinGW-w64 64-bit compiler on Windows 10. I had issue with compilation as mentioned in issue #1, maybe it is relevant to this problem in some way.

ggerganov commented 4 years ago

Thanks for the feedback. Currently, I don't have a Windows machine so I cannot test it myself, but my expectation was that it wouldn't work. As far as I understand, ncurses is not supported on Windows. I am pretty new to ncurses and I might be wrong, but I guess since it is POSIX based, it won't work on Windows. Maybe try in cygwin or WSL?

WSSDude commented 4 years ago

Hm, didn't know that tbh. I just downloaded package as said, I don't know what ncurses is/does in details.

I'll try to run it from one of those as you suggested hopefully later this day.

WSSDude commented 4 years ago

It seems to work on WSL Ubuntu. (Sorry to reply late...)

oising commented 4 years ago

@WSSDude -- it won't work in Windows Terminal because they don't support the mouse yet (SGR in virtual terminal mode).

If you open WSL on windows in a regular conhost window (start > run > WSL) it will work on windows 10 that is later than v1809

oising commented 4 years ago

Oh, you might also have to turn off "quick edit" for the console (conhost)