peeking into stdin (programing question)

Inizio della pagina
Allegati:
Messaggio come e-mail
+ (text/plain)
Delete this message
Reply to this message
Autore: John (EBo) David
Data:  
Oggetto: peeking into stdin (programing question)
wrote:
>
> Not sure but try kbhit() returns true if something is waiting.
>
>        if(kbhit())
>              {
>              c=getch();
>              ...
>              }


I looked around and all I could find for kbit was a reference to it
being expected as a define in Borland Builder. From this I'm guessing
that it is a Win*'ism.

ncurses cbreak() is close to what I'm looking for, but it mucked with
the IO and I wanted to avoint that... I was able to get ncurses to work
though. To compare timing diferences I'm going to try the cfmakeraw
now...

??
EBo --