/* SCHELP.C Driver for screen help */ /* */ /* 15-AUG-1985 16:31 removed from orig schelp.c to allow */ /* overlaying of the help subsystem in PDP-11 TED. */ /* */ /* Copyright Notice */ /* */ /* */ /* C version Copyright (C) 1984 Change Software, Inc. */ /* Copyright (C) 1978 1979 1980 1981 1982 1983 1984 1985 */ /* Change Software, Inc. */ /* */ /* */ /* This software is furnished under a license and may */ /* be used and copied only in accordance with the */ /* terms of such license and with the inclusion of */ /* the above copyright notice. This software or any */ /* other copies thereof may not be provided or other- */ /* wise made available to any other person. No title */ /* to and ownership of the software is hereby trans- */ /* ferred. */ /* */ #include "sysdef.h" static char *vthelpfile[] = { "" , "TEDANSI" , "TEDVT100" , "TEDVT220" , "" } ; static char buffer[512] ; static char notopic[] = "" ; static char nulltopic[] = "\01" ; static char vtmenu[] = "vtm" ; #define then #define VTOPEN 1 #define TEDOPEN 2 schelp() { int status ; extern int termtype,hlpopen,hlpctx[] ; extern char *hlbuffer ; extern char *gettopic() ; register char *topic ; hlbuffer = &buffer ; hlpctx[0] = 0 ; if ( hlpopen != VTOPEN ) then if ( (status=opnhlp(vthelpfile[termtype]))==0 ) then { tederror("Can't open editor help file") ; prsys_error() ; suspend(1) ; hlpopen = 0 ; return(0) ; } hlpopen = VTOPEN ; dspmenu() ; topic = ¬opic ; while ( *topic != *nulltopic ) { if ( *(topic=gettopic(VTOPEN)) != *nulltopic ) then if ( *topic == *notopic ) then { putbin("Help not found for that topic",0); suspend(2) ; } else dsptopic(topic) ; } return(1) ; } dspmenu() { sclear() ; dsptopic(vtmenu) ; }