reading character

S

Spidey

How can I read a single character from the keyboard without waiting for
the RETURN key?

i know this can be done in windows using interrupt mechanism,

but how we can do the same in linux?
 
C

Chris Dollin

Spidey said:
How can I read a single character from the keyboard without waiting for
the RETURN key?
Non-portably.

i know this can be done in windows using interrupt mechanism,
but how we can do the same in linux?

How about asking in comp.unix.programming? I /think/ the magic word is
"ncurses", but they would /know/.
 
R

Richard Heathfield

Chris Dollin said:
How about asking in comp.unix.programming?

Great idea. When it doesn't work, try comp.unix.programmer instead.
I /think/ the magic word is
"ncurses", but they would /know/.

Your answer is a fine example of why it is better to ask questions in the
most appropriate newsgroup. (In other words, ncurses is probably /not/ what
he needs.)
 
C

Chris Dollin

Richard said:
Chris Dollin said:


Great idea. When it doesn't work, try comp.unix.programmer instead.

Bah. Thanks, Richard. I should start using external memory more.
Your answer is a fine example of why it is better to ask questions in the
most appropriate newsgroup.

Thank you: it wasn't entirely accidental.
 
S

Skarmander

Spidey said:
How can I read a single character from the keyboard without waiting for
the RETURN key?
Your question has already been answered by Richard Heathfield, but for the
purpose of educating third parties: you have asked question 19.1 in the FAQ
(literally, in fact). http://c-faq.com

S.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,770
Messages
2,569,583
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top