1 #ifndef __OTL_TABLE_H__ 2 #define __OTL_TABLE_H__ 3 4 #include "otlayout.h" 5 6 OTL_BEGIN_HEADER 7 8 typedef struct OTL_TableRec_* OTL_Table; 9 10 typedef enum 11 { 12 OTL_TABLE_TYPE_GDEF = 1, 13 OTL_TABLE_TYPE_GSUB, 14 OTL_TABLE_TYPE_GPOS, 15 OTL_TABLE_TYPE_BASE, 16 OTL_TABLE_TYPE_JSTF 17 18 } OTL_TableType; 19 20 21 /* this may become a private structure later */ 22 typedef struct OTL_TableRec_ 23 { 24 OTL_TableType type; 25 OTL_Bytes base; 26 OTL_Bytes limit; 27 28 OTL_Tag script_tag; 29 OTL_Tag lang_tag; 30 31 OTL_UInt lookup_count; 32 OTL_Byte* lookup_flags; 33 34 OTL_UInt feature_count; 35 OTL_Tag feature_tags; 36 OTL_Byte* feature_flags; 37 38 } OTL_TableRec; 39 40 41 OTL_API( OTL_Error ) 42 otl_table_validate( OTL_Bytes table, 43 OTL_Size size, 44 OTL_TableType type, 45 OTL_Size *abyte_size ); 46 47 OTL_API( void ) 48 otl_table_init( OTL_Table table, 49 OTL_TableType type, 50 OTL_Bytes base, 51 OTL_Size size ); 52 53 OTL_API( void ) 54 otl_table_set_script( OTL_Table table, 55 OTL_ScriptTag script, 56 OTL_LangTag language ); 57 58 OTL_END_HEADER 59 60 #endif /* __OTL_TABLE_H__ */ 61