I have the following code:
#include <ncurses.h>
#include <string.h>
int
main()
{
int ch;
initscr();
noecho();
cbreak();
refresh();
while(1)
{
ch = getch();
addch(ch);
};
return 0;
}
It should output something on the screen when the mouse buttons are pressed but it doesn't.
I tried the tips that fixed Mouse movement events in NCurses with no success.
Also when I run htop in the same terminal mouse clicks works. And htop doesn't seem to do anything different, do they? https://github.com/hishamhm/htop/search?q=MOUSE&ref=cmdform