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

« back to all changes in this revision

Viewing changes to docs/html/pango-Miscellaneous-Utilities.html

  • Committer: Bazaar Package Importer
  • Author(s): Loic Minier
  • Date: 2007-12-18 21:11:37 UTC
  • mfrom: (1.2.44 upstream)
  • Revision ID: james.westby@ubuntu.com-20071218211137-0ibmwreimvxf3cp1
Tags: 1.19.2-1ubuntu1
* Sync with Debian; Ubuntu changes are:
  - Add patch 30_anymetrics, turns on FC_ANY_METRICS whenever looking up
    fonts with fontconfig; lets fontconfig's configuration know that we
    don't care about getting a font with exactly the same shape as the
    family we asked for and fixes (eg) a firefox vs. evince font metrics
    ugliness issue.

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
<th width="100%" align="center">Pango Reference Manual</th>
38
38
<td><a accesskey="n" href="pango-Version-Checking.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
39
39
</tr>
40
 
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id3238764" class="shortcut">Top</a>
 
40
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id3255801" class="shortcut">Top</a>
41
41
                  &#160;|&#160;
42
 
                  <a href="#id3239404" class="shortcut">Description</a></nobr></td></tr>
 
42
                  <a href="#id3256442" class="shortcut">Description</a></nobr></td></tr>
43
43
</table>
44
44
<div class="refentry" lang="en">
45
45
<a name="pango-Miscellaneous-Utilities"></a><div class="titlepage"></div>
46
46
<div class="refnamediv"><table width="100%"><tr>
47
47
<td valign="top">
48
48
<h2>
49
 
<a name="id3238764"></a><span class="refentrytitle">Miscellaneous Utilities</span>
 
49
<a name="id3255801"></a><span class="refentrytitle">Miscellaneous Utilities</span>
50
50
</h2>
51
51
<p>Miscellaneous Utilities &#8212; Various convenience and utility functions</p>
52
52
</td>
149
149
</pre>
150
150
</div>
151
151
<div class="refsect1" lang="en">
152
 
<a name="id3239404"></a><h2>Description</h2>
 
152
<a name="id3256442"></a><h2>Description</h2>
153
153
<p>
154
154
The functions and utilities in this section are mostly used from Pango
155
155
backends and modules, but may be useful for other purposes too.
156
156
</p>
157
157
</div>
158
158
<div class="refsect1" lang="en">
159
 
<a name="id3239421"></a><h2>Details</h2>
 
159
<a name="id3256458"></a><h2>Details</h2>
160
160
<div class="refsect2" lang="en">
161
 
<a name="id3239431"></a><h3>
 
161
<a name="id3256469"></a><h3>
162
162
<a name="pango-split-file-list"></a>pango_split_file_list ()</h3>
163
 
<a class="indexterm" name="id3239444"></a><pre class="programlisting">char**              pango_split_file_list               (const char *str);</pre>
 
163
<a class="indexterm" name="id3256481"></a><pre class="programlisting">char**              pango_split_file_list               (const char *str);</pre>
164
164
<p>
165
165
Splits a <a
166
166
href="../glib/glib-Standard-Macros.html#G-SEARCHPATH-SEPARATOR:CAPS"
191
191
</div>
192
192
<hr>
193
193
<div class="refsect2" lang="en">
194
 
<a name="id3239541"></a><h3>
 
194
<a name="id3256578"></a><h3>
195
195
<a name="pango-trim-string"></a>pango_trim_string ()</h3>
196
 
<a class="indexterm" name="id3239554"></a><pre class="programlisting">char*               pango_trim_string                   (const char *str);</pre>
 
196
<a class="indexterm" name="id3256592"></a><pre class="programlisting">char*               pango_trim_string                   (const char *str);</pre>
197
197
<p>
198
198
Trims leading and trailing whitespace from a string.</p>
199
199
<p>
219
219
</div>
220
220
<hr>
221
221
<div class="refsect2" lang="en">
222
 
<a name="id3239625"></a><h3>
 
222
<a name="id3256663"></a><h3>
223
223
<a name="pango-read-line"></a>pango_read_line ()</h3>
224
 
<a class="indexterm" name="id3239638"></a><pre class="programlisting"><a
 
224
<a class="indexterm" name="id3256676"></a><pre class="programlisting"><a
225
225
href="../glib/glib-Basic-Types.html#gint"
226
226
>gint</a>                pango_read_line                     (FILE *stream,
227
227
                                                         <a
265
265
</div>
266
266
<hr>
267
267
<div class="refsect2" lang="en">
268
 
<a name="id3239750"></a><h3>
 
268
<a name="id3256787"></a><h3>
269
269
<a name="pango-skip-space"></a>pango_skip_space ()</h3>
270
 
<a class="indexterm" name="id3239762"></a><pre class="programlisting"><a
 
270
<a class="indexterm" name="id3256800"></a><pre class="programlisting"><a
271
271
href="../glib/glib-Basic-Types.html#gboolean"
272
272
>gboolean</a>            pango_skip_space                    (const char **pos);</pre>
273
273
<p>
296
296
</div>
297
297
<hr>
298
298
<div class="refsect2" lang="en">
299
 
<a name="id3239834"></a><h3>
 
299
<a name="id3256872"></a><h3>
300
300
<a name="pango-scan-word"></a>pango_scan_word ()</h3>
301
 
<a class="indexterm" name="id3239847"></a><pre class="programlisting"><a
 
301
<a class="indexterm" name="id3256885"></a><pre class="programlisting"><a
302
302
href="../glib/glib-Basic-Types.html#gboolean"
303
303
>gboolean</a>            pango_scan_word                     (const char **pos,
304
304
                                                         <a
340
340
</div>
341
341
<hr>
342
342
<div class="refsect2" lang="en">
343
 
<a name="id3239958"></a><h3>
 
343
<a name="id3256995"></a><h3>
344
344
<a name="pango-scan-string"></a>pango_scan_string ()</h3>
345
 
<a class="indexterm" name="id3239971"></a><pre class="programlisting"><a
 
345
<a class="indexterm" name="id3257008"></a><pre class="programlisting"><a
346
346
href="../glib/glib-Basic-Types.html#gboolean"
347
347
>gboolean</a>            pango_scan_string                   (const char **pos,
348
348
                                                         <a
385
385
</div>
386
386
<hr>
387
387
<div class="refsect2" lang="en">
388
 
<a name="id3240083"></a><h3>
 
388
<a name="id3257120"></a><h3>
389
389
<a name="pango-scan-int"></a>pango_scan_int ()</h3>
390
 
<a class="indexterm" name="id3240096"></a><pre class="programlisting"><a
 
390
<a class="indexterm" name="id3257133"></a><pre class="programlisting"><a
391
391
href="../glib/glib-Basic-Types.html#gboolean"
392
392
>gboolean</a>            pango_scan_int                      (const char **pos,
393
393
                                                         int *out);</pre>
422
422
</div>
423
423
<hr>
424
424
<div class="refsect2" lang="en">
425
 
<a name="id3240188"></a><h3>
 
425
<a name="id3257226"></a><h3>
426
426
<a name="pango-config-key-get"></a>pango_config_key_get ()</h3>
427
 
<a class="indexterm" name="id3240202"></a><pre class="programlisting">char*               pango_config_key_get                (const char *key);</pre>
 
427
<a class="indexterm" name="id3257239"></a><pre class="programlisting">char*               pango_config_key_get                (const char *key);</pre>
428
428
<p>
429
429
Looks up a key in the Pango config database
430
430
(pseudo-win.ini style, read from $sysconfdir/pango/pangorc,
455
455
</div>
456
456
<hr>
457
457
<div class="refsect2" lang="en">
458
 
<a name="id3240286"></a><h3>
 
458
<a name="id3257324"></a><h3>
459
459
<a name="pango-lookup-aliases"></a>pango_lookup_aliases ()</h3>
460
 
<a class="indexterm" name="id3240300"></a><pre class="programlisting">void                pango_lookup_aliases                (const char *fontname,
 
460
<a class="indexterm" name="id3257337"></a><pre class="programlisting">void                pango_lookup_aliases                (const char *fontname,
461
461
                                                         char ***families,
462
462
                                                         int *n_families);</pre>
463
463
<p>
491
491
</div>
492
492
<hr>
493
493
<div class="refsect2" lang="en">
494
 
<a name="id3240420"></a><h3>
 
494
<a name="id3257458"></a><h3>
495
495
<a name="pango-parse-enum"></a>pango_parse_enum ()</h3>
496
 
<a class="indexterm" name="id3240436"></a><pre class="programlisting"><a
 
496
<a class="indexterm" name="id3257473"></a><pre class="programlisting"><a
497
497
href="../glib/glib-Basic-Types.html#gboolean"
498
498
>gboolean</a>            pango_parse_enum                    (<a
499
499
href="../gobject/gobject-Type-Information.html#GType"
578
578
</div>
579
579
<hr>
580
580
<div class="refsect2" lang="en">
581
 
<a name="id3240750"></a><h3>
 
581
<a name="id3257787"></a><h3>
582
582
<a name="pango-parse-style"></a>pango_parse_style ()</h3>
583
 
<a class="indexterm" name="id3240763"></a><pre class="programlisting"><a
 
583
<a class="indexterm" name="id3257800"></a><pre class="programlisting"><a
584
584
href="../glib/glib-Basic-Types.html#gboolean"
585
585
>gboolean</a>            pango_parse_style                   (const char *str,
586
586
                                                         <a class="link" href="pango-Fonts.html#PangoStyle">PangoStyle</a> *style,
628
628
</div>
629
629
<hr>
630
630
<div class="refsect2" lang="en">
631
 
<a name="id3240913"></a><h3>
 
631
<a name="id3257950"></a><h3>
632
632
<a name="pango-parse-variant"></a>pango_parse_variant ()</h3>
633
 
<a class="indexterm" name="id3240926"></a><pre class="programlisting"><a
 
633
<a class="indexterm" name="id3257963"></a><pre class="programlisting"><a
634
634
href="../glib/glib-Basic-Types.html#gboolean"
635
635
>gboolean</a>            pango_parse_variant                 (const char *str,
636
636
                                                         <a class="link" href="pango-Fonts.html#PangoVariant">PangoVariant</a> *variant,
678
678
</div>
679
679
<hr>
680
680
<div class="refsect2" lang="en">
681
 
<a name="id3241077"></a><h3>
 
681
<a name="id3258114"></a><h3>
682
682
<a name="pango-parse-weight"></a>pango_parse_weight ()</h3>
683
 
<a class="indexterm" name="id3241090"></a><pre class="programlisting"><a
 
683
<a class="indexterm" name="id3258127"></a><pre class="programlisting"><a
684
684
href="../glib/glib-Basic-Types.html#gboolean"
685
685
>gboolean</a>            pango_parse_weight                  (const char *str,
686
686
                                                         <a class="link" href="pango-Fonts.html#PangoWeight">PangoWeight</a> *weight,
728
728
</div>
729
729
<hr>
730
730
<div class="refsect2" lang="en">
731
 
<a name="id3241240"></a><h3>
 
731
<a name="id3258277"></a><h3>
732
732
<a name="pango-parse-stretch"></a>pango_parse_stretch ()</h3>
733
 
<a class="indexterm" name="id3241253"></a><pre class="programlisting"><a
 
733
<a class="indexterm" name="id3258290"></a><pre class="programlisting"><a
734
734
href="../glib/glib-Basic-Types.html#gboolean"
735
735
>gboolean</a>            pango_parse_stretch                 (const char *str,
736
736
                                                         <a class="link" href="pango-Fonts.html#PangoStretch">PangoStretch</a> *stretch,
780
780
</div>
781
781
<hr>
782
782
<div class="refsect2" lang="en">
783
 
<a name="id3241406"></a><h3>
 
783
<a name="id3258443"></a><h3>
784
784
<a name="pango-get-sysconf-subdirectory"></a>pango_get_sysconf_subdirectory ()</h3>
785
 
<a class="indexterm" name="id3241420"></a><pre class="programlisting">const char*         pango_get_sysconf_subdirectory      (void);</pre>
 
785
<a class="indexterm" name="id3258457"></a><pre class="programlisting">const char*         pango_get_sysconf_subdirectory      (void);</pre>
786
786
<p>
787
787
On Unix, returns the name of the "pango" subdirectory of SYSCONFDIR
788
788
(which is set at compile time). On Win32, returns a subdirectory of
803
803
</div>
804
804
<hr>
805
805
<div class="refsect2" lang="en">
806
 
<a name="id3241466"></a><h3>
 
806
<a name="id3258503"></a><h3>
807
807
<a name="pango-get-lib-subdirectory"></a>pango_get_lib_subdirectory ()</h3>
808
 
<a class="indexterm" name="id3241480"></a><pre class="programlisting">const char*         pango_get_lib_subdirectory          (void);</pre>
 
808
<a class="indexterm" name="id3258517"></a><pre class="programlisting">const char*         pango_get_lib_subdirectory          (void);</pre>
809
809
<p>
810
810
On Unix, returns the name of the "pango" subdirectory of LIBDIR
811
811
(which is set at compile time). On Win32, returns the Pango
827
827
</div>
828
828
<hr>
829
829
<div class="refsect2" lang="en">
830
 
<a name="id3241526"></a><h3>
 
830
<a name="id3258563"></a><h3>
831
831
<a name="pango-log2vis-get-embedding-levels"></a>pango_log2vis_get_embedding_levels ()</h3>
832
 
<a class="indexterm" name="id3241543"></a><pre class="programlisting"><a
 
832
<a class="indexterm" name="id3258580"></a><pre class="programlisting"><a
833
833
href="../glib/glib-Basic-Types.html#guint8"
834
834
>guint8</a>*             pango_log2vis_get_embedding_levels  (const <a
835
835
href="../glib/glib-Basic-Types.html#gchar"
882
882
</div>
883
883
<hr>
884
884
<div class="refsect2" lang="en">
885
 
<a name="id3241675"></a><h3>
 
885
<a name="id3258713"></a><h3>
886
886
<a name="pango-language-get-default"></a>pango_language_get_default ()</h3>
887
 
<a class="indexterm" name="id3241692"></a><pre class="programlisting"><a class="link" href="pango-Text-Attributes.html#PangoLanguage">PangoLanguage</a>*      pango_language_get_default          (void);</pre>
 
887
<a class="indexterm" name="id3258729"></a><pre class="programlisting"><a class="link" href="pango-Text-Attributes.html#PangoLanguage">PangoLanguage</a>*      pango_language_get_default          (void);</pre>
888
888
<p>
889
889
Returns the <a class="link" href="pango-Text-Attributes.html#PangoLanguage"><span class="type">PangoLanguage</span></a> for the current locale of the process.
890
890
Note that this can change over the life of an application.
933
933
</div>
934
934
<hr>
935
935
<div class="refsect2" lang="en">
936
 
<a name="id3241839"></a><h3>
 
936
<a name="id3258877"></a><h3>
937
937
<a name="pango-language-get-sample-string"></a>pango_language_get_sample_string ()</h3>
938
 
<a class="indexterm" name="id3241853"></a><pre class="programlisting">const char*         pango_language_get_sample_string    (<a class="link" href="pango-Text-Attributes.html#PangoLanguage">PangoLanguage</a> *language);</pre>
 
938
<a class="indexterm" name="id3258890"></a><pre class="programlisting">const char*         pango_language_get_sample_string    (<a class="link" href="pango-Text-Attributes.html#PangoLanguage">PangoLanguage</a> *language);</pre>
939
939
<p>
940
940
Get a string that is representative of the characters needed to
941
941
render a particular language. This function is a bad hack for
962
962
</div>
963
963
<hr>
964
964
<div class="refsect2" lang="en">
965
 
<a name="id3241927"></a><h3>
 
965
<a name="id3258964"></a><h3>
966
966
<a name="pango-is-zero-width"></a>pango_is_zero_width ()</h3>
967
 
<a class="indexterm" name="id3241942"></a><pre class="programlisting"><a
 
967
<a class="indexterm" name="id3258979"></a><pre class="programlisting"><a
968
968
href="../glib/glib-Basic-Types.html#gboolean"
969
969
>gboolean</a>            pango_is_zero_width                 (<a
970
970
href="../glib/glib-Unicode-Manipulation.html#gunichar"
1005
1005
</div>
1006
1006
<hr>
1007
1007
<div class="refsect2" lang="en">
1008
 
<a name="id3242061"></a><h3>
 
1008
<a name="id3259099"></a><h3>
1009
1009
<a name="pango-quantize-line-geometry"></a>pango_quantize_line_geometry ()</h3>
1010
 
<a class="indexterm" name="id3242077"></a><pre class="programlisting">void                pango_quantize_line_geometry        (int *thickness,
 
1010
<a class="indexterm" name="id3259115"></a><pre class="programlisting">void                pango_quantize_line_geometry        (int *thickness,
1011
1011
                                                         int *position);</pre>
1012
1012
<p>
1013
1013
Quantizes the thickness and position of a line, typically an
1016
1016
such lines looking blurry.
1017
1017
</p>
1018
1018
<p>
1019
 
Care is taken to make sure <em class="parameter"><code>thickness</code></em> is at least 1 when this function</p>
 
1019
Care is taken to make sure <em class="parameter"><code>thickness</code></em> is at least one pixel when this
 
1020
function returns, but returned <em class="parameter"><code>position</code></em> may become zero as a result
 
1021
of rounding.</p>
1020
1022
<p>
1021
1023
 
1022
1024
</p>
1025
1027
<tbody>
1026
1028
<tr>
1027
1029
<td><p><span class="term"><em class="parameter"><code>thickness</code></em>&#160;:</span></p></td>
1028
 
<td> pointer to the thickness of a line, in Pango scaled units
 
1030
<td> pointer to the thickness of a line, in Pango units
1029
1031
</td>
1030
1032
</tr>
1031
1033
<tr>