Git init
[external/pango1.0.git] / docs / tmpl / xft-fonts.sgml
1 <!-- ##### SECTION Title ##### -->
2 Xft Fonts and Rendering
3
4 <!-- ##### SECTION Short_Description ##### -->
5 Font handling and rendering with the Xft backend
6
7 <!-- ##### SECTION Long_Description ##### -->
8 <para>
9 The Xft library is a library for displaying fonts on the X window
10 system; internally it uses the fontconfig library to locate font
11 files, and the FreeType library to load and render fonts. The
12 Xft backend is the recommended Pango font backend for screen
13 display with X. (The <link linkend="pango-Cairo-Rendering">Cairo back end</link> is another possibility.)
14 </para>
15 <para>
16 Using the Xft backend is generally straightforward;
17 pango_xft_get_context() creates a context for a specified display
18 and screen. You can then create a #PangoLayout with that context
19 and render it with pango_xft_render_layout(). At a more advanced
20 level, the low-level fontconfig options used for rendering fonts
21 can be affected using pango_xft_set_default_substitute(), and
22 pango_xft_substitute_changed().
23 </para>
24 <para>
25 A range of functions for drawing pieces of a layout, such as
26 individual layout lines and glyphs strings are provided.  You can also
27 directly create a #PangoXftRenderer. Finally, in some advanced cases, it
28 is useful to derive from #PangoXftRenderer. Deriving from
29 #PangoXftRenderer is useful for two reasons. One reason is be to
30 support custom attributes by overriding #PangoRendererClass virtual
31 functions like 'prepare_run' or 'draw_shape'. The reason is to
32 customize exactly how the final bits are drawn to the destination by
33 overriding the #PangoXftRendererClass virtual functions
34 'composite_glyphs' and 'composite_trapezoids'.
35 </para>
36
37 <!-- ##### SECTION See_Also ##### -->
38 <para>
39
40 </para>
41
42 <!-- ##### SECTION Stability_Level ##### -->
43
44
45 <!-- ##### STRUCT PangoXftFont ##### -->
46 <para>
47 #PangoXftFont is an implementation of #PangoFcFont using the Xft
48 library for rendering.  It is used in conjunction with #PangoXftFontMap.
49 </para>
50
51
52 <!-- ##### STRUCT PangoXftFontMap ##### -->
53 <para>
54 #PangoXftFontMap is an implementation of #PangoFcFontMap suitable for
55 the Xft library as the renderer.  It is used in to create fonts of
56 type #PangoXftFont.
57 </para>
58
59
60 <!-- ##### MACRO PANGO_RENDER_TYPE_XFT ##### -->
61 <para>
62 A string constant that was used to identify shape engines that work
63 with the Xft backend. See %PANGO_RENDER_TYPE_FC for the replacement.
64 </para>
65
66
67
68 <!-- ##### FUNCTION pango_xft_get_context ##### -->
69 <para>
70
71 </para>
72
73 @display: 
74 @screen: 
75 @Returns: 
76
77
78 <!-- ##### FUNCTION pango_xft_get_font_map ##### -->
79 <para>
80
81 </para>
82
83 @display: 
84 @screen: 
85 @Returns: 
86
87
88 <!-- ##### FUNCTION pango_xft_set_default_substitute ##### -->
89 <para>
90
91 </para>
92
93 @display: 
94 @screen: 
95 @func: 
96 @data: 
97 @notify: 
98
99
100 <!-- ##### USER_FUNCTION PangoXftSubstituteFunc ##### -->
101 <para>
102 Function type for doing final config tweaking on prepared FcPatterns.
103 </para>
104
105 @pattern: the FcPattern to tweak.
106 @data: user data.
107
108
109 <!-- ##### FUNCTION pango_xft_substitute_changed ##### -->
110 <para>
111
112 </para>
113
114 @display: 
115 @screen: 
116
117
118 <!-- ##### FUNCTION pango_xft_shutdown_display ##### -->
119 <para>
120
121 </para>
122
123 @display: 
124 @screen: 
125
126
127 <!-- ##### FUNCTION pango_xft_font_get_font ##### -->
128 <para>
129
130 </para>
131
132 @font: 
133 @Returns: 
134
135
136 <!-- ##### FUNCTION pango_xft_font_get_display ##### -->
137 <para>
138
139 </para>
140
141 @font: 
142 @Returns: 
143
144
145 <!-- ##### FUNCTION pango_xft_font_has_char ##### -->
146 <para>
147
148 </para>
149
150 @font: 
151 @wc: 
152 @Returns: 
153
154
155 <!-- ##### FUNCTION pango_xft_font_lock_face ##### -->
156 <para>
157
158 </para>
159
160 @font: 
161 @Returns: 
162
163
164 <!-- ##### FUNCTION pango_xft_font_unlock_face ##### -->
165 <para>
166
167 </para>
168
169 @font: 
170
171
172 <!-- ##### FUNCTION pango_xft_font_get_glyph ##### -->
173 <para>
174
175 </para>
176
177 @font: 
178 @wc: 
179 @Returns: 
180
181
182 <!-- ##### FUNCTION pango_xft_font_get_unknown_glyph ##### -->
183 <para>
184
185 </para>
186
187 @font: 
188 @wc: 
189 @Returns: 
190
191
192 <!-- ##### STRUCT PangoXftRenderer ##### -->
193 <para>
194
195 </para>
196
197
198 <!-- ##### ARG PangoXftRenderer:display ##### -->
199 <para>
200
201 </para>
202
203 <!-- ##### ARG PangoXftRenderer:screen ##### -->
204 <para>
205
206 </para>
207
208 <!-- ##### STRUCT PangoXftRendererClass ##### -->
209 <para>
210
211 </para>
212
213 @composite_trapezoids: 
214 @composite_glyphs: 
215
216 <!-- ##### FUNCTION pango_xft_renderer_new ##### -->
217 <para>
218
219 </para>
220
221 @display: 
222 @screen: 
223 @Returns: 
224
225
226 <!-- ##### FUNCTION pango_xft_renderer_set_draw ##### -->
227 <para>
228
229 </para>
230
231 @xftrenderer: 
232 @draw: 
233
234
235 <!-- ##### FUNCTION pango_xft_renderer_set_default_color ##### -->
236 <para>
237
238 </para>
239
240 @xftrenderer: 
241 @default_color: 
242
243
244 <!-- ##### FUNCTION pango_xft_render ##### -->
245 <para>
246
247 </para>
248
249 @draw: 
250 @color: 
251 @font: 
252 @glyphs: 
253 @x: 
254 @y: 
255
256
257 <!-- ##### FUNCTION pango_xft_picture_render ##### -->
258 <para>
259
260 </para>
261
262 @display: 
263 @src_picture: 
264 @dest_picture: 
265 @font: 
266 @glyphs: 
267 @x: 
268 @y: 
269
270
271 <!-- ##### FUNCTION pango_xft_render_transformed ##### -->
272 <para>
273
274 </para>
275
276 @draw: 
277 @color: 
278 @matrix: 
279 @font: 
280 @glyphs: 
281 @x: 
282 @y: 
283
284
285 <!-- ##### FUNCTION pango_xft_render_layout_line ##### -->
286 <para>
287
288 </para>
289
290 @draw: 
291 @color: 
292 @line: 
293 @x: 
294 @y: 
295
296
297 <!-- ##### FUNCTION pango_xft_render_layout ##### -->
298 <para>
299
300 </para>
301
302 @draw: 
303 @color: 
304 @layout: 
305 @x: 
306 @y: 
307
308