Answers for "c++ turn off cursor"

C++
1

c++ hide cursor

void set_cursor(bool visible){
    CONSOLE_CURSOR_INFO info;
    info.dwSize = 100;
    info.bVisible = visible;
    SetConsoleCursorInfo(GetStdHandle(STD_OUTPUT_HANDLE), &info);
}
Posted by: Guest on October-06-2020
0

How to get cursor position c++

POINT p;
if (GetCursorPos(&p))
{
    //cursor position now in p.x and p.y
}
Posted by: Guest on August-09-2021

Browse Popular Code Answers by Language