jpayne@68
|
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
jpayne@68
|
2 <html>
|
jpayne@68
|
3 <head>
|
jpayne@68
|
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
jpayne@68
|
5 <title>cairo_font_face_t: Cairo: A Vector Graphics Library</title>
|
jpayne@68
|
6 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
|
jpayne@68
|
7 <link rel="home" href="index.html" title="Cairo: A Vector Graphics Library">
|
jpayne@68
|
8 <link rel="up" href="cairo-fonts.html" title="Fonts">
|
jpayne@68
|
9 <link rel="prev" href="cairo-fonts.html" title="Fonts">
|
jpayne@68
|
10 <link rel="next" href="cairo-cairo-scaled-font-t.html" title="cairo_scaled_font_t">
|
jpayne@68
|
11 <meta name="generator" content="GTK-Doc V1.27 (XML mode)">
|
jpayne@68
|
12 <link rel="stylesheet" href="style.css" type="text/css">
|
jpayne@68
|
13 </head>
|
jpayne@68
|
14 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
jpayne@68
|
15 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
|
jpayne@68
|
16 <td width="100%" align="left" class="shortcuts">
|
jpayne@68
|
17 <a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span>
|
jpayne@68
|
18 <a href="#cairo-cairo-font-face-t.description" class="shortcut">Description</a></span>
|
jpayne@68
|
19 </td>
|
jpayne@68
|
20 <td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
|
jpayne@68
|
21 <td><a accesskey="u" href="cairo-fonts.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
|
jpayne@68
|
22 <td><a accesskey="p" href="cairo-fonts.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
|
jpayne@68
|
23 <td><a accesskey="n" href="cairo-cairo-scaled-font-t.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
|
jpayne@68
|
24 </tr></table>
|
jpayne@68
|
25 <div class="refentry">
|
jpayne@68
|
26 <a name="cairo-cairo-font-face-t"></a><div class="titlepage"></div>
|
jpayne@68
|
27 <div class="refnamediv"><table width="100%"><tr>
|
jpayne@68
|
28 <td valign="top">
|
jpayne@68
|
29 <h2><span class="refentrytitle"><a name="cairo-cairo-font-face-t.top_of_page"></a>cairo_font_face_t</span></h2>
|
jpayne@68
|
30 <p>cairo_font_face_t — Base class for font faces</p>
|
jpayne@68
|
31 </td>
|
jpayne@68
|
32 <td class="gallery_image" valign="top" align="right"></td>
|
jpayne@68
|
33 </tr></table></div>
|
jpayne@68
|
34 <div class="refsect1">
|
jpayne@68
|
35 <a name="cairo-cairo-font-face-t.functions"></a><h2>Functions</h2>
|
jpayne@68
|
36 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
37 <colgroup>
|
jpayne@68
|
38 <col width="150px" class="functions_return">
|
jpayne@68
|
39 <col class="functions_name">
|
jpayne@68
|
40 </colgroup>
|
jpayne@68
|
41 <tbody>
|
jpayne@68
|
42 <tr>
|
jpayne@68
|
43 <td class="function_type">
|
jpayne@68
|
44 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="returnvalue">cairo_font_face_t</span></a> *
|
jpayne@68
|
45 </td>
|
jpayne@68
|
46 <td class="function_name">
|
jpayne@68
|
47 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-reference" title="cairo_font_face_reference ()">cairo_font_face_reference</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
48 </td>
|
jpayne@68
|
49 </tr>
|
jpayne@68
|
50 <tr>
|
jpayne@68
|
51 <td class="function_type">
|
jpayne@68
|
52 <span class="returnvalue">void</span>
|
jpayne@68
|
53 </td>
|
jpayne@68
|
54 <td class="function_name">
|
jpayne@68
|
55 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-destroy" title="cairo_font_face_destroy ()">cairo_font_face_destroy</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
56 </td>
|
jpayne@68
|
57 </tr>
|
jpayne@68
|
58 <tr>
|
jpayne@68
|
59 <td class="function_type">
|
jpayne@68
|
60 <a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
jpayne@68
|
61 </td>
|
jpayne@68
|
62 <td class="function_name">
|
jpayne@68
|
63 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-status" title="cairo_font_face_status ()">cairo_font_face_status</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
64 </td>
|
jpayne@68
|
65 </tr>
|
jpayne@68
|
66 <tr>
|
jpayne@68
|
67 <td class="function_type">
|
jpayne@68
|
68 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-type-t" title="enum cairo_font_type_t"><span class="returnvalue">cairo_font_type_t</span></a>
|
jpayne@68
|
69 </td>
|
jpayne@68
|
70 <td class="function_name">
|
jpayne@68
|
71 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-type" title="cairo_font_face_get_type ()">cairo_font_face_get_type</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
72 </td>
|
jpayne@68
|
73 </tr>
|
jpayne@68
|
74 <tr>
|
jpayne@68
|
75 <td class="function_type">unsigned <span class="returnvalue">int</span>
|
jpayne@68
|
76 </td>
|
jpayne@68
|
77 <td class="function_name">
|
jpayne@68
|
78 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-reference-count" title="cairo_font_face_get_reference_count ()">cairo_font_face_get_reference_count</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
79 </td>
|
jpayne@68
|
80 </tr>
|
jpayne@68
|
81 <tr>
|
jpayne@68
|
82 <td class="function_type">
|
jpayne@68
|
83 <a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
jpayne@68
|
84 </td>
|
jpayne@68
|
85 <td class="function_name">
|
jpayne@68
|
86 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-set-user-data" title="cairo_font_face_set_user_data ()">cairo_font_face_set_user_data</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
87 </td>
|
jpayne@68
|
88 </tr>
|
jpayne@68
|
89 <tr>
|
jpayne@68
|
90 <td class="function_type">
|
jpayne@68
|
91 <span class="returnvalue">void</span> *
|
jpayne@68
|
92 </td>
|
jpayne@68
|
93 <td class="function_name">
|
jpayne@68
|
94 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-user-data" title="cairo_font_face_get_user_data ()">cairo_font_face_get_user_data</a> <span class="c_punctuation">()</span>
|
jpayne@68
|
95 </td>
|
jpayne@68
|
96 </tr>
|
jpayne@68
|
97 </tbody>
|
jpayne@68
|
98 </table></div>
|
jpayne@68
|
99 </div>
|
jpayne@68
|
100 <div class="refsect1">
|
jpayne@68
|
101 <a name="cairo-cairo-font-face-t.other"></a><h2>Types and Values</h2>
|
jpayne@68
|
102 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
103 <colgroup>
|
jpayne@68
|
104 <col width="150px" class="name">
|
jpayne@68
|
105 <col class="description">
|
jpayne@68
|
106 </colgroup>
|
jpayne@68
|
107 <tbody>
|
jpayne@68
|
108 <tr>
|
jpayne@68
|
109 <td class="typedef_keyword">typedef</td>
|
jpayne@68
|
110 <td class="function_name"><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t">cairo_font_face_t</a></td>
|
jpayne@68
|
111 </tr>
|
jpayne@68
|
112 <tr>
|
jpayne@68
|
113 <td class="datatype_keyword">enum</td>
|
jpayne@68
|
114 <td class="function_name"><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-type-t" title="enum cairo_font_type_t">cairo_font_type_t</a></td>
|
jpayne@68
|
115 </tr>
|
jpayne@68
|
116 </tbody>
|
jpayne@68
|
117 </table></div>
|
jpayne@68
|
118 </div>
|
jpayne@68
|
119 <div class="refsect1">
|
jpayne@68
|
120 <a name="cairo-cairo-font-face-t.description"></a><h2>Description</h2>
|
jpayne@68
|
121 <p><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> represents a particular font at a particular weight,
|
jpayne@68
|
122 slant, and other characteristic but no size, transformation, or size.</p>
|
jpayne@68
|
123 <p>Font faces are created using <em class="firstterm">font-backend</em>-specific
|
jpayne@68
|
124 constructors, typically of the form
|
jpayne@68
|
125 <code class="function">cairo_<span class="emphasis"><em>backend</em></span>_font_face_create()</code>,
|
jpayne@68
|
126 or implicitly using the <em class="firstterm">toy</em> text API by way of
|
jpayne@68
|
127 <a class="link" href="cairo-text.html#cairo-select-font-face" title="cairo_select_font_face ()"><code class="function">cairo_select_font_face()</code></a>. The resulting face can be accessed using
|
jpayne@68
|
128 <a class="link" href="cairo-text.html#cairo-get-font-face" title="cairo_get_font_face ()"><code class="function">cairo_get_font_face()</code></a>.</p>
|
jpayne@68
|
129 </div>
|
jpayne@68
|
130 <div class="refsect1">
|
jpayne@68
|
131 <a name="cairo-cairo-font-face-t.functions_details"></a><h2>Functions</h2>
|
jpayne@68
|
132 <div class="refsect2">
|
jpayne@68
|
133 <a name="cairo-font-face-reference"></a><h3>cairo_font_face_reference ()</h3>
|
jpayne@68
|
134 <pre class="programlisting"><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="returnvalue">cairo_font_face_t</span></a> *
|
jpayne@68
|
135 cairo_font_face_reference (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>);</pre>
|
jpayne@68
|
136 <p>Increases the reference count on <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
137 by one. This prevents
|
jpayne@68
|
138 <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
139 from being destroyed until a matching call to
|
jpayne@68
|
140 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-destroy" title="cairo_font_face_destroy ()"><code class="function">cairo_font_face_destroy()</code></a> is made.</p>
|
jpayne@68
|
141 <p>Use <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-reference-count" title="cairo_font_face_get_reference_count ()"><code class="function">cairo_font_face_get_reference_count()</code></a> to get the number of
|
jpayne@68
|
142 references to a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a>.</p>
|
jpayne@68
|
143 <div class="refsect3">
|
jpayne@68
|
144 <a name="cairo-font-face-reference.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
145 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
146 <colgroup>
|
jpayne@68
|
147 <col width="150px" class="parameters_name">
|
jpayne@68
|
148 <col class="parameters_description">
|
jpayne@68
|
149 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
150 </colgroup>
|
jpayne@68
|
151 <tbody><tr>
|
jpayne@68
|
152 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
153 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a>, (may be <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> in which case this
|
jpayne@68
|
154 function does nothing).</p></td>
|
jpayne@68
|
155 <td class="parameter_annotations"> </td>
|
jpayne@68
|
156 </tr></tbody>
|
jpayne@68
|
157 </table></div>
|
jpayne@68
|
158 </div>
|
jpayne@68
|
159 <div class="refsect3">
|
jpayne@68
|
160 <a name="cairo-font-face-reference.returns"></a><h4>Returns</h4>
|
jpayne@68
|
161 <p> the referenced <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a>.</p>
|
jpayne@68
|
162 </div>
|
jpayne@68
|
163 <p class="since">Since: 1.0</p>
|
jpayne@68
|
164 </div>
|
jpayne@68
|
165 <hr>
|
jpayne@68
|
166 <div class="refsect2">
|
jpayne@68
|
167 <a name="cairo-font-face-destroy"></a><h3>cairo_font_face_destroy ()</h3>
|
jpayne@68
|
168 <pre class="programlisting"><span class="returnvalue">void</span>
|
jpayne@68
|
169 cairo_font_face_destroy (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>);</pre>
|
jpayne@68
|
170 <p>Decreases the reference count on <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
171 by one. If the result
|
jpayne@68
|
172 is zero, then <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
173 and all associated resources are freed.
|
jpayne@68
|
174 See <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-reference" title="cairo_font_face_reference ()"><code class="function">cairo_font_face_reference()</code></a>.</p>
|
jpayne@68
|
175 <div class="refsect3">
|
jpayne@68
|
176 <a name="cairo-font-face-destroy.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
177 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
178 <colgroup>
|
jpayne@68
|
179 <col width="150px" class="parameters_name">
|
jpayne@68
|
180 <col class="parameters_description">
|
jpayne@68
|
181 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
182 </colgroup>
|
jpayne@68
|
183 <tbody><tr>
|
jpayne@68
|
184 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
185 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a></p></td>
|
jpayne@68
|
186 <td class="parameter_annotations"> </td>
|
jpayne@68
|
187 </tr></tbody>
|
jpayne@68
|
188 </table></div>
|
jpayne@68
|
189 </div>
|
jpayne@68
|
190 <p class="since">Since: 1.0</p>
|
jpayne@68
|
191 </div>
|
jpayne@68
|
192 <hr>
|
jpayne@68
|
193 <div class="refsect2">
|
jpayne@68
|
194 <a name="cairo-font-face-status"></a><h3>cairo_font_face_status ()</h3>
|
jpayne@68
|
195 <pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
jpayne@68
|
196 cairo_font_face_status (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>);</pre>
|
jpayne@68
|
197 <p>Checks whether an error has previously occurred for this
|
jpayne@68
|
198 font face</p>
|
jpayne@68
|
199 <div class="refsect3">
|
jpayne@68
|
200 <a name="cairo-font-face-status.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
201 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
202 <colgroup>
|
jpayne@68
|
203 <col width="150px" class="parameters_name">
|
jpayne@68
|
204 <col class="parameters_description">
|
jpayne@68
|
205 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
206 </colgroup>
|
jpayne@68
|
207 <tbody><tr>
|
jpayne@68
|
208 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
209 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a></p></td>
|
jpayne@68
|
210 <td class="parameter_annotations"> </td>
|
jpayne@68
|
211 </tr></tbody>
|
jpayne@68
|
212 </table></div>
|
jpayne@68
|
213 </div>
|
jpayne@68
|
214 <div class="refsect3">
|
jpayne@68
|
215 <a name="cairo-font-face-status.returns"></a><h4>Returns</h4>
|
jpayne@68
|
216 <p> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or another error such as
|
jpayne@68
|
217 <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a>.</p>
|
jpayne@68
|
218 </div>
|
jpayne@68
|
219 <p class="since">Since: 1.0</p>
|
jpayne@68
|
220 </div>
|
jpayne@68
|
221 <hr>
|
jpayne@68
|
222 <div class="refsect2">
|
jpayne@68
|
223 <a name="cairo-font-face-get-type"></a><h3>cairo_font_face_get_type ()</h3>
|
jpayne@68
|
224 <pre class="programlisting"><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-type-t" title="enum cairo_font_type_t"><span class="returnvalue">cairo_font_type_t</span></a>
|
jpayne@68
|
225 cairo_font_face_get_type (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>);</pre>
|
jpayne@68
|
226 <p>This function returns the type of the backend used to create
|
jpayne@68
|
227 a font face. See <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-type-t" title="enum cairo_font_type_t"><span class="type">cairo_font_type_t</span></a> for available types.</p>
|
jpayne@68
|
228 <div class="refsect3">
|
jpayne@68
|
229 <a name="cairo-font-face-get-type.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
230 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
231 <colgroup>
|
jpayne@68
|
232 <col width="150px" class="parameters_name">
|
jpayne@68
|
233 <col class="parameters_description">
|
jpayne@68
|
234 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
235 </colgroup>
|
jpayne@68
|
236 <tbody><tr>
|
jpayne@68
|
237 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
238 <td class="parameter_description"><p>a font face</p></td>
|
jpayne@68
|
239 <td class="parameter_annotations"> </td>
|
jpayne@68
|
240 </tr></tbody>
|
jpayne@68
|
241 </table></div>
|
jpayne@68
|
242 </div>
|
jpayne@68
|
243 <div class="refsect3">
|
jpayne@68
|
244 <a name="cairo-font-face-get-type.returns"></a><h4>Returns</h4>
|
jpayne@68
|
245 <p> The type of <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
246 .</p>
|
jpayne@68
|
247 </div>
|
jpayne@68
|
248 <p class="since">Since: 1.2</p>
|
jpayne@68
|
249 </div>
|
jpayne@68
|
250 <hr>
|
jpayne@68
|
251 <div class="refsect2">
|
jpayne@68
|
252 <a name="cairo-font-face-get-reference-count"></a><h3>cairo_font_face_get_reference_count ()</h3>
|
jpayne@68
|
253 <pre class="programlisting">unsigned <span class="returnvalue">int</span>
|
jpayne@68
|
254 cairo_font_face_get_reference_count (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>);</pre>
|
jpayne@68
|
255 <p>Returns the current reference count of <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
256 .</p>
|
jpayne@68
|
257 <div class="refsect3">
|
jpayne@68
|
258 <a name="cairo-font-face-get-reference-count.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
259 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
260 <colgroup>
|
jpayne@68
|
261 <col width="150px" class="parameters_name">
|
jpayne@68
|
262 <col class="parameters_description">
|
jpayne@68
|
263 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
264 </colgroup>
|
jpayne@68
|
265 <tbody><tr>
|
jpayne@68
|
266 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
267 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a></p></td>
|
jpayne@68
|
268 <td class="parameter_annotations"> </td>
|
jpayne@68
|
269 </tr></tbody>
|
jpayne@68
|
270 </table></div>
|
jpayne@68
|
271 </div>
|
jpayne@68
|
272 <div class="refsect3">
|
jpayne@68
|
273 <a name="cairo-font-face-get-reference-count.returns"></a><h4>Returns</h4>
|
jpayne@68
|
274 <p> the current reference count of <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
275 . If the
|
jpayne@68
|
276 object is a nil object, 0 will be returned.</p>
|
jpayne@68
|
277 </div>
|
jpayne@68
|
278 <p class="since">Since: 1.4</p>
|
jpayne@68
|
279 </div>
|
jpayne@68
|
280 <hr>
|
jpayne@68
|
281 <div class="refsect2">
|
jpayne@68
|
282 <a name="cairo-font-face-set-user-data"></a><h3>cairo_font_face_set_user_data ()</h3>
|
jpayne@68
|
283 <pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
jpayne@68
|
284 cairo_font_face_set_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>,
|
jpayne@68
|
285 <em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>,
|
jpayne@68
|
286 <em class="parameter"><code><span class="type">void</span> *user_data</code></em>,
|
jpayne@68
|
287 <em class="parameter"><code><a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> destroy</code></em>);</pre>
|
jpayne@68
|
288 <p>Attach user data to <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
289 . To remove user data from a font face,
|
jpayne@68
|
290 call this function with the key that was used to set it and <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
|
jpayne@68
|
291 for <em class="parameter"><code>data</code></em>
|
jpayne@68
|
292 .</p>
|
jpayne@68
|
293 <div class="refsect3">
|
jpayne@68
|
294 <a name="cairo-font-face-set-user-data.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
295 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
296 <colgroup>
|
jpayne@68
|
297 <col width="150px" class="parameters_name">
|
jpayne@68
|
298 <col class="parameters_description">
|
jpayne@68
|
299 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
300 </colgroup>
|
jpayne@68
|
301 <tbody>
|
jpayne@68
|
302 <tr>
|
jpayne@68
|
303 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
304 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a></p></td>
|
jpayne@68
|
305 <td class="parameter_annotations"> </td>
|
jpayne@68
|
306 </tr>
|
jpayne@68
|
307 <tr>
|
jpayne@68
|
308 <td class="parameter_name"><p>key</p></td>
|
jpayne@68
|
309 <td class="parameter_description"><p>the address of a <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> to attach the user data to</p></td>
|
jpayne@68
|
310 <td class="parameter_annotations"> </td>
|
jpayne@68
|
311 </tr>
|
jpayne@68
|
312 <tr>
|
jpayne@68
|
313 <td class="parameter_name"><p>user_data</p></td>
|
jpayne@68
|
314 <td class="parameter_description"><p>the user data to attach to the font face</p></td>
|
jpayne@68
|
315 <td class="parameter_annotations"> </td>
|
jpayne@68
|
316 </tr>
|
jpayne@68
|
317 <tr>
|
jpayne@68
|
318 <td class="parameter_name"><p>destroy</p></td>
|
jpayne@68
|
319 <td class="parameter_description"><p>a <a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> which will be called when the
|
jpayne@68
|
320 font face is destroyed or when new user data is attached using the
|
jpayne@68
|
321 same key.</p></td>
|
jpayne@68
|
322 <td class="parameter_annotations"> </td>
|
jpayne@68
|
323 </tr>
|
jpayne@68
|
324 </tbody>
|
jpayne@68
|
325 </table></div>
|
jpayne@68
|
326 </div>
|
jpayne@68
|
327 <div class="refsect3">
|
jpayne@68
|
328 <a name="cairo-font-face-set-user-data.returns"></a><h4>Returns</h4>
|
jpayne@68
|
329 <p> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a> if a
|
jpayne@68
|
330 slot could not be allocated for the user data.</p>
|
jpayne@68
|
331 </div>
|
jpayne@68
|
332 <p class="since">Since: 1.0</p>
|
jpayne@68
|
333 </div>
|
jpayne@68
|
334 <hr>
|
jpayne@68
|
335 <div class="refsect2">
|
jpayne@68
|
336 <a name="cairo-font-face-get-user-data"></a><h3>cairo_font_face_get_user_data ()</h3>
|
jpayne@68
|
337 <pre class="programlisting"><span class="returnvalue">void</span> *
|
jpayne@68
|
338 cairo_font_face_get_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> *font_face</code></em>,
|
jpayne@68
|
339 <em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>);</pre>
|
jpayne@68
|
340 <p>Return user data previously attached to <em class="parameter"><code>font_face</code></em>
|
jpayne@68
|
341 using the specified
|
jpayne@68
|
342 key. If no user data has been attached with the given key this
|
jpayne@68
|
343 function returns <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
|
jpayne@68
|
344 <div class="refsect3">
|
jpayne@68
|
345 <a name="cairo-font-face-get-user-data.parameters"></a><h4>Parameters</h4>
|
jpayne@68
|
346 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
347 <colgroup>
|
jpayne@68
|
348 <col width="150px" class="parameters_name">
|
jpayne@68
|
349 <col class="parameters_description">
|
jpayne@68
|
350 <col width="200px" class="parameters_annotations">
|
jpayne@68
|
351 </colgroup>
|
jpayne@68
|
352 <tbody>
|
jpayne@68
|
353 <tr>
|
jpayne@68
|
354 <td class="parameter_name"><p>font_face</p></td>
|
jpayne@68
|
355 <td class="parameter_description"><p>a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a></p></td>
|
jpayne@68
|
356 <td class="parameter_annotations"> </td>
|
jpayne@68
|
357 </tr>
|
jpayne@68
|
358 <tr>
|
jpayne@68
|
359 <td class="parameter_name"><p>key</p></td>
|
jpayne@68
|
360 <td class="parameter_description"><p>the address of the <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> the user data was
|
jpayne@68
|
361 attached to</p></td>
|
jpayne@68
|
362 <td class="parameter_annotations"> </td>
|
jpayne@68
|
363 </tr>
|
jpayne@68
|
364 </tbody>
|
jpayne@68
|
365 </table></div>
|
jpayne@68
|
366 </div>
|
jpayne@68
|
367 <div class="refsect3">
|
jpayne@68
|
368 <a name="cairo-font-face-get-user-data.returns"></a><h4>Returns</h4>
|
jpayne@68
|
369 <p> the user data previously attached or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.</p>
|
jpayne@68
|
370 </div>
|
jpayne@68
|
371 <p class="since">Since: 1.0</p>
|
jpayne@68
|
372 </div>
|
jpayne@68
|
373 </div>
|
jpayne@68
|
374 <div class="refsect1">
|
jpayne@68
|
375 <a name="cairo-cairo-font-face-t.other_details"></a><h2>Types and Values</h2>
|
jpayne@68
|
376 <div class="refsect2">
|
jpayne@68
|
377 <a name="cairo-font-face-t"></a><h3>cairo_font_face_t</h3>
|
jpayne@68
|
378 <pre class="programlisting">typedef struct _cairo_font_face cairo_font_face_t;
|
jpayne@68
|
379 </pre>
|
jpayne@68
|
380 <p>A <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> specifies all aspects of a font other
|
jpayne@68
|
381 than the size or font matrix (a font matrix is used to distort
|
jpayne@68
|
382 a font by shearing it or scaling it unequally in the two
|
jpayne@68
|
383 directions) . A font face can be set on a <a class="link" href="cairo-cairo-t.html#cairo-t" title="cairo_t"><span class="type">cairo_t</span></a> by using
|
jpayne@68
|
384 <a class="link" href="cairo-text.html#cairo-set-font-face" title="cairo_set_font_face ()"><code class="function">cairo_set_font_face()</code></a>; the size and font matrix are set with
|
jpayne@68
|
385 <a class="link" href="cairo-text.html#cairo-set-font-size" title="cairo_set_font_size ()"><code class="function">cairo_set_font_size()</code></a> and <a class="link" href="cairo-text.html#cairo-set-font-matrix" title="cairo_set_font_matrix ()"><code class="function">cairo_set_font_matrix()</code></a>.</p>
|
jpayne@68
|
386 <p>There are various types of font faces, depending on the
|
jpayne@68
|
387 <em class="firstterm">font backend</em> they use. The type of a
|
jpayne@68
|
388 font face can be queried using <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-type" title="cairo_font_face_get_type ()"><code class="function">cairo_font_face_get_type()</code></a>.</p>
|
jpayne@68
|
389 <p>Memory management of <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> is done with
|
jpayne@68
|
390 <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-reference" title="cairo_font_face_reference ()"><code class="function">cairo_font_face_reference()</code></a> and <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-destroy" title="cairo_font_face_destroy ()"><code class="function">cairo_font_face_destroy()</code></a>.</p>
|
jpayne@68
|
391 <p class="since">Since: 1.0</p>
|
jpayne@68
|
392 </div>
|
jpayne@68
|
393 <hr>
|
jpayne@68
|
394 <div class="refsect2">
|
jpayne@68
|
395 <a name="cairo-font-type-t"></a><h3>enum cairo_font_type_t</h3>
|
jpayne@68
|
396 <p><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-type-t" title="enum cairo_font_type_t"><span class="type">cairo_font_type_t</span></a> is used to describe the type of a given font
|
jpayne@68
|
397 face or scaled font. The font types are also known as "font
|
jpayne@68
|
398 backends" within cairo.</p>
|
jpayne@68
|
399 <p>The type of a font face is determined by the function used to
|
jpayne@68
|
400 create it, which will generally be of the form
|
jpayne@68
|
401 <code class="function">cairo_<span class="emphasis"><em>type</em></span>_font_face_create()</code>.
|
jpayne@68
|
402 The font face type can be queried with <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-get-type" title="cairo_font_face_get_type ()"><code class="function">cairo_font_face_get_type()</code></a></p>
|
jpayne@68
|
403 <p>The various <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t" title="cairo_font_face_t"><span class="type">cairo_font_face_t</span></a> functions can be used with a font face
|
jpayne@68
|
404 of any type.</p>
|
jpayne@68
|
405 <p>The type of a scaled font is determined by the type of the font
|
jpayne@68
|
406 face passed to <a class="link" href="cairo-cairo-scaled-font-t.html#cairo-scaled-font-create" title="cairo_scaled_font_create ()"><code class="function">cairo_scaled_font_create()</code></a>. The scaled font type can
|
jpayne@68
|
407 be queried with <a class="link" href="cairo-cairo-scaled-font-t.html#cairo-scaled-font-get-type" title="cairo_scaled_font_get_type ()"><code class="function">cairo_scaled_font_get_type()</code></a></p>
|
jpayne@68
|
408 <p>The various <a class="link" href="cairo-cairo-scaled-font-t.html#cairo-scaled-font-t" title="cairo_scaled_font_t"><span class="type">cairo_scaled_font_t</span></a> functions can be used with scaled
|
jpayne@68
|
409 fonts of any type, but some font backends also provide
|
jpayne@68
|
410 type-specific functions that must only be called with a scaled font
|
jpayne@68
|
411 of the appropriate type. These functions have names that begin with
|
jpayne@68
|
412 <code class="function">cairo_<span class="emphasis"><em>type</em></span>_scaled_font()</code>
|
jpayne@68
|
413 such as <a class="link" href="cairo-FreeType-Fonts.html#cairo-ft-scaled-font-lock-face" title="cairo_ft_scaled_font_lock_face ()"><code class="function">cairo_ft_scaled_font_lock_face()</code></a>.</p>
|
jpayne@68
|
414 <p>The behavior of calling a type-specific function with a scaled font
|
jpayne@68
|
415 of the wrong type is undefined.</p>
|
jpayne@68
|
416 <p>New entries may be added in future versions.</p>
|
jpayne@68
|
417 <div class="refsect3">
|
jpayne@68
|
418 <a name="cairo-font-type-t.members"></a><h4>Members</h4>
|
jpayne@68
|
419 <div class="informaltable"><table class="informaltable" width="100%" border="0">
|
jpayne@68
|
420 <colgroup>
|
jpayne@68
|
421 <col width="300px" class="enum_members_name">
|
jpayne@68
|
422 <col class="enum_members_description">
|
jpayne@68
|
423 <col width="200px" class="enum_members_annotations">
|
jpayne@68
|
424 </colgroup>
|
jpayne@68
|
425 <tbody>
|
jpayne@68
|
426 <tr>
|
jpayne@68
|
427 <td class="enum_member_name"><p><a name="CAIRO-FONT-TYPE-TOY:CAPS"></a>CAIRO_FONT_TYPE_TOY</p></td>
|
jpayne@68
|
428 <td class="enum_member_description">
|
jpayne@68
|
429 <p>The font was created using cairo's toy font api (Since: 1.2)</p>
|
jpayne@68
|
430 </td>
|
jpayne@68
|
431 <td class="enum_member_annotations"> </td>
|
jpayne@68
|
432 </tr>
|
jpayne@68
|
433 <tr>
|
jpayne@68
|
434 <td class="enum_member_name"><p><a name="CAIRO-FONT-TYPE-FT:CAPS"></a>CAIRO_FONT_TYPE_FT</p></td>
|
jpayne@68
|
435 <td class="enum_member_description">
|
jpayne@68
|
436 <p>The font is of type FreeType (Since: 1.2)</p>
|
jpayne@68
|
437 </td>
|
jpayne@68
|
438 <td class="enum_member_annotations"> </td>
|
jpayne@68
|
439 </tr>
|
jpayne@68
|
440 <tr>
|
jpayne@68
|
441 <td class="enum_member_name"><p><a name="CAIRO-FONT-TYPE-WIN32:CAPS"></a>CAIRO_FONT_TYPE_WIN32</p></td>
|
jpayne@68
|
442 <td class="enum_member_description">
|
jpayne@68
|
443 <p>The font is of type Win32 (Since: 1.2)</p>
|
jpayne@68
|
444 </td>
|
jpayne@68
|
445 <td class="enum_member_annotations"> </td>
|
jpayne@68
|
446 </tr>
|
jpayne@68
|
447 <tr>
|
jpayne@68
|
448 <td class="enum_member_name"><p><a name="CAIRO-FONT-TYPE-QUARTZ:CAPS"></a>CAIRO_FONT_TYPE_QUARTZ</p></td>
|
jpayne@68
|
449 <td class="enum_member_description">
|
jpayne@68
|
450 <p>The font is of type Quartz (Since: 1.6, in 1.2 and
|
jpayne@68
|
451 1.4 it was named CAIRO_FONT_TYPE_ATSUI)</p>
|
jpayne@68
|
452 </td>
|
jpayne@68
|
453 <td class="enum_member_annotations"> </td>
|
jpayne@68
|
454 </tr>
|
jpayne@68
|
455 <tr>
|
jpayne@68
|
456 <td class="enum_member_name"><p><a name="CAIRO-FONT-TYPE-USER:CAPS"></a>CAIRO_FONT_TYPE_USER</p></td>
|
jpayne@68
|
457 <td class="enum_member_description">
|
jpayne@68
|
458 <p>The font was create using cairo's user font api (Since: 1.8)</p>
|
jpayne@68
|
459 </td>
|
jpayne@68
|
460 <td class="enum_member_annotations"> </td>
|
jpayne@68
|
461 </tr>
|
jpayne@68
|
462 </tbody>
|
jpayne@68
|
463 </table></div>
|
jpayne@68
|
464 </div>
|
jpayne@68
|
465 <p class="since">Since: 1.2</p>
|
jpayne@68
|
466 </div>
|
jpayne@68
|
467 </div>
|
jpayne@68
|
468 <div class="refsect1">
|
jpayne@68
|
469 <a name="cairo-cairo-font-face-t.see-also"></a><h2>See Also</h2>
|
jpayne@68
|
470 <p><a class="link" href="cairo-cairo-scaled-font-t.html#cairo-scaled-font-t" title="cairo_scaled_font_t"><span class="type">cairo_scaled_font_t</span></a></p>
|
jpayne@68
|
471 </div>
|
jpayne@68
|
472 </div>
|
jpayne@68
|
473 <div class="footer">
|
jpayne@68
|
474 <hr>Generated by GTK-Doc V1.27</div>
|
jpayne@68
|
475 </body>
|
jpayne@68
|
476 </html> |