abstract This is a summary description of FORTRAN callable subroutines that allow the user to readily access the capabilities of a VT-220. It is assumed that the the user has available for further reference the VT-220 Programmer Pocket Guide as some of the arguments used in the subroutine calls are based on the hardware expecte values. The VT-200 controled by these routines must be the current SYS$INPUT and SYS$OUTPUT . 1.0 APPLICATION_KEYPAD Called with no arguments, this subroutine set the keyboard keypad to application mode (escape sequences sent when pressed). This mode is reset when the subroutine NUMERIC_KEYPAD is invoked. 2.0 CLEAR_ALL_TAB Called with no arguments, this subroutine clears all tabs currently set on the terminal. See also CLEAR_TAB and SET_TAB . 3.0 CLEAR_CHARACTER(I) Starting at the curent cursor position, clears the character at that position ant the next I-1 characters in the line. 4.0 CLEAR_LINE(I) Clears part or all of the current line resided on by the cursor, depending on the value of the passed variable I . I ACTION 0 Erase line from cursor position to the end of the line 1 Erase line from beginning of the line to the cursor position 2 Erase the entire line. Page 2 5.0 CLEAR_SCREEN(I) Clears all or part of the entire display screen depending on the passed value of the argument I . I ACTION 0 Erases the screen from the cursor position to the end of the display. 1 Erases the screen from the top of the display to and includeing the cursor position. 2 Erases the entire screen 6.0 CLEAR_TAB Clears the tab setting at the current horizontal position of the cursor. See also CLEAR_ALL_TAB and SET_TAB . 7.0 ERASE_LINE(I) Erases all characters in part or all of the current line resided on by the cursor that have not been declared to have the characteristic NOT ERASEABLE, depending on the value of the passed variable I . I ACTION 0 Erase eraseable characters in line from cursor position to the end of the line 1 Erase eraseable characters in line from beginning of the line to the cursor position 2 Erase eraseable characters in the entire line. 8.0 ERASE_SCREEN(I) Erases the all the characters that do not have the characteristic NOT ERASEABLE from all or part of the entire display screen depending on the passed value of the argument I . I ACTION 0 Erases all eraseable characters from the screen from the cursor position to the end of the display. 1 Erases all eraseable characters from the screen from the top of the display to and includeing the cursor position. 2 Erases all eraseable characters from the entire screen Page 3 9.0 JUMP Called with no arguments, this subroutine sets the scrolling mode to jump mode vice smooth mode. 10.0 MOVE_CURSOR(I,J) Moves the cursor to the specified row and column position on the screen. The row (I) runs from 1 to 24 and the column (J) runs from 1 to 132 . Depending on the terminal setting of the ORIGIN mode, the origin is either (RESET) the upper left corner of the screen or (SET) the upper left corner of the scrolling region as set by the SCROLL command. 11.0 NUMERIC_KEYPAD Called with no arguments, this subroutine set the keyboard keypad to numeric mode (numbers sent when pressed). This mode is reset when the subroutine APPLICATION_KEYPAD is invoked. 12.0 POP_CURSOR Called with no arguments, this is the compliment to the PUSH_CURSOR subroutine. This routine causes the terminal to reset itself to the position, graphic rendition,character set, wrap flag, origin mode and selective erase it had at the time of the last PUSH_CURSOR command. 13.0 PRINT_LINE Called with no arguments. For terminals with printers attached. Causes the line containing the cursor to be printed. 14.0 PRINT_SCREEN Called with no arguments. For terminals with printers attached. Depending on the terminal mode DECEXT will print either (SET) the entire screen or (RESET) the scrolling region. The current value of the printer form feed mode (DECPFF) determines if the screen print terminates with a form feed. Page 4 15.0 PUSH_CURSOR Called with no arguments, this is the compliment to the POP_CURSOR subroutine. This routine causes the terminal to save for later reset via the POP_CURSOR command, the current position, graphic rendition,character set, wrap flag, origin mode and selective erase . 16.0 RESET_AUTO_PRINT Called with no arguments. For terminals with printers attached. This is the compliment to the SET_AUTO_PRINT subroutine. Turns off the printing of lines as they appear on the terminal. 17.0 RESET_PRINTER_CONTROLLER Called with no arguments. For terminals with printers attached. This is the compliment to the SET_PRINTER_CONTROLLER subroutine. Turns off the redirection of output from the terminal screen to the printer. 18.0 RESET_TERMINAL(I) Resets the selected terminal characteristic to the default value. This is the compliment of the SET_TERMINAL subroutine. Page 5 I Mnemonic Set Mode Reset Mode 1 DECCKM-Cursor Key Application Cursor 2 DECANM-ANSI/VT52 ANSII VT52 3 DECCOLM-Column 132 80 4 DECSCLM-Scrolling Smooth Jump 5 DECSCNM -Screen Reverse Normal 6 DECOM-Origin Origin Absolute 7 DECAWM-Auto wrap On Off 8 DECARM-Auto repeat On Off 18 DECPFF-Print form feed On Off 19 DECPEX-Print extent Full screen Scrolling region 25 DECTCEM-Text cursor enable On Off 38 DECTEK-Tektronix 40120/4014 On Off 42 DECNRCM-Character set National Multinational 102 KAM-Keyboard Action Locked Unlocked 104 IRM-Insertion/replacement Insert Replace 112 SRM-Send-Recieve Off On 120 LNM-Line Feed/New line New Line Line Feed 19.0 SCROLL(I,J) Sets the screen scrolling region to row I to row J. Where 1.LE.I.LE.J.LE.24 . 20.0 SELECT_CHARACTER_SET(N,NAME) Allows the user to dynamicaly alter at run time what character sets are available for output to the terminal. The argument N designates what character set (G0, G1, G2, G3) is to be loaded with with the designated font. N is an integer variable takeing the value 0-3. NAME is a character string of length 1-3 containing the name of the font to be down line loaded to the specified charater set Gx. The fonts currently available are: Page 6 Name Font A British B ASCII C Finnish E Norwegian/Danish H Swedish K German Q French Canadian R French Y Italian Z Spanish < DEC Suplemental = Swiss 0 DEC Special Graphics 4 Dutch 5 Finnish 6 Norwegian/Danish 7 Swedish The name may also be the name of a user defined font that has been previously down line loaded. 21.0 SET_AUTO_PRINT Called with no arguments. For terminals with printers attached. This is the compliment to the RESET_AUTO_PRINT subroutine. Turns on the printing of lines as they appear on the terminal. 22.0 SET_MODE(ICHAR) Clears the current character print out mode and resets it to the modes set in ICHAR . Where ICHAR is the sum of all the individual modes that the user wants set. Page 7 I Meaning 1 Increased intensity 2 Underscore 4 Blink 8 Negative 16 Select character set G0-G3 for GL, where N=0-3 coresponding to the character set wanted-ICHAR=ICHAR+16*N 64 Select character set G0-G3 for GR, where N=0-3 coresponding to the character set wanted-ICHAR=ICHAR+64*N 256 Not eraseable 512 Eraseable 1024 Line attributes-calculated as follows single width line ICHAR=ICHAR Double width line ICHAR=ICHAR+1024 Double height top half ICHAR=ICHAR+2048 Double height bottom half ICHAR=ICHAR+3072 23.0 SET_PRINTER_CONTROLLER Called with no arguments. For terminals with printers attached. This is the compliment to the RESET_PRINTER_CONTROLLER subroutine. Turns on the redirection of output from the terminal screen to the printer. 24.0 SET_TAB Sets the tab setting at the current horizontal position of the cursor. See also CLEAR_ALL_TAB and CLEAR_TAB . 25.0 SET_TERMINAL Sets the selected terminal characteristic to the set value. This is the compliment of the RESET_TERMINAL subroutine. Page 8 I Mnemonic Set Mode Reset Mode 1 DECCKM-Cursor Key Application Cursor 2 DECANM-ANSI/VT52 ANSII VT52 3 DECCOLM-Column 132 80 4 DECSCLM-Scrolling Smooth Jump 5 DECSCNM -Screen Reverse Normal 6 DECOM-Origin Origin Absolute 7 DECAWM-Auto wrap On Off 8 DECARM-Auto repeat On Off 18 DECPFF-Print form feed On Off 19 DECPEX-Print extent Full screen Scrolling region 25 DECTCEM-Text cursor enable On Off 38 DECTEK-Tektronix 40120/4014 On Off 42 DECNRCM-Character set National Multinational 102 KAM-Keyboard Action Locked Unlocked 104 IRM-Insertion/replacement Insert Replace 112 SRM-Send-Recieve Off On 120 LNM-Line Feed/New line New Line Line Feed 26.0 SMOOTH Called with no arguments, this subroutine sets the scrolling mode to smooth mode vice jump mode. 27.0 WIDTH_132 Sets the terminal to 132 column mode. This is the same as the column mode of the SET_TERMINAL/RESET_TERMINAL subroutines. 28.0 WIDTH_80 Sets the terminal to 80 column mode. This is the same as the column mode of the SET_TERMINAL/RESET_TERMINAL subroutines. 29.0 WRITE_FLOAT(I,J,F,IFORMAT,ICHAR) outputs the specific floating point number to the screen at the specified location, with the specified format and characteristics. The arguments I and J specify the starting location of the string to be written. They are integer variables matching the arguments required by MOVE_CURSOR . Page 9 F is a floating point variable containing the value to be output. IFORMAT is a character string containing the format of the conversion of F to a string. ICHAR is an integer specifying the chracteristics of the string to be written the value depends on the characteristics wanted, as outlined in SET_MODE . If the user wants a double height string, then he need only specify the option number for double height top half and the bottom will be automaticaly written in. If the bottom half is specifified, no special handleing will be done. 30.0 WRITE_INTEGER(I,J,N,IWIDTH,ICHAR) outputs the specific integer number to the screen at the specified location, with the specified format and characteristics. The arguments I and J specify the starting location of the string to be written. They are integer variables matching the arguments required by MOVE_CURSOR . N is a integer variable containing the value to be output. IWIDTH is an integer containing the number of characters in the I format specification of the conversion of N to a string. ICHAR is an integer specifying the chracteristics of the string to be written the value depends on the characteristics wanted, as outlined in SET_MODE . If the user wants a double height string, then he need only specify the option number for double height top half and the bottom will be automaticaly written in. If the bottom half is specifified, no special handleing will be done. 31.0 WRITE_STRING(I,J,STRING,ICHAR) outputs the specific string to the screen at the specified location, with the specified characteristics. The arguments I and J specify the starting location of the string to be written. They are integer variables matching the arguments required by MOVE_CURSOR . STRING is a character string to be output. ICHAR is an integer specifying the chracteristics of the string to be written the value depends on the characteristics wanted, as outlined in SET_MODE . If the user wants a double height string, then he need only specify the option number for double height top half and the bottom will be automaticaly written in. If the bottom half is specifified, no special Page 10 handleing will be done. Page Index-1 INDEX APPLICATION_KEYPAD . . . . . . . . . 1, 3 CLEAR_ALL_TAB . . . . . . . . . . . 1-2, 7 CLEAR_CHARACTER . . . . . . . . . . 1 CLEAR_LINE . . . . . . . . . . . . . 1 CLEAR_SCREEN . . . . . . . . . . . . 2 CLEAR_TAB . . . . . . . . . . . . . 1-2, 7 ERASE_LINE . . . . . . . . . . . . . 2 ERASE_SCREEN . . . . . . . . . . . . 2 JUMP . . . . . . . . . . . . . . . . 3, 8 MOVE_CURSOR . . . . . . . . . . . . 3, 8-9 NUMERIC_KEYPAD . . . . . . . . . . . 1, 3 POP_CURSOR . . . . . . . . . . . . . 3-4 PRINT_LINE . . . . . . . . . . . . . 3 PRINT_SCREEN . . . . . . . . . . . . 3 PUSH_CURSOR . . . . . . . . . . . . 3-4 RESET_AUTO_PRINT . . . . . . . . . . 4, 6 RESET_PRINTER_CONTROLLER . . . . . . 4, 7 RESET_TERMINAL . . . . . . . . . . . 3-4, 7 SCROLL . . . . . . . . . . . . . . . 3, 5 SELECT_CHARACTER_SET . . . . . . . . 5 SET_AUTO_PRINT . . . . . . . . . . . 4, 6 SET_MODE . . . . . . . . . . . . . . 2-3 SET_MODE . . . . . . . . . . . . . . 9 SET_PRINTER_CONTROLLER . . . . . . . 4, 7 SET_TAB . . . . . . . . . . . . . . 1-2, 7 SET_TERMINAL . . . . . . . . . . . . 3-4, 7 SMOOTH . . . . . . . . . . . . . . . 3, 8 WIDTH_132 . . . . . . . . . . . . . 8 WIDTH_80 . . . . . . . . . . . . . . 8 WRITE_FLOAT . . . . . . . . . . . . 8 WRITE_INTEGER . . . . . . . . . . . 9 WRITE_STRING . . . . . . . . . . . . 9