! 30 Jan 91 tv950, ib3101
! 19 Nov 90 wyse60,pcterm
! 11 Jun 89
! term.cmd 
!
PROC statconf
	set echo off
	status
ENDPROC statconf

PROC editconf
	set echo off
	setvar width 79			! wopen width
	setvar flen 59			! max at read field width
	wclose 1,0
	wopen 1,4,0,20,$(width),-1,-1,0,0
	wselect 0
	if _1 = ''
		at 4,11 "Editing current configuration"
	else
		at 4,11 "Editing configuration file '"+_1+"'"
	endif
	at 23,20 "F1 or \^E to Accept, [ESC] to abort"
	wselect 1
	at clear
	at 1,10 "Remark " 	get _cremark len $(flen)
	at 2, 4	"Phone Number "	get _cnumber len $(flen)
	at 3, 7	"Baud rate "	get _cbaud list "115200","57600","38400","19200","9600","4800","2400","1200","600","300","110"
	at 4,10	"Parity "	get _cparity list "NONE","EVEN","ODD","MARK","SPACE"
	at 5, 5	"Word length "	get _cwordlen list "8","7","6","5"
	at 6, 7	"Stop bits "	get _cstopbits list "1","2"
	at 7, 3	"Terminal Mode " get _cmode list "FULL","HALF","TALK","DUMP","MNEMONIC","CONTROL"
	at 8, 7	"Emulation "	get _cemulate list "VT100","VT102","VT220-7","VT220-8","SCOANSI","TV912","TV925","TV950","WYSE50","WYSE60","ANSI","TTY","VT52","ADM1","IB3101","PCTERM"
	at 9, 3 "Xfer Protocol " get _cxprot list "TERMCRC","WTERMCRC","ZMODEM","KERMIT","MODEM7","XMODEM","YMODEM","TERM5","OLDTERM"
	at 10, 4 "Capture Mode " get _cprotocol list "ASCII","BINARY"
	at 11, 4 "Capture File " get _ccaptfile len $(flen)
	at 12, 6 "Auto Login "	get _clogin len $(flen)
	at 13, 5 "Auto Logout "	get _clogout len $(flen)
	at 14, 4 "Start Server " get _cstartsrv len $(flen)
	at 15, 5 "Stop Server "	get _cstopsrv len $(flen)
	at 16, 4 "Auto Cmdfile " get _ccmdfile len $(flen)
	at 17, 2 "WRU Answerback " get _cwru len $(flen)
	at read
	wselect 0
	wclose 1
	if _retval != 0
		return 512		! don't setconfig
	endif
	return 0			! do setconfig
ENDPROC editconf
