INTEGER ITEM(300) INTEGER FORM,LINES0,LASTL0,USAGE0,OPTIO0 COMMON /HELPC0/FORM,LINES0,LASTL0,USAGE0,ITEM,OPTIO0 INTEGER SEARC0,ARG,JUNK INTEGER GETARG,EQUAL,LOOKUP,LOCAT0 INTEGER PAGE INTEGER AAAAA0(3) INTEGER AAAAB0(3) INTEGER AAAAC0(3) INTEGER AAAAD0(3) INTEGER AAAAE0(3) INTEGER AAAAF0(3) INTEGER AAAAG0(3) INTEGER AAAAH0(3) INTEGER AAAAI0(3) INTEGER AAAAJ0(13) INTEGER AAAAK0(8) DATA AAAAA0/173,227,0/ DATA AAAAB0/173,228,0/ DATA AAAAC0/173,230,0/ DATA AAAAD0/173,231,0/ DATA AAAAE0/173,233,0/ DATA AAAAF0/191,170,0/ DATA AAAAG0/173,240,0/ DATA AAAAH0/173,243,0/ DATA AAAAI0/173,245,0/ DATA AAAAJ0/231,229,238,229,242,225,236,160,232,229,236,240,0/ DATA AAAAK0/231,229,238,229,242,225,236,0/ OPTIO0=2 SEARC0=-1 FORM=2 LINES0=0 LASTL0=1 USAGE0=0 ITEM(1)=0 ARG=1 GOTO 10002 10000 ARG=ARG+(1) 10002 IF((GETARG(ARG,ITEM,300).EQ.-1))GOTO 10001 CALL MAPSTR(ITEM,1) IF((EQUAL(ITEM,AAAAA0).NE.1))GOTO 10003 SEARC0=1 GOTO 10004 10003 IF((EQUAL(ITEM,AAAAB0).NE.1))GOTO 10005 OPTIO0=0 GOTO 10006 10005 IF((EQUAL(ITEM,AAAAC0).NE.1))GOTO 10007 SEARC0=4 GOTO 10008 10007 IF((EQUAL(ITEM,AAAAD0).NE.1))GOTO 10009 SEARC0=3 GOTO 10010 10009 IF((EQUAL(ITEM,AAAAE0).NE.1))GOTO 10011 JUNK=LOCAT0(AAAAF0) IF((JUNK.NE.-1))GOTO 10012 CALL SWT 10012 GOTO 10013 10011 IF((EQUAL(ITEM,AAAAG0).NE.1))GOTO 10014 FORM=1 GOTO 10015 10014 IF((EQUAL(ITEM,AAAAH0).NE.1))GOTO 10016 SEARC0=2 GOTO 10017 10016 IF((EQUAL(ITEM,AAAAI0).NE.1))GOTO 10018 USAGE0=1 GOTO 10019 10018 JUNK=LOOKUP(ITEM,SEARC0) IF((JUNK.NE.0))GOTO 10020 CALL PRINT(-15,'Sorry, no help is available fo *r *s*n.',ITEM) GOTO 10021 10020 IF((JUNK.NE.-1))GOTO 10022 CALL SWT 10022 CONTINUE 10021 CONTINUE 10019 CONTINUE 10017 CONTINUE 10015 CONTINUE 10013 CONTINUE 10010 CONTINUE 10008 CONTINUE 10006 CONTINUE 10004 GOTO 10000 10001 IF((ARG.NE.1))GOTO 10023 CALL CTOC(AAAAJ0,ITEM,101) JUNK=LOOKUP(AAAAK0,3) 10023 CALL SWT END INTEGER FUNCTION LOOKUP(ITEM,SEARC0) INTEGER ITEM(1) INTEGER SEARC0 INTEGER LOCAU0,LOCAV0,LOCAT0,LOCAW0 INTEGER AAAAL0 INTEGER AAAAM0 AAAAL0=SEARC0 GOTO 10024 10025 LOOKUP=LOCAU0(ITEM) IF((LOOKUP.NE.0))GOTO 10026 LOOKUP=LOCAV0(ITEM) IF((LOOKUP.NE.0))GOTO 10027 LOOKUP=LOCAW0(ITEM) 10027 CONTINUE 10026 GOTO 10028 10029 LOOKUP=LOCAU0(ITEM) GOTO 10028 10030 LOOKUP=LOCAV0(ITEM) GOTO 10028 10031 LOOKUP=LOCAT0(ITEM) GOTO 10028 10032 LOOKUP=LOCAW0(ITEM) GOTO 10028 10024 AAAAM0=AAAAL0+2 GOTO(10025,10033,10029,10030,10032,10031),AAAAM0 10033 CALL ERROR('in look_up: can''t happen.') 10028 RETURN END INTEGER FUNCTION LOCAU0(ITEM) INTEGER ITEM(1) INTEGER PATH(300) INTEGER FILE INTEGER OPEN,DISPL0 INTEGER AAAAN0(18) INTEGER AAAAO0(18) INTEGER AAAAP0(18) DATA AAAAN0/189,228,239,227,189,175,230,237,225,238,175,243,177,17 *5,166,174,228,0/ DATA AAAAO0/189,228,239,227,189,175,230,237,225,238,175,243,179,17 *5,166,174,228,0/ DATA AAAAP0/189,228,239,227,189,175,230,237,225,238,175,243,181,17 *5,166,174,228,0/ CALL SUBST0(AAAAN0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10034 CALL SUBST0(AAAAO0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10035 CALL SUBST0(AAAAP0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10036 LOCAU0=0 RETURN 10036 CONTINUE 10035 CONTINUE 10034 IF((DISPL0(FILE).NE.-1))GOTO 10037 CALL CLOSE(FILE) LOCAU0=-1 RETURN 10037 CALL CLOSE(FILE) LOCAU0=1 RETURN END INTEGER FUNCTION LOCAV0(ITEM) INTEGER ITEM(1) INTEGER PATH(300) INTEGER FILE INTEGER OPEN,DISPL0 INTEGER AAAAQ0(18) INTEGER AAAAR0(18) INTEGER AAAAS0(18) DATA AAAAQ0/189,228,239,227,189,175,230,237,225,238,175,243,178,17 *5,166,174,228,0/ DATA AAAAR0/189,228,239,227,189,175,230,237,225,238,175,243,180,17 *5,166,174,228,0/ DATA AAAAS0/189,228,239,227,189,175,230,237,225,238,175,243,182,17 *5,166,174,228,0/ CALL SUBST0(AAAAQ0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10038 CALL SUBST0(AAAAR0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10039 CALL SUBST0(AAAAS0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10040 LOCAV0=0 RETURN 10040 CONTINUE 10039 CONTINUE 10038 IF((DISPL0(FILE).NE.-1))GOTO 10041 CALL CLOSE(FILE) LOCAV0=-1 RETURN 10041 CALL CLOSE(FILE) LOCAV0=1 RETURN END INTEGER FUNCTION LOCAW0(ITEM) INTEGER ITEM(1) INTEGER PATH(300) INTEGER FILE INTEGER OPEN,DISPL0 INTEGER AAAAT0(15) DATA AAAAT0/189,228,239,227,189,175,232,229,236,240,175,166,174,22 *8,0/ CALL SUBST0(AAAAT0,ITEM,PATH,300) FILE=OPEN(PATH,1) IF((FILE.NE.-3))GOTO 10042 LOCAW0=0 RETURN 10042 IF((DISPL0(FILE).NE.-1))GOTO 10043 CALL CLOSE(FILE) LOCAW0=-1 RETURN 10043 CALL CLOSE(FILE) LOCAW0=1 RETURN END INTEGER FUNCTION LOCAT0(INDEX0) INTEGER INDEX0(1) INTEGER ITEM(300) INTEGER FORM,LINES0,LASTL0,USAGE0,OPTIO0 COMMON /HELPC0/FORM,LINES0,LASTL0,USAGE0,ITEM,OPTIO0 INTEGER PAT(128),LINE(300),LCLINE(300) INTEGER PPROM0(300),EPPRO0(300),STR(300) INTEGER FILE,PAGE INTEGER OPEN,MAKPAT,MATCH,DISPM0,GETLIN,EQUAL,I,J INTEGER SCRAT0,MKTEMP,RMTEMP INTEGER AAAAU0(26) INTEGER AAAAV0(20) INTEGER AAAAW0(28) INTEGER AAAAX0(20) INTEGER AAAAY0(3) INTEGER AAAAZ0(26) INTEGER AAABA0(26) INTEGER AAABB0(18) INTEGER AAABC0(18) DATA AAAAU0/170,243,186,160,160,233,236,236,173,230,239,242,237,22 *9,228,160,240,225,244,244,229,242,238,170,238,0/ DATA AAAAV0/189,228,239,227,189,175,230,237,225,238,175,227,239,23 *8,244,229,238,244,243,0/ DATA AAAAW0/227,225,238,238,239,244,160,239,240,229,238,160,233,23 *8,228,229,248,160,230,233,236,229,160,170,243,170,238,0/ DATA AAAAX0/189,228,239,227,189,175,230,237,225,238,175,227,239,23 *8,244,229,238,244,243,0/ DATA AAAAY0/191,170,0/ DATA AAAAZ0/232,229,236,240,160,233,238,228,229,248,160,219,170,17 *0,233,171,221,160,237,239,242,229,160,191,160,0/ DATA AAABA0/232,229,236,240,160,233,238,228,229,248,160,219,170,17 *0,233,164,221,160,237,239,242,229,160,191,160,0/ DATA AAABB0/170,243,160,219,170,170,233,171,221,160,237,239,242,22 *9,160,191,160,0/ DATA AAABC0/170,243,160,219,170,170,233,164,221,160,237,239,242,22 *9,160,191,160,0/ LOCAT0=1 IF((MAKPAT(INDEX0,1,0,PAT).NE.-3))GOTO 10044 CALL PRINT(-15,AAAAU0,INDEX0) RETURN 10044 FILE=OPEN(AAAAV0,1) IF((FILE.NE.-3))GOTO 10045 CALL PRINT(-15,AAAAW0,AAAAX0) RETURN 10045 SCRAT0=MKTEMP(3) IF((SCRAT0.NE.-3))GOTO 10046 CALL ERROR('cannot create scratch file for help entry.') 10046 CONTINUE 10047 IF((GETLIN(LINE,FILE,300).EQ.-1))GOTO 10048 CALL SCOPY(LINE,1,LCLINE,1) CALL MAPSTR(LCLINE,1) IF((MATCH(LCLINE,PAT).NE.1))GOTO 10049 IF((DISPM0(LINE,SCRAT0).NE.-3))GOTO 10050 GOTO 10048 10050 CONTINUE 10049 GOTO 10047 10048 CALL CLOSE(FILE) CALL REWIND(SCRAT0) IF((EQUAL(INDEX0,AAAAY0).NE.1))GOTO 10051 CALL ENCODE(PPROM0,101,AAAAZ0) CALL ENCODE(EPPRO0,101,AAABA0) GOTO 10052 10051 I=1 J=1 GOTO 10055 10053 I=I+(1) 10055 IF((INDEX0(I).EQ.0))GOTO 10054 IF((J.GE.300-1))GOTO 10056 STR(J)=INDEX0(I) IF((STR(J).NE.170))GOTO 10057 STR(J+1)=170 J=J+(1) 10057 J=J+(1) 10056 GOTO 10053 10054 STR(J)=0 CALL ENCODE(PPROM0,101,AAABB0,STR) CALL ENCODE(EPPRO0,101,AAABC0,STR) 10052 IF((PAGE(SCRAT0,PPROM0,EPPRO0,23,-11,OPTIO0).NE.-1))GOTO 10058 LOCAT0=-1 10058 IF((RMTEMP(SCRAT0).NE.-3))GOTO 10059 CALL ERROR('cannot close scratch file.') 10059 RETURN END SUBROUTINE SUBST0(TEMPL0,ITEM,RESULT,MAXLEN) INTEGER MAXLEN INTEGER TEMPL0(1),ITEM(1),RESULT(MAXLEN) INTEGER I,J,K I=1 J=1 10060 IF((TEMPL0(I).EQ.0))GOTO 10061 IF((J.GE.MAXLEN))GOTO 10061 IF((TEMPL0(I).EQ.166))GOTO 10062 RESULT(J)=TEMPL0(I) I=I+(1) J=J+(1) GOTO 10063 10062 I=I+(1) K=1 GOTO 10066 10064 K=K+(1) 10066 IF((ITEM(K).EQ.0))GOTO 10065 IF((J.GE.MAXLEN))GOTO 10065 RESULT(J)=ITEM(K) J=J+(1) GOTO 10064 10065 CONTINUE 10063 GOTO 10060 10061 RESULT(J)=0 RETURN END INTEGER FUNCTION DISPL0(FILE) INTEGER FILE INTEGER ITEM(300) INTEGER FORM,LINES0,LASTL0,USAGE0,OPTIO0 COMMON /HELPC0/FORM,LINES0,LASTL0,USAGE0,ITEM,OPTIO0 INTEGER LINE(300),SFUNC0(26),SDESC0(35) INTEGER PPROM0(300),EPPRO0(300),STR(300) INTEGER GETLIN,DISPM0,EQUAL,I,J,PAGE INTEGER SCRAT0,MKTEMP,RMTEMP INTEGER AAABD0(18) INTEGER AAABE0(18) DATA SFUNC0/223,136,198,223,136,245,223,136,238,223,136,227,223,13 *6,244,223,136,233,223,136,239,223,136,238,138,0/ DATA SDESC0/223,136,196,223,136,229,223,136,243,223,136,227,223,13 *6,242,223,136,233,223,136,240,223,136,244,223,136,233,223,136,239, *223,136,238,138,0/ DATA AAABD0/170,243,160,219,170,170,233,171,221,160,237,239,242,22 *9,160,191,160,0/ DATA AAABE0/170,243,160,219,170,170,233,164,221,160,237,239,242,22 *9,160,191,160,0/ IF((USAGE0.NE.0))GOTO 10067 SCRAT0=MKTEMP(3) IF((SCRAT0.NE.-3))GOTO 10068 CALL ERROR('cannot create scratch file for help entry.') 10068 CONTINUE 10067 CONTINUE 10069 IF((GETLIN(LINE,FILE,300).EQ.-1))GOTO 10070 IF((USAGE0.NE.1))GOTO 10071 IF((EQUAL(LINE(13),SFUNC0).EQ.1))GOTO 10073 IF((EQUAL(LINE(13),SDESC0).EQ.1))GOTO 10073 GOTO 10072 10073 GOTO 10070 10072 CONTINUE 10071 IF((USAGE0.NE.1))GOTO 10074 IF((DISPM0(LINE,-11).NE.-3))GOTO 10075 GOTO 10070 10075 GOTO 10076 10074 IF((DISPM0(LINE,SCRAT0).NE.-3))GOTO 10077 GOTO 10070 10077 CONTINUE 10076 GOTO 10069 10070 IF((USAGE0.NE.0))GOTO 10078 CALL REWIND(SCRAT0) I=1 J=1 GOTO 10081 10079 I=I+(1) 10081 IF((ITEM(I).EQ.0))GOTO 10080 IF((J.GE.300-1))GOTO 10082 STR(J)=ITEM(I) IF((STR(J).NE.170))GOTO 10083 STR(J+1)=170 J=J+(1) 10083 J=J+(1) 10082 GOTO 10079 10080 STR(J)=0 CALL ENCODE(PPROM0,101,AAABD0,STR) CALL ENCODE(EPPRO0,101,AAABE0,STR) DISPL0=PAGE(SCRAT0,PPROM0,EPPRO0,23,-11,OPTIO0) IF((RMTEMP(SCRAT0).NE.-3))GOTO 10084 CALL ERROR('cannot close scratch file.') 10084 CONTINUE 10078 RETURN END INTEGER FUNCTION DISPM0(LINE,FD) INTEGER LINE(1) INTEGER FD INTEGER ITEM(300) INTEGER FORM,LINES0,LASTL0,USAGE0,OPTIO0 COMMON /HELPC0/FORM,LINES0,LASTL0,USAGE0,ITEM,OPTIO0 INTEGER I,J IF((FORM.NE.1))GOTO 10085 CALL PUTLIN(LINE,FD) DISPM0=-2 RETURN 10085 IF((LINE(1).NE.138))GOTO 10086 IF((LASTL0.NE.1))GOTO 10087 DISPM0=-2 RETURN 10087 LASTL0=1 GOTO 10088 10086 LASTL0=0 10088 J=1 I=1 GOTO 10091 10089 I=I+(1) 10091 IF((LINE(I).EQ.0))GOTO 10090 IF((LINE(I).NE.136))GOTO 10092 J=J-(1) GOTO 10093 10092 LINE(J)=LINE(I) J=J+(1) 10093 GOTO 10089 10090 LINE(J)=0 I=1 10094 IF((I.GE.13))GOTO 10095 IF((LINE(I).EQ.138))GOTO 10095 IF((LINE(I).EQ.0))GOTO 10095 I=I+(1) GOTO 10094 10095 CALL PUTLIN(LINE(I),FD) LINES0=LINES0+(1) DISPM0=-2 RETURN END C ---- Long Name Map ---- C sdescription sdesc0 C pprompt pprom0 C helpcom helpc0 C locatesub locav0 C displayline dispm0 C locateinx locat0 C indexitem index0 C epprompt eppro0 C display displ0 C usageonly usage0 C searchrule searc0 C locatecmd locau0 C sfunction sfunc0 C substitute subst0 C lastlineblank lastl0 C locategen locaw0 C scratchfd scrat0 C template templ0 C linessofar lines0 C options optio0