~canonical-dx-team/ubuntu/maverick/gtk+2.0/menuproxy

« back to all changes in this revision

Viewing changes to docs/reference/gdk/html/gdk-Pango-Interaction.html

  • Committer: Bazaar Package Importer
  • Author(s): Sebastian Dröge
  • Date: 2010-06-11 12:19:30 UTC
  • mfrom: (1.11.6 upstream)
  • mto: This revision was merged to the branch mainline in revision 175.
  • Revision ID: james.westby@ubuntu.com-20100611121930-n4pklvkoqdsg12vm
Tags: 2.21.2-1
* New upstream development release:
  + debian/rules,
    debian/libgtk2.0-0.symbols:
    - Update for new API symbols.
  + debian/patches/070_mandatory-relibtoolize.patch:
    - Regenerated for the new version.
  + debian/control.in:
    - Update GLib (build-) dependency to >= 2.25.8.

Show diffs side-by-side

added added

removed removed

Lines of Context:
67
67
                    <a class="link" href="gdk-Pango-Interaction.html#GdkPangoAttrEmbossColor" title="GdkPangoAttrEmbossColor">GdkPangoAttrEmbossColor</a>;
68
68
                    <a class="link" href="gdk-Pango-Interaction.html#GdkPangoAttrStipple" title="GdkPangoAttrStipple">GdkPangoAttrStipple</a>;
69
69
<a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-attr-emboss-color-new" title="gdk_pango_attr_emboss_color_new ()">gdk_pango_attr_emboss_color_new</a>     (<em class="parameter"><code>const <a class="link" href="gdk-Colormaps-and-Colors.html#GdkColor" title="GdkColor"><span class="type">GdkColor</span></a> *color</code></em>);
70
 
<a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-attr-embossed-new" title="gdk_pango_attr_embossed_new ()">gdk_pango_attr_embossed_new</a>         (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> embossed</code></em>);
 
70
<a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-attr-embossed-new" title="gdk_pango_attr_embossed_new ()">gdk_pango_attr_embossed_new</a>         (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> embossed</code></em>);
71
71
<a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-attr-stipple-new" title="gdk_pango_attr_stipple_new ()">gdk_pango_attr_stipple_new</a>          (<em class="parameter"><code><a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkBitmap" title="GdkBitmap"><span class="type">GdkBitmap</span></a> *stipple</code></em>);
72
72
<a class="link" href="gdk-Points-Rectangles-and-Regions.html#GdkRegion" title="GdkRegion"><span class="returnvalue">GdkRegion</span></a> *         <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-layout-get-clip-region" title="gdk_pango_layout_get_clip_region ()">gdk_pango_layout_get_clip_region</a>    (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> *layout</code></em>,
73
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
74
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
75
 
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
76
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);
 
73
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
 
74
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
 
75
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
 
76
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);
77
77
<a class="link" href="gdk-Points-Rectangles-and-Regions.html#GdkRegion" title="GdkRegion"><span class="returnvalue">GdkRegion</span></a> *         <a class="link" href="gdk-Pango-Interaction.html#gdk-pango-layout-line-get-clip-region" title="gdk_pango_layout_line_get_clip_region ()">gdk_pango_layout_line_get_clip_region</a>
78
78
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayoutLine"><span class="type">PangoLayoutLine</span></a> *line</code></em>,
79
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
80
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
81
 
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
82
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);
 
79
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
 
80
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
 
81
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
 
82
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);
83
83
</pre>
84
84
</div>
85
85
<div class="refsect1" title="Object Hierarchy">
86
86
<a name="gdk-Pango-Interaction.object-hierarchy"></a><h2>Object Hierarchy</h2>
87
87
<pre class="synopsis">
88
 
  <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
 
88
  <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
89
89
   +----<a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PangoRenderer">PangoRenderer</a>
90
90
         +----GdkPangoRenderer
91
91
</pre>
107
107
<p>
108
108
Creating a <a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> object is the first step in rendering text,
109
109
and requires getting a handle to a <a href="/usr/share/gtk-doc/html/pango/pango-Text-Processing.html#PangoContext"><span class="type">PangoContext</span></a>. For GTK+ programs,
110
 
you'll usually want to use <a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>, or
111
 
<a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-create-pango-layout"><code class="function">gtk_widget_create_pango_layout()</code></a>, rather than using the lowlevel
 
110
you'll usually want to use <a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>, or
 
111
<a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-create-pango-layout"><code class="function">gtk_widget_create_pango_layout()</code></a>, rather than using the lowlevel
112
112
<a class="link" href="gdk-Pango-Interaction.html#gdk-pango-context-get-for-screen" title="gdk_pango_context_get_for_screen ()"><code class="function">gdk_pango_context_get_for_screen()</code></a>. Once you have a <a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a>, you
113
113
can set the text and attributes of it with Pango functions like
114
114
<a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#pango-layout-set-text"><code class="function">pango_layout_set_text()</code></a> and get its size with <a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#pango-layout-get-size"><code class="function">pango_layout_get_size()</code></a>.
196
196
        <td class="listing_code"><pre class="programlisting"><span class="preproc">#define</span><span class="normal"> RADIUS </span><span class="number">100</span>
197
197
<span class="preproc">#define</span><span class="normal"> N_WORDS </span><span class="number">10</span>
198
198
<span class="preproc">#define</span><span class="normal"> FONT </span><span class="string">"Sans Bold 18"</span>
199
 
<span class="normal"><a href="GdkScreen.html">GdkScreen</a> </span><span class="symbol">*</span><span class="normal">screen </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="gdk-Drawing-Primitives.html#gdk-drawable-get-screen">gdk_drawable_get_screen</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">drawable</span><span class="symbol">);</span>
200
 
<span class="normal"><a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PangoRenderer">PangoRenderer</a> </span><span class="symbol">*</span><span class="normal">renderer</span><span class="symbol">;</span>
201
 
<span class="normal"><a href="gdk-Graphics-Contexts.html#GdkGC">GdkGC</a> </span><span class="symbol">*</span><span class="normal">gc</span><span class="symbol">;</span>
202
 
<span class="normal"><a href="/usr/share/gtk-doc/html/pango/pango-Glyph-Storage.html#PangoMatrix">PangoMatrix</a> matrix </span><span class="symbol">=</span><span class="normal"> <a href="/usr/share/gtk-doc/html/pango/pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS">PANGO_MATRIX_INIT</a></span><span class="symbol">;</span>
203
 
<span class="normal"><a href="/usr/share/gtk-doc/html/pango/pango-Text-Processing.html#PangoContext">PangoContext</a> </span><span class="symbol">*</span><span class="normal">context</span><span class="symbol">;</span>
204
 
<span class="normal"><a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayout">PangoLayout</a> </span><span class="symbol">*</span><span class="normal">layout</span><span class="symbol">;</span>
205
 
<span class="normal"><a href="/usr/share/gtk-doc/html/pango/pango-Fonts.html#PangoFontDescription">PangoFontDescription</a> </span><span class="symbol">*</span><span class="normal">desc</span><span class="symbol">;</span>
 
199
<span class="usertype">GdkScreen</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">screen </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="gdk-Drawing-Primitives.html#gdk-drawable-get-screen">gdk_drawable_get_screen</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">drawable</span><span class="symbol">);</span>
 
200
<span class="usertype">PangoRenderer</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">renderer</span><span class="symbol">;</span>
 
201
<span class="usertype">GdkGC</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">gc</span><span class="symbol">;</span>
 
202
<span class="usertype">PangoMatrix</span><span class="normal"> matrix </span><span class="symbol">=</span><span class="normal"> <a href="/usr/share/gtk-doc/html/pango/pango-Glyph-Storage.html#PANGO-MATRIX-INIT:CAPS">PANGO_MATRIX_INIT</a></span><span class="symbol">;</span>
 
203
<span class="usertype">PangoContext</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">context</span><span class="symbol">;</span>
 
204
<span class="usertype">PangoLayout</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">layout</span><span class="symbol">;</span>
 
205
<span class="usertype">PangoFontDescription</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">desc</span><span class="symbol">;</span>
206
206
<span class="type">double</span><span class="normal"> device_radius</span><span class="symbol">;</span>
207
207
<span class="type">int</span><span class="normal"> width</span><span class="symbol">,</span><span class="normal"> height</span><span class="symbol">;</span>
208
208
<span class="type">int</span><span class="normal"> i</span><span class="symbol">;</span>
215
215
<span class="comment"> * where we are drawing are [-RADIUS, RADIUS], [-RADIUS, RADIUS]</span>
216
216
<span class="comment"> * We first center, then change the scale */</span>
217
217
<span class="function"><a href="gdk-Drawing-Primitives.html#gdk-drawable-get-size">gdk_drawable_get_size</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">drawable</span><span class="symbol">,</span><span class="normal"> </span><span class="symbol">&amp;</span><span class="normal">width</span><span class="symbol">,</span><span class="normal"> </span><span class="symbol">&amp;</span><span class="normal">height</span><span class="symbol">);</span>
218
 
<span class="normal">device_radius </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#MIN:CAPS">MIN</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">width</span><span class="symbol">,</span><span class="normal"> height</span><span class="symbol">)</span><span class="normal"> </span><span class="symbol">/</span><span class="normal"> </span><span class="number">2</span><span class="symbol">.;</span>
 
218
<span class="normal">device_radius </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#MIN:CAPS">MIN</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">width</span><span class="symbol">,</span><span class="normal"> height</span><span class="symbol">)</span><span class="normal"> </span><span class="symbol">/</span><span class="normal"> </span><span class="number">2</span><span class="symbol">.;</span>
219
219
<span class="function"><a href="/usr/share/gtk-doc/html/pango/pango-Glyph-Storage.html#pango-matrix-translate">pango_matrix_translate</a></span><span class="normal"> </span><span class="symbol">(&amp;</span><span class="normal">matrix</span><span class="symbol">,</span>
220
220
<span class="normal">                        device_radius </span><span class="symbol">+</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">width </span><span class="symbol">-</span><span class="normal"> </span><span class="number">2</span><span class="normal"> </span><span class="symbol">*</span><span class="normal"> device_radius</span><span class="symbol">)</span><span class="normal"> </span><span class="symbol">/</span><span class="normal"> </span><span class="number">2</span><span class="symbol">,</span>
221
221
<span class="normal">                        device_radius </span><span class="symbol">+</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">height </span><span class="symbol">-</span><span class="normal"> </span><span class="number">2</span><span class="normal"> </span><span class="symbol">*</span><span class="normal"> device_radius</span><span class="symbol">)</span><span class="normal"> </span><span class="symbol">/</span><span class="normal"> </span><span class="number">2</span><span class="symbol">);</span>
230
230
<span class="comment">/* Draw the layout N_WORDS times in a circle */</span>
231
231
<span class="keyword">for</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">i </span><span class="symbol">=</span><span class="normal"> </span><span class="number">0</span><span class="symbol">;</span><span class="normal"> i </span><span class="symbol">&lt;</span><span class="normal"> N_WORDS</span><span class="symbol">;</span><span class="normal"> i</span><span class="symbol">++)</span>
232
232
<span class="normal">  </span><span class="cbracket">{</span>
233
 
<span class="normal">    <a href="gdk-Colormaps-and-Colors.html#GdkColor">GdkColor</a> color</span><span class="symbol">;</span>
234
 
<span class="normal">    <a href="/usr/share/gtk-doc/html/pango/pango-Glyph-Storage.html#PangoMatrix">PangoMatrix</a> rotated_matrix </span><span class="symbol">=</span><span class="normal"> matrix</span><span class="symbol">;</span>
 
233
<span class="normal">    </span><span class="usertype">GdkColor</span><span class="normal"> color</span><span class="symbol">;</span>
 
234
<span class="normal">    </span><span class="usertype">PangoMatrix</span><span class="normal"> rotated_matrix </span><span class="symbol">=</span><span class="normal"> matrix</span><span class="symbol">;</span>
235
235
<span class="normal">    </span><span class="type">int</span><span class="normal"> width</span><span class="symbol">,</span><span class="normal"> height</span><span class="symbol">;</span>
236
236
<span class="normal">    </span><span class="type">double</span><span class="normal"> angle </span><span class="symbol">=</span><span class="normal"> </span><span class="symbol">(</span><span class="number">360</span><span class="symbol">.</span><span class="normal"> </span><span class="symbol">*</span><span class="normal"> i</span><span class="symbol">)</span><span class="normal"> </span><span class="symbol">/</span><span class="normal"> N_WORDS</span><span class="symbol">;</span>
237
237
<span class="normal">    </span><span class="comment">/* Gradient from red at angle == 60 to blue at angle == 300 */</span>
250
250
<span class="normal">  </span><span class="cbracket">}</span>
251
251
<span class="comment">/* Clean up default renderer, since it is shared */</span>
252
252
<span class="function"><a href="gdk-Pango-Interaction.html#gdk-pango-renderer-set-override-color">gdk_pango_renderer_set_override_color</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GDK_PANGO_RENDERER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">renderer</span><span class="symbol">),</span>
253
 
<span class="normal">                                       <a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PANGO-RENDER-PART-FOREGROUND:CAPS">PANGO_RENDER_PART_FOREGROUND</a></span><span class="symbol">,</span><span class="normal"> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
254
 
<span class="function"><a href="gdk-Pango-Interaction.html#gdk-pango-renderer-set-drawable">gdk_pango_renderer_set_drawable</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GDK_PANGO_RENDERER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">renderer</span><span class="symbol">),</span><span class="normal"> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
255
 
<span class="function"><a href="gdk-Pango-Interaction.html#gdk-pango-renderer-set-gc">gdk_pango_renderer_set_gc</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GDK_PANGO_RENDERER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">renderer</span><span class="symbol">),</span><span class="normal"> <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
 
253
<span class="normal">                                       <a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PANGO-RENDER-PART-FOREGROUND:CAPS">PANGO_RENDER_PART_FOREGROUND</a></span><span class="symbol">,</span><span class="normal"> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
 
254
<span class="function"><a href="gdk-Pango-Interaction.html#gdk-pango-renderer-set-drawable">gdk_pango_renderer_set_drawable</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GDK_PANGO_RENDERER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">renderer</span><span class="symbol">),</span><span class="normal"> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
 
255
<span class="function"><a href="gdk-Pango-Interaction.html#gdk-pango-renderer-set-gc">gdk_pango_renderer_set_gc</a></span><span class="normal"> </span><span class="symbol">(</span><span class="function">GDK_PANGO_RENDERER</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">renderer</span><span class="symbol">),</span><span class="normal"> <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS">NULL</a></span><span class="symbol">);</span>
256
256
<span class="comment">/* free the objects we created */</span>
257
 
<span class="function"><a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">layout</span><span class="symbol">);</span>
258
 
<span class="function"><a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">context</span><span class="symbol">);</span>
259
 
<span class="function"><a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">gc</span><span class="symbol">);</span></pre></td>
 
257
<span class="function"><a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">layout</span><span class="symbol">);</span>
 
258
<span class="function"><a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">context</span><span class="symbol">);</span>
 
259
<span class="function"><a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref">g_object_unref</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">gc</span><span class="symbol">);</span></pre></td>
260
260
      </tr>
261
261
    </tbody>
262
262
  </table>
264
264
 
265
265
</div>
266
266
<br class="example-break"><div class="figure">
267
 
<a name="id620285"></a><p class="title"><b>Figure 1. Output of <a class="xref" href="gdk-Pango-Interaction.html#rotated-example" title="Example 8. Using GdkPangoRenderer to draw transformed text">Example 8, “Using <span class="type">GdkPangoRenderer</span> to draw transformed text”</a></b></p>
 
267
<a name="id734237"></a><p class="title"><b>Figure 1. Output of <a class="xref" href="gdk-Pango-Interaction.html#rotated-example" title="Example 8. Using GdkPangoRenderer to draw transformed text">Example 8, “Using <span class="type">GdkPangoRenderer</span> to draw transformed text”</a></b></p>
268
268
<div class="figure-contents"><div><img src="rotated-text.png" alt="Output of"></div></div>
269
269
</div>
270
270
<br class="figure-break">
328
328
</tr>
329
329
<tr>
330
330
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
331
 
<td> a newly created <a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PangoRenderer"><span class="type">PangoRenderer</span></a>. Free with <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.
 
331
<td> a newly created <a href="/usr/share/gtk-doc/html/pango/pango-pango-renderer.html#PangoRenderer"><span class="type">PangoRenderer</span></a>. Free with <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.
332
332
 
333
333
</td>
334
334
</tr>
389
389
</tr>
390
390
<tr>
391
391
<td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td>
392
 
<td> the new target drawable, or <a href="/usr/share/gtk-doc/html/glib/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>
 
392
<td> the new target drawable, 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>
393
393
</td>
394
394
</tr>
395
395
</tbody>
404
404
<p>
405
405
Sets the GC the renderer draws with. Note that the GC must not be
406
406
modified until it is unset by calling the function again with
407
 
<a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> for the <em class="parameter"><code>gc</code></em> parameter, since GDK may make internal copies
 
407
<a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> for the <em class="parameter"><code>gc</code></em> parameter, since GDK may make internal copies
408
408
of the GC which won't be updated to follow changes to the
409
409
original GC.
410
410
</p>
418
418
</tr>
419
419
<tr>
420
420
<td><p><span class="term"><em class="parameter"><code>gc</code></em> :</span></p></td>
421
 
<td> the new GC to use for drawing, or <a href="/usr/share/gtk-doc/html/glib/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>
 
421
<td> the new GC to use for drawing, 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>
422
422
</td>
423
423
</tr>
424
424
</tbody>
488
488
</tr>
489
489
<tr>
490
490
<td><p><span class="term"><em class="parameter"><code>color</code></em> :</span></p></td>
491
 
<td> the color to use, or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to unset a previously
 
491
<td> the color to use, or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> to unset a previously
492
492
        set override color. <span class="annotation">[<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
493
493
</td>
494
494
</tr>
507
507
The context must be freed when you're finished with it.
508
508
</p>
509
509
<p>
510
 
When using GTK+, normally you should use <a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
 
510
When using GTK+, normally you should use <a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
511
511
instead of this function, to get the appropriate context for
512
512
the widget you intend to render text onto.
513
513
</p>
514
514
<p>
515
515
The newly created context will have the default font options (see
516
516
<a href="/usr/share/gtk-doc/html/cairo/cairo-font-options.html#cairo-font-options-t"><span class="type">cairo_font_options_t</span></a>) for the default screen; if these options
517
 
change it will not be updated. Using <a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
 
517
change it will not be updated. Using <a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
518
518
is more convenient if you want to keep a context around and track
519
519
changes to the screen's font rendering settings.
520
520
</p>
538
538
The context must be freed when you're finished with it.
539
539
</p>
540
540
<p>
541
 
When using GTK+, normally you should use <a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
 
541
When using GTK+, normally you should use <a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
542
542
instead of this function, to get the appropriate context for
543
543
the widget you intend to render text onto.
544
544
</p>
545
545
<p>
546
546
The newly created context will have the default font options
547
547
(see <a href="/usr/share/gtk-doc/html/cairo/cairo-font-options.html#cairo-font-options-t"><span class="type">cairo_font_options_t</span></a>) for the screen; if these options
548
 
change it will not be updated. Using <a href="/usr/share/gtk-doc/html/gtk3/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
 
548
change it will not be updated. Using <a href="http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-pango-context"><code class="function">gtk_widget_get_pango_context()</code></a>
549
549
is more convenient if you want to keep a context around and track
550
550
changes to the screen's font rendering settings.
551
551
</p>
619
619
</td>
620
620
</tr>
621
621
<tr>
622
 
<td><p><span class="term"><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GdkPangoAttrEmbossed.embossed"></a>embossed</code></em>;</span></p></td>
 
622
<td><p><span class="term"><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> <em class="structfield"><code><a name="GdkPangoAttrEmbossed.embossed"></a>embossed</code></em>;</span></p></td>
623
623
<td>the embossed bitmap.
624
624
</td>
625
625
</tr>
709
709
<hr>
710
710
<div class="refsect2" title="gdk_pango_attr_embossed_new ()">
711
711
<a name="gdk-pango-attr-embossed-new"></a><h3>gdk_pango_attr_embossed_new ()</h3>
712
 
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    gdk_pango_attr_embossed_new         (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> embossed</code></em>);</pre>
 
712
<pre class="programlisting"><a href="/usr/share/gtk-doc/html/pango/pango-Text-Attributes.html#PangoAttribute"><span class="returnvalue">PangoAttribute</span></a> *    gdk_pango_attr_embossed_new         (<em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> embossed</code></em>);</pre>
713
713
<p>
714
714
Creates a new attribute flagging a region as embossed or not.
715
715
</p>
757
757
<div class="refsect2" title="gdk_pango_layout_get_clip_region ()">
758
758
<a name="gdk-pango-layout-get-clip-region"></a><h3>gdk_pango_layout_get_clip_region ()</h3>
759
759
<pre class="programlisting"><a class="link" href="gdk-Points-Rectangles-and-Regions.html#GdkRegion" title="GdkRegion"><span class="returnvalue">GdkRegion</span></a> *         gdk_pango_layout_get_clip_region    (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> *layout</code></em>,
760
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
761
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
762
 
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
763
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);</pre>
 
760
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
 
761
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
 
762
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
 
763
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);</pre>
764
764
<p>
765
765
Obtains a clip region which contains the areas where the given ranges
766
766
of text would be drawn. <em class="parameter"><code>x_origin</code></em> and <em class="parameter"><code>y_origin</code></em> are the same position
814
814
<a name="gdk-pango-layout-line-get-clip-region"></a><h3>gdk_pango_layout_line_get_clip_region ()</h3>
815
815
<pre class="programlisting"><a class="link" href="gdk-Points-Rectangles-and-Regions.html#GdkRegion" title="GdkRegion"><span class="returnvalue">GdkRegion</span></a> *         gdk_pango_layout_line_get_clip_region
816
816
                                                        (<em class="parameter"><code><a href="/usr/share/gtk-doc/html/pango/pango-Layout-Objects.html#PangoLayoutLine"><span class="type">PangoLayoutLine</span></a> *line</code></em>,
817
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
818
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
819
 
                                                         <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
820
 
                                                         <em class="parameter"><code><a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);</pre>
 
817
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> x_origin</code></em>,
 
818
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> y_origin</code></em>,
 
819
                                                         <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *index_ranges</code></em>,
 
820
                                                         <em class="parameter"><code><a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gint"><span class="type">gint</span></a> n_ranges</code></em>);</pre>
821
821
<p>
822
822
Obtains a clip region which contains the areas where the given
823
823
ranges of text would be drawn. <em class="parameter"><code>x_origin</code></em> and <em class="parameter"><code>y_origin</code></em> are the same