Path: utzoo!attcan!uunet!zephyr.ens.tek.com!uw-beaver!mit-eddie!mintaka!yale!cs.utexas.edu!usc!julius.cs.uiuc.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!hplabs!hpcc05!hpcuhb!hpcllla!hpclisp!defaria@hpclapd.HP.COM From: defaria@hpclapd.HP.COM (Andy DeFaria) Newsgroups: comp.lang.ada Subject: Re: Keyboard input Message-ID: <920031@hpclapd.HP.COM> Date: 21 Sep 90 17:50:08 GMT References: <39@screamer.csee.usf.edu> Organization: Hewlett-Packard Calif. Language Lab Lines: 23 >/ hpclapd:comp.lang.ada / sampson@cod.NOSC.MIL (Charles H. Sampson) / 4:20 pm Sep 20, 1990 / > Lots of operating systems give the programmer the ability to read >individual keystrokes, in addition to reading entire lines. I've always >assumed that the "usual" Ada approach to inputting single characters >(above) was an implementation decision: If the individual keystrokes >are read, the system's line-editing features (backspace, start over, etc.) >are either lost or must be duplicated in the Ada program. If they're >lost, the program becomes very user-unfriendly. For example, if the >user enters "A-backspace-B", more than likely only the "B" appears on >the screen, but the Ada program has seen all three characters and might >even emit an error message about them, which looks like it's complaining >about the "B". Implementors, is my assumption about your decision right? Sure, sure, sure... But what if he Ada programmer, like the initial poster, *WANTS* to do their own single character I/O and handle any editting process, perhaps to provide a different, more friendly or consistent editting process, huh? How does he/she do it? P.S. I hate when people don't answer the question posed P.S.S. I'm also not answering the question but I don't know the answer. Perhaps the solution is to call the OS routine (read or getc) but that isn't Ada or portable.