From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=BAYES_00,INVALID_DATE autolearn=no autolearn_force=no version=3.4.4 Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!att!tut.cis.ohio-state.edu!ucbvax!EAST.Pima.edu!RHARWOOD From: RHARWOOD@EAST.Pima.edu (Ray Harwood) Newsgroups: comp.lang.ada Subject: GetACharacter(KeyPressed) Message-ID: Date: 23 Nov 90 20:44:00 GMT Sender: usenet@ucbvax.BERKELEY.EDU Organization: The Internet List-Id: In Info-Ada #207, Arne Gehlhaar asks about "reading characters without pressing a return." I'd like to make a few observations that might help this specific question, and the understanding of Ada in general: 1) The Ada package TEXT_IO merely presents PROCEDURES and FUNCTIONS (okay, maybe some types, too!). It strikes me a little odd that Arne says "there is no Ada COMMAND that allows me...". There is quite a difference between the actual Ada LANGUAGE syntax (while-loop, for-loop, case statement, etc) and the available "routines" provided with any ONE particular compiler. 2) From it's Pascal heritage, keyboard-oriented IO relies heavily on the operating system (or some intermediary) to give the user a line editing capability prior to actually "sending" a line of input to the program. Any attempt to get(x) in Ada (or READ or READLN in Pascal) basically halts program execution until a carriage return is entered. I'd suggest using package sequential_io, using a CHARACTER as the "item type" being read... sequential_io and direct_io are typically (!) NOT buffered. Ray Harwood, Data Basix PO Box 18324 Tucson, AZ 85731 AppleLink: DATA.BASIX CompuServe: 76645,1370 Phone: (602)721-1988 FAX: (602)721-7240 Associate Faculty, Pima Community College