Hello, if I try to compile a cpp file using both conio.h and curses.h in it. If I try to run it with conio.h before curses.h I get an error in the main.cpp.
main.cpp|13|undefined reference to `_imp__stdscr'|
If I put curses first then the conio.h opens in codeblocks and I get an error there.
conio.h|38|error: macro "getch" passed 1 arguments, but takes just 0|
I just really want to use curses.h that's the thing. Then after start learning actual graphics. How could I get getch(); to work with curses? Btw I am trying to compile in Codeblocks with the default compiler but I wouldn't mind using Visual Studio but I don't know how to use C++ with it
as above:
1. Compile on Linux or Mac (or another Unix). Curses is a Unix library.
2. Call initscr() before calling getch()
3. link against libcurses and libtinfo.
It is really not about making getch available though. If you need a non-echoing input, Unix systems have more direct solutions.