NCURSES: Testing if a window has input instead of calling wgetch()
I'd just like to start by saying that ncurses/curses is one of the most finicky libraries I've ever dealt with... Everything has to be just right, or you get some funky results...
I'm learning ncurses and I've run into some trouble...
I have a main loop in my program which is waiting for wgetch(win) to return a value before continuing with the rest of my loop.
Anyway... My question is, does ncurses provide a function to test if a window has a key press waiting rather than wgetch() which waits for a key press?
ch = wgetch(my_window);
/* key handling code here */
/* other stuff I need to do here
* like updating time elapsed at top of screen */
/* yada yada yada */
Or will I have to use timer_create to periodically update everything that can't wait, like timers etc.?
Thanks in advance,