tvcurses_h

/*
**	Copyright 2009, Universities Research Association.  All rights reserved.
*/
/******************************************************************************/
/* tvcurses.h
**  
**	prototypes and defined constants for argument values for
**	ul_tvcurses library routines
**
*/
/******************************************************************************/

#ifndef TVCURSES_DEFINED			/* do this only once */
#define	TVCURSES_DEFINED
#include <curses.h>

/******************************************************************************/
/* 
**	macros
*/
/******************************************************************************/

/******************************************************************************/
/* 
**	defined constants for argument values and structure definitions
*/
/******************************************************************************/

#define	TV_TOP_ROW		0			/* top row of screen */
#define	TV_BOTTOM_ROW		(LINES - 1)		/* bottom row of screen */
#define	TV_LEFT_COLUMN		0			/* left column of screen */
#define	TV_RIGHT_COLUMN		(COLS _ 1)		/* right column of screen */

#define	TV_NORMAL		(FALSE)			/* normal text */
#define	TV_BOLD			(TRUE)			/* bold text */

#define	TV_NO_BORDER		(FALSE)			/* no border */
#define	TV_BORDER		(TRUE)			/* draw border */

#define	TV_ATTR_NORMAL 		1			/* normal text mode */
#define	TV_ATTR_UNDERLINE 	4			/* underline mode */
#define	TV_ATTR_REVERSE		7			/* reverse video mode */

/******************************************************************************/
/* 
**	data structures
*/
/******************************************************************************/


/******************************************************************************/
/*
**	function prototypes
*/
/******************************************************************************/

extern "C" {
int rdcursc(int *row, int *column);
int tvblnkc(int row, int column, int num_chars);
int tvboxc(int left_column, int top_row, int right_column, int bottom_row,
	   int bold);
int tvceolc(int row, int column);
int tvceopc(int row, int column);
int tvclrc(void);
int tvfillc(int row, int column, char character, int num_chars, int bold);
int tvflshc(void);
int tvhlinc(int row, int left_column, int num_chars, int bold);
int tvinit(char *title, int border);
int tvmc(int row, int column, char *passed_text, int num_chars, int bold);
int tvm_centerc(int row, char *text, int num_chars, int bold);
int tvrfmtc(int *num_rows, int *num_columns);
int tvscrsc(int row, int column);
int tvsetcolorc(int foreground_color, int background_color=BLACK,
		int attribute=TV_ATTR_NORMAL);
int tvvlinc(int top_row, int column, int num_chars, int bold);
int tv_cleanup(void);
}

/******************************************************************************/
/*
**	equivalent name definitions
*/
/******************************************************************************/

#define	RDCURSC				rdcursc
#define	TVBLNKC				tvblnkc
#define	TVBOXC				tvboxc
#define	TVCEOLC				tvceolc
#define	TVCEOPC				tvceopc
#define	TVCLRC				tvclrc
#define	TVFILLC				tvfillc
#define	TVFLSH				tvflsh
#define	TVHLINC				tvhlinc
#define	TVINIT				tvinit
#define	TVMC				tvmc
#define	TVM_CENTERC			tvm_centerc
#define	TVRFMTC				tvrfmtc
#define	TVSCRSC				tvscrsc
#define	TVSETCOLORC			tvsetcolorc
#define	TVVLINC				tvvlinc
#define	TV_CLEANUP			tv_cleanup

#endif