Google
 

Trailing-Edge - PDP-10 Archives - bb-j710b-bm_tops20_v41_tools - tools/sed/sedont.mac
There are 2 other files named sedont.mac in the archive. Click here to see a list.
TITLE	SEDONT - ONTEL TERMINAL DEFINITIONS FOR THE EDITOR
SUBTTL	A CHRISTOPHER HALL FECIT

;THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
;  OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
;
;COPYRIGHT (C) 1981 BY DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.

;LOAD THE EDITOR BY: .LOAD SEDONT,SED

	SEARCH	SEDSYM
IFE TOPS10,<SEARCH MONSYM>

	EXTERN	CPOPJ,PUTTYP,PUTNUM,PUTSTG,PUTSQ1,TRMNAM
	INTERN	TERMNL

TERMNL:	OONTEL	;ADDRESS OF THE TERMINAL TABLE TO USE

OONTEL: BYTE (7) 36		;CURSOR UP
	BYTE (7) 34		; DOWN
	BYTE (7) 35		; RIGHT
	BYTE (7) 10		; LEFT
	BYTE (7) 37		; HOME
	BYTE (7) 4,";",6	;CLEAR PAGE
	BYTE (7) 4,"+",6	;CLEAR LINE
	BYTE (7) 12,6		;ROLL UP AND CLEAR LINE
	BYTE (7) 32,4,"+",6	;ROLL DOWN AND CLEAR LINE
	BYTE (7) 16		;PROTECT ON
	BYTE (7) 17		;PROTECT OFF
	0			;INSERT LINE
	BYTE (7) 4,"5"," ",6	;INSERT SPACE
	0			;DELETE LINE
	BYTE (7) 4,"6",6,6	;DELETE SPACE
	BYTE (7) 37,36		;MOVE TO BOTTOM
	BYTE (7) 37,4,";",6	;HOME AND CLEAR PAGE
	POSCUR			;ROUTINE TO POSITION TO CHARACTER
	POSLIN			;ROUTINE TO POSITION TO START OF LINE
	^D20			;LINES PER PAGE
	^D80			;CHARACTERS PER LINE
	WRP!TBS			;FLAGS (WRAPAROUND, HARD TABS)
	CPOPJ			;ROUTINE TO CALL ON ENTRY
	CPOPJ			;ROUTINE TO CALL ON EXIT
	0,,0			;NO NULLS NEEDED
	IONTEL			;ADDRESS OF TERMINAL INPUT TABLE

		 0			;COMMAND FOR RUBOUT (RESET)
IONTEL: EXP	40, 1, 2, 3, 4, 5, 6, 7 ;RECALL IS A NULL
	EXP	10,11,50,13,14,15,16,17
	EXP	20,21,22,23,24,25,26,27
	EXP	30,31,32,33,34,35,36,37

;MOVE TO ROW (RW), COLUMN (CM)

POSCUR:	MOVE	T1,[BYTE (7) 4,"-"]
	PUSHJ	P,PUTSQ1	;START IT OFF
	MOVE	T1,RW		;GET ROW POSITION
	IDIVI	T1,12
	ADDI	T1,"0"
	IDPB	T1,TY
	MOVEI	T1,"0"(T2)
	IDPB	T1,TY

	MOVE	T1,CM		;GET COLUMN POSITION
	IDIVI	T1,12
	ADDI	T1,"0"
	IDPB	T1,TY
	MOVEI	T1,"0"(T2)
	IDPB	T1,TY
	JRST	POSEND		;DONE

;MOVE TO START OF LINE (T4)

POSLIN:	MOVE	T1,[BYTE (7) 4,"-"]
	PUSHJ	P,PUTSQ1	;START IT OFF
	MOVE	T1,T4		;GET ROW POSITION
	IDIVI	T1,12
	ADDI	T1,"0"
	IDPB	T1,TY
	MOVEI	T1,"0"(T2)
	IDPB	T1,TY
	MOVEI	T1,"0"		;MOVE TO COLUMN ZERO
	IDPB	T1,TY
	IDPB	T1,TY
	JRST	POSEND		;DONE

	END