1 /* QuesoGLC 2 * A free implementation of the OpenGL Character Renderer (GLC) 3 * Copyright (c) 2002, 2004-2007, Bertrand Coconnier 4 * 5 * This library is free software; you can redistribute it and/or 6 * modify it under the terms of the GNU Lesser General Public 7 * License as published by the Free Software Foundation; either 8 * version 2.1 of the License, or (at your option) any later version. 9 * 10 * This library is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 * Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public 16 * License along with this library; if not, write to the Free Software 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 */ 19 /* $Id: ocharmap.h 800 2008-06-04 21:47:50Z bcoconni $ */ 20 21 /** \file 22 * header of the object __GLCcharMap which manage the charmaps of both the fonts 23 * and the masters. 24 */ 25 26 #ifndef __glc_ocharmap_h 27 #define __glc_ocharmap_h 28 29 #include "ocontext.h" 30 #include "oglyph.h" 31 32 typedef struct __GLCcharMapElementRec __GLCcharMapElement; 33 typedef struct __GLCcharMapRec __GLCcharMap; 34 typedef struct __GLCmasterRec __GLCmaster; 35 36 struct __GLCcharMapElementRec { 37 GLCulong mappedCode; 38 __GLCglyph* glyph; 39 }; 40 41 struct __GLCcharMapRec { 42 FcCharSet* charSet; 43 __GLCarray* map; 44 }; 45 46 __GLCcharMap* __glcCharMapCreate(__GLCmaster* inMaster, __GLCcontext* inContext); 47 void __glcCharMapDestroy(__GLCcharMap* This); 48 void __glcCharMapAddChar(__GLCcharMap* This, GLint inCode, 49 __GLCglyph* inGlyph); 50 void __glcCharMapRemoveChar(__GLCcharMap* This, GLint inCode); 51 const GLCchar8* __glcCharMapGetCharName(__GLCcharMap* This, GLint inCode); 52 __GLCglyph* __glcCharMapGetGlyph(__GLCcharMap* This, GLint inCode); 53 GLboolean __glcCharMapHasChar(__GLCcharMap* This, GLint inCode); 54 const GLCchar8* __glcCharMapGetCharNameByIndex(__GLCcharMap* This, 55 GLint inIndex); 56 GLint __glcCharMapGetCount(__GLCcharMap* This); 57 GLint __glcCharMapGetMaxMappedCode(__GLCcharMap* This); 58 GLint __glcCharMapGetMinMappedCode(__GLCcharMap* This); 59 #endif 60