00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef _CHARCANVAS_H
00027 #define _CHARCANVAS_H
00028
00035 #include <wchar.h>
00036
00038 typedef struct
00039 {
00040 wchar_t c;
00041 char damaged_flag;
00042 unsigned char *bitmap;
00043 }
00044 cc_elem;
00045
00047 typedef struct
00048 {
00049 int width;
00050 int height;
00051 cc_elem *elements;
00052 }
00053 cc_canvas;
00054
00055
00061 cc_canvas *
00062 cc_create_canvas (unsigned int width, unsigned int height);
00063
00066 void
00067 cc_delete_canvas (cc_canvas *canvas);
00068
00074 void
00075 cc_put_char (cc_canvas *canvas, unsigned int x_pos, unsigned int y_pos,
00076 wchar_t character);
00077
00084 void
00085 cc_write_text (cc_canvas *canvas, unsigned int x_pos, unsigned int y_pos,
00086 char *utf8_string);
00087
00093 cc_elem*
00094 cc_get_element (cc_canvas *canvas, unsigned int x_pos, unsigned int y_pos);
00095
00099 void
00100 cc_clear_damaged_regions (cc_canvas *canvas);
00101
00102
00103 #endif