Seppo Mustonen : Programming Survo in C

7. Include files

Various system constants, variables and macros are defined in include files survo.h, survoext.h and survodat.h.
     In all standard SURVO 84C compilands, survo.h and survoext.h must be included. In compilands working with SURVO 84C data (lists, tables, files, etc.) or using extra specifications, also survodat.h should be observed.

The most important constants defined in survo.h are the following (current values in parentheses):
EP4 Maximum number of `words' on one edit line (100)
LLENGTH Maximum length of a `word' or a `line' (256)
LNAME Maximum length of a pathname (64)
MAXPARM Maximum number of `words' in a command (24)

The following macros, defined in survo.h, are available for the screen control etc.:
WAIT halts the process and displays the message `Press any key!' until the user has pressed a key.
CLS clears the screen.
LOCATE((int)r,(int)c) The cursor will be located on line r and column c.
ERASE erases the current line.
BEEP gives a sound signal.
CURSOR_OFF makes the cursor invisible.
CURSOR_ON displays a normal cursor.
CURSOR_INS displays an extended cursor (used in insert mode).
CURSOR_POS((int *)prow,(int *)pcol) saves the current row and column of the cursor in *prow and *pcol.
SCROLL_UP((int)lin1,(int)lin2,(int)n) scrolls the lines from lin1 to lin2 n steps upwards.
SCROLL_DOWN((int)lin1,(int)lin2,(int)n) scrolls the lines from lin1 to lin2 n steps downwards.
PR_UP moves the cursor one step upwards.
PR_DOWN moves the cursor one step downwards.
PR_RIGHT moves the cursor one step to the right.
PR_LEFT moves the cursor one step to the left.
PR_ENRM sets the normal display mode (shadow blank).
PR_EBLD sets the bold mode (shadow 1).
PR_ESUB sets the subscript mode (shadow 2).
PR_ESUP sets the superscript mode (shadow 3).
PR_EUDL sets the underlining mode (shadow 4).
PR_EBLK sets the blinking mode (shadow 5)
PR_EOVR sets the oblique mode (shadow 6)
PR_EINV sets the inverse mode (shadow 7)
PR_EINV2 sets the secondary inverse mode (shadow 8)
PR_EBLD2 sets the secondary bold mode (shadow 9).


Previous: Space allocation
Next: Libraries


Front page of Programming Survo in C