Google
 

Trailing-Edge - PDP-10 Archives - bb-y390o-bm_tops20_v41_atpch_20 - autopatch/tfrcob.c13
There are 3 other files named tfrcob.c13 in the archive. Click here to see a list.
 REP 22/1	;13C1
	IF1	<PRINTX TFRCOB-20 Version 4(232)>
 WIT
	IF1	<PRINTX TFRCOB-20 Version 4(236)>
 INS 5/2	;13C2
	;BCM	6-Dec-85	[236] Set TOPBOT in .OUP95, for SETATR routines.
	;BCM	26-Nov-85	[235] Make TFRSET/TFRRST set/restore video attributes
	;BCM	26-Nov-85	[234] Correct edit 204, save reg E across call to TTCHK
 REP 32/12	;13C3
	TFREN2:
 WIT

	TFREN2:	PUSH	P,E			;[234] SAVE E FOR LATER
 INS 36/12	;13C4
		POP	P,E			;[234] NOW WE CAN RESTORE E
 INS 138/19	;13C5
	;**;[235] At RSTCOL+5L
		SETZM	V132FG			;[235] Not 132 anymore
 REP 15/68	;13C6
	;**;[221] At TFRSET+3L, insert 7 lines
		SKIPN	V132FG			;[221] ARE WE SUPPOSED TO BE 132 MODE?
		  RET				;[221] NO, RETURN
		MOVE	A,TTJFN			;[221] THEN SET THE TERMINAL
		HRROI	B,[BYTE (7)33,"[","?","3","h",0,0,0,0,0]
		SETZ	C,			;[221]
		SOUT				;[221]
		 ERJMP	.+1			;[221]
 WIT
	;**;[235] At TFRSET+3L
		MOVE	A,TTYPE			;[235] GET REAL TERMINAL TYPE
		CAIGE	A,%VT100		;[235] DO WE HAVE VT100 STYLE TTY?
		 RET				;[235] NO, THEN DONE
		PUSH	P,OPTTTY		;[235] SAVE OPTIMIZER STATE
		MOVEM	A,OPTTTY		;[235] TURN OPTIMIZER OFF
		SKIPN	MLTNMF			;[235] NEED TO RESTORE SCROLL REGION?
		 JRST	SET.1			;[235] NO, SKIP THIS PART
		CALL	$SCESC			;[235] <ESC>
		MOVEI	A,"["			;[235]
		CALL	$SCHAR			;[235]
		MOVE	A,MLTLOR		;[235] GET TOP OF SCROLL REGION
		CALL	$SCNUM			;[235] SEND IT
		CALL	$SCSC			;[235] SEND SEMI-COLON ";"
		MOVE	A,MLTHIR		;[235] GET BOTTOM OF SCROLL REGION
		CALL	$SCNUM			;[235] SEND IT
		MOVEI 	A,"r"			;[235] WRAP UP WITH "r" FOR DECSTBM
		CALL	$SCHAR			;[235]
	SET.1:	SKIPN	B,CHARST		;[235] USING SPECIAL CHR SET?
		 JRST	SET.2			;[235] NO, SKIP THIS PART
		CALL	$SCESC			;[235] <ESC>
		MOVEI	A,"("			;[235] AND A "("
		CALL	$SCHAR			;[235]
		MOVE	A,["B"			;[235] US
			   "A"			;[235] UK
			   "0"			;[235] GRAPHIC
			   "1"](B)		;[235] ALTERNATE
		CALL	$SCHAR			;[235] SEND CHR FOR G0 SET
		HRROI	A,[BYTE (7)ESC,")","0",0] ;[235] ALWAYS SET G1
		CALL	$SASCIZ			;[235] TO GRAPHICS
	SET.2:	HRROI	A,[BYTE (7)ESC,"[","?","5","h",0]
		SKIPE	REVSCR			;[235] REVERSE VIDEO?
		 CALL	$SASCIZ			;[235] YES
		HRROI	A,[BYTE (7)ESC,"[","?","3","h",0]
		SKIPE	V132FG			;[235] 132 COLUMNS?
		 CALL	$SASCIZ			;[235] YES
		CALL	$SEND			;[235] FLUSH IT ALL
		POP	P,OPTTTY		;[235] RESTORE OPTIMIZER
 REP 9/69	;13C7
		CALL	$TTSET			;FIRST SET THE TERMINAL
		CALL	$SEND			;AND FORCE OUT AND ANYTHING
		CALL	$TTRST			;RESET THE TERMINAL CHARACTERISTICS
 WIT
	;**;[235] At TFRRST
		MOVE	A,TTYPE			;[235] GET TERMINAL TYPE
		CAIGE	A,%VT100		;[235] DO WE HAVE VT100 TYPE?
		 JRST	RST.1			;[235] NO, SKIP THIS
		PUSH	P,OPTTTY		;[235] SAVE OPTIMIZER STATE
		MOVEM	A,OPTTTY		;[235] TURN OFF OPTIMIZER
		HRROI	A,[BYTE (7)ESC,"[","1",";","2","4","r",0]
		CALL	$SASCIZ			;[235] CLEAR SCROLLING REGION
		HRROI	A,[BYTE (7)ESC,"(","B",ESC,")","B",ESC,"[","m",0]
		CALL	$SASCIZ			;[235] MAKE CHR SET U.S.
		HRROI	A,[BYTE (7)ESC,"[","?","3","l",0]
		CALL	$SASCIZ			;[235] SET 80 COLUMN MODE
		CALL	$SEND			;[235] FLUSH IT ALL
		POP	P,OPTTTY		;[235] RESTORE OPTIMIZER STATE
	RST.1:	CALL	$TTRST			;RESET THE TERMINAL CHARACTERISTICS
 REP 351/90	;13C8
		MOVEM	C,FLDATR		;   JUST IN CASE IT WAS LEFT OUT.
		CALL	$POSIT
 WIT
	;**;[236] AT .OUP95+6L
		TXNE	D,%OTAL1		;[236] IS IT TOP?
		 SETZM	TOPBOT			;[236] YES
		TXNE	D,%OTAL2		;[236] IT IT BOTTOM?
		 SETOM	TOPBOT			;[236] YES
		MOVEM	C,FLDATR		;   JUST IN CASE IT WAS LEFT OUT.
		CALL	$POSIT
		SETZM	TOPBOT			;[236] CLEAR THE CONDITION
 SUM 4951