README - TFPdraw.h

The TIFont Project - C library
by the janjanIIteam

To use TFPdraw.h:
add file "TFPdraw.h" to your TIgcc project
write #include "TFPdraw.h" at the beginning of C file
call USE_TFP(); at the beginning of the main function
call ENDUSE_TFP(); at the end of the main function

Folowing functions are provided by TFPdraw.h:
BEGUSE_TFP()
ENDUSE_TFP()
CONFIG_TFP(char buf[8])
ToChar(short Y,short l,short h,char m[12])
XChar(short x,short y,structCHAR c,MODE mode,unsigned char *Plane):
XStr(short x,short y,char *str,short attr,MODE mode,unsigned char *Plane)

And folowing type:
CHAR


BEGUSE_TFP():

You must use this function to start using TFP;


ENDUSE_TFP():

You must use this function to stop using TFP;


CONFIG_TFP(char buf[8]):

Load the font file wich has the name buf into the current directory


ToChar(short Y,short l,short h,char m[12]):

returns a CHAR structure wich contents informations given as parameters


XChar(short x,short y,structCHAR c,MODE mode,unsigned char *Plane):

draws a char on given plane at given coordinates


XStr(short x,short y,char *str,short attr,MODE mode,unsigned char *Plane):

draws a string on given plane at given coordinates.
attr can be:
NORMAL      - normal
UNDERLINE   - underline
BARRE       - striped
BOLD        - bold

mode can be:
MODE_OR
MODE_XOR
MODE_REPLACE



struct CHAR

struct CHAR
{
char Yoffset;
char lar;
char hau;
unsigned char map[12];
};