32
30
<h2><span class="refentrytitle"><a name="pango-Glyph-Storage.top_of_page"></a>Glyph Storage</span></h2>
33
31
<p>Glyph Storage — Structures for storing information about glyphs</p>
35
<td valign="top" align="right"></td>
33
<td class="gallery_image" valign="top" align="right"></td>
36
34
</tr></table></div>
37
<div class="refsynopsisdiv">
38
<a name="pango-Glyph-Storage.synopsis"></a><h2>Synopsis</h2>
39
<a name="PangoMatrix"></a><a name="PangoGlyphString"></a><a name="PangoGlyphItem"></a><a name="PangoGlyphItemIter"></a><pre class="synopsis">#define <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE">PANGO_SCALE</a>
40
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS:CAPS" title="PANGO_PIXELS()">PANGO_PIXELS</a> (d)
41
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS-FLOOR:CAPS" title="PANGO_PIXELS_FLOOR()">PANGO_PIXELS_FLOOR</a> (d)
42
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS-CEIL:CAPS" title="PANGO_PIXELS_CEIL()">PANGO_PIXELS_CEIL</a> (d)
43
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-UNITS-ROUND:CAPS" title="PANGO_UNITS_ROUND()">PANGO_UNITS_ROUND</a> (d)
44
<span class="returnvalue">double</span> <a class="link" href="pango-Glyph-Storage.html#pango-units-to-double" title="pango_units_to_double ()">pango_units_to_double</a> (<em class="parameter"><code><span class="type">int</span> i</code></em>);
45
<span class="returnvalue">int</span> <a class="link" href="pango-Glyph-Storage.html#pango-units-from-double" title="pango_units_from_double ()">pango_units_from_double</a> (<em class="parameter"><code><span class="type">double</span> d</code></em>);
46
struct <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle">PangoRectangle</a>;
47
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-ASCENT:CAPS" title="PANGO_ASCENT()">PANGO_ASCENT</a> (rect)
48
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-DESCENT:CAPS" title="PANGO_DESCENT()">PANGO_DESCENT</a> (rect)
49
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-LBEARING:CAPS" title="PANGO_LBEARING()">PANGO_LBEARING</a> (rect)
50
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-RBEARING:CAPS" title="PANGO_RBEARING()">PANGO_RBEARING</a> (rect)
51
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()">pango_extents_to_pixels</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *inclusive</code></em>,
52
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *nearest</code></em>);
53
struct <a class="link" href="pango-Glyph-Storage.html#PangoMatrix-struct" title="struct PangoMatrix">PangoMatrix</a>;
54
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-MATRIX:CAPS" title="PANGO_TYPE_MATRIX">PANGO_TYPE_MATRIX</a>
55
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS" title="PANGO_MATRIX_INIT">PANGO_MATRIX_INIT</a>
56
<a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="returnvalue">PangoMatrix</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-matrix-copy" title="pango_matrix_copy ()">pango_matrix_copy</a> (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);
57
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-free" title="pango_matrix_free ()">pango_matrix_free</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);
58
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-translate" title="pango_matrix_translate ()">pango_matrix_translate</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
59
<em class="parameter"><code><span class="type">double</span> tx</code></em>,
60
<em class="parameter"><code><span class="type">double</span> ty</code></em>);
61
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-scale" title="pango_matrix_scale ()">pango_matrix_scale</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
62
<em class="parameter"><code><span class="type">double</span> scale_x</code></em>,
63
<em class="parameter"><code><span class="type">double</span> scale_y</code></em>);
64
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-rotate" title="pango_matrix_rotate ()">pango_matrix_rotate</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
65
<em class="parameter"><code><span class="type">double</span> degrees</code></em>);
66
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-concat" title="pango_matrix_concat ()">pango_matrix_concat</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
67
<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *new_matrix</code></em>);
68
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-point" title="pango_matrix_transform_point ()">pango_matrix_transform_point</a> (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
69
<em class="parameter"><code><span class="type">double</span> *x</code></em>,
70
<em class="parameter"><code><span class="type">double</span> *y</code></em>);
71
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-distance" title="pango_matrix_transform_distance ()">pango_matrix_transform_distance</a> (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
72
<em class="parameter"><code><span class="type">double</span> *dx</code></em>,
73
<em class="parameter"><code><span class="type">double</span> *dy</code></em>);
74
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-rectangle" title="pango_matrix_transform_rectangle ()">pango_matrix_transform_rectangle</a> (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
75
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);
76
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-pixel-rectangle" title="pango_matrix_transform_pixel_rectangle ()">pango_matrix_transform_pixel_rectangle</a>
77
(<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
78
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);
79
<span class="returnvalue">double</span> <a class="link" href="pango-Glyph-Storage.html#pango-matrix-get-font-scale-factor" title="pango_matrix_get_font_scale_factor ()">pango_matrix_get_font_scale_factor</a> (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);
80
typedef <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a>;
81
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS" title="PANGO_GLYPH_EMPTY">PANGO_GLYPH_EMPTY</a>
82
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-INVALID-INPUT:CAPS" title="PANGO_GLYPH_INVALID_INPUT">PANGO_GLYPH_INVALID_INPUT</a>
83
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-UNKNOWN-FLAG:CAPS" title="PANGO_GLYPH_UNKNOWN_FLAG">PANGO_GLYPH_UNKNOWN_FLAG</a>
84
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-GET-UNKNOWN-GLYPH:CAPS" title="PANGO_GET_UNKNOWN_GLYPH()">PANGO_GET_UNKNOWN_GLYPH</a> (wc)
85
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphInfo" title="struct PangoGlyphInfo">PangoGlyphInfo</a>;
86
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphGeometry" title="struct PangoGlyphGeometry">PangoGlyphGeometry</a>;
87
typedef <a class="link" href="pango-Glyph-Storage.html#PangoGlyphUnit" title="PangoGlyphUnit">PangoGlyphUnit</a>;
88
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphVisAttr" title="struct PangoGlyphVisAttr">PangoGlyphVisAttr</a>;
89
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString-struct" title="struct PangoGlyphString">PangoGlyphString</a>;
90
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem-struct" title="struct PangoGlyphItem">PangoGlyphItem</a>;
91
struct <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter-struct" title="struct PangoGlyphItemIter">PangoGlyphItemIter</a>;
92
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-STRING:CAPS" title="PANGO_TYPE_GLYPH_STRING">PANGO_TYPE_GLYPH_STRING</a>
93
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-new" title="pango_glyph_string_new ()">pango_glyph_string_new</a> (<em class="parameter"><code><span class="type">void</span></code></em>);
94
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-copy" title="pango_glyph_string_copy ()">pango_glyph_string_copy</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);
95
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-set-size" title="pango_glyph_string_set_size ()">pango_glyph_string_set_size</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>,
96
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> new_len</code></em>);
97
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()">pango_glyph_string_free</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);
98
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents" title="pango_glyph_string_extents ()">pango_glyph_string_extents</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
99
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
100
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
101
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);
102
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents-range" title="pango_glyph_string_extents_range ()">pango_glyph_string_extents_range</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
103
<em class="parameter"><code><span class="type">int</span> start</code></em>,
104
<em class="parameter"><code><span class="type">int</span> end</code></em>,
105
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
106
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
107
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);
108
<span class="returnvalue">int</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-width" title="pango_glyph_string_get_width ()">pango_glyph_string_get_width</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>);
109
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-index-to-x" title="pango_glyph_string_index_to_x ()">pango_glyph_string_index_to_x</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
110
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
111
<em class="parameter"><code><span class="type">int</span> length</code></em>,
112
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
113
<em class="parameter"><code><span class="type">int</span> index_</code></em>,
114
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> trailing</code></em>,
115
<em class="parameter"><code><span class="type">int</span> *x_pos</code></em>);
116
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-x-to-index" title="pango_glyph_string_x_to_index ()">pango_glyph_string_x_to_index</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
117
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
118
<em class="parameter"><code><span class="type">int</span> length</code></em>,
119
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
120
<em class="parameter"><code><span class="type">int</span> x_pos</code></em>,
121
<em class="parameter"><code><span class="type">int</span> *index_</code></em>,
122
<em class="parameter"><code><span class="type">int</span> *trailing</code></em>);
123
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-logical-widths" title="pango_glyph_string_get_logical_widths ()">pango_glyph_string_get_logical_widths</a>
124
(<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
125
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
126
<em class="parameter"><code><span class="type">int</span> length</code></em>,
127
<em class="parameter"><code><span class="type">int</span> embedding_level</code></em>,
128
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);
129
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-ITEM:CAPS" title="PANGO_TYPE_GLYPH_ITEM">PANGO_TYPE_GLYPH_ITEM</a>
130
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-copy" title="pango_glyph_item_copy ()">pango_glyph_item_copy</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>);
131
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()">pango_glyph_item_free</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>);
132
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-split" title="pango_glyph_item_split ()">pango_glyph_item_split</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>,
133
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
134
<em class="parameter"><code><span class="type">int</span> split_index</code></em>);
135
<a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-apply-attrs" title="pango_glyph_item_apply_attrs ()">pango_glyph_item_apply_attrs</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
136
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
137
<em class="parameter"><code><a class="link" href="pango-Text-Attributes.html#PangoAttrList"><span class="type">PangoAttrList</span></a> *list</code></em>);
138
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-letter-space" title="pango_glyph_item_letter_space ()">pango_glyph_item_letter_space</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
139
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
140
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoLogAttr" title="PangoLogAttr"><span class="type">PangoLogAttr</span></a> *log_attrs</code></em>,
141
<em class="parameter"><code><span class="type">int</span> letter_spacing</code></em>);
142
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-get-logical-widths" title="pango_glyph_item_get_logical_widths ()">pango_glyph_item_get_logical_widths</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
143
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
144
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);
145
#define <a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-ITEM-ITER:CAPS" title="PANGO_TYPE_GLYPH_ITEM_ITER">PANGO_TYPE_GLYPH_ITEM_ITER</a>
146
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="returnvalue">PangoGlyphItemIter</span></a> * <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-copy" title="pango_glyph_item_iter_copy ()">pango_glyph_item_iter_copy</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *orig</code></em>);
147
<span class="returnvalue">void</span> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-free" title="pango_glyph_item_iter_free ()">pango_glyph_item_iter_free</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);
148
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-init-start" title="pango_glyph_item_iter_init_start ()">pango_glyph_item_iter_init_start</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
149
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
150
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);
151
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-init-end" title="pango_glyph_item_iter_init_end ()">pango_glyph_item_iter_init_end</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
152
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
153
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);
154
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-next-cluster" title="pango_glyph_item_iter_next_cluster ()">pango_glyph_item_iter_next_cluster</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);
155
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-prev-cluster" title="pango_glyph_item_iter_prev_cluster ()">pango_glyph_item_iter_prev_cluster</a> (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);
35
<div class="refsect1">
36
<a name="pango-Glyph-Storage.functions"></a><h2>Functions</h2>
37
<div class="informaltable"><table width="100%" border="0">
39
<col width="150px" class="functions_return">
40
<col class="functions_name">
44
<td class="define_keyword">#define</td>
45
<td class="function_name">
46
<a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS:CAPS" title="PANGO_PIXELS()">PANGO_PIXELS</a><span class="c_punctuation">()</span>
50
<td class="define_keyword">#define</td>
51
<td class="function_name">
52
<a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS-FLOOR:CAPS" title="PANGO_PIXELS_FLOOR()">PANGO_PIXELS_FLOOR</a><span class="c_punctuation">()</span>
56
<td class="define_keyword">#define</td>
57
<td class="function_name">
58
<a class="link" href="pango-Glyph-Storage.html#PANGO-PIXELS-CEIL:CAPS" title="PANGO_PIXELS_CEIL()">PANGO_PIXELS_CEIL</a><span class="c_punctuation">()</span>
62
<td class="define_keyword">#define</td>
63
<td class="function_name">
64
<a class="link" href="pango-Glyph-Storage.html#PANGO-UNITS-ROUND:CAPS" title="PANGO_UNITS_ROUND()">PANGO_UNITS_ROUND</a><span class="c_punctuation">()</span>
68
<td class="function_type">
69
<span class="returnvalue">double</span>
71
<td class="function_name">
72
<a class="link" href="pango-Glyph-Storage.html#pango-units-to-double" title="pango_units_to_double ()">pango_units_to_double</a> <span class="c_punctuation">()</span>
76
<td class="function_type">
77
<span class="returnvalue">int</span>
79
<td class="function_name">
80
<a class="link" href="pango-Glyph-Storage.html#pango-units-from-double" title="pango_units_from_double ()">pango_units_from_double</a> <span class="c_punctuation">()</span>
84
<td class="define_keyword">#define</td>
85
<td class="function_name">
86
<a class="link" href="pango-Glyph-Storage.html#PANGO-ASCENT:CAPS" title="PANGO_ASCENT()">PANGO_ASCENT</a><span class="c_punctuation">()</span>
90
<td class="define_keyword">#define</td>
91
<td class="function_name">
92
<a class="link" href="pango-Glyph-Storage.html#PANGO-DESCENT:CAPS" title="PANGO_DESCENT()">PANGO_DESCENT</a><span class="c_punctuation">()</span>
96
<td class="define_keyword">#define</td>
97
<td class="function_name">
98
<a class="link" href="pango-Glyph-Storage.html#PANGO-LBEARING:CAPS" title="PANGO_LBEARING()">PANGO_LBEARING</a><span class="c_punctuation">()</span>
102
<td class="define_keyword">#define</td>
103
<td class="function_name">
104
<a class="link" href="pango-Glyph-Storage.html#PANGO-RBEARING:CAPS" title="PANGO_RBEARING()">PANGO_RBEARING</a><span class="c_punctuation">()</span>
108
<td class="function_type">
109
<span class="returnvalue">void</span>
111
<td class="function_name">
112
<a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()">pango_extents_to_pixels</a> <span class="c_punctuation">()</span>
116
<td class="define_keyword">#define</td>
117
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-MATRIX:CAPS" title="PANGO_TYPE_MATRIX">PANGO_TYPE_MATRIX</a></td>
120
<td class="function_type">
121
<a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="returnvalue">PangoMatrix</span></a> *
123
<td class="function_name">
124
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-copy" title="pango_matrix_copy ()">pango_matrix_copy</a> <span class="c_punctuation">()</span>
128
<td class="function_type">
129
<span class="returnvalue">void</span>
131
<td class="function_name">
132
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-free" title="pango_matrix_free ()">pango_matrix_free</a> <span class="c_punctuation">()</span>
136
<td class="function_type">
137
<span class="returnvalue">void</span>
139
<td class="function_name">
140
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-translate" title="pango_matrix_translate ()">pango_matrix_translate</a> <span class="c_punctuation">()</span>
144
<td class="function_type">
145
<span class="returnvalue">void</span>
147
<td class="function_name">
148
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-scale" title="pango_matrix_scale ()">pango_matrix_scale</a> <span class="c_punctuation">()</span>
152
<td class="function_type">
153
<span class="returnvalue">void</span>
155
<td class="function_name">
156
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-rotate" title="pango_matrix_rotate ()">pango_matrix_rotate</a> <span class="c_punctuation">()</span>
160
<td class="function_type">
161
<span class="returnvalue">void</span>
163
<td class="function_name">
164
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-concat" title="pango_matrix_concat ()">pango_matrix_concat</a> <span class="c_punctuation">()</span>
168
<td class="function_type">
169
<span class="returnvalue">void</span>
171
<td class="function_name">
172
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-point" title="pango_matrix_transform_point ()">pango_matrix_transform_point</a> <span class="c_punctuation">()</span>
176
<td class="function_type">
177
<span class="returnvalue">void</span>
179
<td class="function_name">
180
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-distance" title="pango_matrix_transform_distance ()">pango_matrix_transform_distance</a> <span class="c_punctuation">()</span>
184
<td class="function_type">
185
<span class="returnvalue">void</span>
187
<td class="function_name">
188
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-rectangle" title="pango_matrix_transform_rectangle ()">pango_matrix_transform_rectangle</a> <span class="c_punctuation">()</span>
192
<td class="function_type">
193
<span class="returnvalue">void</span>
195
<td class="function_name">
196
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-pixel-rectangle" title="pango_matrix_transform_pixel_rectangle ()">pango_matrix_transform_pixel_rectangle</a> <span class="c_punctuation">()</span>
200
<td class="function_type">
201
<span class="returnvalue">double</span>
203
<td class="function_name">
204
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-get-font-scale-factor" title="pango_matrix_get_font_scale_factor ()">pango_matrix_get_font_scale_factor</a> <span class="c_punctuation">()</span>
208
<td class="define_keyword">#define</td>
209
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS" title="PANGO_GLYPH_EMPTY">PANGO_GLYPH_EMPTY</a></td>
212
<td class="define_keyword">#define</td>
213
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-INVALID-INPUT:CAPS" title="PANGO_GLYPH_INVALID_INPUT">PANGO_GLYPH_INVALID_INPUT</a></td>
216
<td class="define_keyword">#define</td>
217
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-UNKNOWN-FLAG:CAPS" title="PANGO_GLYPH_UNKNOWN_FLAG">PANGO_GLYPH_UNKNOWN_FLAG</a></td>
220
<td class="define_keyword">#define</td>
221
<td class="function_name">
222
<a class="link" href="pango-Glyph-Storage.html#PANGO-GET-UNKNOWN-GLYPH:CAPS" title="PANGO_GET_UNKNOWN_GLYPH()">PANGO_GET_UNKNOWN_GLYPH</a><span class="c_punctuation">()</span>
226
<td class="define_keyword">#define</td>
227
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-STRING:CAPS" title="PANGO_TYPE_GLYPH_STRING">PANGO_TYPE_GLYPH_STRING</a></td>
230
<td class="function_type">
231
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> *
233
<td class="function_name">
234
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-new" title="pango_glyph_string_new ()">pango_glyph_string_new</a> <span class="c_punctuation">()</span>
238
<td class="function_type">
239
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> *
241
<td class="function_name">
242
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-copy" title="pango_glyph_string_copy ()">pango_glyph_string_copy</a> <span class="c_punctuation">()</span>
246
<td class="function_type">
247
<span class="returnvalue">void</span>
249
<td class="function_name">
250
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-set-size" title="pango_glyph_string_set_size ()">pango_glyph_string_set_size</a> <span class="c_punctuation">()</span>
254
<td class="function_type">
255
<span class="returnvalue">void</span>
257
<td class="function_name">
258
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()">pango_glyph_string_free</a> <span class="c_punctuation">()</span>
262
<td class="function_type">
263
<span class="returnvalue">void</span>
265
<td class="function_name">
266
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents" title="pango_glyph_string_extents ()">pango_glyph_string_extents</a> <span class="c_punctuation">()</span>
270
<td class="function_type">
271
<span class="returnvalue">void</span>
273
<td class="function_name">
274
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents-range" title="pango_glyph_string_extents_range ()">pango_glyph_string_extents_range</a> <span class="c_punctuation">()</span>
278
<td class="function_type">
279
<span class="returnvalue">int</span>
281
<td class="function_name">
282
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-width" title="pango_glyph_string_get_width ()">pango_glyph_string_get_width</a> <span class="c_punctuation">()</span>
286
<td class="function_type">
287
<span class="returnvalue">void</span>
289
<td class="function_name">
290
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-index-to-x" title="pango_glyph_string_index_to_x ()">pango_glyph_string_index_to_x</a> <span class="c_punctuation">()</span>
294
<td class="function_type">
295
<span class="returnvalue">void</span>
297
<td class="function_name">
298
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-x-to-index" title="pango_glyph_string_x_to_index ()">pango_glyph_string_x_to_index</a> <span class="c_punctuation">()</span>
302
<td class="function_type">
303
<span class="returnvalue">void</span>
305
<td class="function_name">
306
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-logical-widths" title="pango_glyph_string_get_logical_widths ()">pango_glyph_string_get_logical_widths</a> <span class="c_punctuation">()</span>
310
<td class="define_keyword">#define</td>
311
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-ITEM:CAPS" title="PANGO_TYPE_GLYPH_ITEM">PANGO_TYPE_GLYPH_ITEM</a></td>
314
<td class="function_type">
315
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> *
317
<td class="function_name">
318
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-copy" title="pango_glyph_item_copy ()">pango_glyph_item_copy</a> <span class="c_punctuation">()</span>
322
<td class="function_type">
323
<span class="returnvalue">void</span>
325
<td class="function_name">
326
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()">pango_glyph_item_free</a> <span class="c_punctuation">()</span>
330
<td class="function_type">
331
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> *
333
<td class="function_name">
334
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-split" title="pango_glyph_item_split ()">pango_glyph_item_split</a> <span class="c_punctuation">()</span>
338
<td class="function_type">
339
<a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> *
341
<td class="function_name">
342
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-apply-attrs" title="pango_glyph_item_apply_attrs ()">pango_glyph_item_apply_attrs</a> <span class="c_punctuation">()</span>
346
<td class="function_type">
347
<span class="returnvalue">void</span>
349
<td class="function_name">
350
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-letter-space" title="pango_glyph_item_letter_space ()">pango_glyph_item_letter_space</a> <span class="c_punctuation">()</span>
354
<td class="function_type">
355
<span class="returnvalue">void</span>
357
<td class="function_name">
358
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-get-logical-widths" title="pango_glyph_item_get_logical_widths ()">pango_glyph_item_get_logical_widths</a> <span class="c_punctuation">()</span>
362
<td class="define_keyword">#define</td>
363
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-TYPE-GLYPH-ITEM-ITER:CAPS" title="PANGO_TYPE_GLYPH_ITEM_ITER">PANGO_TYPE_GLYPH_ITEM_ITER</a></td>
366
<td class="function_type">
367
<a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="returnvalue">PangoGlyphItemIter</span></a> *
369
<td class="function_name">
370
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-copy" title="pango_glyph_item_iter_copy ()">pango_glyph_item_iter_copy</a> <span class="c_punctuation">()</span>
374
<td class="function_type">
375
<span class="returnvalue">void</span>
377
<td class="function_name">
378
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-free" title="pango_glyph_item_iter_free ()">pango_glyph_item_iter_free</a> <span class="c_punctuation">()</span>
382
<td class="function_type">
383
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
385
<td class="function_name">
386
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-init-start" title="pango_glyph_item_iter_init_start ()">pango_glyph_item_iter_init_start</a> <span class="c_punctuation">()</span>
390
<td class="function_type">
391
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
393
<td class="function_name">
394
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-init-end" title="pango_glyph_item_iter_init_end ()">pango_glyph_item_iter_init_end</a> <span class="c_punctuation">()</span>
398
<td class="function_type">
399
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
401
<td class="function_name">
402
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-next-cluster" title="pango_glyph_item_iter_next_cluster ()">pango_glyph_item_iter_next_cluster</a> <span class="c_punctuation">()</span>
406
<td class="function_type">
407
<a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
409
<td class="function_name">
410
<a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-prev-cluster" title="pango_glyph_item_iter_prev_cluster ()">pango_glyph_item_iter_prev_cluster</a> <span class="c_punctuation">()</span>
416
<a name="PangoMatrix"></a><a name="PangoGlyphString"></a><a name="PangoGlyphItem"></a><a name="PangoGlyphItemIter"></a><div class="refsect1">
417
<a name="pango-Glyph-Storage.other"></a><h2>Types and Values</h2>
418
<div class="informaltable"><table width="100%" border="0">
420
<col width="150px" class="name">
421
<col class="description">
425
<td class="define_keyword">#define</td>
426
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE">PANGO_SCALE</a></td>
429
<td class="datatype_keyword">struct</td>
430
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle">PangoRectangle</a></td>
433
<td class="datatype_keyword">struct</td>
434
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoMatrix-struct" title="struct PangoMatrix">PangoMatrix</a></td>
437
<td class="define_keyword">#define</td>
438
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS" title="PANGO_MATRIX_INIT">PANGO_MATRIX_INIT</a></td>
441
<td class="typedef_keyword">typedef</td>
442
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph">PangoGlyph</a></td>
445
<td class="datatype_keyword">struct</td>
446
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphInfo" title="struct PangoGlyphInfo">PangoGlyphInfo</a></td>
449
<td class="datatype_keyword">struct</td>
450
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphGeometry" title="struct PangoGlyphGeometry">PangoGlyphGeometry</a></td>
453
<td class="typedef_keyword">typedef</td>
454
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphUnit" title="PangoGlyphUnit">PangoGlyphUnit</a></td>
457
<td class="datatype_keyword">struct</td>
458
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphVisAttr" title="struct PangoGlyphVisAttr">PangoGlyphVisAttr</a></td>
461
<td class="datatype_keyword">struct</td>
462
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString-struct" title="struct PangoGlyphString">PangoGlyphString</a></td>
465
<td class="datatype_keyword">struct</td>
466
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem-struct" title="struct PangoGlyphItem">PangoGlyphItem</a></td>
469
<td class="datatype_keyword">struct</td>
470
<td class="function_name"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter-struct" title="struct PangoGlyphItemIter">PangoGlyphItemIter</a></td>
158
475
<div class="refsect1">
159
476
<a name="pango-Glyph-Storage.object-hierarchy"></a><h2>Object Hierarchy</h2>
160
<pre class="synopsis">
164
<pre class="synopsis">
166
+----PangoGlyphString
168
<pre class="synopsis">
172
<pre class="synopsis">
174
+----PangoGlyphItemIter
477
<pre class="screen"> GBoxed
478
<span class="lineart">├──</span> PangoGlyphItem
479
<span class="lineart">├──</span> PangoGlyphItemIter
480
<span class="lineart">├──</span> PangoGlyphString
481
<span class="lineart">╰──</span> PangoMatrix
177
484
<div class="refsect1">
178
485
<a name="pango-Glyph-Storage.description"></a><h2>Description</h2>
180
<a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a> produces a string of glyphs which
486
<p>pango_shape() produces a string of glyphs which
181
487
can be measured or drawn to the screen. The following
182
488
structures are used to store information about
185
491
<div class="refsect1">
186
<a name="pango-Glyph-Storage.details"></a><h2>Details</h2>
187
<div class="refsect2">
188
<a name="PANGO-SCALE:CAPS"></a><h3>PANGO_SCALE</h3>
189
<pre class="programlisting">#define PANGO_SCALE 1024
192
The <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> macro represents the scale between dimensions used
193
for Pango distances and device units. (The definition of device
194
units is dependent on the output device; it will typically be pixels
195
for a screen, and points for a printer.) <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> is currently
196
1024, but this may be changed in the future.</p>
198
When setting font sizes, device units are always considered to be
199
points (as in "12 point font"), rather than pixels.</p>
492
<a name="pango-Glyph-Storage.functions_details"></a><h2>Functions</h2>
202
493
<div class="refsect2">
203
494
<a name="PANGO-PIXELS:CAPS"></a><h3>PANGO_PIXELS()</h3>
204
495
<pre class="programlisting">#define PANGO_PIXELS(d) (((int)(d) + 512) >> 10)
207
Converts a dimension to device units by rounding.</p>
208
<div class="variablelist"><table border="0" class="variablelist">
497
<p>Converts a dimension to device units by rounding.</p>
498
<div class="refsect3">
499
<a name="id-1.2.3.11.2.5"></a><h4>Parameters</h4>
500
<div class="informaltable"><table width="100%" border="0">
210
<col align="left" valign="top">
502
<col width="150px" class="parameters_name">
503
<col class="parameters_description">
504
<col width="200px" class="parameters_annotations">
215
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
216
<td>a dimension in Pango units.</td>
219
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
220
<td>rounded dimension in device units.</td>
507
<td class="parameter_name"><p>d</p></td>
508
<td class="parameter_description"><p>a dimension in Pango units.</p></td>
509
<td class="parameter_annotations"> </td>
513
<div class="refsect3">
514
<a name="id-1.2.3.11.2.6"></a><h4>Returns</h4>
515
<p> rounded dimension in device units.</p>
226
520
<div class="refsect2">
227
521
<a name="PANGO-PIXELS-FLOOR:CAPS"></a><h3>PANGO_PIXELS_FLOOR()</h3>
228
522
<pre class="programlisting">#define PANGO_PIXELS_FLOOR(d) (((int)(d)) >> 10)
231
Converts a dimension to device units by flooring.</p>
232
<div class="variablelist"><table border="0" class="variablelist">
524
<p>Converts a dimension to device units by flooring.</p>
525
<div class="refsect3">
526
<a name="id-1.2.3.11.3.5"></a><h4>Parameters</h4>
527
<div class="informaltable"><table width="100%" border="0">
234
<col align="left" valign="top">
529
<col width="150px" class="parameters_name">
530
<col class="parameters_description">
531
<col width="200px" class="parameters_annotations">
239
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
240
<td>a dimension in Pango units.</td>
243
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
244
<td>floored dimension in device units.</td>
534
<td class="parameter_name"><p>d</p></td>
535
<td class="parameter_description"><p>a dimension in Pango units.</p></td>
536
<td class="parameter_annotations"> </td>
540
<div class="refsect3">
541
<a name="id-1.2.3.11.3.6"></a><h4>Returns</h4>
542
<p> floored dimension in device units.</p>
248
545
<p class="since">Since 1.14</p>
252
549
<a name="PANGO-PIXELS-CEIL:CAPS"></a><h3>PANGO_PIXELS_CEIL()</h3>
253
550
<pre class="programlisting">#define PANGO_PIXELS_CEIL(d) (((int)(d) + 1023) >> 10)
256
Converts a dimension to device units by ceiling.</p>
257
<div class="variablelist"><table border="0" class="variablelist">
552
<p>Converts a dimension to device units by ceiling.</p>
553
<div class="refsect3">
554
<a name="id-1.2.3.11.4.5"></a><h4>Parameters</h4>
555
<div class="informaltable"><table width="100%" border="0">
259
<col align="left" valign="top">
557
<col width="150px" class="parameters_name">
558
<col class="parameters_description">
559
<col width="200px" class="parameters_annotations">
264
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
265
<td>a dimension in Pango units.</td>
268
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
269
<td>ceiled dimension in device units.</td>
562
<td class="parameter_name"><p>d</p></td>
563
<td class="parameter_description"><p>a dimension in Pango units.</p></td>
564
<td class="parameter_annotations"> </td>
568
<div class="refsect3">
569
<a name="id-1.2.3.11.4.6"></a><h4>Returns</h4>
570
<p> ceiled dimension in device units.</p>
273
573
<p class="since">Since 1.14</p>
276
576
<div class="refsect2">
277
577
<a name="PANGO-UNITS-ROUND:CAPS"></a><h3>PANGO_UNITS_ROUND()</h3>
278
578
<pre class="programlisting">#define PANGO_UNITS_ROUND(d)</pre>
280
Rounds a dimension to whole device units, but does not
579
<p>Rounds a dimension to whole device units, but does not
281
580
convert it to device units.</p>
282
<div class="variablelist"><table border="0" class="variablelist">
581
<div class="refsect3">
582
<a name="id-1.2.3.11.5.5"></a><h4>Parameters</h4>
583
<div class="informaltable"><table width="100%" border="0">
284
<col align="left" valign="top">
585
<col width="150px" class="parameters_name">
586
<col class="parameters_description">
587
<col width="200px" class="parameters_annotations">
289
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
290
<td>a dimension in Pango units.</td>
293
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
294
<td>rounded dimension in Pango units.</td>
590
<td class="parameter_name"><p>d</p></td>
591
<td class="parameter_description"><p>a dimension in Pango units.</p></td>
592
<td class="parameter_annotations"> </td>
596
<div class="refsect3">
597
<a name="id-1.2.3.11.5.6"></a><h4>Returns</h4>
598
<p> rounded dimension in Pango units.</p>
298
601
<p class="since">Since 1.18</p>
301
604
<div class="refsect2">
302
<a name="pango-units-to-double"></a><h3>pango_units_to_double ()</h3>
303
<pre class="programlisting"><span class="returnvalue">double</span> pango_units_to_double (<em class="parameter"><code><span class="type">int</span> i</code></em>);</pre>
305
Converts a number in Pango units to floating-point: divides
605
<a name="pango-units-to-double"></a><h3>pango_units_to_double ()</h3>
606
<pre class="programlisting"><span class="returnvalue">double</span>
607
pango_units_to_double (<em class="parameter"><code><span class="type">int</span> i</code></em>);</pre>
608
<p>Converts a number in Pango units to floating-point: divides
306
609
it by <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a>.</p>
307
<div class="variablelist"><table border="0" class="variablelist">
610
<div class="refsect3">
611
<a name="id-1.2.3.11.6.5"></a><h4>Parameters</h4>
612
<div class="informaltable"><table width="100%" border="0">
309
<col align="left" valign="top">
614
<col width="150px" class="parameters_name">
615
<col class="parameters_description">
616
<col width="200px" class="parameters_annotations">
314
<td><p><span class="term"><em class="parameter"><code>i</code></em> :</span></p></td>
315
<td>value in Pango units</td>
318
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
319
<td>the double value.</td>
619
<td class="parameter_name"><p>i</p></td>
620
<td class="parameter_description"><p>value in Pango units</p></td>
621
<td class="parameter_annotations"> </td>
625
<div class="refsect3">
626
<a name="id-1.2.3.11.6.6"></a><h4>Returns</h4>
627
<p> the double value.</p>
323
630
<p class="since">Since 1.16</p>
326
633
<div class="refsect2">
327
<a name="pango-units-from-double"></a><h3>pango_units_from_double ()</h3>
328
<pre class="programlisting"><span class="returnvalue">int</span> pango_units_from_double (<em class="parameter"><code><span class="type">double</span> d</code></em>);</pre>
330
Converts a floating-point number to Pango units: multiplies
634
<a name="pango-units-from-double"></a><h3>pango_units_from_double ()</h3>
635
<pre class="programlisting"><span class="returnvalue">int</span>
636
pango_units_from_double (<em class="parameter"><code><span class="type">double</span> d</code></em>);</pre>
637
<p>Converts a floating-point number to Pango units: multiplies
331
638
it by <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> and rounds to nearest integer.</p>
332
<div class="variablelist"><table border="0" class="variablelist">
639
<div class="refsect3">
640
<a name="id-1.2.3.11.7.5"></a><h4>Parameters</h4>
641
<div class="informaltable"><table width="100%" border="0">
334
<col align="left" valign="top">
643
<col width="150px" class="parameters_name">
644
<col class="parameters_description">
645
<col width="200px" class="parameters_annotations">
339
<td><p><span class="term"><em class="parameter"><code>d</code></em> :</span></p></td>
340
<td>double floating-point value</td>
343
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
344
<td>the value in Pango units.</td>
648
<td class="parameter_name"><p>d</p></td>
649
<td class="parameter_description"><p>double floating-point value</p></td>
650
<td class="parameter_annotations"> </td>
654
<div class="refsect3">
655
<a name="id-1.2.3.11.7.6"></a><h4>Returns</h4>
656
<p> the value in Pango units.</p>
348
659
<p class="since">Since 1.16</p>
351
662
<div class="refsect2">
352
<a name="PangoRectangle"></a><h3>struct PangoRectangle</h3>
353
<pre class="programlisting">struct PangoRectangle {
361
The <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> structure represents a rectangle. It is frequently
362
used to represent the logical or ink extents of a single glyph or section
363
of text. (See, for instance, <a class="link" href="pango-Fonts.html#pango-font-get-glyph-extents" title="pango_font_get_glyph_extents ()"><code class="function">pango_font_get_glyph_extents()</code></a>)</p>
364
<div class="variablelist"><table border="0" class="variablelist">
366
<col align="left" valign="top">
371
<td><p><span class="term"><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.x"></a>x</code></em>;</span></p></td>
372
<td>X coordinate of the left side of the rectangle.</td>
375
<td><p><span class="term"><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.y"></a>y</code></em>;</span></p></td>
376
<td>Y coordinate of the the top side of the rectangle.</td>
379
<td><p><span class="term"><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.width"></a>width</code></em>;</span></p></td>
380
<td>width of the rectangle.</td>
383
<td><p><span class="term"><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.height"></a>height</code></em>;</span></p></td>
384
<td>height of the rectangle.</td>
390
<div class="refsect2">
391
663
<a name="PANGO-ASCENT:CAPS"></a><h3>PANGO_ASCENT()</h3>
392
664
<pre class="programlisting">#define PANGO_ASCENT(rect) (-(rect).y)
395
Extracts the <em class="firstterm">ascent</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
666
<p>Extracts the <em class="firstterm">ascent</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
396
667
representing glyph extents. The ascent is the distance from the
397
668
baseline to the highest point of the character. This is positive if the
398
669
glyph ascends above the baseline.</p>
399
<div class="variablelist"><table border="0" class="variablelist">
670
<div class="refsect3">
671
<a name="id-1.2.3.11.8.5"></a><h4>Parameters</h4>
672
<div class="informaltable"><table width="100%" border="0">
401
<col align="left" valign="top">
674
<col width="150px" class="parameters_name">
675
<col class="parameters_description">
676
<col width="200px" class="parameters_annotations">
405
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
406
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
679
<td class="parameter_name"><p>rect</p></td>
680
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a></p></td>
681
<td class="parameter_annotations"> </td>
412
687
<div class="refsect2">
413
688
<a name="PANGO-DESCENT:CAPS"></a><h3>PANGO_DESCENT()</h3>
414
689
<pre class="programlisting">#define PANGO_DESCENT(rect) ((rect).y + (rect).height)
417
Extracts the <em class="firstterm">descent</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
691
<p>Extracts the <em class="firstterm">descent</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
418
692
representing glyph extents. The descent is the distance from the
419
693
baseline to the lowest point of the character. This is positive if the
420
694
glyph descends below the baseline.</p>
421
<div class="variablelist"><table border="0" class="variablelist">
695
<div class="refsect3">
696
<a name="id-1.2.3.11.9.5"></a><h4>Parameters</h4>
697
<div class="informaltable"><table width="100%" border="0">
423
<col align="left" valign="top">
699
<col width="150px" class="parameters_name">
700
<col class="parameters_description">
701
<col width="200px" class="parameters_annotations">
427
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
428
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
704
<td class="parameter_name"><p>rect</p></td>
705
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a></p></td>
706
<td class="parameter_annotations"> </td>
434
712
<div class="refsect2">
435
713
<a name="PANGO-LBEARING:CAPS"></a><h3>PANGO_LBEARING()</h3>
436
714
<pre class="programlisting">#define PANGO_LBEARING(rect) ((rect).x)
439
Extracts the <em class="firstterm">left bearing</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
716
<p>Extracts the <em class="firstterm">left bearing</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
440
717
representing glyph extents. The left bearing is the distance from the
441
718
horizontal origin to the farthest left point of the character.
442
719
This is positive for characters drawn completely to the right of the
443
720
glyph origin.</p>
444
<div class="variablelist"><table border="0" class="variablelist">
721
<div class="refsect3">
722
<a name="id-1.2.3.11.10.5"></a><h4>Parameters</h4>
723
<div class="informaltable"><table width="100%" border="0">
446
<col align="left" valign="top">
725
<col width="150px" class="parameters_name">
726
<col class="parameters_description">
727
<col width="200px" class="parameters_annotations">
450
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
451
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
730
<td class="parameter_name"><p>rect</p></td>
731
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a></p></td>
732
<td class="parameter_annotations"> </td>
457
738
<div class="refsect2">
458
739
<a name="PANGO-RBEARING:CAPS"></a><h3>PANGO_RBEARING()</h3>
459
740
<pre class="programlisting">#define PANGO_RBEARING(rect) ((rect).x + (rect).width)
462
Extracts the <em class="firstterm">right bearing</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
742
<p>Extracts the <em class="firstterm">right bearing</em> from a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
463
743
representing glyph extents. The right bearing is the distance from the
464
744
horizontal origin to the farthest right point of the character.
465
745
This is positive except for characters drawn completely to the left of the
466
746
horizontal origin.</p>
467
<div class="variablelist"><table border="0" class="variablelist">
747
<div class="refsect3">
748
<a name="id-1.2.3.11.11.5"></a><h4>Parameters</h4>
749
<div class="informaltable"><table width="100%" border="0">
469
<col align="left" valign="top">
751
<col width="150px" class="parameters_name">
752
<col class="parameters_description">
753
<col width="200px" class="parameters_annotations">
473
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
474
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a>
756
<td class="parameter_name"><p>rect</p></td>
757
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a></p></td>
758
<td class="parameter_annotations"> </td>
480
764
<div class="refsect2">
481
<a name="pango-extents-to-pixels"></a><h3>pango_extents_to_pixels ()</h3>
482
<pre class="programlisting"><span class="returnvalue">void</span> pango_extents_to_pixels (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *inclusive</code></em>,
483
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *nearest</code></em>);</pre>
485
Converts extents from Pango units to device units, dividing by the
765
<a name="pango-extents-to-pixels"></a><h3>pango_extents_to_pixels ()</h3>
766
<pre class="programlisting"><span class="returnvalue">void</span>
767
pango_extents_to_pixels (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *inclusive</code></em>,
768
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *nearest</code></em>);</pre>
769
<p>Converts extents from Pango units to device units, dividing by the
486
770
<a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> factor and performing rounding.</p>
488
The <em class="parameter"><code>inclusive</code></em> rectangle is converted by flooring the x/y coordinates and extending
771
<p>The <em class="parameter"><code>inclusive</code></em>
772
rectangle is converted by flooring the x/y coordinates and extending
489
773
width/height, such that the final rectangle completely includes the original
492
The <em class="parameter"><code>nearest</code></em> rectangle is converted by rounding the coordinates
775
<p>The <em class="parameter"><code>nearest</code></em>
776
rectangle is converted by rounding the coordinates
493
777
of the rectangle to the nearest device unit (pixel).</p>
495
The rule to which argument to use is: if you want the resulting device-space
496
rectangle to completely contain the original rectangle, pass it in as <em class="parameter"><code>inclusive</code></em>.
778
<p>The rule to which argument to use is: if you want the resulting device-space
779
rectangle to completely contain the original rectangle, pass it in as <em class="parameter"><code>inclusive</code></em>
497
781
If you want two touching-but-not-overlapping rectangles stay
498
782
touching-but-not-overlapping after rounding to device units, pass them in
499
as <em class="parameter"><code>nearest</code></em>.</p>
500
<div class="variablelist"><table border="0" class="variablelist">
783
as <em class="parameter"><code>nearest</code></em>
785
<div class="refsect3">
786
<a name="id-1.2.3.11.12.8"></a><h4>Parameters</h4>
787
<div class="informaltable"><table width="100%" border="0">
502
<col align="left" valign="top">
789
<col width="150px" class="parameters_name">
790
<col class="parameters_description">
791
<col width="200px" class="parameters_annotations">
507
<td><p><span class="term"><em class="parameter"><code>inclusive</code></em> :</span></p></td>
508
<td>rectangle to round to pixels inclusively, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
795
<td class="parameter_name"><p>inclusive</p></td>
796
<td class="parameter_description"><p> rectangle to round to pixels inclusively, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
797
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
512
<td><p><span class="term"><em class="parameter"><code>nearest</code></em> :</span></p></td>
513
<td>rectangle to round to nearest pixels, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
800
<td class="parameter_name"><p>nearest</p></td>
801
<td class="parameter_description"><p> rectangle to round to nearest pixels, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
802
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
518
807
<p class="since">Since 1.16</p>
521
810
<div class="refsect2">
522
<a name="PangoMatrix-struct"></a><h3>struct PangoMatrix</h3>
523
<pre class="programlisting">struct PangoMatrix {
533
A structure specifying a transformation between user-space
534
coordinates and device coordinates. The transformation
538
<pre class="programlisting">
539
x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0;
540
y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0;
542
<div class="variablelist"><table border="0" class="variablelist">
544
<col align="left" valign="top">
549
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.xx"></a>xx</code></em>;</span></p></td>
550
<td>1st component of the transformation matrix</td>
553
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.xy"></a>xy</code></em>;</span></p></td>
554
<td>2nd component of the transformation matrix</td>
557
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.yx"></a>yx</code></em>;</span></p></td>
558
<td>3rd component of the transformation matrix</td>
561
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.yy"></a>yy</code></em>;</span></p></td>
562
<td>4th component of the transformation matrix</td>
565
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.x0"></a>x0</code></em>;</span></p></td>
566
<td>x translation</td>
569
<td><p><span class="term"><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.y0"></a>y0</code></em>;</span></p></td>
570
<td>y translation</td>
574
<p class="since">Since 1.6</p>
577
<div class="refsect2">
578
811
<a name="PANGO-TYPE-MATRIX:CAPS"></a><h3>PANGO_TYPE_MATRIX</h3>
579
812
<pre class="programlisting">#define PANGO_TYPE_MATRIX (pango_matrix_get_type ())
582
The GObject type for <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p>
585
<div class="refsect2">
586
<a name="PANGO-MATRIX-INIT:CAPS"></a><h3>PANGO_MATRIX_INIT</h3>
587
<pre class="programlisting">#define PANGO_MATRIX_INIT { 1., 0., 0., 1., 0., 0. }
590
Constant that can be used to initialize a PangoMatrix to
591
the identity transform.</p>
594
<div class="informalexample">
595
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
598
<td class="listing_lines" align="right"><pre>1
600
<td class="listing_code"><pre class="programlisting"><span class="usertype">PangoMatrix</span><span class="normal"> matrix </span><span class="symbol">=</span><span class="normal"> <a href="pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS">PANGO_MATRIX_INIT</a></span><span class="symbol">;</span>
601
<span class="function"><a href="pango-Glyph-Storage.html#pango-matrix-rotate">pango_matrix_rotate</a></span><span class="normal"> </span><span class="symbol">(&</span><span class="normal">matrix</span><span class="symbol">,</span><span class="normal"> </span><span class="number">45</span><span class="symbol">.);</span></pre></td>
607
<p class="since">Since 1.6</p>
610
<div class="refsect2">
611
<a name="pango-matrix-copy"></a><h3>pango_matrix_copy ()</h3>
612
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="returnvalue">PangoMatrix</span></a> * pango_matrix_copy (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
614
Copies a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>.</p>
615
<div class="variablelist"><table border="0" class="variablelist">
617
<col align="left" valign="top">
622
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
623
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
627
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
628
<td>the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, which should
629
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-matrix-free" title="pango_matrix_free ()"><code class="function">pango_matrix_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
630
<em class="parameter"><code>matrix</code></em> was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
634
<p class="since">Since 1.6</p>
637
<div class="refsect2">
638
<a name="pango-matrix-free"></a><h3>pango_matrix_free ()</h3>
639
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
641
Free a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> created with <a class="link" href="pango-Glyph-Storage.html#pango-matrix-copy" title="pango_matrix_copy ()"><code class="function">pango_matrix_copy()</code></a>.</p>
642
<div class="variablelist"><table border="0" class="variablelist">
644
<col align="left" valign="top">
648
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
649
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
653
<p class="since">Since 1.6</p>
656
<div class="refsect2">
657
<a name="pango-matrix-translate"></a><h3>pango_matrix_translate ()</h3>
658
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_translate (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
659
<em class="parameter"><code><span class="type">double</span> tx</code></em>,
660
<em class="parameter"><code><span class="type">double</span> ty</code></em>);</pre>
662
Changes the transformation represented by <em class="parameter"><code>matrix</code></em> to be the
663
transformation given by first translating by (<em class="parameter"><code>tx</code></em>, <em class="parameter"><code>ty</code></em>)
814
<p>The GObject type for <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p>
817
<div class="refsect2">
818
<a name="pango-matrix-copy"></a><h3>pango_matrix_copy ()</h3>
819
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="returnvalue">PangoMatrix</span></a> *
820
pango_matrix_copy (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
821
<p>Copies a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>.</p>
822
<div class="refsect3">
823
<a name="id-1.2.3.11.14.5"></a><h4>Parameters</h4>
824
<div class="informaltable"><table width="100%" border="0">
826
<col width="150px" class="parameters_name">
827
<col class="parameters_description">
828
<col width="200px" class="parameters_annotations">
831
<td class="parameter_name"><p>matrix</p></td>
832
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
833
<td class="parameter_annotations"> </td>
837
<div class="refsect3">
838
<a name="id-1.2.3.11.14.6"></a><h4>Returns</h4>
839
<p> the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, which should
840
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-matrix-free" title="pango_matrix_free ()"><code class="function">pango_matrix_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if
841
<em class="parameter"><code>matrix</code></em>
842
was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
845
<p class="since">Since 1.6</p>
848
<div class="refsect2">
849
<a name="pango-matrix-free"></a><h3>pango_matrix_free ()</h3>
850
<pre class="programlisting"><span class="returnvalue">void</span>
851
pango_matrix_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
852
<p>Free a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> created with <a class="link" href="pango-Glyph-Storage.html#pango-matrix-copy" title="pango_matrix_copy ()"><code class="function">pango_matrix_copy()</code></a>.</p>
853
<div class="refsect3">
854
<a name="id-1.2.3.11.15.5"></a><h4>Parameters</h4>
855
<div class="informaltable"><table width="100%" border="0">
857
<col width="150px" class="parameters_name">
858
<col class="parameters_description">
859
<col width="200px" class="parameters_annotations">
862
<td class="parameter_name"><p>matrix</p></td>
863
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
864
<td class="parameter_annotations"> </td>
868
<p class="since">Since 1.6</p>
871
<div class="refsect2">
872
<a name="pango-matrix-translate"></a><h3>pango_matrix_translate ()</h3>
873
<pre class="programlisting"><span class="returnvalue">void</span>
874
pango_matrix_translate (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
875
<em class="parameter"><code><span class="type">double</span> tx</code></em>,
876
<em class="parameter"><code><span class="type">double</span> ty</code></em>);</pre>
877
<p>Changes the transformation represented by <em class="parameter"><code>matrix</code></em>
879
transformation given by first translating by (<em class="parameter"><code>tx</code></em>
880
, <em class="parameter"><code>ty</code></em>
664
882
then applying the original transformation.</p>
665
<div class="variablelist"><table border="0" class="variablelist">
883
<div class="refsect3">
884
<a name="id-1.2.3.11.16.5"></a><h4>Parameters</h4>
885
<div class="informaltable"><table width="100%" border="0">
667
<col align="left" valign="top">
887
<col width="150px" class="parameters_name">
888
<col class="parameters_description">
889
<col width="200px" class="parameters_annotations">
672
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
673
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>
677
<td><p><span class="term"><em class="parameter"><code>tx</code></em> :</span></p></td>
678
<td>amount to translate in the X direction</td>
681
<td><p><span class="term"><em class="parameter"><code>ty</code></em> :</span></p></td>
682
<td>amount to translate in the Y direction</td>
893
<td class="parameter_name"><p>matrix</p></td>
894
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p></td>
895
<td class="parameter_annotations"> </td>
898
<td class="parameter_name"><p>tx</p></td>
899
<td class="parameter_description"><p>amount to translate in the X direction</p></td>
900
<td class="parameter_annotations"> </td>
903
<td class="parameter_name"><p>ty</p></td>
904
<td class="parameter_description"><p>amount to translate in the Y direction</p></td>
905
<td class="parameter_annotations"> </td>
686
910
<p class="since">Since 1.6</p>
689
913
<div class="refsect2">
690
<a name="pango-matrix-scale"></a><h3>pango_matrix_scale ()</h3>
691
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_scale (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
692
<em class="parameter"><code><span class="type">double</span> scale_x</code></em>,
693
<em class="parameter"><code><span class="type">double</span> scale_y</code></em>);</pre>
695
Changes the transformation represented by <em class="parameter"><code>matrix</code></em> to be the
696
transformation given by first scaling by <em class="parameter"><code>sx</code></em> in the X direction
697
and <em class="parameter"><code>sy</code></em> in the Y direction then applying the original
914
<a name="pango-matrix-scale"></a><h3>pango_matrix_scale ()</h3>
915
<pre class="programlisting"><span class="returnvalue">void</span>
916
pango_matrix_scale (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
917
<em class="parameter"><code><span class="type">double</span> scale_x</code></em>,
918
<em class="parameter"><code><span class="type">double</span> scale_y</code></em>);</pre>
919
<p>Changes the transformation represented by <em class="parameter"><code>matrix</code></em>
921
transformation given by first scaling by <em class="parameter"><code>sx</code></em>
923
and <em class="parameter"><code>sy</code></em>
924
in the Y direction then applying the original
698
925
transformation.</p>
699
<div class="variablelist"><table border="0" class="variablelist">
926
<div class="refsect3">
927
<a name="id-1.2.3.11.17.5"></a><h4>Parameters</h4>
928
<div class="informaltable"><table width="100%" border="0">
701
<col align="left" valign="top">
930
<col width="150px" class="parameters_name">
931
<col class="parameters_description">
932
<col width="200px" class="parameters_annotations">
706
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
707
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>
711
<td><p><span class="term"><em class="parameter"><code>scale_x</code></em> :</span></p></td>
712
<td>amount to scale by in X direction</td>
715
<td><p><span class="term"><em class="parameter"><code>scale_y</code></em> :</span></p></td>
716
<td>amount to scale by in Y direction</td>
936
<td class="parameter_name"><p>matrix</p></td>
937
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p></td>
938
<td class="parameter_annotations"> </td>
941
<td class="parameter_name"><p>scale_x</p></td>
942
<td class="parameter_description"><p>amount to scale by in X direction</p></td>
943
<td class="parameter_annotations"> </td>
946
<td class="parameter_name"><p>scale_y</p></td>
947
<td class="parameter_description"><p>amount to scale by in Y direction</p></td>
948
<td class="parameter_annotations"> </td>
720
953
<p class="since">Since 1.6</p>
723
956
<div class="refsect2">
724
<a name="pango-matrix-rotate"></a><h3>pango_matrix_rotate ()</h3>
725
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_rotate (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
726
<em class="parameter"><code><span class="type">double</span> degrees</code></em>);</pre>
728
Changes the transformation represented by <em class="parameter"><code>matrix</code></em> to be the
729
transformation given by first rotating by <em class="parameter"><code>degrees</code></em> degrees
957
<a name="pango-matrix-rotate"></a><h3>pango_matrix_rotate ()</h3>
958
<pre class="programlisting"><span class="returnvalue">void</span>
959
pango_matrix_rotate (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
960
<em class="parameter"><code><span class="type">double</span> degrees</code></em>);</pre>
961
<p>Changes the transformation represented by <em class="parameter"><code>matrix</code></em>
963
transformation given by first rotating by <em class="parameter"><code>degrees</code></em>
730
965
counter-clockwise then applying the original transformation.</p>
731
<div class="variablelist"><table border="0" class="variablelist">
966
<div class="refsect3">
967
<a name="id-1.2.3.11.18.5"></a><h4>Parameters</h4>
968
<div class="informaltable"><table width="100%" border="0">
733
<col align="left" valign="top">
970
<col width="150px" class="parameters_name">
971
<col class="parameters_description">
972
<col width="200px" class="parameters_annotations">
738
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
739
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>
976
<td class="parameter_name"><p>matrix</p></td>
977
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p></td>
978
<td class="parameter_annotations"> </td>
743
<td><p><span class="term"><em class="parameter"><code>degrees</code></em> :</span></p></td>
744
<td>degrees to rotate counter-clockwise</td>
981
<td class="parameter_name"><p>degrees</p></td>
982
<td class="parameter_description"><p>degrees to rotate counter-clockwise</p></td>
983
<td class="parameter_annotations"> </td>
748
988
<p class="since">Since 1.6</p>
751
991
<div class="refsect2">
752
<a name="pango-matrix-concat"></a><h3>pango_matrix_concat ()</h3>
753
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_concat (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
754
<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *new_matrix</code></em>);</pre>
756
Changes the transformation represented by <em class="parameter"><code>matrix</code></em> to be the
992
<a name="pango-matrix-concat"></a><h3>pango_matrix_concat ()</h3>
993
<pre class="programlisting"><span class="returnvalue">void</span>
994
pango_matrix_concat (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
995
<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *new_matrix</code></em>);</pre>
996
<p>Changes the transformation represented by <em class="parameter"><code>matrix</code></em>
757
998
transformation given by first applying transformation
758
given by <em class="parameter"><code>new_matrix</code></em> then applying the original transformation.</p>
759
<div class="variablelist"><table border="0" class="variablelist">
999
given by <em class="parameter"><code>new_matrix</code></em>
1000
then applying the original transformation.</p>
1001
<div class="refsect3">
1002
<a name="id-1.2.3.11.19.5"></a><h4>Parameters</h4>
1003
<div class="informaltable"><table width="100%" border="0">
761
<col align="left" valign="top">
1005
<col width="150px" class="parameters_name">
1006
<col class="parameters_description">
1007
<col width="200px" class="parameters_annotations">
766
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
767
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>
1011
<td class="parameter_name"><p>matrix</p></td>
1012
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p></td>
1013
<td class="parameter_annotations"> </td>
771
<td><p><span class="term"><em class="parameter"><code>new_matrix</code></em> :</span></p></td>
772
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>
1016
<td class="parameter_name"><p>new_matrix</p></td>
1017
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a></p></td>
1018
<td class="parameter_annotations"> </td>
777
1023
<p class="since">Since 1.6</p>
780
1026
<div class="refsect2">
781
<a name="pango-matrix-transform-point"></a><h3>pango_matrix_transform_point ()</h3>
782
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_transform_point (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
783
<em class="parameter"><code><span class="type">double</span> *x</code></em>,
784
<em class="parameter"><code><span class="type">double</span> *y</code></em>);</pre>
786
Transforms the point (<em class="parameter"><code>x</code></em>, <em class="parameter"><code>y</code></em>) by <em class="parameter"><code>matrix</code></em>.</p>
787
<div class="variablelist"><table border="0" class="variablelist">
1027
<a name="pango-matrix-transform-point"></a><h3>pango_matrix_transform_point ()</h3>
1028
<pre class="programlisting"><span class="returnvalue">void</span>
1029
pango_matrix_transform_point (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
1030
<em class="parameter"><code><span class="type">double</span> *x</code></em>,
1031
<em class="parameter"><code><span class="type">double</span> *y</code></em>);</pre>
1032
<p>Transforms the point (<em class="parameter"><code>x</code></em>
1033
, <em class="parameter"><code>y</code></em>
1034
) by <em class="parameter"><code>matrix</code></em>
1036
<div class="refsect3">
1037
<a name="id-1.2.3.11.20.5"></a><h4>Parameters</h4>
1038
<div class="informaltable"><table width="100%" border="0">
789
<col align="left" valign="top">
1040
<col width="150px" class="parameters_name">
1041
<col class="parameters_description">
1042
<col width="200px" class="parameters_annotations">
794
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
795
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
799
<td><p><span class="term"><em class="parameter"><code>x</code></em> :</span></p></td>
800
<td>in/out X position. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span>
804
<td><p><span class="term"><em class="parameter"><code>y</code></em> :</span></p></td>
805
<td>in/out Y position. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span>
1046
<td class="parameter_name"><p>matrix</p></td>
1047
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1048
<td class="parameter_annotations"> </td>
1051
<td class="parameter_name"><p>x</p></td>
1052
<td class="parameter_description"><p> in/out X position. </p></td>
1053
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span></td>
1056
<td class="parameter_name"><p>y</p></td>
1057
<td class="parameter_description"><p> in/out Y position. </p></td>
1058
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span></td>
810
1063
<p class="since">Since 1.16</p>
813
1066
<div class="refsect2">
814
<a name="pango-matrix-transform-distance"></a><h3>pango_matrix_transform_distance ()</h3>
815
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_transform_distance (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
816
<em class="parameter"><code><span class="type">double</span> *dx</code></em>,
817
<em class="parameter"><code><span class="type">double</span> *dy</code></em>);</pre>
819
Transforms the distance vector (<em class="parameter"><code>dx</code></em>,<em class="parameter"><code>dy</code></em>) by <em class="parameter"><code>matrix</code></em>. This is
820
similar to <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-point" title="pango_matrix_transform_point ()"><code class="function">pango_matrix_transform_point()</code></a> except that the translation
1067
<a name="pango-matrix-transform-distance"></a><h3>pango_matrix_transform_distance ()</h3>
1068
<pre class="programlisting"><span class="returnvalue">void</span>
1069
pango_matrix_transform_distance (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
1070
<em class="parameter"><code><span class="type">double</span> *dx</code></em>,
1071
<em class="parameter"><code><span class="type">double</span> *dy</code></em>);</pre>
1072
<p>Transforms the distance vector (<em class="parameter"><code>dx</code></em>
1073
,<em class="parameter"><code>dy</code></em>
1074
) by <em class="parameter"><code>matrix</code></em>
1076
similar to <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-point" title="pango_matrix_transform_point ()"><code class="function">pango_matrix_transform_point()</code></a> except that the translation
821
1077
components of the transformation are ignored. The calculation of
822
1078
the returned vector is as follows:</p>
825
1079
<pre class="programlisting">
826
1080
dx2 = dx1 * xx + dy1 * xy;
827
1081
dy2 = dx1 * yx + dy1 * yy;
830
Affine transformations are position invariant, so the same vector
831
always transforms to the same vector. If (<em class="parameter"><code>x1</code></em>,<em class="parameter"><code>y1</code></em>) transforms
832
to (<em class="parameter"><code>x2</code></em>,<em class="parameter"><code>y2</code></em>) then (<em class="parameter"><code>x1</code></em>+<em class="parameter"><code>dx1</code></em>,<em class="parameter"><code>y1</code></em>+<em class="parameter"><code>dy1</code></em>) will transform to
833
(<em class="parameter"><code>x1</code></em>+<em class="parameter"><code>dx2</code></em>,<em class="parameter"><code>y1</code></em>+<em class="parameter"><code>dy2</code></em>) for all values of <em class="parameter"><code>x1</code></em> and <em class="parameter"><code>x2</code></em>.</p>
834
<div class="variablelist"><table border="0" class="variablelist">
1083
<p>Affine transformations are position invariant, so the same vector
1084
always transforms to the same vector. If (<em class="parameter"><code>x1</code></em>
1085
,<em class="parameter"><code>y1</code></em>
1087
to (<em class="parameter"><code>x2</code></em>
1088
,<em class="parameter"><code>y2</code></em>
1089
) then (<em class="parameter"><code>x1</code></em>
1090
+<em class="parameter"><code>dx1</code></em>
1091
,<em class="parameter"><code>y1</code></em>
1092
+<em class="parameter"><code>dy1</code></em>
1094
(<em class="parameter"><code>x1</code></em>
1095
+<em class="parameter"><code>dx2</code></em>
1096
,<em class="parameter"><code>y1</code></em>
1097
+<em class="parameter"><code>dy2</code></em>
1098
) for all values of <em class="parameter"><code>x1</code></em>
1099
and <em class="parameter"><code>x2</code></em>
1101
<div class="refsect3">
1102
<a name="id-1.2.3.11.21.7"></a><h4>Parameters</h4>
1103
<div class="informaltable"><table width="100%" border="0">
836
<col align="left" valign="top">
1105
<col width="150px" class="parameters_name">
1106
<col class="parameters_description">
1107
<col width="200px" class="parameters_annotations">
841
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
842
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
846
<td><p><span class="term"><em class="parameter"><code>dx</code></em> :</span></p></td>
847
<td>in/out X component of a distance vector. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span>
851
<td><p><span class="term"><em class="parameter"><code>dy</code></em> :</span></p></td>
852
<td>in/out Y component of a distance vector. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span>
1111
<td class="parameter_name"><p>matrix</p></td>
1112
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1113
<td class="parameter_annotations"> </td>
1116
<td class="parameter_name"><p>dx</p></td>
1117
<td class="parameter_description"><p> in/out X component of a distance vector. </p></td>
1118
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span></td>
1121
<td class="parameter_name"><p>dy</p></td>
1122
<td class="parameter_description"><p> in/out Y component of a distance vector. </p></td>
1123
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>]</span></td>
857
1128
<p class="since">Since 1.16</p>
860
1131
<div class="refsect2">
861
<a name="pango-matrix-transform-rectangle"></a><h3>pango_matrix_transform_rectangle ()</h3>
862
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_transform_rectangle (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
863
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);</pre>
865
First transforms <em class="parameter"><code>rect</code></em> using <em class="parameter"><code>matrix</code></em>, then calculates the bounding box
1132
<a name="pango-matrix-transform-rectangle"></a><h3>pango_matrix_transform_rectangle ()</h3>
1133
<pre class="programlisting"><span class="returnvalue">void</span>
1134
pango_matrix_transform_rectangle (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
1135
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);</pre>
1136
<p>First transforms <em class="parameter"><code>rect</code></em>
1137
using <em class="parameter"><code>matrix</code></em>
1138
, then calculates the bounding box
866
1139
of the transformed rectangle. The rectangle should be in Pango units.</p>
868
This function is useful for example when you want to draw a rotated
869
<em class="parameter"><code>PangoLayout</code></em> to an image buffer, and want to know how large the image
1140
<p>This function is useful for example when you want to draw a rotated
1141
<em class="parameter"><code>PangoLayout</code></em>
1142
to an image buffer, and want to know how large the image
870
1143
should be and how much you should shift the layout when rendering.</p>
872
If you have a rectangle in device units (pixels), use
873
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-pixel-rectangle" title="pango_matrix_transform_pixel_rectangle ()"><code class="function">pango_matrix_transform_pixel_rectangle()</code></a>.</p>
875
If you have the rectangle in Pango units and want to convert to
1144
<p>If you have a rectangle in device units (pixels), use
1145
<a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-pixel-rectangle" title="pango_matrix_transform_pixel_rectangle ()"><code class="function">pango_matrix_transform_pixel_rectangle()</code></a>.</p>
1146
<p>If you have the rectangle in Pango units and want to convert to
876
1147
transformed pixel bounding box, it is more accurate to transform it first
877
(using this function) and pass the result to <a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()"><code class="function">pango_extents_to_pixels()</code></a>,
1148
(using this function) and pass the result to <a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()"><code class="function">pango_extents_to_pixels()</code></a>,
878
1149
first argument, for an inclusive rounded rectangle.
879
1150
However, there are valid reasons that you may want to convert
880
1151
to pixels first and then transform, for example when the transformed
881
1152
coordinates may overflow in Pango units (large matrix translation for
883
<div class="variablelist"><table border="0" class="variablelist">
1154
<div class="refsect3">
1155
<a name="id-1.2.3.11.22.8"></a><h4>Parameters</h4>
1156
<div class="informaltable"><table width="100%" border="0">
885
<col align="left" valign="top">
1158
<col width="150px" class="parameters_name">
1159
<col class="parameters_description">
1160
<col width="200px" class="parameters_annotations">
890
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
891
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1164
<td class="parameter_name"><p>matrix</p></td>
1165
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1166
<td class="parameter_annotations"> </td>
895
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
896
<td>in/out bounding box in Pango units, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
1169
<td class="parameter_name"><p>rect</p></td>
1170
<td class="parameter_description"><p> in/out bounding box in Pango units, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
1171
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
901
1176
<p class="since">Since 1.16</p>
904
1179
<div class="refsect2">
905
<a name="pango-matrix-transform-pixel-rectangle"></a><h3>pango_matrix_transform_pixel_rectangle ()</h3>
906
<pre class="programlisting"><span class="returnvalue">void</span> pango_matrix_transform_pixel_rectangle
907
(<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
908
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);</pre>
910
First transforms the <em class="parameter"><code>rect</code></em> using <em class="parameter"><code>matrix</code></em>, then calculates the bounding box
1180
<a name="pango-matrix-transform-pixel-rectangle"></a><h3>pango_matrix_transform_pixel_rectangle ()</h3>
1181
<pre class="programlisting"><span class="returnvalue">void</span>
1182
pango_matrix_transform_pixel_rectangle
1183
(<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>,
1184
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *rect</code></em>);</pre>
1185
<p>First transforms the <em class="parameter"><code>rect</code></em>
1186
using <em class="parameter"><code>matrix</code></em>
1187
, then calculates the bounding box
911
1188
of the transformed rectangle. The rectangle should be in device units
914
This function is useful for example when you want to draw a rotated
915
<em class="parameter"><code>PangoLayout</code></em> to an image buffer, and want to know how large the image
1190
<p>This function is useful for example when you want to draw a rotated
1191
<em class="parameter"><code>PangoLayout</code></em>
1192
to an image buffer, and want to know how large the image
916
1193
should be and how much you should shift the layout when rendering.</p>
918
For better accuracy, you should use <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-rectangle" title="pango_matrix_transform_rectangle ()"><code class="function">pango_matrix_transform_rectangle()</code></a> on
1194
<p>For better accuracy, you should use <a class="link" href="pango-Glyph-Storage.html#pango-matrix-transform-rectangle" title="pango_matrix_transform_rectangle ()"><code class="function">pango_matrix_transform_rectangle()</code></a> on
919
1195
original rectangle in Pango units and convert to pixels afterward
920
using <a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()"><code class="function">pango_extents_to_pixels()</code></a>'s first argument.</p>
921
<div class="variablelist"><table border="0" class="variablelist">
1196
using <a class="link" href="pango-Glyph-Storage.html#pango-extents-to-pixels" title="pango_extents_to_pixels ()"><code class="function">pango_extents_to_pixels()</code></a>'s first argument.</p>
1197
<div class="refsect3">
1198
<a name="id-1.2.3.11.23.7"></a><h4>Parameters</h4>
1199
<div class="informaltable"><table width="100%" border="0">
923
<col align="left" valign="top">
1201
<col width="150px" class="parameters_name">
1202
<col class="parameters_description">
1203
<col width="200px" class="parameters_annotations">
928
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
929
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1207
<td class="parameter_name"><p>matrix</p></td>
1208
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1209
<td class="parameter_annotations"> </td>
933
<td><p><span class="term"><em class="parameter"><code>rect</code></em> :</span></p></td>
934
<td>in/out bounding box in device units, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
1212
<td class="parameter_name"><p>rect</p></td>
1213
<td class="parameter_description"><p> in/out bounding box in device units, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
1214
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for input and for returning results. Default is transfer full."><span class="acronym">inout</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
939
1219
<p class="since">Since 1.16</p>
942
1222
<div class="refsect2">
943
<a name="pango-matrix-get-font-scale-factor"></a><h3>pango_matrix_get_font_scale_factor ()</h3>
944
<pre class="programlisting"><span class="returnvalue">double</span> pango_matrix_get_font_scale_factor (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
946
Returns the scale factor of a matrix on the height of the font.
1223
<a name="pango-matrix-get-font-scale-factor"></a><h3>pango_matrix_get_font_scale_factor ()</h3>
1224
<pre class="programlisting"><span class="returnvalue">double</span>
1225
pango_matrix_get_font_scale_factor (<em class="parameter"><code>const <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a> *matrix</code></em>);</pre>
1226
<p>Returns the scale factor of a matrix on the height of the font.
947
1227
That is, the scale factor in the direction perpendicular to the
948
1228
vector that the X coordinate is mapped to.</p>
949
<div class="variablelist"><table border="0" class="variablelist">
1229
<div class="refsect3">
1230
<a name="id-1.2.3.11.24.5"></a><h4>Parameters</h4>
1231
<div class="informaltable"><table width="100%" border="0">
951
<col align="left" valign="top">
1233
<col width="150px" class="parameters_name">
1234
<col class="parameters_description">
1235
<col width="200px" class="parameters_annotations">
956
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
957
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
961
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
962
<td>the scale factor of <em class="parameter"><code>matrix</code></em> on the height of the font,
963
or 1.0 if <em class="parameter"><code>matrix</code></em> is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
1238
<td class="parameter_name"><p>matrix</p></td>
1239
<td class="parameter_description"><p> a <a class="link" href="pango-Glyph-Storage.html#PangoMatrix"><span class="type">PangoMatrix</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. </p></td>
1240
<td class="parameter_annotations"><span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
1244
<div class="refsect3">
1245
<a name="id-1.2.3.11.24.6"></a><h4>Returns</h4>
1246
<p> the scale factor of <em class="parameter"><code>matrix</code></em>
1247
on the height of the font,
1248
or 1.0 if <em class="parameter"><code>matrix</code></em>
1249
is <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
967
1252
<p class="since">Since 1.12</p>
970
1255
<div class="refsect2">
971
<a name="PangoGlyph"></a><h3>PangoGlyph</h3>
972
<pre class="programlisting">typedef guint32 PangoGlyph;
975
A <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> represents a single glyph in the output form of a string.</p>
978
<div class="refsect2">
979
1256
<a name="PANGO-GLYPH-EMPTY:CAPS"></a><h3>PANGO_GLYPH_EMPTY</h3>
980
1257
<pre class="programlisting">#define PANGO_GLYPH_EMPTY ((PangoGlyph)0x0FFFFFFF)
983
The <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS" title="PANGO_GLYPH_EMPTY"><code class="literal">PANGO_GLYPH_EMPTY</code></a> macro represents a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that has a
1259
<p>The <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS" title="PANGO_GLYPH_EMPTY"><code class="literal">PANGO_GLYPH_EMPTY</code></a> macro represents a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that has a
984
1260
special meaning, which is a zero-width empty glyph. This is useful for
985
1261
example in shaper modules, to use as the glyph for various zero-width
986
Unicode characters (those passing <a class="link" href="pango-Miscellaneous-Utilities.html#pango-is-zero-width" title="pango_is_zero_width ()"><code class="function">pango_is_zero_width()</code></a>).</p>
1262
Unicode characters (those passing <a class="link" href="pango-Miscellaneous-Utilities.html#pango-is-zero-width" title="pango_is_zero_width ()"><code class="function">pango_is_zero_width()</code></a>).</p>
989
1265
<div class="refsect2">
990
1266
<a name="PANGO-GLYPH-INVALID-INPUT:CAPS"></a><h3>PANGO_GLYPH_INVALID_INPUT</h3>
991
1267
<pre class="programlisting">#define PANGO_GLYPH_INVALID_INPUT ((PangoGlyph)0xFFFFFFFF)
994
The <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-INVALID-INPUT:CAPS" title="PANGO_GLYPH_INVALID_INPUT"><code class="literal">PANGO_GLYPH_INVALID_INPUT</code></a> macro represents a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that has a
1269
<p>The <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-INVALID-INPUT:CAPS" title="PANGO_GLYPH_INVALID_INPUT"><code class="literal">PANGO_GLYPH_INVALID_INPUT</code></a> macro represents a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that has a
995
1270
special meaning of invalid input. <a class="link" href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> produces one such glyph
996
1271
per invalid input UTF-8 byte and such a glyph is rendered as a crossed
999
Note that this value is defined such that it has the <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-UNKNOWN-FLAG:CAPS" title="PANGO_GLYPH_UNKNOWN_FLAG"><code class="literal">PANGO_GLYPH_UNKNOWN_FLAG</code></a>
1273
<p>Note that this value is defined such that it has the <a class="link" href="pango-Glyph-Storage.html#PANGO-GLYPH-UNKNOWN-FLAG:CAPS" title="PANGO_GLYPH_UNKNOWN_FLAG"><code class="literal">PANGO_GLYPH_UNKNOWN_FLAG</code></a>
1001
1275
<p class="since">Since 1.20</p>
1015
1288
<a name="PANGO-GET-UNKNOWN-GLYPH:CAPS"></a><h3>PANGO_GET_UNKNOWN_GLYPH()</h3>
1016
1289
<pre class="programlisting">#define PANGO_GET_UNKNOWN_GLYPH(wc) ((PangoGlyph)(wc)|PANGO_GLYPH_UNKNOWN_FLAG)
1019
The way this unknown glyphs are rendered is backend specific. For example,
1291
<p>The way this unknown glyphs are rendered is backend specific. For example,
1020
1292
a box with the hexadecimal Unicode code-point of the character written in it
1021
1293
is what is done in the most common backends.</p>
1022
<div class="variablelist"><table border="0" class="variablelist">
1024
<col align="left" valign="top">
1029
<td><p><span class="term"><em class="parameter"><code>wc</code></em> :</span></p></td>
1030
<td>a Unicode character</td>
1033
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1034
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that means no glyph was found for <em class="parameter"><code>wc</code></em>.</td>
1294
<div class="refsect3">
1295
<a name="id-1.2.3.11.28.5"></a><h4>Parameters</h4>
1296
<div class="informaltable"><table width="100%" border="0">
1298
<col width="150px" class="parameters_name">
1299
<col class="parameters_description">
1300
<col width="200px" class="parameters_annotations">
1303
<td class="parameter_name"><p>wc</p></td>
1304
<td class="parameter_description"><p>a Unicode character</p></td>
1305
<td class="parameter_annotations"> </td>
1309
<div class="refsect3">
1310
<a name="id-1.2.3.11.28.6"></a><h4>Returns</h4>
1311
<p> a <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> value that means no glyph was found for <em class="parameter"><code>wc</code></em>
1317
<div class="refsect2">
1318
<a name="PANGO-TYPE-GLYPH-STRING:CAPS"></a><h3>PANGO_TYPE_GLYPH_STRING</h3>
1319
<pre class="programlisting">#define PANGO_TYPE_GLYPH_STRING (pango_glyph_string_get_type ())
1321
<p>The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</p>
1324
<div class="refsect2">
1325
<a name="pango-glyph-string-new"></a><h3>pango_glyph_string_new ()</h3>
1326
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> *
1327
pango_glyph_string_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
1328
<p>Create a new <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</p>
1329
<div class="refsect3">
1330
<a name="id-1.2.3.11.30.5"></a><h4>Returns</h4>
1331
<p> the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, which
1332
should be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()"><code class="function">pango_glyph_string_free()</code></a>.</p>
1337
<div class="refsect2">
1338
<a name="pango-glyph-string-copy"></a><h3>pango_glyph_string_copy ()</h3>
1339
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> *
1340
pango_glyph_string_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);</pre>
1341
<p>Copy a glyph string and associated storage.</p>
1342
<div class="refsect3">
1343
<a name="id-1.2.3.11.31.5"></a><h4>Parameters</h4>
1344
<div class="informaltable"><table width="100%" border="0">
1346
<col width="150px" class="parameters_name">
1347
<col class="parameters_description">
1348
<col width="200px" class="parameters_annotations">
1351
<td class="parameter_name"><p>string</p></td>
1352
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1353
<td class="parameter_annotations"> </td>
1357
<div class="refsect3">
1358
<a name="id-1.2.3.11.31.6"></a><h4>Returns</h4>
1359
<p> the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, which
1360
should be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()"><code class="function">pango_glyph_string_free()</code></a>,
1361
or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>string</code></em>
1362
was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
1367
<div class="refsect2">
1368
<a name="pango-glyph-string-set-size"></a><h3>pango_glyph_string_set_size ()</h3>
1369
<pre class="programlisting"><span class="returnvalue">void</span>
1370
pango_glyph_string_set_size (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>,
1371
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> new_len</code></em>);</pre>
1372
<p>Resize a glyph string to the given length.</p>
1373
<div class="refsect3">
1374
<a name="id-1.2.3.11.32.5"></a><h4>Parameters</h4>
1375
<div class="informaltable"><table width="100%" border="0">
1377
<col width="150px" class="parameters_name">
1378
<col class="parameters_description">
1379
<col width="200px" class="parameters_annotations">
1383
<td class="parameter_name"><p>string</p></td>
1384
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</p></td>
1385
<td class="parameter_annotations"> </td>
1388
<td class="parameter_name"><p>new_len</p></td>
1389
<td class="parameter_description"><p>the new length of the string.</p></td>
1390
<td class="parameter_annotations"> </td>
1397
<div class="refsect2">
1398
<a name="pango-glyph-string-free"></a><h3>pango_glyph_string_free ()</h3>
1399
<pre class="programlisting"><span class="returnvalue">void</span>
1400
pango_glyph_string_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);</pre>
1401
<p>Free a glyph string and associated storage.</p>
1402
<div class="refsect3">
1403
<a name="id-1.2.3.11.33.5"></a><h4>Parameters</h4>
1404
<div class="informaltable"><table width="100%" border="0">
1406
<col width="150px" class="parameters_name">
1407
<col class="parameters_description">
1408
<col width="200px" class="parameters_annotations">
1411
<td class="parameter_name"><p>string</p></td>
1412
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1413
<td class="parameter_annotations"> </td>
1419
<div class="refsect2">
1420
<a name="pango-glyph-string-extents"></a><h3>pango_glyph_string_extents ()</h3>
1421
<pre class="programlisting"><span class="returnvalue">void</span>
1422
pango_glyph_string_extents (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1423
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
1424
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
1425
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);</pre>
1426
<p>Compute the logical and ink extents of a glyph string. See the documentation
1427
for <a class="link" href="pango-Fonts.html#pango-font-get-glyph-extents" title="pango_font_get_glyph_extents ()"><code class="function">pango_font_get_glyph_extents()</code></a> for details about the interpretation
1428
of the rectangles.</p>
1429
<div class="refsect3">
1430
<a name="id-1.2.3.11.34.5"></a><h4>Parameters</h4>
1431
<div class="informaltable"><table width="100%" border="0">
1433
<col width="150px" class="parameters_name">
1434
<col class="parameters_description">
1435
<col width="200px" class="parameters_annotations">
1439
<td class="parameter_name"><p>glyphs</p></td>
1440
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a></p></td>
1441
<td class="parameter_annotations"> </td>
1444
<td class="parameter_name"><p>font</p></td>
1445
<td class="parameter_description"><p>a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a></p></td>
1446
<td class="parameter_annotations"> </td>
1449
<td class="parameter_name"><p>ink_rect</p></td>
1450
<td class="parameter_description"><p> rectangle used to store the extents of the glyph string
1451
as drawn or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to indicate that the result is not needed. </p></td>
1452
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
1455
<td class="parameter_name"><p>logical_rect</p></td>
1456
<td class="parameter_description"><p> rectangle used to store the logical extents of the
1457
glyph string or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to indicate that the result is not needed. </p></td>
1458
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span></td>
1465
<div class="refsect2">
1466
<a name="pango-glyph-string-extents-range"></a><h3>pango_glyph_string_extents_range ()</h3>
1467
<pre class="programlisting"><span class="returnvalue">void</span>
1468
pango_glyph_string_extents_range (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1469
<em class="parameter"><code><span class="type">int</span> start</code></em>,
1470
<em class="parameter"><code><span class="type">int</span> end</code></em>,
1471
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
1472
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
1473
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);</pre>
1474
<p>Computes the extents of a sub-portion of a glyph string. The extents are
1475
relative to the start of the glyph string range (the origin of their
1476
coordinate system is at the start of the range, not at the start of the entire
1478
<div class="refsect3">
1479
<a name="id-1.2.3.11.35.5"></a><h4>Parameters</h4>
1480
<div class="informaltable"><table width="100%" border="0">
1482
<col width="150px" class="parameters_name">
1483
<col class="parameters_description">
1484
<col width="200px" class="parameters_annotations">
1488
<td class="parameter_name"><p>glyphs</p></td>
1489
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a></p></td>
1490
<td class="parameter_annotations"> </td>
1493
<td class="parameter_name"><p>start</p></td>
1494
<td class="parameter_description"><p>start index</p></td>
1495
<td class="parameter_annotations"> </td>
1498
<td class="parameter_name"><p>end</p></td>
1499
<td class="parameter_description"><p>end index (the range is the set of bytes with
1500
indices such that start <= index < end)</p></td>
1501
<td class="parameter_annotations"> </td>
1504
<td class="parameter_name"><p>font</p></td>
1505
<td class="parameter_description"><p>a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a></p></td>
1506
<td class="parameter_annotations"> </td>
1509
<td class="parameter_name"><p>ink_rect</p></td>
1510
<td class="parameter_description"><p> rectangle used to store the
1511
extents of the glyph string range as drawn or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to
1512
indicate that the result is not needed. </p></td>
1513
<td class="parameter_annotations"><span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span></td>
1516
<td class="parameter_name"><p>logical_rect</p></td>
1517
<td class="parameter_description"><p> rectangle used to store the
1518
logical extents of the glyph string range or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to
1519
indicate that the result is not needed. </p></td>
1520
<td class="parameter_annotations"><span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span></td>
1527
<div class="refsect2">
1528
<a name="pango-glyph-string-get-width"></a><h3>pango_glyph_string_get_width ()</h3>
1529
<pre class="programlisting"><span class="returnvalue">int</span>
1530
pango_glyph_string_get_width (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>);</pre>
1531
<p>Computes the logical width of the glyph string as can also be computed
1532
using <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents" title="pango_glyph_string_extents ()"><code class="function">pango_glyph_string_extents()</code></a>. However, since this only computes the
1533
width, it's much faster. This is in fact only a convenience function that
1534
computes the sum of geometry.width for each glyph in the <em class="parameter"><code>glyphs</code></em>
1536
<div class="refsect3">
1537
<a name="id-1.2.3.11.36.5"></a><h4>Parameters</h4>
1538
<div class="informaltable"><table width="100%" border="0">
1540
<col width="150px" class="parameters_name">
1541
<col class="parameters_description">
1542
<col width="200px" class="parameters_annotations">
1545
<td class="parameter_name"><p>glyphs</p></td>
1546
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a></p></td>
1547
<td class="parameter_annotations"> </td>
1551
<div class="refsect3">
1552
<a name="id-1.2.3.11.36.6"></a><h4>Returns</h4>
1553
<p> the logical width of the glyph string.</p>
1556
<p class="since">Since 1.14</p>
1559
<div class="refsect2">
1560
<a name="pango-glyph-string-index-to-x"></a><h3>pango_glyph_string_index_to_x ()</h3>
1561
<pre class="programlisting"><span class="returnvalue">void</span>
1562
pango_glyph_string_index_to_x (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1563
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
1564
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1565
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
1566
<em class="parameter"><code><span class="type">int</span> index_</code></em>,
1567
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> trailing</code></em>,
1568
<em class="parameter"><code><span class="type">int</span> *x_pos</code></em>);</pre>
1569
<p>Converts from character position to x position. (X position
1570
is measured from the left edge of the run). Character positions
1571
are computed by dividing up each cluster into equal portions.</p>
1572
<div class="refsect3">
1573
<a name="id-1.2.3.11.37.5"></a><h4>Parameters</h4>
1574
<div class="informaltable"><table width="100%" border="0">
1576
<col width="150px" class="parameters_name">
1577
<col class="parameters_description">
1578
<col width="200px" class="parameters_annotations">
1582
<td class="parameter_name"><p>glyphs</p></td>
1583
<td class="parameter_description"><p>the glyphs return from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a></p></td>
1584
<td class="parameter_annotations"> </td>
1587
<td class="parameter_name"><p>text</p></td>
1588
<td class="parameter_description"><p>the text for the run</p></td>
1589
<td class="parameter_annotations"> </td>
1592
<td class="parameter_name"><p>length</p></td>
1593
<td class="parameter_description"><p>the number of bytes (not characters) in <em class="parameter"><code>text</code></em>
1595
<td class="parameter_annotations"> </td>
1598
<td class="parameter_name"><p>analysis</p></td>
1599
<td class="parameter_description"><p>the analysis information return from <a class="link" href="pango-Text-Processing.html#pango-itemize" title="pango_itemize ()"><code class="function">pango_itemize()</code></a></p></td>
1600
<td class="parameter_annotations"> </td>
1603
<td class="parameter_name"><p>index_</p></td>
1604
<td class="parameter_description"><p>the byte index within <em class="parameter"><code>text</code></em>
1606
<td class="parameter_annotations"> </td>
1609
<td class="parameter_name"><p>trailing</p></td>
1610
<td class="parameter_description"><p>whether we should compute the result for the beginning (<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>)
1611
or end (<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>) of the character.</p></td>
1612
<td class="parameter_annotations"> </td>
1615
<td class="parameter_name"><p>x_pos</p></td>
1616
<td class="parameter_description"><p> location to store result. </p></td>
1617
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
1624
<div class="refsect2">
1625
<a name="pango-glyph-string-x-to-index"></a><h3>pango_glyph_string_x_to_index ()</h3>
1626
<pre class="programlisting"><span class="returnvalue">void</span>
1627
pango_glyph_string_x_to_index (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1628
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
1629
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1630
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
1631
<em class="parameter"><code><span class="type">int</span> x_pos</code></em>,
1632
<em class="parameter"><code><span class="type">int</span> *index_</code></em>,
1633
<em class="parameter"><code><span class="type">int</span> *trailing</code></em>);</pre>
1634
<p>Convert from x offset to character position. Character positions
1635
are computed by dividing up each cluster into equal portions.
1636
In scripts where positioning within a cluster is not allowed
1637
(such as Thai), the returned value may not be a valid cursor
1638
position; the caller must combine the result with the logical
1639
attributes for the text to compute the valid cursor position.</p>
1640
<div class="refsect3">
1641
<a name="id-1.2.3.11.38.5"></a><h4>Parameters</h4>
1642
<div class="informaltable"><table width="100%" border="0">
1644
<col width="150px" class="parameters_name">
1645
<col class="parameters_description">
1646
<col width="200px" class="parameters_annotations">
1650
<td class="parameter_name"><p>glyphs</p></td>
1651
<td class="parameter_description"><p>the glyphs returned from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a></p></td>
1652
<td class="parameter_annotations"> </td>
1655
<td class="parameter_name"><p>text</p></td>
1656
<td class="parameter_description"><p>the text for the run</p></td>
1657
<td class="parameter_annotations"> </td>
1660
<td class="parameter_name"><p>length</p></td>
1661
<td class="parameter_description"><p>the number of bytes (not characters) in text.</p></td>
1662
<td class="parameter_annotations"> </td>
1665
<td class="parameter_name"><p>analysis</p></td>
1666
<td class="parameter_description"><p>the analysis information return from <a class="link" href="pango-Text-Processing.html#pango-itemize" title="pango_itemize ()"><code class="function">pango_itemize()</code></a></p></td>
1667
<td class="parameter_annotations"> </td>
1670
<td class="parameter_name"><p>x_pos</p></td>
1671
<td class="parameter_description"><p>the x offset (in Pango units)</p></td>
1672
<td class="parameter_annotations"> </td>
1675
<td class="parameter_name"><p>index_</p></td>
1676
<td class="parameter_description"><p> location to store calculated byte index within <em class="parameter"><code>text</code></em>
1678
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
1681
<td class="parameter_name"><p>trailing</p></td>
1682
<td class="parameter_description"><p> location to store a boolean indicating
1683
whether the user clicked on the leading or trailing
1684
edge of the character. </p></td>
1685
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span></td>
1692
<div class="refsect2">
1693
<a name="pango-glyph-string-get-logical-widths"></a><h3>pango_glyph_string_get_logical_widths ()</h3>
1694
<pre class="programlisting"><span class="returnvalue">void</span>
1695
pango_glyph_string_get_logical_widths (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1696
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1697
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1698
<em class="parameter"><code><span class="type">int</span> embedding_level</code></em>,
1699
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);</pre>
1700
<p>Given a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> resulting from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a> and the corresponding
1701
text, determine the screen width corresponding to each character. When
1702
multiple characters compose a single cluster, the width of the entire
1703
cluster is divided equally among the characters.</p>
1704
<p>See also <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-get-logical-widths" title="pango_glyph_item_get_logical_widths ()"><code class="function">pango_glyph_item_get_logical_widths()</code></a>.</p>
1705
<div class="refsect3">
1706
<a name="id-1.2.3.11.39.6"></a><h4>Parameters</h4>
1707
<div class="informaltable"><table width="100%" border="0">
1709
<col width="150px" class="parameters_name">
1710
<col class="parameters_description">
1711
<col width="200px" class="parameters_annotations">
1715
<td class="parameter_name"><p>glyphs</p></td>
1716
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a></p></td>
1717
<td class="parameter_annotations"> </td>
1720
<td class="parameter_name"><p>text</p></td>
1721
<td class="parameter_description"><p>the text corresponding to the glyphs</p></td>
1722
<td class="parameter_annotations"> </td>
1725
<td class="parameter_name"><p>length</p></td>
1726
<td class="parameter_description"><p>the length of <em class="parameter"><code>text</code></em>
1728
<td class="parameter_annotations"> </td>
1731
<td class="parameter_name"><p>embedding_level</p></td>
1732
<td class="parameter_description"><p>the embedding level of the string</p></td>
1733
<td class="parameter_annotations"> </td>
1736
<td class="parameter_name"><p>logical_widths</p></td>
1737
<td class="parameter_description"><p> an array whose length is the number of
1738
characters in text (equal to g_utf8_strlen (text,
1739
length) unless text has NUL bytes) to be filled in
1740
with the resulting character widths. </p></td>
1741
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span></td>
1748
<div class="refsect2">
1749
<a name="PANGO-TYPE-GLYPH-ITEM:CAPS"></a><h3>PANGO_TYPE_GLYPH_ITEM</h3>
1750
<pre class="programlisting">#define PANGO_TYPE_GLYPH_ITEM (pango_glyph_item_get_type ())
1752
<p>The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>.</p>
1755
<div class="refsect2">
1756
<a name="pango-glyph-item-copy"></a><h3>pango_glyph_item_copy ()</h3>
1757
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> *
1758
pango_glyph_item_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>);</pre>
1759
<p>Make a deep copy of an existing <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> structure.</p>
1760
<div class="refsect3">
1761
<a name="id-1.2.3.11.41.5"></a><h4>Parameters</h4>
1762
<div class="informaltable"><table width="100%" border="0">
1764
<col width="150px" class="parameters_name">
1765
<col class="parameters_description">
1766
<col width="200px" class="parameters_annotations">
1769
<td class="parameter_name"><p>orig</p></td>
1770
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1771
<td class="parameter_annotations"> </td>
1775
<div class="refsect3">
1776
<a name="id-1.2.3.11.41.6"></a><h4>Returns</h4>
1777
<p> the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, which should
1778
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1779
if <em class="parameter"><code>orig</code></em>
1780
was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
1783
<p class="since">Since 1.20</p>
1786
<div class="refsect2">
1787
<a name="pango-glyph-item-free"></a><h3>pango_glyph_item_free ()</h3>
1788
<pre class="programlisting"><span class="returnvalue">void</span>
1789
pango_glyph_item_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>);</pre>
1790
<p>Frees a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> and resources to which it points.</p>
1791
<div class="refsect3">
1792
<a name="id-1.2.3.11.42.5"></a><h4>Parameters</h4>
1793
<div class="informaltable"><table width="100%" border="0">
1795
<col width="150px" class="parameters_name">
1796
<col class="parameters_description">
1797
<col width="200px" class="parameters_annotations">
1800
<td class="parameter_name"><p>glyph_item</p></td>
1801
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
1802
<td class="parameter_annotations"> </td>
1806
<p class="since">Since 1.6</p>
1809
<div class="refsect2">
1810
<a name="pango-glyph-item-split"></a><h3>pango_glyph_item_split ()</h3>
1811
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> *
1812
pango_glyph_item_split (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>,
1813
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1814
<em class="parameter"><code><span class="type">int</span> split_index</code></em>);</pre>
1815
<p>Modifies <em class="parameter"><code>orig</code></em>
1816
to cover only the text after <em class="parameter"><code>split_index</code></em>
1818
returns a new item that covers the text before <em class="parameter"><code>split_index</code></em>
1820
used to be in <em class="parameter"><code>orig</code></em>
1821
. You can think of <em class="parameter"><code>split_index</code></em>
1823
the returned item. <em class="parameter"><code>split_index</code></em>
1824
may not be 0, and it may not be
1825
greater than or equal to the length of <em class="parameter"><code>orig</code></em>
1826
(that is, there must
1827
be at least one byte assigned to each item, you can't create a
1828
zero-length item).</p>
1829
<p>This function is similar in function to <a class="link" href="pango-Text-Processing.html#pango-item-split" title="pango_item_split ()"><code class="function">pango_item_split()</code></a> (and uses
1831
<div class="refsect3">
1832
<a name="id-1.2.3.11.43.6"></a><h4>Parameters</h4>
1833
<div class="informaltable"><table width="100%" border="0">
1835
<col width="150px" class="parameters_name">
1836
<col class="parameters_description">
1837
<col width="200px" class="parameters_annotations">
1841
<td class="parameter_name"><p>orig</p></td>
1842
<td class="parameter_description"><p>a <a class="link" href="pango-Text-Processing.html#PangoItem"><span class="type">PangoItem</span></a></p></td>
1843
<td class="parameter_annotations"> </td>
1846
<td class="parameter_name"><p>text</p></td>
1847
<td class="parameter_description"><p>text to which positions in <em class="parameter"><code>orig</code></em>
1849
<td class="parameter_annotations"> </td>
1852
<td class="parameter_name"><p>split_index</p></td>
1853
<td class="parameter_description"><p>byte index of position to split item, relative to the start of the item</p></td>
1854
<td class="parameter_annotations"> </td>
1859
<div class="refsect3">
1860
<a name="id-1.2.3.11.43.7"></a><h4>Returns</h4>
1861
<p> the newly allocated item representing text before
1862
<em class="parameter"><code>split_index</code></em>
1863
, which should be freed
1864
with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>.</p>
1867
<p class="since">Since 1.2</p>
1870
<div class="refsect2">
1871
<a name="pango-glyph-item-apply-attrs"></a><h3>pango_glyph_item_apply_attrs ()</h3>
1872
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> *
1873
pango_glyph_item_apply_attrs (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1874
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1875
<em class="parameter"><code><a class="link" href="pango-Text-Attributes.html#PangoAttrList"><span class="type">PangoAttrList</span></a> *list</code></em>);</pre>
1876
<p>Splits a shaped item (PangoGlyphItem) into multiple items based
1877
on an attribute list. The idea is that if you have attributes
1878
that don't affect shaping, such as color or underline, to avoid
1879
affecting shaping, you filter them out (<a class="link" href="pango-Text-Attributes.html#pango-attr-list-filter" title="pango_attr_list_filter ()"><code class="function">pango_attr_list_filter()</code></a>),
1880
apply the shaping process and then reapply them to the result using
1882
<p>All attributes that start or end inside a cluster are applied
1883
to that cluster; for instance, if half of a cluster is underlined
1884
and the other-half strikethrough, then the cluster will end
1885
up with both underline and strikethrough attributes. In these
1886
cases, it may happen that item->extra_attrs for some of the
1887
result items can have multiple attributes of the same type.</p>
1888
<p>This function takes ownership of <em class="parameter"><code>glyph_item</code></em>
1890
as one of the elements in the list.</p>
1891
<div class="refsect3">
1892
<a name="id-1.2.3.11.44.7"></a><h4>Parameters</h4>
1893
<div class="informaltable"><table width="100%" border="0">
1895
<col width="150px" class="parameters_name">
1896
<col class="parameters_description">
1897
<col width="200px" class="parameters_annotations">
1901
<td class="parameter_name"><p>glyph_item</p></td>
1902
<td class="parameter_description"><p>a shaped item</p></td>
1903
<td class="parameter_annotations"> </td>
1906
<td class="parameter_name"><p>text</p></td>
1907
<td class="parameter_description"><p>text that <em class="parameter"><code>list</code></em>
1909
<td class="parameter_annotations"> </td>
1912
<td class="parameter_name"><p>list</p></td>
1913
<td class="parameter_description"><p>a <a class="link" href="pango-Text-Attributes.html#PangoAttrList"><span class="type">PangoAttrList</span></a></p></td>
1914
<td class="parameter_annotations"> </td>
1919
<div class="refsect3">
1920
<a name="id-1.2.3.11.44.8"></a><h4>Returns</h4>
1922
list of glyph items resulting from splitting <em class="parameter"><code>glyph_item</code></em>
1924
the elements using <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>, the list using
1925
<a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#g-slist-free"><code class="function">g_slist_free()</code></a>. </p>
1926
<p><span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> Pango.GlyphItem]</span></p>
1928
<p class="since">Since 1.2</p>
1931
<div class="refsect2">
1932
<a name="pango-glyph-item-letter-space"></a><h3>pango_glyph_item_letter_space ()</h3>
1933
<pre class="programlisting"><span class="returnvalue">void</span>
1934
pango_glyph_item_letter_space (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1935
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1936
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoLogAttr" title="PangoLogAttr"><span class="type">PangoLogAttr</span></a> *log_attrs</code></em>,
1937
<em class="parameter"><code><span class="type">int</span> letter_spacing</code></em>);</pre>
1938
<p>Adds spacing between the graphemes of <em class="parameter"><code>glyph_item</code></em>
1940
give the effect of typographic letter spacing.</p>
1941
<div class="refsect3">
1942
<a name="id-1.2.3.11.45.5"></a><h4>Parameters</h4>
1943
<div class="informaltable"><table width="100%" border="0">
1945
<col width="150px" class="parameters_name">
1946
<col class="parameters_description">
1947
<col width="200px" class="parameters_annotations">
1951
<td class="parameter_name"><p>glyph_item</p></td>
1952
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a></p></td>
1953
<td class="parameter_annotations"> </td>
1956
<td class="parameter_name"><p>text</p></td>
1957
<td class="parameter_description"><p>text that <em class="parameter"><code>glyph_item</code></em>
1959
(glyph_item->item->offset is an offset from the
1960
start of <em class="parameter"><code>text</code></em>
1962
<td class="parameter_annotations"> </td>
1965
<td class="parameter_name"><p>log_attrs</p></td>
1966
<td class="parameter_description"><p> logical attributes for the item
1967
(the first logical attribute refers to the position
1968
before the first character in the item). </p></td>
1969
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span></td>
1972
<td class="parameter_name"><p>letter_spacing</p></td>
1973
<td class="parameter_description"><p>amount of letter spacing to add
1974
in Pango units. May be negative, though too large
1975
negative values will give ugly results.</p></td>
1976
<td class="parameter_annotations"> </td>
1981
<p class="since">Since 1.6</p>
1984
<div class="refsect2">
1985
<a name="pango-glyph-item-get-logical-widths"></a><h3>pango_glyph_item_get_logical_widths ()</h3>
1986
<pre class="programlisting"><span class="returnvalue">void</span>
1987
pango_glyph_item_get_logical_widths (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1988
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1989
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);</pre>
1990
<p>Given a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> and the corresponding
1991
text, determine the screen width corresponding to each character. When
1992
multiple characters compose a single cluster, the width of the entire
1993
cluster is divided equally among the characters.</p>
1994
<p>See also <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-logical-widths" title="pango_glyph_string_get_logical_widths ()"><code class="function">pango_glyph_string_get_logical_widths()</code></a>.</p>
1995
<div class="refsect3">
1996
<a name="id-1.2.3.11.46.6"></a><h4>Parameters</h4>
1997
<div class="informaltable"><table width="100%" border="0">
1999
<col width="150px" class="parameters_name">
2000
<col class="parameters_description">
2001
<col width="200px" class="parameters_annotations">
2005
<td class="parameter_name"><p>glyph_item</p></td>
2006
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a></p></td>
2007
<td class="parameter_annotations"> </td>
2010
<td class="parameter_name"><p>text</p></td>
2011
<td class="parameter_description"><p>text that <em class="parameter"><code>glyph_item</code></em>
2013
(glyph_item->item->offset is an offset from the
2014
start of <em class="parameter"><code>text</code></em>
2016
<td class="parameter_annotations"> </td>
2019
<td class="parameter_name"><p>logical_widths</p></td>
2020
<td class="parameter_description"><p> an array whose length is the number of
2021
characters in glyph_item (equal to
2022
glyph_item->item->num_chars) to be filled in with
2023
the resulting character widths. </p></td>
2024
<td class="parameter_annotations"><span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span></td>
2029
<p class="since">Since 1.26</p>
2032
<div class="refsect2">
2033
<a name="PANGO-TYPE-GLYPH-ITEM-ITER:CAPS"></a><h3>PANGO_TYPE_GLYPH_ITEM_ITER</h3>
2034
<pre class="programlisting">#define PANGO_TYPE_GLYPH_ITEM_ITER (pango_glyph_item_iter_get_type ())
2036
<p>The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>.</p>
2037
<p class="since">Since 1.22</p>
2040
<div class="refsect2">
2041
<a name="pango-glyph-item-iter-copy"></a><h3>pango_glyph_item_iter_copy ()</h3>
2042
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="returnvalue">PangoGlyphItemIter</span></a> *
2043
pango_glyph_item_iter_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *orig</code></em>);</pre>
2044
<p>Make a shallow copy of an existing <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure.</p>
2045
<div class="refsect3">
2046
<a name="id-1.2.3.11.48.5"></a><h4>Parameters</h4>
2047
<div class="informaltable"><table width="100%" border="0">
2049
<col width="150px" class="parameters_name">
2050
<col class="parameters_description">
2051
<col width="200px" class="parameters_annotations">
2054
<td class="parameter_name"><p>orig</p></td>
2055
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
2056
<td class="parameter_annotations"> </td>
2060
<div class="refsect3">
2061
<a name="id-1.2.3.11.48.6"></a><h4>Returns</h4>
2062
<p> the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, which should
2063
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-free" title="pango_glyph_item_iter_free ()"><code class="function">pango_glyph_item_iter_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
2064
if <em class="parameter"><code>orig</code></em>
2065
was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
2068
<p class="since">Since 1.22</p>
2071
<div class="refsect2">
2072
<a name="pango-glyph-item-iter-free"></a><h3>pango_glyph_item_iter_free ()</h3>
2073
<pre class="programlisting"><span class="returnvalue">void</span>
2074
pango_glyph_item_iter_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
2075
<p>Frees a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> created by <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-copy" title="pango_glyph_item_iter_copy ()"><code class="function">pango_glyph_item_iter_copy()</code></a>.</p>
2076
<div class="refsect3">
2077
<a name="id-1.2.3.11.49.5"></a><h4>Parameters</h4>
2078
<div class="informaltable"><table width="100%" border="0">
2080
<col width="150px" class="parameters_name">
2081
<col class="parameters_description">
2082
<col width="200px" class="parameters_annotations">
2085
<td class="parameter_name"><p>iter</p></td>
2086
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a></p></td>
2087
<td class="parameter_annotations"> </td>
2091
<p class="since">Since 1.22</p>
2094
<div class="refsect2">
2095
<a name="pango-glyph-item-iter-init-start"></a><h3>pango_glyph_item_iter_init_start ()</h3>
2096
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
2097
pango_glyph_item_iter_init_start (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
2098
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
2099
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);</pre>
2100
<p>Initializes a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure to point to the
2101
first cluster in a glyph item.
2102
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2103
<div class="refsect3">
2104
<a name="id-1.2.3.11.50.5"></a><h4>Parameters</h4>
2105
<div class="informaltable"><table width="100%" border="0">
2107
<col width="150px" class="parameters_name">
2108
<col class="parameters_description">
2109
<col width="200px" class="parameters_annotations">
2113
<td class="parameter_name"><p>iter</p></td>
2114
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a></p></td>
2115
<td class="parameter_annotations"> </td>
2118
<td class="parameter_name"><p>glyph_item</p></td>
2119
<td class="parameter_description"><p>the glyph item to iterate over</p></td>
2120
<td class="parameter_annotations"> </td>
2123
<td class="parameter_name"><p>text</p></td>
2124
<td class="parameter_description"><p>text corresponding to the glyph item</p></td>
2125
<td class="parameter_annotations"> </td>
2130
<div class="refsect3">
2131
<a name="id-1.2.3.11.50.6"></a><h4>Returns</h4>
2132
<p> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if there are no clusters in the glyph item</p>
2135
<p class="since">Since 1.22</p>
2138
<div class="refsect2">
2139
<a name="pango-glyph-item-iter-init-end"></a><h3>pango_glyph_item_iter_init_end ()</h3>
2140
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
2141
pango_glyph_item_iter_init_end (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
2142
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
2143
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);</pre>
2144
<p>Initializes a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure to point to the
2145
last cluster in a glyph item.
2146
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2147
<div class="refsect3">
2148
<a name="id-1.2.3.11.51.5"></a><h4>Parameters</h4>
2149
<div class="informaltable"><table width="100%" border="0">
2151
<col width="150px" class="parameters_name">
2152
<col class="parameters_description">
2153
<col width="200px" class="parameters_annotations">
2157
<td class="parameter_name"><p>iter</p></td>
2158
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a></p></td>
2159
<td class="parameter_annotations"> </td>
2162
<td class="parameter_name"><p>glyph_item</p></td>
2163
<td class="parameter_description"><p>the glyph item to iterate over</p></td>
2164
<td class="parameter_annotations"> </td>
2167
<td class="parameter_name"><p>text</p></td>
2168
<td class="parameter_description"><p>text corresponding to the glyph item</p></td>
2169
<td class="parameter_annotations"> </td>
2174
<div class="refsect3">
2175
<a name="id-1.2.3.11.51.6"></a><h4>Returns</h4>
2176
<p> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if there are no clusters in the glyph item</p>
2179
<p class="since">Since 1.22</p>
2182
<div class="refsect2">
2183
<a name="pango-glyph-item-iter-next-cluster"></a><h3>pango_glyph_item_iter_next_cluster ()</h3>
2184
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
2185
pango_glyph_item_iter_next_cluster (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
2186
<p>Advances the iterator to the next cluster in the glyph item.
2187
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2188
<div class="refsect3">
2189
<a name="id-1.2.3.11.52.5"></a><h4>Parameters</h4>
2190
<div class="informaltable"><table width="100%" border="0">
2192
<col width="150px" class="parameters_name">
2193
<col class="parameters_description">
2194
<col width="200px" class="parameters_annotations">
2197
<td class="parameter_name"><p>iter</p></td>
2198
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a></p></td>
2199
<td class="parameter_annotations"> </td>
2203
<div class="refsect3">
2204
<a name="id-1.2.3.11.52.6"></a><h4>Returns</h4>
2205
<p> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the iterator was advanced, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if we were already on the
2209
<p class="since">Since 1.22</p>
2212
<div class="refsect2">
2213
<a name="pango-glyph-item-iter-prev-cluster"></a><h3>pango_glyph_item_iter_prev_cluster ()</h3>
2214
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
2215
pango_glyph_item_iter_prev_cluster (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
2216
<p>Moves the iterator to the preceding cluster in the glyph item.
2217
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2218
<div class="refsect3">
2219
<a name="id-1.2.3.11.53.5"></a><h4>Parameters</h4>
2220
<div class="informaltable"><table width="100%" border="0">
2222
<col width="150px" class="parameters_name">
2223
<col class="parameters_description">
2224
<col width="200px" class="parameters_annotations">
2227
<td class="parameter_name"><p>iter</p></td>
2228
<td class="parameter_description"><p>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a></p></td>
2229
<td class="parameter_annotations"> </td>
2233
<div class="refsect3">
2234
<a name="id-1.2.3.11.53.6"></a><h4>Returns</h4>
2235
<p> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the iterator was moved, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if we were already on the
2239
<p class="since">Since 1.22</p>
2242
<div class="refsect1">
2243
<a name="pango-Glyph-Storage.other_details"></a><h2>Types and Values</h2>
2244
<div class="refsect2">
2245
<a name="PANGO-SCALE:CAPS"></a><h3>PANGO_SCALE</h3>
2246
<pre class="programlisting">#define PANGO_SCALE 1024
2248
<p>The <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> macro represents the scale between dimensions used
2249
for Pango distances and device units. (The definition of device
2250
units is dependent on the output device; it will typically be pixels
2251
for a screen, and points for a printer.) <a class="link" href="pango-Glyph-Storage.html#PANGO-SCALE:CAPS" title="PANGO_SCALE"><code class="literal">PANGO_SCALE</code></a> is currently
2252
1024, but this may be changed in the future.</p>
2253
<p>When setting font sizes, device units are always considered to be
2254
points (as in "12 point font"), rather than pixels.</p>
2257
<div class="refsect2">
2258
<a name="PangoRectangle"></a><h3>struct PangoRectangle</h3>
2259
<pre class="programlisting">struct PangoRectangle {
2266
<p>The <a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> structure represents a rectangle. It is frequently
2267
used to represent the logical or ink extents of a single glyph or section
2268
of text. (See, for instance, <a class="link" href="pango-Fonts.html#pango-font-get-glyph-extents" title="pango_font_get_glyph_extents ()"><code class="function">pango_font_get_glyph_extents()</code></a>)</p>
2269
<div class="refsect3">
2270
<a name="id-1.2.3.12.3.5"></a><h4>Members</h4>
2271
<div class="informaltable"><table width="100%" border="0">
2273
<col width="300px" class="struct_members_name">
2274
<col class="struct_members_description">
2275
<col width="200px" class="struct_members_annotations">
2279
<td class="struct_member_name"><p><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.x"></a>x</code></em>;</p></td>
2280
<td class="struct_member_description"><p>X coordinate of the left side of the rectangle.</p></td>
2281
<td class="struct_member_annotations"> </td>
2284
<td class="struct_member_name"><p><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.y"></a>y</code></em>;</p></td>
2285
<td class="struct_member_description"><p>Y coordinate of the the top side of the rectangle.</p></td>
2286
<td class="struct_member_annotations"> </td>
2289
<td class="struct_member_name"><p><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.width"></a>width</code></em>;</p></td>
2290
<td class="struct_member_description"><p>width of the rectangle.</p></td>
2291
<td class="struct_member_annotations"> </td>
2294
<td class="struct_member_name"><p><span class="type">int</span> <em class="structfield"><code><a name="PangoRectangle.height"></a>height</code></em>;</p></td>
2295
<td class="struct_member_description"><p>height of the rectangle.</p></td>
2296
<td class="struct_member_annotations"> </td>
2303
<div class="refsect2">
2304
<a name="PangoMatrix-struct"></a><h3>struct PangoMatrix</h3>
2305
<pre class="programlisting">struct PangoMatrix {
2314
<p>A structure specifying a transformation between user-space
2315
coordinates and device coordinates. The transformation
2317
<pre class="programlisting">
2318
x_device = x_user * matrix->xx + y_user * matrix->xy + matrix->x0;
2319
y_device = x_user * matrix->yx + y_user * matrix->yy + matrix->y0;
2321
<div class="refsect3">
2322
<a name="id-1.2.3.12.4.6"></a><h4>Members</h4>
2323
<div class="informaltable"><table width="100%" border="0">
2325
<col width="300px" class="struct_members_name">
2326
<col class="struct_members_description">
2327
<col width="200px" class="struct_members_annotations">
2331
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.xx"></a>xx</code></em>;</p></td>
2332
<td class="struct_member_description"><p>1st component of the transformation matrix</p></td>
2333
<td class="struct_member_annotations"> </td>
2336
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.xy"></a>xy</code></em>;</p></td>
2337
<td class="struct_member_description"><p>2nd component of the transformation matrix</p></td>
2338
<td class="struct_member_annotations"> </td>
2341
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.yx"></a>yx</code></em>;</p></td>
2342
<td class="struct_member_description"><p>3rd component of the transformation matrix</p></td>
2343
<td class="struct_member_annotations"> </td>
2346
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.yy"></a>yy</code></em>;</p></td>
2347
<td class="struct_member_description"><p>4th component of the transformation matrix</p></td>
2348
<td class="struct_member_annotations"> </td>
2351
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.x0"></a>x0</code></em>;</p></td>
2352
<td class="struct_member_description"><p>x translation</p></td>
2353
<td class="struct_member_annotations"> </td>
2356
<td class="struct_member_name"><p><span class="type">double</span> <em class="structfield"><code><a name="PangoMatrix-struct.y0"></a>y0</code></em>;</p></td>
2357
<td class="struct_member_description"><p>y translation</p></td>
2358
<td class="struct_member_annotations"> </td>
2363
<p class="since">Since 1.6</p>
2366
<div class="refsect2">
2367
<a name="PANGO-MATRIX-INIT:CAPS"></a><h3>PANGO_MATRIX_INIT</h3>
2368
<pre class="programlisting">#define PANGO_MATRIX_INIT { 1., 0., 0., 1., 0., 0. }
2370
<p>Constant that can be used to initialize a PangoMatrix to
2371
the identity transform.</p>
2372
<div class="informalexample">
2373
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
2376
<td class="listing_lines" align="right"><pre>1
2378
<td class="listing_code"><pre class="programlisting"><span class="usertype">PangoMatrix</span><span class="normal"> matrix </span><span class="symbol">=</span><span class="normal"> <a href="pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS">PANGO_MATRIX_INIT</a></span><span class="symbol">;</span>
2379
<span class="function"><a href="pango-Glyph-Storage.html#pango-matrix-rotate">pango_matrix_rotate</a></span><span class="normal"> </span><span class="symbol">(&</span><span class="normal">matrix</span><span class="symbol">,</span><span class="normal"> </span><span class="number">45</span><span class="symbol">.);</span></pre></td>
2385
<p class="since">Since 1.6</p>
2388
<div class="refsect2">
2389
<a name="PangoGlyph"></a><h3>PangoGlyph</h3>
2390
<pre class="programlisting">typedef guint32 PangoGlyph;
2392
<p>A <a class="link" href="pango-Glyph-Storage.html#PangoGlyph" title="PangoGlyph"><span class="type">PangoGlyph</span></a> represents a single glyph in the output form of a string.</p>
1040
2395
<div class="refsect2">
1229
Note that <em class="parameter"><code>text</code></em> is the start of the text for layout, which is then
1230
indexed by <code class="literal"><em class="parameter"><code>glyph_item->item->offset</code></em></code> to get to the
1231
text of <em class="parameter"><code>glyph_item</code></em>. The <em class="parameter"><code>start_index</code></em> and <em class="parameter"><code>end_index</code></em> values can directly
1232
index into <em class="parameter"><code>text</code></em>. The <em class="parameter"><code>start_glyph</code></em>, <em class="parameter"><code>end_glyph</code></em>, <em class="parameter"><code>start_char</code></em>, and <em class="parameter"><code>end_char</code></em>
1233
values however are zero-based for the <em class="parameter"><code>glyph_item</code></em>. For each cluster, the
2600
<p>Note that <em class="parameter"><code>text</code></em>
2601
is the start of the text for layout, which is then
2602
indexed by <code class="literal"><em class="parameter"><code>glyph_item->item->offset</code></em>
2603
</code> to get to the
2604
text of <em class="parameter"><code>glyph_item</code></em>
2605
. The <em class="parameter"><code>start_index</code></em>
2606
and <em class="parameter"><code>end_index</code></em>
2608
index into <em class="parameter"><code>text</code></em>
2609
. The <em class="parameter"><code>start_glyph</code></em>
2610
, <em class="parameter"><code>end_glyph</code></em>
2611
, <em class="parameter"><code>start_char</code></em>
2612
, and <em class="parameter"><code>end_char</code></em>
2614
values however are zero-based for the <em class="parameter"><code>glyph_item</code></em>
2615
. For each cluster, the
1234
2616
item pointed at by the start variables is included in the cluster while
1235
2617
the one pointed at by end variables is not.</p>
1237
None of the members of a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> should be modified manually.</p>
1238
<p class="since">Since 1.22</p>
1241
<div class="refsect2">
1242
<a name="PANGO-TYPE-GLYPH-STRING:CAPS"></a><h3>PANGO_TYPE_GLYPH_STRING</h3>
1243
<pre class="programlisting">#define PANGO_TYPE_GLYPH_STRING (pango_glyph_string_get_type ())
1246
The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</p>
1249
<div class="refsect2">
1250
<a name="pango-glyph-string-new"></a><h3>pango_glyph_string_new ()</h3>
1251
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> * pango_glyph_string_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
1253
Create a new <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</p>
1254
<div class="variablelist"><table border="0" class="variablelist">
1256
<col align="left" valign="top">
1260
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1261
<td>the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, which
1262
should be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()"><code class="function">pango_glyph_string_free()</code></a>.</td>
1267
<div class="refsect2">
1268
<a name="pango-glyph-string-copy"></a><h3>pango_glyph_string_copy ()</h3>
1269
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="returnvalue">PangoGlyphString</span></a> * pango_glyph_string_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);</pre>
1271
Copy a glyph string and associated storage.</p>
1272
<div class="variablelist"><table border="0" class="variablelist">
1274
<col align="left" valign="top">
1279
<td><p><span class="term"><em class="parameter"><code>string</code></em> :</span></p></td>
1280
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1284
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1285
<td>the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, which
1286
should be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-free" title="pango_glyph_string_free ()"><code class="function">pango_glyph_string_free()</code></a>,
1287
or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>string</code></em> was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
1293
<div class="refsect2">
1294
<a name="pango-glyph-string-set-size"></a><h3>pango_glyph_string_set_size ()</h3>
1295
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_set_size (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>,
1296
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> new_len</code></em>);</pre>
1298
Resize a glyph string to the given length.</p>
1299
<div class="variablelist"><table border="0" class="variablelist">
1301
<col align="left" valign="top">
1306
<td><p><span class="term"><em class="parameter"><code>string</code></em> :</span></p></td>
1307
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>.</td>
1310
<td><p><span class="term"><em class="parameter"><code>new_len</code></em> :</span></p></td>
1311
<td>the new length of the string.</td>
1317
<div class="refsect2">
1318
<a name="pango-glyph-string-free"></a><h3>pango_glyph_string_free ()</h3>
1319
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *string</code></em>);</pre>
1321
Free a glyph string and associated storage.</p>
1322
<div class="variablelist"><table border="0" class="variablelist">
1324
<col align="left" valign="top">
1328
<td><p><span class="term"><em class="parameter"><code>string</code></em> :</span></p></td>
1329
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1335
<div class="refsect2">
1336
<a name="pango-glyph-string-extents"></a><h3>pango_glyph_string_extents ()</h3>
1337
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_extents (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1338
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
1339
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
1340
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);</pre>
1342
Compute the logical and ink extents of a glyph string. See the documentation
1343
for <a class="link" href="pango-Fonts.html#pango-font-get-glyph-extents" title="pango_font_get_glyph_extents ()"><code class="function">pango_font_get_glyph_extents()</code></a> for details about the interpretation
1344
of the rectangles.</p>
1345
<div class="variablelist"><table border="0" class="variablelist">
1347
<col align="left" valign="top">
1352
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1353
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>
1357
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
1358
<td>a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>
1362
<td><p><span class="term"><em class="parameter"><code>ink_rect</code></em> :</span></p></td>
1363
<td>rectangle used to store the extents of the glyph string
1364
as drawn or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to indicate that the result is not needed. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
1368
<td><p><span class="term"><em class="parameter"><code>logical_rect</code></em> :</span></p></td>
1369
<td>rectangle used to store the logical extents of the
1370
glyph string or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to indicate that the result is not needed. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
1377
<div class="refsect2">
1378
<a name="pango-glyph-string-extents-range"></a><h3>pango_glyph_string_extents_range ()</h3>
1379
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_extents_range (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1380
<em class="parameter"><code><span class="type">int</span> start</code></em>,
1381
<em class="parameter"><code><span class="type">int</span> end</code></em>,
1382
<em class="parameter"><code><a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a> *font</code></em>,
1383
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *ink_rect</code></em>,
1384
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoRectangle" title="struct PangoRectangle"><span class="type">PangoRectangle</span></a> *logical_rect</code></em>);</pre>
1386
Computes the extents of a sub-portion of a glyph string. The extents are
1387
relative to the start of the glyph string range (the origin of their
1388
coordinate system is at the start of the range, not at the start of the entire
1390
<div class="variablelist"><table border="0" class="variablelist">
1392
<col align="left" valign="top">
1397
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1398
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>
1402
<td><p><span class="term"><em class="parameter"><code>start</code></em> :</span></p></td>
1403
<td>start index</td>
1406
<td><p><span class="term"><em class="parameter"><code>end</code></em> :</span></p></td>
1407
<td>end index (the range is the set of bytes with
1408
indices such that start <= index < end)</td>
1411
<td><p><span class="term"><em class="parameter"><code>font</code></em> :</span></p></td>
1412
<td>a <a class="link" href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>
1416
<td><p><span class="term"><em class="parameter"><code>ink_rect</code></em> :</span></p></td>
1417
<td>rectangle used to store the
1418
extents of the glyph string range as drawn or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to
1419
indicate that the result is not needed. <span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span>
1423
<td><p><span class="term"><em class="parameter"><code>logical_rect</code></em> :</span></p></td>
1424
<td>rectangle used to store the
1425
logical extents of the glyph string range or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to
1426
indicate that the result is not needed. <span class="annotation">[<acronym title="Out parameter, where caller must allocate storage."><span class="acronym">out caller-allocates</span></acronym>]</span>
1433
<div class="refsect2">
1434
<a name="pango-glyph-string-get-width"></a><h3>pango_glyph_string_get_width ()</h3>
1435
<pre class="programlisting"><span class="returnvalue">int</span> pango_glyph_string_get_width (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>);</pre>
1437
Computes the logical width of the glyph string as can also be computed
1438
using <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-extents" title="pango_glyph_string_extents ()"><code class="function">pango_glyph_string_extents()</code></a>. However, since this only computes the
1439
width, it's much faster. This is in fact only a convenience function that
1440
computes the sum of geometry.width for each glyph in the <em class="parameter"><code>glyphs</code></em>.</p>
1441
<div class="variablelist"><table border="0" class="variablelist">
1443
<col align="left" valign="top">
1448
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1449
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>
1453
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1454
<td>the logical width of the glyph string.</td>
1458
<p class="since">Since 1.14</p>
1461
<div class="refsect2">
1462
<a name="pango-glyph-string-index-to-x"></a><h3>pango_glyph_string_index_to_x ()</h3>
1463
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_index_to_x (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1464
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
1465
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1466
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
1467
<em class="parameter"><code><span class="type">int</span> index_</code></em>,
1468
<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> trailing</code></em>,
1469
<em class="parameter"><code><span class="type">int</span> *x_pos</code></em>);</pre>
1471
Converts from character position to x position. (X position
1472
is measured from the left edge of the run). Character positions
1473
are computed by dividing up each cluster into equal portions.</p>
1474
<div class="variablelist"><table border="0" class="variablelist">
1476
<col align="left" valign="top">
1481
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1482
<td>the glyphs return from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a>
1486
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1487
<td>the text for the run</td>
1490
<td><p><span class="term"><em class="parameter"><code>length</code></em> :</span></p></td>
1491
<td>the number of bytes (not characters) in <em class="parameter"><code>text</code></em>.</td>
1494
<td><p><span class="term"><em class="parameter"><code>analysis</code></em> :</span></p></td>
1495
<td>the analysis information return from <a class="link" href="pango-Text-Processing.html#pango-itemize" title="pango_itemize ()"><code class="function">pango_itemize()</code></a>
1499
<td><p><span class="term"><em class="parameter"><code>index_</code></em> :</span></p></td>
1500
<td>the byte index within <em class="parameter"><code>text</code></em>
1504
<td><p><span class="term"><em class="parameter"><code>trailing</code></em> :</span></p></td>
1505
<td>whether we should compute the result for the beginning (<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a>)
1506
or end (<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>) of the character.</td>
1509
<td><p><span class="term"><em class="parameter"><code>x_pos</code></em> :</span></p></td>
1510
<td>location to store result. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span>
1517
<div class="refsect2">
1518
<a name="pango-glyph-string-x-to-index"></a><h3>pango_glyph_string_x_to_index ()</h3>
1519
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_x_to_index (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1520
<em class="parameter"><code><span class="type">char</span> *text</code></em>,
1521
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1522
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoAnalysis" title="struct PangoAnalysis"><span class="type">PangoAnalysis</span></a> *analysis</code></em>,
1523
<em class="parameter"><code><span class="type">int</span> x_pos</code></em>,
1524
<em class="parameter"><code><span class="type">int</span> *index_</code></em>,
1525
<em class="parameter"><code><span class="type">int</span> *trailing</code></em>);</pre>
1527
Convert from x offset to character position. Character positions
1528
are computed by dividing up each cluster into equal portions.
1529
In scripts where positioning within a cluster is not allowed
1530
(such as Thai), the returned value may not be a valid cursor
1531
position; the caller must combine the result with the logical
1532
attributes for the text to compute the valid cursor position.</p>
1533
<div class="variablelist"><table border="0" class="variablelist">
1535
<col align="left" valign="top">
1540
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1541
<td>the glyphs returned from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a>
1545
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1546
<td>the text for the run</td>
1549
<td><p><span class="term"><em class="parameter"><code>length</code></em> :</span></p></td>
1550
<td>the number of bytes (not characters) in text.</td>
1553
<td><p><span class="term"><em class="parameter"><code>analysis</code></em> :</span></p></td>
1554
<td>the analysis information return from <a class="link" href="pango-Text-Processing.html#pango-itemize" title="pango_itemize ()"><code class="function">pango_itemize()</code></a>
1558
<td><p><span class="term"><em class="parameter"><code>x_pos</code></em> :</span></p></td>
1559
<td>the x offset (in Pango units)</td>
1562
<td><p><span class="term"><em class="parameter"><code>index_</code></em> :</span></p></td>
1563
<td>location to store calculated byte index within <em class="parameter"><code>text</code></em>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span>
1567
<td><p><span class="term"><em class="parameter"><code>trailing</code></em> :</span></p></td>
1568
<td>location to store a boolean indicating
1569
whether the user clicked on the leading or trailing
1570
edge of the character. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>]</span>
1577
<div class="refsect2">
1578
<a name="pango-glyph-string-get-logical-widths"></a><h3>pango_glyph_string_get_logical_widths ()</h3>
1579
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_string_get_logical_widths
1580
(<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> *glyphs</code></em>,
1581
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1582
<em class="parameter"><code><span class="type">int</span> length</code></em>,
1583
<em class="parameter"><code><span class="type">int</span> embedding_level</code></em>,
1584
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);</pre>
1586
Given a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a> resulting from <a class="link" href="pango-Text-Processing.html#pango-shape" title="pango_shape ()"><code class="function">pango_shape()</code></a> and the corresponding
1587
text, determine the screen width corresponding to each character. When
1588
multiple characters compose a single cluster, the width of the entire
1589
cluster is divided equally among the characters.</p>
1591
See also <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-get-logical-widths" title="pango_glyph_item_get_logical_widths ()"><code class="function">pango_glyph_item_get_logical_widths()</code></a>.</p>
1592
<div class="variablelist"><table border="0" class="variablelist">
1594
<col align="left" valign="top">
1599
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
1600
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphString"><span class="type">PangoGlyphString</span></a>
1604
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1605
<td>the text corresponding to the glyphs</td>
1608
<td><p><span class="term"><em class="parameter"><code>length</code></em> :</span></p></td>
1609
<td>the length of <em class="parameter"><code>text</code></em>, in bytes</td>
1612
<td><p><span class="term"><em class="parameter"><code>embedding_level</code></em> :</span></p></td>
1613
<td>the embedding level of the string</td>
1616
<td><p><span class="term"><em class="parameter"><code>logical_widths</code></em> :</span></p></td>
1617
<td>an array whose length is the number of
1618
characters in text (equal to g_utf8_strlen (text,
1619
length) unless text has NUL bytes) to be filled in
1620
with the resulting character widths. <span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span>
1627
<div class="refsect2">
1628
<a name="PANGO-TYPE-GLYPH-ITEM:CAPS"></a><h3>PANGO_TYPE_GLYPH_ITEM</h3>
1629
<pre class="programlisting">#define PANGO_TYPE_GLYPH_ITEM (pango_glyph_item_get_type ())
1632
The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>.</p>
1635
<div class="refsect2">
1636
<a name="pango-glyph-item-copy"></a><h3>pango_glyph_item_copy ()</h3>
1637
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> * pango_glyph_item_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>);</pre>
1639
Make a deep copy of an existing <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> structure.</p>
1640
<div class="variablelist"><table border="0" class="variablelist">
1642
<col align="left" valign="top">
1647
<td><p><span class="term"><em class="parameter"><code>orig</code></em> :</span></p></td>
1648
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1652
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1653
<td>the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, which should
1654
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1655
if <em class="parameter"><code>orig</code></em> was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
1659
<p class="since">Since 1.20</p>
1662
<div class="refsect2">
1663
<a name="pango-glyph-item-free"></a><h3>pango_glyph_item_free ()</h3>
1664
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_item_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>);</pre>
1666
Frees a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> and resources to which it points.</p>
1667
<div class="variablelist"><table border="0" class="variablelist">
1669
<col align="left" valign="top">
1673
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1674
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1678
<p class="since">Since 1.6</p>
1681
<div class="refsect2">
1682
<a name="pango-glyph-item-split"></a><h3>pango_glyph_item_split ()</h3>
1683
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="returnvalue">PangoGlyphItem</span></a> * pango_glyph_item_split (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *orig</code></em>,
1684
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1685
<em class="parameter"><code><span class="type">int</span> split_index</code></em>);</pre>
1687
Modifies <em class="parameter"><code>orig</code></em> to cover only the text after <em class="parameter"><code>split_index</code></em>, and
1688
returns a new item that covers the text before <em class="parameter"><code>split_index</code></em> that
1689
used to be in <em class="parameter"><code>orig</code></em>. You can think of <em class="parameter"><code>split_index</code></em> as the length of
1690
the returned item. <em class="parameter"><code>split_index</code></em> may not be 0, and it may not be
1691
greater than or equal to the length of <em class="parameter"><code>orig</code></em> (that is, there must
1692
be at least one byte assigned to each item, you can't create a
1693
zero-length item).</p>
1695
This function is similar in function to <a class="link" href="pango-Text-Processing.html#pango-item-split" title="pango_item_split ()"><code class="function">pango_item_split()</code></a> (and uses
1697
<div class="variablelist"><table border="0" class="variablelist">
1699
<col align="left" valign="top">
1704
<td><p><span class="term"><em class="parameter"><code>orig</code></em> :</span></p></td>
1705
<td>a <a class="link" href="pango-Text-Processing.html#PangoItem"><span class="type">PangoItem</span></a>
1709
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1710
<td>text to which positions in <em class="parameter"><code>orig</code></em> apply</td>
1713
<td><p><span class="term"><em class="parameter"><code>split_index</code></em> :</span></p></td>
1714
<td>byte index of position to split item, relative to the start of the item</td>
1717
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1718
<td>the newly allocated item representing text before
1719
<em class="parameter"><code>split_index</code></em>, which should be freed
1720
with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>.</td>
1724
<p class="since">Since 1.2</p>
1727
<div class="refsect2">
1728
<a name="pango-glyph-item-apply-attrs"></a><h3>pango_glyph_item_apply_attrs ()</h3>
1729
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"><span class="returnvalue">GSList</span></a> * pango_glyph_item_apply_attrs (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1730
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1731
<em class="parameter"><code><a class="link" href="pango-Text-Attributes.html#PangoAttrList"><span class="type">PangoAttrList</span></a> *list</code></em>);</pre>
1733
Splits a shaped item (PangoGlyphItem) into multiple items based
1734
on an attribute list. The idea is that if you have attributes
1735
that don't affect shaping, such as color or underline, to avoid
1736
affecting shaping, you filter them out (<a class="link" href="pango-Text-Attributes.html#pango-attr-list-filter" title="pango_attr_list_filter ()"><code class="function">pango_attr_list_filter()</code></a>),
1737
apply the shaping process and then reapply them to the result using
1740
All attributes that start or end inside a cluster are applied
1741
to that cluster; for instance, if half of a cluster is underlined
1742
and the other-half strikethrough, then the cluster will end
1743
up with both underline and strikethrough attributes. In these
1744
cases, it may happen that item->extra_attrs for some of the
1745
result items can have multiple attributes of the same type.</p>
1747
This function takes ownership of <em class="parameter"><code>glyph_item</code></em>; it will be reused
1748
as one of the elements in the list.</p>
1749
<div class="variablelist"><table border="0" class="variablelist">
1751
<col align="left" valign="top">
1756
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1757
<td>a shaped item</td>
1760
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1761
<td>text that <em class="parameter"><code>list</code></em> applies to</td>
1764
<td><p><span class="term"><em class="parameter"><code>list</code></em> :</span></p></td>
1765
<td>a <a class="link" href="pango-Text-Attributes.html#PangoAttrList"><span class="type">PangoAttrList</span></a>
1769
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1771
list of glyph items resulting from splitting <em class="parameter"><code>glyph_item</code></em>. Free
1772
the elements using <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-free" title="pango_glyph_item_free ()"><code class="function">pango_glyph_item_free()</code></a>, the list using
1773
<a href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#g-slist-free"><code class="function">g_slist_free()</code></a>. <span class="annotation">[<acronym title="Free data after the code is done."><span class="acronym">transfer full</span></acronym>][<acronym title="Generics and defining elements of containers and arrays."><span class="acronym">element-type</span></acronym> Pango.GlyphItem]</span>
1778
<p class="since">Since 1.2</p>
1781
<div class="refsect2">
1782
<a name="pango-glyph-item-letter-space"></a><h3>pango_glyph_item_letter_space ()</h3>
1783
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_item_letter_space (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1784
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1785
<em class="parameter"><code><a class="link" href="pango-Text-Processing.html#PangoLogAttr" title="PangoLogAttr"><span class="type">PangoLogAttr</span></a> *log_attrs</code></em>,
1786
<em class="parameter"><code><span class="type">int</span> letter_spacing</code></em>);</pre>
1788
Adds spacing between the graphemes of <em class="parameter"><code>glyph_item</code></em> to
1789
give the effect of typographic letter spacing.</p>
1790
<div class="variablelist"><table border="0" class="variablelist">
1792
<col align="left" valign="top">
1797
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1798
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>
1802
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1803
<td>text that <em class="parameter"><code>glyph_item</code></em> corresponds to
1804
(glyph_item->item->offset is an offset from the
1805
start of <em class="parameter"><code>text</code></em>)</td>
1808
<td><p><span class="term"><em class="parameter"><code>log_attrs</code></em> :</span></p></td>
1809
<td>logical attributes for the item
1810
(the first logical attribute refers to the position
1811
before the first character in the item). <span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span>
1815
<td><p><span class="term"><em class="parameter"><code>letter_spacing</code></em> :</span></p></td>
1816
<td>amount of letter spacing to add
1817
in Pango units. May be negative, though too large
1818
negative values will give ugly results.</td>
1822
<p class="since">Since 1.6</p>
1825
<div class="refsect2">
1826
<a name="pango-glyph-item-get-logical-widths"></a><h3>pango_glyph_item_get_logical_widths ()</h3>
1827
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_item_get_logical_widths (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1828
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>,
1829
<em class="parameter"><code><span class="type">int</span> *logical_widths</code></em>);</pre>
1831
Given a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> and the corresponding
1832
text, determine the screen width corresponding to each character. When
1833
multiple characters compose a single cluster, the width of the entire
1834
cluster is divided equally among the characters.</p>
1836
See also <a class="link" href="pango-Glyph-Storage.html#pango-glyph-string-get-logical-widths" title="pango_glyph_string_get_logical_widths ()"><code class="function">pango_glyph_string_get_logical_widths()</code></a>.</p>
1837
<div class="variablelist"><table border="0" class="variablelist">
1839
<col align="left" valign="top">
1844
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1845
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a>
1849
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1850
<td>text that <em class="parameter"><code>glyph_item</code></em> corresponds to
1851
(glyph_item->item->offset is an offset from the
1852
start of <em class="parameter"><code>text</code></em>)</td>
1855
<td><p><span class="term"><em class="parameter"><code>logical_widths</code></em> :</span></p></td>
1856
<td>an array whose length is the number of
1857
characters in glyph_item (equal to
1858
glyph_item->item->num_chars) to be filled in with
1859
the resulting character widths. <span class="annotation">[<acronym title="Parameter points to an array of items."><span class="acronym">array</span></acronym>]</span>
1864
<p class="since">Since 1.26</p>
1867
<div class="refsect2">
1868
<a name="PANGO-TYPE-GLYPH-ITEM-ITER:CAPS"></a><h3>PANGO_TYPE_GLYPH_ITEM_ITER</h3>
1869
<pre class="programlisting">#define PANGO_TYPE_GLYPH_ITEM_ITER (pango_glyph_item_iter_get_type ())
1872
The <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> type for <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>.</p>
1873
<p class="since">Since 1.22</p>
1876
<div class="refsect2">
1877
<a name="pango-glyph-item-iter-copy"></a><h3>pango_glyph_item_iter_copy ()</h3>
1878
<pre class="programlisting"><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="returnvalue">PangoGlyphItemIter</span></a> * pango_glyph_item_iter_copy (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *orig</code></em>);</pre>
1880
Make a shallow copy of an existing <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure.</p>
1881
<div class="variablelist"><table border="0" class="variablelist">
1883
<col align="left" valign="top">
1888
<td><p><span class="term"><em class="parameter"><code>orig</code></em> :</span></p></td>
1889
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1893
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1894
<td>the newly allocated <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, which should
1895
be freed with <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-free" title="pango_glyph_item_iter_free ()"><code class="function">pango_glyph_item_iter_free()</code></a>, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1896
if <em class="parameter"><code>orig</code></em> was <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</td>
1900
<p class="since">Since 1.22</p>
1903
<div class="refsect2">
1904
<a name="pango-glyph-item-iter-free"></a><h3>pango_glyph_item_iter_free ()</h3>
1905
<pre class="programlisting"><span class="returnvalue">void</span> pango_glyph_item_iter_free (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
1907
Frees a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> created by <a class="link" href="pango-Glyph-Storage.html#pango-glyph-item-iter-copy" title="pango_glyph_item_iter_copy ()"><code class="function">pango_glyph_item_iter_copy()</code></a>.</p>
1908
<div class="variablelist"><table border="0" class="variablelist">
1910
<col align="left" valign="top">
1914
<td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td>
1915
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>, may be <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
1919
<p class="since">Since 1.22</p>
1922
<div class="refsect2">
1923
<a name="pango-glyph-item-iter-init-start"></a><h3>pango_glyph_item_iter_init_start ()</h3>
1924
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> pango_glyph_item_iter_init_start (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
1925
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1926
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);</pre>
1928
Initializes a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure to point to the
1929
first cluster in a glyph item.
1930
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
1931
<div class="variablelist"><table border="0" class="variablelist">
1933
<col align="left" valign="top">
1938
<td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td>
1939
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>
1943
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1944
<td>the glyph item to iterate over</td>
1947
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1948
<td>text corresponding to the glyph item</td>
1951
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1953
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if there are no clusters in the glyph item</td>
1957
<p class="since">Since 1.22</p>
1960
<div class="refsect2">
1961
<a name="pango-glyph-item-iter-init-end"></a><h3>pango_glyph_item_iter_init_end ()</h3>
1962
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> pango_glyph_item_iter_init_end (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>,
1963
<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItem"><span class="type">PangoGlyphItem</span></a> *glyph_item</code></em>,
1964
<em class="parameter"><code>const <span class="type">char</span> *text</code></em>);</pre>
1966
Initializes a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> structure to point to the
1967
last cluster in a glyph item.
1968
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
1969
<div class="variablelist"><table border="0" class="variablelist">
1971
<col align="left" valign="top">
1976
<td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td>
1977
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>
1981
<td><p><span class="term"><em class="parameter"><code>glyph_item</code></em> :</span></p></td>
1982
<td>the glyph item to iterate over</td>
1985
<td><p><span class="term"><em class="parameter"><code>text</code></em> :</span></p></td>
1986
<td>text corresponding to the glyph item</td>
1989
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
1991
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if there are no clusters in the glyph item</td>
1995
<p class="since">Since 1.22</p>
1998
<div class="refsect2">
1999
<a name="pango-glyph-item-iter-next-cluster"></a><h3>pango_glyph_item_iter_next_cluster ()</h3>
2000
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> pango_glyph_item_iter_next_cluster (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
2002
Advances the iterator to the next cluster in the glyph item.
2003
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2004
<div class="variablelist"><table border="0" class="variablelist">
2006
<col align="left" valign="top">
2011
<td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td>
2012
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>
2016
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
2018
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the iterator was advanced, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if we were already on the
2023
<p class="since">Since 1.22</p>
2026
<div class="refsect2">
2027
<a name="pango-glyph-item-iter-prev-cluster"></a><h3>pango_glyph_item_iter_prev_cluster ()</h3>
2028
<pre class="programlisting"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a> pango_glyph_item_iter_prev_cluster (<em class="parameter"><code><a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> *iter</code></em>);</pre>
2030
Moves the iterator to the preceding cluster in the glyph item.
2031
See <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> for details of cluster orders.</p>
2032
<div class="variablelist"><table border="0" class="variablelist">
2034
<col align="left" valign="top">
2039
<td><p><span class="term"><em class="parameter"><code>iter</code></em> :</span></p></td>
2040
<td>a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a>
2044
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
2046
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if the iterator was moved, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> if we were already on the
2618
<p>None of the members of a <a class="link" href="pango-Glyph-Storage.html#PangoGlyphItemIter"><span class="type">PangoGlyphItemIter</span></a> should be modified manually.</p>
2051
2619
<p class="since">Since 1.22</p>
2055
2623
<div class="footer">
2057
Generated by GTK-Doc V1.19.1</div>
2625
Generated by GTK-Doc V1.20.1</div>
b'\\ No newline at end of file'