/* gchars.h */

/* Printing of text in fancy graphic chars */

#ifndef __gchars_h
#define __gchars_h

/* Mapping of characters to graphic data */
#define gchars_NUM 0
#define gchars_ALPHA 10
#define gchars_STOP  36
#define gchars_DASH  37
#define gchars_QUEST 38
#define gchars_PLING 39
#define gchars_APOST 40
#define gchars_COLON 41
#define gchars_COMMA 42

/* Load the graphics */
void gchars_init(char *filename);

/* Move invisible cursor (word-aligned scrn coords) */
void gchars_moveto(int x,int y);

/* Write 1 char at cursor
   Spaces act as overwrite
   13 and 10 act as '\n'
   Unknown chars are ignored, cursor doesn't move
 */
void gchars_writec(char ch);

/* Write NULL-terminated string at cursor */
void gchars_writes(char *str);

/* Pass printf type string to gchars_writes (limit 256 chars) */
void gchars_printf(char *format,...);

/* Print a string centre aligned
   It will split lines if necessary, but 'words' must be no more than 20 chars
   Include no control characters
 */
void gchars_centre(char *str);

/* Print a formatted string centre aligned
   It will split lines if necessary, but 'words' must be no more than 20 chars
   Include no control characters
 */
void gchars_centref(char *format,...);

/* Input a string into buffer, only allowing len characters, only contained
   in valid
   Letters forced upper case
 */
void gchars_input(char *buffer,int len,char *valid);

#endif
