Re: char-ready?

From: Chet Murthy <>
Date: Wed, 22 Mar 1995 14:38:59 -0500

> > I had modified it for the next release, but I'm a little bit confused with it
> > . I'm wondering if char-ready? should answer #t as soon as a character is
> > typed or when the user as typed Return (i.e. I'm wondering if char-ready?
> > should set the lin in raw-mode or not).
> Hm. I don't know about reading from the user/current-input-port, but
> it's important for some applications that you be able to read characters
> as they come in--since not all protocols make newlines significant. (I
> guess if you were trying to build a full-screen character-display text
> editor with STk this would be important, too.)
> On the other hand, I have a feeling char-ready? shouldn't assume this.
> I mentioned in a previous message that I'd added support for non-blocking
> input with callbacks, and that I was having `set-port-callback!' turn
> off buffering, but I don't think that's right either. Maybe we need an
> explicit way to turn off line-mode or buffering input on a port.

I would be wary of changing things too much from the UNIX model -- provide
a way to get to the filedescriptor beneath a stream, and a way to do
ioctl's and leave it to the programmer to do the rest, for the moment.

Building too much knowledge of the particularities of UNIX terminal
I/O into STk is a good way of making it difficult to port to PCs.

Received on Wed Mar 22 1995 - 20:40:30 CET

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST