Page:FORTRAN IV enhanced character graphics (IA fortranivenhance5003wolc).pdf/6

 which retrieves bits N1 through N2 of WORD as an integer when the bits are numbered from the right (starting with 1).

Character (byte) access is provided by another internal function CHAR (J) which returns the J'th character of a textual string in the form of a binary integer. This function (which uses IFLD) will work on those computers which allow alphabetic characters to be manipulated as integers.

This is the case with the IBM 360/370 and UNIVAC 1100 computers. For others the functions CHAR or IFLD may need to be rewritten.

The BLOCK DATA subprogram is written in an extension of FORTRAN IV which allows definition of arrays in DATA statements. This extension is compatible with most FORTRAN compilers.

All of the routines were run through the Pfort verifier (5), and no errors other than those of the FORTRAN extension were detected. To date the program has run successfully on the IBM 370, UNIVAC 1100, CDC 7600, and PDP-11 computers.

III. DESCRIPTION OF THE PROGRAMS

SYMBOLTEST MAIN PROGRAM

This is a main program which draws all of the alphabets and plots all of the plotting symbols available.

LENGTH (XLEN, HEIGHT, TEXT, N)

This subroutine returns in XLEN the length in inches of a textual string TEXT comprising N characters. This information is useful for centering and alignment.

STRIN (I, TEXT)

This integer function returns the I'th computer word of the textual string 'TEXT'. It is used only internally in SYMBOL.

SYMBOL (X, Y, HEIGHT, TEXT, THETA, N)

This subroutine draws graphic characters and plot symbols.

When N is positive, N characters from the textual string TEXT are drawn. When N is negative, and TEXT is a binary integer between 0 and 21, a centered symbol from the set of 22 plotting symbols is plotted at (X,Y). When N is nought, a single simplex alphameric character (right justified in TEXT) is plotted at (X,Y). When X and/or Y = 999., the annotation is continued following the X and/or Y termination in the previous call to SYMBOL. The conventions for N < 0 and N = 0 were designed to be compatible with local vendor supplied software. Minor modifications to the programs will accommodate other conventions. 2