{ SPX Library Version 2.0 Copyright 1993 Scott D. Ramsay } SPX_TXT is the raster font handling unit. It also allows you to display your own fonts. Has a built in small text font. (Font used in GUI- of vspmaker and geomaker.) ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ function stlen(s:string):word; Returns the width of the string in pixels based on the current font. S: String to check ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ procedure putletter(x,y:integer;c:byte;s:string); Display a string on the active page. X,Y: Top-left position to place text; C: Color of text; S: String to display NOTE: IF (X) is negative then the text is centered on the screen ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ procedure drawletter(x,y:integer;c,c2:byte;s:string); Drawletter is the same as putletter with the following addition: putletter(x+1,y+1,c2,s); putletter(x,y,c,s); This allows for shaded text. Set the GUI's vspmaker and geomaker for visual examples. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ procedure putchar(x,y:integer;h:char;c:byte); Display a character on the active page. X,Y: Top-left position to place character; H: Character to display; C: Color of character ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ procedure loadchb(fn:string;var cdata); Load a .CHB character font from disk. FN: DOS file name of .CHB font file; CDATA: Character list to store the loaded font ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ procedure setchb(var buff); Sets the current loaded font. BUFF: Buffer location of the new font EXAMPLE: var myfont : CharList; . . . Loadchb('myfont.chb',myfont); setchb(myfont); putletter(0,0,15,'This is my font'); ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ