[net.micro.amiga] VT100 cursor keys

mjp@spice.cs.cmu.edu (Michael Portuesi) (10/21/86)

Keywords:

> Description:
> Cursor keys send wrong sequence when the keypad is in application mode
> 
> Suggested Fix:
> in window.c, remove the checking for 'keyapp' in the cursor key code.
> always send the sequence currently in the 'else' logic.

A real VT100 has two distinct application modes, Keypad Application
Mode and Cursor Key Mode.  Keypad Application mode applies only to
the keypad; Cursor Key Mode applies only to the cursor keys.  Thus
the suggested fix above is correct.  One should not tamper with the
cursor keys when Keypad Application Mode is selected.  From the VT100
User Guide:

Cursor Key	VT52	ANSI Mode and Cursor	ANSI Mode and Cursor
(Arrow)		Mode	Key Mode Reset		Key Mode Set
------------------------------------------------------------------------
Up		ESC A	ESC [ A			ESC O A
Down		ESC B	ESC [ B			ESC O B
Left		ESC C	ESC [ C			ESC O C
Right		ESC D	ESC [ D			ESC O D

The following control sequences enter/exit Cursor Key Mode and Keypad
Application Mode:

Name			Set			Reset
------------------------------------------------------------------------
Cursor Key Mode		ESC [ ? 1 h		ESC [ ? 1 l
Keypad Application Mode ESC =			ESC >

> Michael Wagner (wagner@utcs)
-- 

+----------------------------------------------------------------------------+
| Mike Portuesi								     |
| Carnegie-Mellon University Computer Science Department		     |
|									     |
| ARPA: mjp@spice.cs.cmu.edu						     |
| UUCP: {harvard | seismo | ucbvax | decwrl}!spice.cs.cmu.edu!mjp	     |
|									     |
| "Talking about music is like dancing about architecture"		     |
|			--Laurie Anderson, "Home of the Brave"		     |
+----------------------------------------------------------------------------+