/*
 ----------------------------------------------------------------
 |    Perlin Production Corporation, February-April 1993 (c).	|##
 |   WINDOW PACKAGE Source Code for SuperSoft C 1.2.3 compiler.	|##
 |    V e r s i o n  3.1 , part 1.  LAST CHANGES: 08.05.1993.	|##
 ----------------------------------------------------------------##
  #################################################################

			LIST OF FUNCTIONS:
	wrt_esc
	wrt_video
	hd_csr
	sh_csr
	cls
	rev_vid
	norm_vid
*/

#include "stdio.h"
#include "conio.h"

wrt_esc(code)
char code;
{
	putchar(ESC);
	putchar(code);
}


wrt_video(x,y,pstr,attrib,txt_size)
char x,y,attrib,txt_size,*pstr;
{
	register char *s;

	wrt_esc(attrib);
	goto_xy(x,y);
	for (s=pstr ; *s && txt_size; txt_size-- ) putchar (*s++);
	wrt_esc(NORM_VID);
}


/*	The next five functions can be defined as macros, but I thought */
/*	that function definition is more convenient (maybe I'm wrong). */

hd_csr()
{
	wrt_esc(HCURS);
}


sh_csr()
{
	wrt_esc(VCURS);
}


cls()
{
	wrt_esc(CLSCR);
}


rev_vid()
{
	wrt_esc(REV_VID);
}


nrm_vid()
{
	wrt_esc(NORM_VID);
}
