Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals  

charcanvas.h

Go to the documentation of this file.
00001 /*
00002  *  charcanvas.h - Canvas for character-oriented devices.
00003  *                 This file is part of the FreeLCD package.
00004  *
00005  *  $Id: charcanvas_8h-source.html,v 1.1 2003/02/16 22:50:41 unicorn Exp $
00006  *
00007  *  This program is free software; you can redistribute it and/or modify it
00008  *  under the terms of the GNU General Public License as published by the
00009  *  Free Software Foundation; either version 2 of the License, or (at your
00010  *  option) any later version.
00011  * 
00012  *  This program is distributed in the hope that it will be useful,
00013  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015  *  GNU General Public License for more details.
00016  *
00017  *  You should have received a copy of the GNU General Public License
00018  *  along with this program; if not, write to the Free Software
00019  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston,
00020  *  MA  02111-1307  USA
00021  *
00022  *  Copyright (c) 2002, 2003, Jeroen van den Berg <unicorn@hippie.nu>
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 /* Multiple include guard */

Generated on Sun Feb 16 23:39:49 2003 for FreeLCD by doxygen1.2.18