| 1 | .sh 1 Variables |
| 2 | .pp |
| 3 | Many variables which are used to describe the terminal environment |
| 4 | are available to the programmer. They are: |
| 5 | .TS |
| 6 | expand; |
| 7 | lw(6m) lw(8n) lw(50n). |
| 8 | type name description |
| 9 | _ |
| 10 | WINDOW * curscr T{ |
| 11 | .fi |
| 12 | current version of the screen (terminal screen). |
| 13 | T} |
| 14 | WINDOW * stdscr T{ |
| 15 | standard screen. Most updates are usually done here. |
| 16 | T} |
| 17 | char * Def\*_term T{ |
| 18 | default terminal type if type cannot be determined |
| 19 | T} |
| 20 | bool My\*_term T{ |
| 21 | use the terminal specification in \fIDef\*_term\fR as terminal, |
| 22 | irrelevant of real terminal type |
| 23 | T} |
| 24 | char * ttytype T{ |
| 25 | full name of the current terminal. |
| 26 | T} |
| 27 | int LINES T{ |
| 28 | number of lines on the terminal |
| 29 | T} |
| 30 | int COLS T{ |
| 31 | number of columns on the terminal |
| 32 | T} |
| 33 | int ERR T{ |
| 34 | error flag returned by routines on a fail. |
| 35 | T} |
| 36 | int OK T{ |
| 37 | error flag returned by routines when things go right. |
| 38 | T} |
| 39 | .TE |
| 40 | .pp |
| 41 | There are also several |
| 42 | .q #define |
| 43 | constants and types |
| 44 | which are of general usefulness: |
| 45 | .sp |
| 46 | .ev 1 |
| 47 | .ta 11n |
| 48 | .(b L |
| 49 | .nf |
| 50 | reg storage class ``register'' (e.g., \fIreg int i;\fR\|) |
| 51 | bool boolean type, actually a ``char'' (e.g., \fIbool doneit;\fR\|) |
| 52 | TRUE boolean ``true'' flag (1). |
| 53 | FALSE boolean ``false'' flag (0). |
| 54 | .fi |
| 55 | .ev |
| 56 | .)b |
| 57 | .lp |