[Lazarus] read single char from STDIN

Chris Kirkpatrick chris.kirkpatrick at doctors.org.uk
Fri Nov 18 17:18:15 CET 2011


On 18/11/11 13:06, Martin wrote:
> Not done any console apps in a long time.
> If I do:
> var c: char;
>   read(c);
>
> It will read individual files, but only after I pressed enter on my 
> terminal. What is needed to read the char immediately?
>
>
> -- 
> _______________________________________________
> Lazarus mailing list
> Lazarus at lists.lazarus.freepascal.org
> http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
>
It really needs      get(c)  but this function, together with put(c), 
which were defined in Jensen & Wirth and all standard Pascals, has long 
been missing from Turbo Pascal, and all its deriviatives such as Freepascal.

Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20111118/40fcd054/attachment-0003.html>


More information about the Lazarus mailing list