~ubuntu-branches/ubuntu/karmic/pango1.0/karmic-security

« back to all changes in this revision

Viewing changes to pango/opentype/harfbuzz-impl.h

Tags: upstream-1.15.4
ImportĀ upstreamĀ versionĀ 1.15.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*******************************************************************
 
2
 *
 
3
 *  Copyright 1996-2000 by
 
4
 *  David Turner, Robert Wilhelm, and Werner Lemberg.
 
5
 *
 
6
 *  Copyright 2006  Behdad Esfahbod
 
7
 *
 
8
 *  This is part of HarfBuzz, an OpenType Layout engine library.
 
9
 *
 
10
 *  See the file name COPYING for licensing information.
 
11
 *
 
12
 ******************************************************************/
 
13
#ifndef HARFBUZZ_IMPL_H
 
14
#define HARFBUZZ_IMPL_H
 
15
 
 
16
#include <ft2build.h>
 
17
#include FT_FREETYPE_H
 
18
#include FT_TRUETYPE_TAGS_H
 
19
 
 
20
FT_BEGIN_HEADER
 
21
 
 
22
#ifndef NULL
 
23
# define NULL ((void *)0)
 
24
#endif
 
25
 
 
26
#ifndef FALSE
 
27
# define FALSE 0
 
28
#endif
 
29
 
 
30
#ifndef TRUE
 
31
# define TRUE 1
 
32
#endif
 
33
 
 
34
#ifndef TTAG_GDEF
 
35
# define TTAG_GDEF  FT_MAKE_TAG( 'G', 'D', 'E', 'F' )
 
36
#endif
 
37
#ifndef TTAG_GPOS
 
38
# define TTAG_GPOS  FT_MAKE_TAG( 'G', 'P', 'O', 'S' )
 
39
#endif
 
40
#ifndef TTAG_GSUB
 
41
# define TTAG_GSUB  FT_MAKE_TAG( 'G', 'S', 'U', 'B' )
 
42
#endif
 
43
 
 
44
#ifndef FT_UNUSED
 
45
# define FT_UNUSED(arg) ((arg) = (arg))
 
46
#endif
 
47
 
 
48
#include "ftglue.h"
 
49
 
 
50
#define ARRAY_LEN(Array) ((int)(sizeof (Array) / sizeof (Array)[0]))
 
51
 
 
52
 
 
53
 
 
54
 
 
55
#define IN_GLYPH( pos )        (buffer->in_string[(pos)].gindex)
 
56
#define IN_ITEM( pos )         (&buffer->in_string[(pos)])
 
57
#define IN_CURGLYPH()          (buffer->in_string[buffer->in_pos].gindex)
 
58
#define IN_CURITEM()           (&buffer->in_string[buffer->in_pos])
 
59
#define IN_PROPERTIES( pos )   (buffer->in_string[(pos)].properties)
 
60
#define IN_LIGID( pos )        (buffer->in_string[(pos)].ligID)
 
61
#define IN_COMPONENT( pos )    (buffer->in_string[(pos)].component)
 
62
#define POSITION( pos )        (&buffer->positions[(pos)])
 
63
#define OUT_GLYPH( pos )       (buffer->out_string[(pos)].gindex)
 
64
#define OUT_ITEM( pos )        (&buffer->out_string[(pos)])
 
65
 
 
66
#define CHECK_Property( gdef, index, flags, property )              \
 
67
          ( ( error = _HB_GDEF_Check_Property( (gdef), (index), (flags),     \
 
68
                                      (property) ) ) != FT_Err_Ok )
 
69
 
 
70
#define ADD_String( buffer, num_in, num_out, glyph_data, component, ligID )             \
 
71
          ( ( error = hb_buffer_add_output_glyphs( (buffer),                           \
 
72
                                                    (num_in), (num_out),                \
 
73
                                                    (glyph_data), (component), (ligID)  \
 
74
                                                  ) ) != FT_Err_Ok )
 
75
#define ADD_Glyph( buffer, glyph_index, component, ligID )                               \
 
76
          ( ( error = hb_buffer_add_output_glyph( (buffer),                             \
 
77
                                                    (glyph_index), (component), (ligID)  \
 
78
                                                  ) ) != FT_Err_Ok )
 
79
 
 
80
 
 
81
FT_END_HEADER
 
82
 
 
83
#endif /* HARFBUZZ_IMPL_H */