I just have a simple question, I cannot find what the key code is for space bar in curses.h. ex. I know the code for down is KEY_DOWN. can anyone help?
There is no macro for the space key. Just use ' ' to represent a space. You can find a complete list of curses key macros here.
Ex.
char mychar = ' ';
if (mychar == ' ') {//Do this...}