IDENTIFICATION DIVISION. PROGRAM-ID. SCREENCTL_HELP. ENVIRONMENT DIVISION. DATA DIVISION. WORKING-STORAGE SECTION. 77 J PIC 999. 01 TOPIC PIC X(9). 01. 02 FUNC-TABLE. 05 PIC X(234) VALUE "BBIG BBOX BEEP - "BIG BLACK BLINK BOLD BOTTOM BOX BPOS BRIGHT - " BRPOS CLEAR CLED CREATE CURSOR FPOS GETAR - " GETCMN GETFUNC GETPF GPOS HLINE JUSTIFY LINE - " LED ". 05 PIC X(162) VALUE "LPOS MORE - "PAUSE PDINQ POS PUTCMN RPOS SCRAM SCROLL - " SPOS SQUEEZE TOP UNBOX UNDERLINEUNSQUEEZE - "VLINE WHITE WINDOW ". 05 PIC X(50) VALUE SPACES. 02 FUNCTIONS REDEFINES FUNC-TABLE OCCURS 47 TIMES PIC X(9). PROCEDURE DIVISION. 0. DISPLAY "#6 S C R E E N C T L - " H E L P". PERFORM DRAW-BOX. DISPLAY "You can get help on all the functions performed by - " SCREENCTL by". DISPLAY "entering the function name at the prompt below.". DISPLAY "". PERFORM VARYING J FROM 1 BY 7 UNTIL J > 49 DISPLAY "" FUNCTIONS (J) " " FUNCTIONS (J + 1) " " FUNCTIONS (J + 2) " " FUNCTIONS (J + 3) " " FUNCTIONS (J + 4) " " FUNCTIONS (J + 5) " " FUNCTIONS (J + 6) END-PERFORM. 1. DISPLAY "Enter Function name, MENU or to Exit: - " " NO ADVANCING. ACCEPT TOPIC BOLD AT END DISPLAY "", GO TO 2. INSPECT TOPIC CONVERTING "abcdefghijklmnopqrstuvwxyz" TO "ABCDEFGHIJKLMNOPQRSTUVWXYZ". IF TOPIC(1:1) = "" DISPLAY "" GO TO 2. IF TOPIC = "MENU" GO TO 0. PERFORM DRAW-BOX. DISPLAY "" TOPIC(1:1) " " TOPIC(2:1) " " TOPIC(3:1) " " TOPIC(4:1) " " TOPIC(5:1) " " TOPIC(6:1) " " TOPIC(7:1) " " TOPIC(8:1) " " TOPIC(9:1). IF TOPIC = "BBIG" DISPLAY "Function Syntax: BBIG l c ""t-e-x-t"" - " {/CLEAR}" DISPLAY "Position the cursor on line l Column c and - " display the" DISPLAY "text string inside the quotes in large BOLD - " characters.". IF TOPIC = "BIG" DISPLAY "Function Syntax: BIG l c ""t-e-x-t"" - " {/CLEAR}" DISPLAY "Position the cursor on line l Column c and - " display the" DISPLAY "text string inside the quotes in large characters.". IF TOPIC = "SCRAM" DISPLAY "Function Syntax: SCRAM l c ""t-e-x-t"" - " {/CLEAR}" DISPLAY "Position the cursor on line l Column c and - " display the" DISPLAY "text string inside the quotes in large characters." DISPLAY """t-e-x-t"" will be built in a random order.". IF TOPIC = "BEEP" DISPLAY "Function Syntax: BEEP x" DISPLAY "Cause the terminal bell to ring." DISPLAY "Where;" DISPLAY "x = # of times the bell is to ring." DISPLAY " If omitted, the terminal bell will ring once.". IF TOPIC = "MORE" DISPLAY "Function Syntax: MORE" DISPLAY "Display ""Press to Continue..."" on - " line 24 of the" DISPLAY "terminal and wait for the user to press the return - " key.". IF TOPIC = "BLACK" DISPLAY "Function Syntax: BLACK" DISPLAY "Set the terminal screen with dark background" DISPLAY "and light characters.". IF TOPIC = "WHITE" DISPLAY "Function Syntax: WHITE" DISPLAY "Set the terminal screen with light - " background" DISPLAY "and dark characters.". IF TOPIC = "CLED" OR "LED0" DISPLAY "Function Syntax: CLED or LED0 or LED 0" DISPLAY "Turn off all ""LEDs"" on a VT100 type - " Keyboard.". IF TOPIC = "BOX" DISPLAY "Function Syntax: BOX l c w d {l c w d} - " {l c w d}" DISPLAY "Draw a BOX on the screen.". IF TOPIC = "BBOX" DISPLAY "Function Syntax: BBOX l c w d {l c w d} - " {l c w d}" DISPLAY "Draw a BOX on the screen with BRIGHT - " lines.". IF TOPIC = "BOX" OR "BBOX" DISPLAY "Where;" DISPLAY "l = Screen line number to start Box drawing." DISPLAY "c = Column on line l to start Box drawing." DISPLAY "w = # of columns wide the Box will be." DISPLAY "d = # of lines to be inside of the Box." DISPLAY "A max. of 3 Boxes can be drawn with this - " command" DISPLAY "at one time." IF TOPIC = "BBOX" DISPLAY "" END-IF DISPLAY "(0lqqqqqqqqqqqqqk" DISPLAY "x x" DISPLAY "x x" DISPLAY "x x" DISPLAY "x x" DISPLAY "mqqqqqqqqqqqqqj(B". IF TOPIC = "BOTTOM" DISPLAY "Function Syntax: BOTTOM" DISPLAY "Draw a horizontal line at the bottom of the - " screen.". IF TOPIC = "TOP" DISPLAY "Function Syntax: TOP" DISPLAY "Position cursor in top left cornor of - " screen.(HOME)". IF TOPIC = "LED" DISPLAY "Function Syntax: LED x or LEDx" DISPLAY "Turn on or off ""LEDs"" on a VT100 type - " terminal." DISPLAY "Where;" DISPLAY "x = Value 0 will trun off all ""LEDs""." DISPLAY "x = Same as ""CLED"" function." DISPLAY "x = Value 1 thru 4, will turn on the" DISPLAY " corresponding ""LED""." DISPLAY "x = Value 5 will turn on all ""LEDs"".". IF TOPIC = "LINE" OR "LPOS" DISPLAY "Function Syntax: LINE l {Clear} or LPOS l - " {Clear}" DISPLAY "Position Cursor on line a given line." DISPLAY "Where;" DISPLAY "l = Line that cursor is to be positioned." DISPLAY "{} = Optional to clear line after cursor - " positioning.". IF TOPIC = "CREATE" DISPLAY "Function Syntax: CREATE" DISPLAY "Define global symbols to execute the - " functions" DISPLAY "performed by SCREENCTL." DISPLAY "Enter following command at the DCL prompt - " or as" DISPLAY "part of a LOGIN.COM." DISPLAY "$ MCR disk:[dir]SCREENCTL CREATE" DISPLAY "Where;" DISPLAY "disk = Disk that SCREENCTL.EXE is located on." DISPLAY "dir = Dir. in which SCREENCTL.EXE is located.". IF TOPIC = "PAUSE" DISPLAY "Function Syntax: PAUSE x" DISPLAY "Halt procedure execution for given number - " of seconds." DISPLAY "Where;" DISPLAY "x = Time value to wait for." DISPLAY " If omitted default of 4 seconds will be used." DISPLAY " /UNTIL=hh:mm Halt execution until the specified" DISPLAY " time of day is reached.". IF TOPIC = "CURSOR" DISPLAY "Function Syntax: CURSOR p1 p2 p3" DISPLAY "Move cursor & display text, or" DISPLAY "Turn terminal cursor OFF or ON." DISPLAY "Where;" DISPLAY "p1 = Direction to move cursor ""U"" ""D"" ""R"" - " ""L""" DISPLAY " ""ON"" or ""OFF"" to turn terminal cursor on - " or off" DISPLAY "p2 = # of positions to move in given direction." DISPLAY "p3 = Text to be displayed after positioning." DISPLAY " text should be places in double quotes. """"". IF TOPIC = "SCROLL" DISPLAY "Function Syntax: SCROLL p1 p2 {p3}" DISPLAY "Set a scrolling region on the screen." DISPLAY "or set terminal for SMOTH or JUMP scroll rate." DISPLAY "Where;" DISPLAY "p1 = 1st line of scroll region." DISPLAY " or ""JUMP"" or ""SMOOTH"" to set rate." DISPLAY "p2 = last line of scroll region." DISPLAY "If omitted scroll area will be the center p1" DISPLAY "lines of the screen." DISPLAY "p3 = IF Smooth, lines will scroll smoothly at 6" DISPLAY "lines per second." DISPLAY "If Jump, lines will jump instantaneously." DISPLAY "If not specified, current terminal scrolling" DISPLAY "mode is used.". IF TOPIC = "HLINE" DISPLAY "Function Syntax: HLINE p1 p2 p3" DISPLAY "Draw a Horizontal line on the screen." DISPLAY "Where;" DISPLAY "p1 = Screen line to draw line on." DISPLAY "p2 = Column to start line." DISPLAY "p3 = # of column long the line is to be.". IF TOPIC = "VLINE" DISPLAY "Function Syntax: VLINE p1 p2 p3" DISPLAY "Draw a Vertical line on the screen." DISPLAY "Where;" DISPLAY "p1 = Screen line to start line." DISPLAY "p2 = Column to start line." DISPLAY "p3 = # of lines long the line is to go down.". IF TOPIC = "PUTCMN" DISPLAY "Function Syntax: PUTCMN ""p1""" DISPLAY "Place data into process common area." DISPLAY "Up to 250 characters can be stored in common area." DISPLAY "Where;" DISPLAY "p1 = Quoted string to be stored in common area.". IF TOPIC = "GETCMN" DISPLAY "Function Syntax: GETCMN p1 {p2}" DISPLAY "Retrieve data from process common area." DISPLAY "Up to 250 characters can be stored in common area." DISPLAY "Where;" DISPLAY "p1 = Symbol where data from common area is to" DISPLAY " be stored." DISPLAY "p2 = Optional parameter value of /GLOBAL can be" DISPLAY " used to create p1 as a Global symbol instead" DISPLAY " of a local symbol.". IF TOPIC = "UNSQUEEZE" DISPLAY "Function Syntax: UNSQUEEZE" DISPLAY "Cancel ""SQUEEZE"" function & set screen to" DISPLAY "full scroll.". IF TOPIC = "UNDERLINE" DISPLAY "Function Syntax: UNDERLINE p1 p2 ""p3""" DISPLAY "Position cursor and display text in - " underlined video.". IF TOPIC = "RPOS" DISPLAY "Function Syntax: RPOS p1 p2 ""p3""" DISPLAY "Position cursor and display text in - " Reverse video.". IF TOPIC = "BRPOS" OR "BOLD" DISPLAY "Function Syntax: BRPOS p1 p2 ""p3"" - " or BOLD p1 p2 ""p3""" DISPLAY "Position cursor and display text in - "  Bold video.". IF TOPIC = "BPOS" DISPLAY "Function Syntax: BPOS p1 p2 ""p3""" DISPLAY "Position cursor and display text and ring" DISPLAY "the terminal bell.". IF TOPIC = "POS" DISPLAY "Function Syntax: POS p1 p2 ""p3""" DISPLAY "Position cursor and display text.". IF TOPIC = "FPOS" OR "BLINK" DISPLAY "Function Syntax: FPOS p1 p2 ""p3"" - " or BLINK p1 p2 ""p3""" DISPLAY "Position cursor and display text in - " flashing video.". IF TOPIC = "GPOS" OR "SPOS" DISPLAY "Function Syntax: GPOS p1 p2 ""p3"" - " or SPOS p1 p2 ""p3""" DISPLAY "Position cursor and display special - " graphic character.". IF TOPIC = "POS" OR "BPOS" OR "FPOS" OR "GPOS" OR "BOLD" OR = "BRPOS" OR "BLINK" OR "RPOS" OR "SPOS" OR "UNDERLINE" DISPLAY "Where;" DISPLAY "p1 = Line where text is to be displayed." DISPLAY "p2 = Starting column where text is to be displayed.". IF TOPIC = "POS" OR "BPOS" OR "FPOS" OR "BOLD" OR "BRPOS" OR "BLINK" OR "RPOS" OR "UNDERLINE" DISPLAY "p3 = Quoted string to be displayed." DISPLAY " /CLEAR Will clear the line before displaying - " p3." DISPLAY "/DOUBLE Quoted string will be D O U B L E S P A C - " E D" DISPLAY "on the line." DISPLAY "/STEP String will be displayed 1 character at a - " time" DISPLAY "acorss." DISPLAY "/WIDE p3 will be displayed in double width Charact - "ers." DISPLAY "Place all ""/"" options after p3.". IF TOPIC = "GPOS" OR "SPOS" DISPLAY "p3 = Quoted character for graphic symbol to display.". IF TOPIC = "BRIGHT" DISPLAY "Function Syntax: UNDERLINE p1 p2 ""p3""" DISPLAY "Turn on BOLD video." DISPLAY "Screen displays following this command will all be" DISPLAY "in BOLD video.". ** IF TOPIC = "GETAR" DISPLAY "Function Syntax: GETAR {p1} {p2} p3" DISPLAY "Position cursor and wait for one of the - " four arrow keys to" DISPLAY "be pressed.". IF TOPIC = "GETPF" DISPLAY "Function Syntax: GETPF {p1} {p2} p3" DISPLAY "Position cursor and wait for one of the - " four ""PF"" keys to" DISPLAY "be pressed.". IF TOPIC = "GETFUNC" DISPLAY "Function Syntax: GETFUNC {p1} {p2} p3" DISPLAY "Position cursor and wait for one of the - " four arrow or" DISPLAY """PF"" keys or any of the VT220 function keys or a - " keypad" DISPLAY "key to be pressed.". IF TOPIC = "GETAR" OR "GETPF" OR "GETFUNC" DISPLAY "Where;" DISPLAY "p1 = Line on which to place cursor." DISPLAY "p2 = Column at which to place cursor." DISPLAY " If p1 & p2 are omitted, cursor is put to next" DISPLAY " line for input." DISPLAY "p3 = Local symbol to receive value of key pressed.". IF TOPIC = "UNBOX" DISPLAY "Function Syntax: UNBOX l c w d {l c w d} - " {l c w d}" DISPLAY "Remove a previouly drawn box using the ""BOX - """ or ""BBOX""" DISPLAY "commands." DISPLAY "Where;" DISPLAY "l = Start line where box is to be removed." DISPLAY "c = Start column where box is to be removed." DISPLAY "w = # of columns wide of box to be removed." DISPLAY "d = # of lines deep of box to be removed." DISPLAY "A max. of 3 Boxes can be removed with this - " command" DISPLAY "at one time.". IF TOPIC(1:4) = "JUST" DISPLAY "Function Syntax: JUSTIFY p1 p2 ""p3""" DISPLAY "Position cursor on given line and display - " text justified" DISPLAY "according to option supplied." DISPLAY "Where;" DISPLAY "p1 = Line on which text is to be displayed." DISPLAY "p2 = Justify option." DISPLAY " Value of ""Right"" or ""Left"" or ""Center""." DISPLAY "p3 = Quote text to be displayed." DISPLAY "Local symbol ""LAST_COL"" is created which - " contains the" DISPLAY "column number where p3 was started.". IF TOPIC = "WINDOW" DISPLAY "Function Syntax: WINDOW p1 p2 p3 p4 p5 p6" DISPLAY "Draw a box with optional Horizontal and - " vertical lines" DISPLAY "within it." DISPLAY "Where;" DISPLAY "p1 = Screen line number to start Box drawing." DISPLAY "p2 = Column on line l to start Box drawing." DISPLAY "p3 = # of columns wide the Box will be." DISPLAY "p4 = # of lines to be inside of the Box." DISPLAY "p5 = Line to draw optional horizontal line." DISPLAY " More then 1 line seperate each with a comma." DISPLAY "p6 = Column to draw optional vertical line." DISPLAY " More then 1 line seperate each with a comma." DISPLAY "To draw a vertical line without drawing a horiztal - " line," DISPLAY "specify p5 as 0." DISPLAY "(0lqqqqqqwqqqqqqk" DISPLAY "x x x" DISPLAY "x x x" DISPLAY "tqqqqqqnqqqqqqu" DISPLAY "x x x" DISPLAY "mqqqqqqvqqqqqqj(B". IF TOPIC = "SQUEEZE" DISPLAY "Function Syntax: SQUEEZE p1 p2 {p3} {p4}" DISPLAY "Set a scrolling region on the screen with a - "n upper and" DISPLAY "lower border." DISPLAY "Where;" DISPLAY "p1 = 1st line of scroll region." DISPLAY "p2 = last line of scroll region." DISPLAY "p3 = Optional character to use as the border." DISPLAY " If p1 & p2 are omitted, SQUEEZE area will be" DISPLAY " the p3 line in the centre of the screen." DISPLAY "p4 = Optional border character used if p1 and p2" DISPLAY " are omitted.". IF TOPIC(1:2) = "CL" AND TOPIC(1:4) NOT = "CLED" DISPLAY "Function Syntax: CLEAR p1 {p2}" DISPLAY "Clear part or all of the terminal screen." DISPLAY "Where;" DISPLAY "p1 = 1st line of area to be cleared. or" DISPLAY " SCREEN or omitted, will clear the whole screen." DISPLAY " LINE will clear line in p2." DISPLAY " TOP Clear the top portion of the screen." DISPLAY "or top portion starting at line p2." DISPLAY " BOTTOM Clear bottom portion of the screen." DISPLAY "or bottom portion starting at line p2." DISPLAY "HOLD Clear screen and not home cursor." DISPLAY "SCROLL Clear scrolling region only." DISPLAY "p2 = last line of area to be cleared or" DISPLAY " Value used if p1 = ""LINE"",""TOP"", - " ""BOTTOM""". IF TOPIC = "PDINQ" DISPLAY "Function Syntax: PDINQ p1 p2 p3 {""p4""} {p5}" DISPLAY "Position cursor, Display text and get input - " from terminal" DISPLAY "and store it in symbol supplied." DISPLAY "Where; p1 = Line to position cursor on." DISPLAY "p2 = Column to position cursor in." DISPLAY "p3 = Local symbol to receive input from terminal." DISPLAY "p4 = Optional quoted text to display before input" DISPLAY " is accepted from terminal." DISPLAY "p5 = /MARK Display checkerboard (0a(B - " at end of prompt." DISPLAY " /SIZE # of characters to be accepted for input." DISPLAY " /GLOBAL make symbol supplied Global not Local." DISPLAY " /TIME=mm:ss Set time limit before input request" DISPLAY " is terminated." DISPLAY " /UPPER Convert all input to UPPER CASE." DISPLAY " /NOECHO Don't echo input on terminal.". *Display "Symbol Not Created" message. IF TOPIC = "GETCMN" OR "PUTCMN" OR "LED" OR "CLED" DISPLAY "This Symbol is NOT defined during the - " CREATE routine" DISPLAY "of SCREENCTL. But is a recognized command.". *Display "TEXT Will Be Centered" Message IF TOPIC = "BBIG" OR "BIG" OR "SCRAM" DISPLAY "Where;" DISPLAY "l = Line where t-e-x-t is to be displayed." DISPLAY "c = Column where t-e-x-t is to be displayed." DISPLAY "If this parameter is omitted, then ""t-e-x-t""" DISPLAY "will be centered on line l.". *Display "NO Parameters" Message IF TOPIC = "MORE" OR "BLACK" OR "WHITE" OR "CLED" OR "BRIGHT" OR "BOTTOM" OR "TOP" OR "UNSQUEEZE" OR "LED0" OR "LED1" OR "LED2" OR "LED3" OR "LED4" OR "LED5" DISPLAY "No parameters associated - " with this function.". GO TO 1. Draw-Box. DISPLAY "7(0lqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq - "qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk". PERFORM VARYING J FROM 3 BY 1 UNTIL J > 21 DISPLAY "[" J ";1Hx[" J ";80Hx" END-PERFORM. DISPLAY "mqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq - "qqqqqqqqqqqqqqqqqqqqqqqqqqqqqj". DISPLAY "(B8". 2. EXIT.