delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2004/03/04/08:00:58

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
From: "Anthony" <akantsel AT integra DOT rmt DOT ru>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: What is portable equivalent of getch()?
Date: Thu, 4 Mar 2004 15:53:21 +0300
Organization: Radio-MSU NOC, Moscow State University
Lines: 20
Message-ID: <c278s4$1n04$1@alpha2.radio-msu.net>
References: <c270na$1jhh$1 AT alpha2 DOT radio-msu DOT net> <40470F8C DOT AA25BECD AT yahoo DOT com>
NNTP-Posting-Host: integra.rmt.ru
X-Trace: alpha2.radio-msu.net 1078404805 56324 81.13.30.150 (4 Mar 2004 12:53:25 GMT)
X-Complaints-To: usenet AT radio-msu DOT net
NNTP-Posting-Date: Thu, 4 Mar 2004 12:53:25 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

"CBFalconer" <cbfalconer AT yahoo DOT com> ???????/???????? ? ???????? ?????????:
news:40470F8C DOT AA25BECD AT yahoo DOT com...
> You can wait for an ENTER (cr) keypress, with something like:
>
>    int flushln(FILE *f)
>    {
>       int ch;
>
>       while ((EOF != (ch = getc(f)) && ('\n' != ch)) continue;
>       return ch;
>    } /* flushln */
>
> which is capable of detecting EOF.
>
Ok, what if I want no echo? I mean, if user press 'a''a''a''cr' I want 'a'-s
not to be printed on the screan?
Thanks.


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019