Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Unsubscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: From: "Lincoln, W. Terry" To: "'Cygwin Mailing List'" Subject: RE: Porting getch() and kbdhit() ??? Date: Wed, 18 Aug 1999 16:39:24 -0400 X-Mailer: Internet Mail Service (5.5.2448.0) I have a M$-C book on my shelf and it says that the function kbhit() should return a 0 if no characters have been struck otherwise the character-code of the struck key (without removing the key from the KB queue). getch() removes a single key from the KB queue (waiting for one if necessary) and returns it character-code without echoing it to the terminal screen. getche() is the same but echoes the character it gets to the screen. W. Terry Lincoln \ \ _ / Senior Engineer \ \ |J| / Ultimate Technology Corporation \ _|E|_ a Tridex Company (NASDAQ:trdx) \ |_ S _| mailto:WTerryLincoln AT engineer DOT com \ |U| http://terrylincoln.isonfire.com \ / |S| \ http://www.AngelFire.com/ny/TerryLincoln \ | | \ ICQ# 39362285 \ | | =========================================== ~~~~~ Opinions expressed do not represent the management of UTC. > -----Original Message----- > From: Mumit Khan [mailto:khan AT xraylith DOT wisc DOT EDU] > Sent: Wednesday, August 18, 1999 2:17 AM > To: cygwin AT sourceware DOT cygnus DOT com > Subject: Re: Porting getch() and kbdhit() ??? > > > Chris Faylor writes: > > Well, that's only partly true. I have no qualms about > including stuff > > that people need in Cygwin. Since these two functions have been > > requested repeatedly, I'd certainly consider applying a > patch which adds > > this functionality to cygwin. > > > > There. I've asked for contributions. That should kill this thread. > > > > How about the following extermely inefficient but portable > POSIX kbdhit > (includes testcase)? > > I have no idea what getch() Philippe is referring to, but probably not > the one that's typically provided by (n)curses. > > ----- cut from here to end. --- snip ---- begin 600 Warren Terry Lincoln (E-mail).vcf M0D5'24XZ5D-!4D0-"E9%4E-)3TXZ,BXQ#0I..DQI;F-O;&X[5V%R