[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference turris::languages

Title:Languages
Notice:Speaking In Tongues
Moderator:TLE::TOKLAS::FELDMAN
Created:Sat Jan 25 1986
Last Modified:Wed May 21 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:394
Total number of notes:2683

23.0. "cursor control and HLL" by MKT782::PETERSON () Thu Aug 16 1984 15:55

	How can one use the arrow keys on a VT100 or LK201 keyboard to move the
cursor under VMS Pascal?  It appears to be relatively straight forward using
QIOs but I'd like not to be machine dependent (Other than the terminal, of
course!).  I suspect that, if it is possible, it will be through some
manipulation of VT100 control characters, but everything I've tried gets munged
by the compiler. 

	Help!

\mtp\


T.RTitleUserPersonal
Name
DateLines
23.1ORPHAN::BRETTMon Aug 20 1984 10:0320
I really don't understand how you can be having difficulty here - or how
you can possibly expect to be machine independent!


There are two distinct issues.


	(1) Reading non-text, non-terminated input from the terminal.
		No-echo almost certainly required.

	(2) Writing non-CRLF terminated output to the terminal.


The ONLY reasonable solution is with a screen management package, either as
found in the RTL or written by you.   This package then has to be ported to
the new h/w.


/Bevin
23.2REX::MINOWTue Aug 21 1984 16:4725
Unfortunately, there are several distinct issues here.  First, I don't
believe the VMS screen management package knows how to READ keys
from the keyboard.  Second, the problems Bevin brings up are shared
by a number of software products, some of which, like DECtalk, don't
have screens.

I wrote a DECtalk support library which has a small number of
system-independent I/O routines (open, close, read/write characters,
trap CTRL/C) which works on rsx, rsts, vms compatibility, vms native,
and several flavors of Unix.  The code is reasonably efficient
on these systems -- it tries to avoid doing one QIO per input byte.

Included in this package is a parser for Ansi-standard escape
sequences.

If you can call VMS SYS$ functions from Pascal, you should be
able to rewrite relevant parts of the library to suit your needs.
You would do all reads using the escape-sequence parser -- it
returns either a single character or a fully-parsed escape sequence.
You can also call the putsequence routine to convert a parsed
sequence to a character string for output to the terminal.

All source code is stored on REX::SYS$SYSDEVICE:[DTLIB.SOURCE].

Martin.
23.3CHEERS::GOGUENFri Sep 07 1984 12:034
KOALA (see note 11) will READ keys from the keyboard very easily.  I've written
many applications which uses non-terminated input...

- Don
23.4KOALA::ROBINSMon Sep 10 1984 12:363
Koala also has code generators for vax/pdp/rainbow.  Maybe more.

sar
23.5LATOUR::AMARTINTue Sep 11 1984 09:292
PDP-10?
				/AHM/THX