Bug 470455 - test_database_sync_embed_visits.js leaks, r=sdwilsh
[wine-gecko.git] / modules / freetype2 / src / autofit / afindic.c
blob3d27f521b6124f5db84844db46c3491ef77c0bab
1 /***************************************************************************/
2 /* */
3 /* afindic.c */
4 /* */
5 /* Auto-fitter hinting routines for Indic scripts (body). */
6 /* */
7 /* Copyright 2007 by */
8 /* Rahul Bhalerao <rahul.bhalerao@redhat.com>, <b.rahul.pm@gmail.com>. */
9 /* */
10 /* This file is part of the FreeType project, and may only be used, */
11 /* modified, and distributed under the terms of the FreeType project */
12 /* license, LICENSE.TXT. By continuing to use, modify, or distribute */
13 /* this file you indicate that you have read the license and */
14 /* understand and accept it fully. */
15 /* */
16 /***************************************************************************/
19 #include "aftypes.h"
20 #include "aflatin.h"
23 #ifdef AF_CONFIG_OPTION_INDIC
25 #include "afindic.h"
26 #include "aferrors.h"
27 #include "afcjk.h"
30 #ifdef AF_USE_WARPER
31 #include "afwarp.h"
32 #endif
35 static FT_Error
36 af_indic_metrics_init( AF_LatinMetrics metrics,
37 FT_Face face )
39 /* use CJK routines */
40 return af_cjk_metrics_init( metrics, face );
44 static void
45 af_indic_metrics_scale( AF_LatinMetrics metrics,
46 AF_Scaler scaler )
48 /* use CJK routines */
49 af_cjk_metrics_scale( metrics, scaler );
53 static FT_Error
54 af_indic_hints_init( AF_GlyphHints hints,
55 AF_LatinMetrics metrics )
57 /* use CJK routines */
58 return af_cjk_hints_init( hints, metrics );
62 static FT_Error
63 af_indic_hints_apply( AF_GlyphHints hints,
64 FT_Outline* outline,
65 AF_LatinMetrics metrics)
67 /* use CJK routines */
68 return af_cjk_hints_apply( hints, outline, metrics );
72 /*************************************************************************/
73 /*************************************************************************/
74 /***** *****/
75 /***** I N D I C S C R I P T C L A S S *****/
76 /***** *****/
77 /*************************************************************************/
78 /*************************************************************************/
81 static const AF_Script_UniRangeRec af_indic_uniranges[] =
83 #if 0
84 { 0x0100, 0xFFFF }, /* why this? */
85 #endif
86 { 0x0900, 0x0DFF}, /* Indic Range */
87 { 0, 0 }
91 FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
92 af_indic_script_class =
94 AF_SCRIPT_INDIC,
95 af_indic_uniranges,
97 sizeof( AF_LatinMetricsRec ),
99 (AF_Script_InitMetricsFunc) af_indic_metrics_init,
100 (AF_Script_ScaleMetricsFunc)af_indic_metrics_scale,
101 (AF_Script_DoneMetricsFunc) NULL,
103 (AF_Script_InitHintsFunc) af_indic_hints_init,
104 (AF_Script_ApplyHintsFunc) af_indic_hints_apply
107 #else /* !AF_CONFIG_OPTION_INDIC */
109 static const AF_Script_UniRangeRec af_indic_uniranges[] =
111 { 0, 0 }
115 FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
116 af_indic_script_class =
118 AF_SCRIPT_INDIC,
119 af_indic_uniranges,
121 sizeof( AF_LatinMetricsRec ),
123 (AF_Script_InitMetricsFunc) NULL,
124 (AF_Script_ScaleMetricsFunc)NULL,
125 (AF_Script_DoneMetricsFunc) NULL,
127 (AF_Script_InitHintsFunc) NULL,
128 (AF_Script_ApplyHintsFunc) NULL
131 #endif /* !AF_CONFIG_OPTION_INDIC */
134 /* END */