BRL-CAD
cursor.h File Reference
#include "common.h"
#include <stdio.h>
Include dependency graph for cursor.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int InitTermCap (FILE *fp)
 
int SetStandout (void)
 
int ClrStandout (void)
 
int ClrEOL (void)
 
int ClrText (void)
 
int DeleteLn (void)
 
int HmCursor (void)
 
int MvCursor (int x, int y)
 
int ScrollDn (void)
 
int ScrollUp (void)
 
int SetScrlReg (int top, int btm)
 
int ResetScrlReg (void)
 

Detailed Description

These are declarations of functions provided by libcursor, a simple wrapper library to terminal capabilities (termcap).

Definition in file cursor.h.

Function Documentation

int InitTermCap ( FILE *  fp)

Initialize termcap.

This function must be called first to read the termcap database and to specify the output stream.

Get individual parameters and control strings. Initialize the terminal. Use 'fp' as output stream.

Returns 1 for success, 0 for failure and prints appropriate diagnostic.

Definition at line 115 of file cursor.c.

References MAX_TERM_LEN, PutChr(), and TI.

Here is the call graph for this function:

int SetStandout ( void  )

These below functions output terminal control strings to the file stream specified by the InitTermCap() call which must precede them. They return 0 if the capability is not described in the termcap database and 1 otherwise. Of course if the database entry is wrong, the command will not do its job. Begin standout mode.

Definition at line 325 of file cursor.c.

References PutChr(), and SO.

Here is the call graph for this function:

int ClrStandout ( void  )

End standout mode.

Definition at line 313 of file cursor.c.

References PutChr(), and SE.

Here is the call graph for this function:

int ClrEOL ( void  )

Clear from the cursor to end of line.

Definition at line 265 of file cursor.c.

References CE, and PutChr().

Here is the call graph for this function:

int ClrText ( void  )

Clear screen and home cursor.

Definition at line 277 of file cursor.c.

References CL, LI, and PutChr().

Here is the call graph for this function:

int DeleteLn ( void  )

Delete the current line.

Definition at line 237 of file cursor.c.

References DL, and PutChr().

Here is the call graph for this function:

int HmCursor ( void  )

Home the cursor.

Definition at line 201 of file cursor.c.

References HO, and PutChr().

Here is the call graph for this function:

int MvCursor ( int  x,
int  y 
)

Move the cursor to screen coordinates x, y.

Definition at line 249 of file cursor.c.

References CM, and PutChr().

Here is the call graph for this function:

int ScrollDn ( void  )

Reverse scroll 1 line.

Definition at line 225 of file cursor.c.

References PutChr(), and SR.

Here is the call graph for this function:

int ScrollUp ( void  )

Forward scroll 1 line.

Definition at line 213 of file cursor.c.

References PutChr(), and SF.

Here is the call graph for this function:

int SetScrlReg ( int  top,
int  btm 
)

Set the scrolling region to be from "top" to "btm".

Definition at line 289 of file cursor.c.

References CS, and PutChr().

Here is the call graph for this function:

int ResetScrlReg ( void  )

Reset the scrolling region to the entire screen.

Definition at line 301 of file cursor.c.

References CS, LI, and PutChr().

Here is the call graph for this function: