<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
  "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
[
<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
]>
<refentry id="pango-Cairo-Rendering">
<refmeta>
<refentrytitle role="top_of_page" id="pango-Cairo-Rendering.top_of_page">Cairo Fonts and Rendering</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>PANGO Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>Cairo Fonts and Rendering</refname>
<refpurpose>Font handling and rendering with Cairo</refpurpose>
</refnamediv>

<refsect1 id="pango-Cairo-Rendering.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_proto_type" colwidth="150px"/>
<colspec colname="functions_proto_name"/>
<tbody>
<row><entry role="function_type"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-get-default">pango_cairo_font_map_get_default</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-set-default">pango_cairo_font_map_set_default</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-new">pango_cairo_font_map_new</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-new-for-font-type">pango_cairo_font_map_new_for_font_type</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="cairo-font-type-t"><returnvalue>cairo_font_type_t</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-get-font-type">pango_cairo_font_map_get_font_type</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-set-resolution">pango_cairo_font_map_set_resolution</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="double"><returnvalue>double</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-get-resolution">pango_cairo_font_map_get_resolution</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoContext"><returnvalue>PangoContext</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-font-map-create-context">pango_cairo_font_map_create_context</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="cairo-scaled-font-t"><returnvalue>cairo_scaled_font_t</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-font-get-scaled-font">pango_cairo_font_get_scaled_font</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-context-set-resolution">pango_cairo_context_set_resolution</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="double"><returnvalue>double</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-context-get-resolution">pango_cairo_context_get_resolution</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-context-set-font-options">pango_cairo_context_set_font_options</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type">const <link linkend="cairo-font-options-t"><returnvalue>cairo_font_options_t</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-context-get-font-options">pango_cairo_context_get_font_options</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><phrase role="c_punctuation">(</phrase><link linkend="PangoCairoShapeRendererFunc">*PangoCairoShapeRendererFunc</link><phrase role="c_punctuation">)</phrase>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-context-set-shape-renderer">pango_cairo_context_set_shape_renderer</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoCairoShapeRendererFunc"><returnvalue>PangoCairoShapeRendererFunc</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-context-get-shape-renderer">pango_cairo_context_get_shape_renderer</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoContext"><returnvalue>PangoContext</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-create-context">pango_cairo_create_context</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-update-context">pango_cairo_update_context</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="PangoLayout"><returnvalue>PangoLayout</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="pango-cairo-create-layout">pango_cairo_create_layout</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-update-layout">pango_cairo_update_layout</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-show-glyph-string">pango_cairo_show_glyph_string</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-show-glyph-item">pango_cairo_show_glyph_item</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-show-layout-line">pango_cairo_show_layout_line</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-show-layout">pango_cairo_show_layout</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-show-error-underline">pango_cairo_show_error_underline</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-glyph-string-path">pango_cairo_glyph_string_path</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-layout-line-path">pango_cairo_layout_line_path</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-layout-path">pango_cairo_layout_path</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="pango-cairo-error-underline-path">pango_cairo_error_underline_path</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<anchor id="PangoCairoFont"/><anchor id="PangoCairoFontMap"/><refsect1 id="pango-Cairo-Rendering.other" role="other_proto">
<title role="other_proto.title">Types and Values</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="other_proto_type" colwidth="150px"/>
<colspec colname="other_proto_name"/>
<tbody>
<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="PangoCairoFont-struct">PangoCairoFont</link></entry></row>
<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="PangoCairoFontMap-struct">PangoCairoFontMap</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="pango-Cairo-Rendering.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<screen>    <link linkend="GInterface">GInterface</link>
    <phrase role="lineart">&#9500;&#9472;&#9472;</phrase> PangoCairoFont
    <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> PangoCairoFontMap
</screen>
</refsect1>
<refsect1 id="pango-Cairo-Rendering.prerequisites" role="prerequisites">
<title role="prerequisites.title">Prerequisites</title>
<para>
PangoCairoFont requires
 <link linkend="PangoFont">PangoFont</link>.</para>
<para>
PangoCairoFontMap requires
 <link linkend="PangoFontMap">PangoFontMap</link>.</para>

</refsect1>


<refsect1 id="pango-Cairo-Rendering.description" role="desc">
<title role="desc.title">Description</title>
<para>The <ulink url="http://cairographics.org">Cairo library</ulink> is a
vector graphics library with a powerful rendering model. It has such
features as anti-aliased primitives, alpha-compositing, and
gradients. Multiple backends for Cairo are available, to allow
rendering to images, to PDF files, and to the screen on X and on other
windowing systems. The functions in this section allow using Pango
to render to Cairo surfaces.</para>
<para>Using Pango with Cairo is straightforward. A <link linkend="PangoContext"><type>PangoContext</type></link> created
with <link linkend="pango-cairo-font-map-create-context"><function>pango_cairo_font_map_create_context()</function></link> can be used on any
Cairo context (cairo_t), but needs to be updated to match the
current transformation matrix and target surface of the Cairo context
using <link linkend="pango-cairo-update-context"><function>pango_cairo_update_context()</function></link>. The convenience functions
<link linkend="pango-cairo-create-layout"><function>pango_cairo_create_layout()</function></link> and <link linkend="pango-cairo-update-layout"><function>pango_cairo_update_layout()</function></link> handle
the common case where the program doesn't need to manipulate the
properties of the <link linkend="PangoContext"><type>PangoContext</type></link>.</para>
<para>When you get the metrics of a layout or of a piece of a layout using
functions such as <link linkend="pango-layout-get-extents"><function>pango_layout_get_extents()</function></link>, the reported metrics
are in user-space coordinates. If a piece of text is 10 units long,
and you call cairo_scale (cr, 2.0), it still is more-or-less 10
units long. However, the results will be affected by hinting
(that is, the process of adjusting the text to look good on the
pixel grid), so you shouldn't assume they are completely independent
of the current transformation matrix. Note that the basic metrics
functions in Pango report results in integer Pango units. To get
to the floating point units used in Cairo divide by <link linkend="PANGO-SCALE:CAPS"><literal>PANGO_SCALE</literal></link>.</para>
<refsect3 id="rotated-example"><title>Using Pango with Cairo</title><informalexample><programlisting role="example" language="C"><![CDATA[
#include <math.h>
#include <pango/pangocairo.h>

static void
draw_text (cairo_t *cr)
{
#define RADIUS 150
#define N_WORDS 10
#define FONT "Sans Bold 27"

  PangoLayout *layout;
  PangoFontDescription *desc;
  int i;

  /* Center coordinates on the middle of the region we are drawing
   */
  cairo_translate (cr, RADIUS, RADIUS);

  /* Create a PangoLayout, set the font and text */
  layout = pango_cairo_create_layout (cr);

  pango_layout_set_text (layout, "Text", -1);
  desc = pango_font_description_from_string (FONT);
  pango_layout_set_font_description (layout, desc);
  pango_font_description_free (desc);

  /* Draw the layout N_WORDS times in a circle */
  for (i = 0; i < N_WORDS; i++)
    {
      int width, height;
      double angle = (360. * i) / N_WORDS;
      double red;

      cairo_save (cr);

      /* Gradient from red at angle == 60 to blue at angle == 240 */
      red   = (1 + cos ((angle - 60) * G_PI / 180.)) / 2;
      cairo_set_source_rgb (cr, red, 0, 1.0 - red);

      cairo_rotate (cr, angle * G_PI / 180.);

      /* Inform Pango to re-layout the text with the new transformation */
      pango_cairo_update_layout (cr, layout);

      pango_layout_get_size (layout, &width, &height);
      cairo_move_to (cr, - ((double)width / PANGO_SCALE) / 2, - RADIUS);
      pango_cairo_show_layout (cr, layout);

      cairo_restore (cr);
    }

  /* free the layout object */
  g_object_unref (layout);
}

int main (int argc, char **argv)
{
  cairo_t *cr;
  char *filename;
  cairo_status_t status;
  cairo_surface_t *surface;

  if (argc != 2)
    {
      g_printerr ("Usage: cairosimple OUTPUT_FILENAME\n");
      return 1;
    }

     filename = argv[1];

  surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32,
                                        2 * RADIUS, 2 * RADIUS);
  cr = cairo_create (surface);

  cairo_set_source_rgb (cr, 1.0, 1.0, 1.0);
  cairo_paint (cr);
  draw_text (cr);
  cairo_destroy (cr);

  status = cairo_surface_write_to_png (surface, filename);
  cairo_surface_destroy (surface);

  if (status != CAIRO_STATUS_SUCCESS)
    {
      g_printerr ("Could not save png to '%s'\n", filename);
      return 1;
    }

  return 0;
}
]]></programlisting></informalexample>
<para></para>
<para>Once you build and run the example code above, you should see the
following result:</para>
<para><inlinemediaobject><imageobject><imagedata fileref="rotated-text.png"></imagedata></imageobject><textobject><phrase>Output of rotated-example</phrase></textobject></inlinemediaobject></para>
</refsect3>

</refsect1>
<refsect1 id="pango-Cairo-Rendering.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="pango-cairo-font-map-get-default" role="function" condition="since:1.10">
<title>pango_cairo_font_map_get_default&#160;()</title>
<indexterm zone="pango-cairo-font-map-get-default" role="1.10"><primary>pango_cairo_font_map_get_default</primary></indexterm>
<programlisting language="C"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
pango_cairo_font_map_get_default (<parameter><type>void</type></parameter>);</programlisting>
<para>Gets a default <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> to use with Cairo.</para>
<para>Note that the type of the returned object will depend
on the particular font backend Cairo was compiled to use;
You generally should only use the <link linkend="PangoFontMap"><type>PangoFontMap</type></link> and
<link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> interfaces on the returned object.</para>
<para>The default Cairo fontmap can be changed by using
<link linkend="pango-cairo-font-map-set-default"><function>pango_cairo_font_map_set_default()</function></link>.  This can be used to
change the Cairo font backend that the default fontmap
uses for example.</para>
<para>Note that since Pango 1.32.6, the default fontmap is per-thread.
Each thread gets its own default fontmap.  In this way,
PangoCairo can be used safely from multiple threads.</para>
<refsect3 id="pango-cairo-font-map-get-default.returns" role="returns">
<title>Returns</title>
<para>the default PangoCairo fontmap
for the current thread. This object is owned by Pango and must not be freed. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-set-default" role="function" condition="since:1.22">
<title>pango_cairo_font_map_set_default&#160;()</title>
<indexterm zone="pango-cairo-font-map-set-default" role="1.22"><primary>pango_cairo_font_map_set_default</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_font_map_set_default (<parameter><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> *fontmap</parameter>);</programlisting>
<para>Sets a default <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> to use with Cairo.</para>
<para>This can be used to change the Cairo font backend that the
default fontmap uses for example.  The old default font map
is unreffed and the new font map referenced.</para>
<para>Note that since Pango 1.32.6, the default fontmap is per-thread.
This function only changes the default fontmap for
the current thread.   Default fontmaps of exisiting threads
are not changed.  Default fontmaps of any new threads will
still be created using <link linkend="pango-cairo-font-map-new"><function>pango_cairo_font_map_new()</function></link>.</para>
<para>A value of <link linkend="NULL:CAPS"><literal>NULL</literal></link> for <parameter>fontmap</parameter>
 will cause the current default
font map to be released and a new default font
map to be created on demand, using <link linkend="pango-cairo-font-map-new"><function>pango_cairo_font_map_new()</function></link>.</para>
<refsect3 id="pango-cairo-font-map-set-default.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fontmap</para></entry>
<entry role="parameter_description"><para>The new default font map, or <link linkend="NULL:CAPS"><literal>NULL</literal></link>. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>nullable</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.22">1.22</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-new" role="function" condition="since:1.10">
<title>pango_cairo_font_map_new&#160;()</title>
<indexterm zone="pango-cairo-font-map-new" role="1.10"><primary>pango_cairo_font_map_new</primary></indexterm>
<programlisting language="C"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
pango_cairo_font_map_new (<parameter><type>void</type></parameter>);</programlisting>
<para>Creates a new <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> object; a fontmap is used
to cache information about available fonts, and holds
certain global parameters such as the resolution.
In most cases, you can use <link linkend="pango-cairo-font-map-get-default"><function>pango_cairo_font_map_get_default()</function></link>
instead.</para>
<para>Note that the type of the returned object will depend
on the particular font backend Cairo was compiled to use;
You generally should only use the <link linkend="PangoFontMap"><type>PangoFontMap</type></link> and
<link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> interfaces on the returned object.</para>
<para>You can override the type of backend returned by using an
environment variable <link linkend="PANGOCAIRO-BACKEND:CAPS"><literal>PANGOCAIRO_BACKEND</literal></link>.  Supported types,
based on your build, are fc (fontconfig), win32, and coretext.
If requested type is not available, NULL is returned. Ie.
this is only useful for testing, when at least two backends
are compiled in.</para>
<refsect3 id="pango-cairo-font-map-new.returns" role="returns">
<title>Returns</title>
<para>the newly allocated <link linkend="PangoFontMap"><type>PangoFontMap</type></link>,
which should be freed with <link linkend="g-object-unref"><function>g_object_unref()</function></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-new-for-font-type" role="function" condition="since:1.18">
<title>pango_cairo_font_map_new_for_font_type&#160;()</title>
<indexterm zone="pango-cairo-font-map-new-for-font-type" role="1.18"><primary>pango_cairo_font_map_new_for_font_type</primary></indexterm>
<programlisting language="C"><link linkend="PangoFontMap"><returnvalue>PangoFontMap</returnvalue></link>&#160;*
pango_cairo_font_map_new_for_font_type
                               (<parameter><link linkend="cairo-font-type-t"><type>cairo_font_type_t</type></link> fonttype</parameter>);</programlisting>
<para>Creates a new <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> object of the type suitable
to be used with cairo font backend of type <parameter>fonttype</parameter>
.</para>
<para>In most cases one should simply use <parameter><link linkend="pango-cairo-font-map-new"><function>pango_cairo_font_map_new()</function></link></parameter>
,
or in fact in most of those cases, just use
<parameter><link linkend="pango-cairo-font-map-get-default"><function>pango_cairo_font_map_get_default()</function></link></parameter>
.</para>
<refsect3 id="pango-cairo-font-map-new-for-font-type.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fonttype</para></entry>
<entry role="parameter_description"><para>desired <link linkend="cairo-font-type-t"><type>cairo_font_type_t</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-font-map-new-for-font-type.returns" role="returns">
<title>Returns</title>
<para>the newly allocated
<link linkend="PangoFontMap"><type>PangoFontMap</type></link> of suitable type which should be freed
with <link linkend="g-object-unref"><function>g_object_unref()</function></link>, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> if the requested
cairo font backend is not supported / compiled in. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>][<acronym>nullable</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-get-font-type" role="function" condition="since:1.18">
<title>pango_cairo_font_map_get_font_type&#160;()</title>
<indexterm zone="pango-cairo-font-map-get-font-type" role="1.18"><primary>pango_cairo_font_map_get_font_type</primary></indexterm>
<programlisting language="C"><link linkend="cairo-font-type-t"><returnvalue>cairo_font_type_t</returnvalue></link>
pango_cairo_font_map_get_font_type (<parameter><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> *fontmap</parameter>);</programlisting>
<para>Gets the type of Cairo font backend that <parameter>fontmap</parameter>
 uses.</para>
<refsect3 id="pango-cairo-font-map-get-font-type.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fontmap</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-font-map-get-font-type.returns" role="returns">
<title>Returns</title>
<para> the <link linkend="cairo-font-type-t"><type>cairo_font_type_t</type></link> cairo font backend type</para>
</refsect3><para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-set-resolution" role="function" condition="since:1.10">
<title>pango_cairo_font_map_set_resolution&#160;()</title>
<indexterm zone="pango-cairo-font-map-set-resolution" role="1.10"><primary>pango_cairo_font_map_set_resolution</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_font_map_set_resolution (<parameter><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> *fontmap</parameter>,
                                     <parameter><link linkend="double"><type>double</type></link> dpi</parameter>);</programlisting>
<para>Sets the resolution for the fontmap. This is a scale factor between
points specified in a <link linkend="PangoFontDescription"><type>PangoFontDescription</type></link> and Cairo units. The
default value is 96, meaning that a 10 point font will be 13
units high. (10 * 96. / 72. = 13.3).</para>
<refsect3 id="pango-cairo-font-map-set-resolution.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fontmap</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>dpi</para></entry>
<entry role="parameter_description"><para>the resolution in "dots per inch". (Physical inches aren't actually
involved; the terminology is conventional.)</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-get-resolution" role="function" condition="since:1.10">
<title>pango_cairo_font_map_get_resolution&#160;()</title>
<indexterm zone="pango-cairo-font-map-get-resolution" role="1.10"><primary>pango_cairo_font_map_get_resolution</primary></indexterm>
<programlisting language="C"><link linkend="double"><returnvalue>double</returnvalue></link>
pango_cairo_font_map_get_resolution (<parameter><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> *fontmap</parameter>);</programlisting>
<para>Gets the resolution for the fontmap. See <link linkend="pango-cairo-font-map-set-resolution"><function>pango_cairo_font_map_set_resolution()</function></link></para>
<refsect3 id="pango-cairo-font-map-get-resolution.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fontmap</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-font-map-get-resolution.returns" role="returns">
<title>Returns</title>
<para> the resolution in "dots per inch"</para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-font-map-create-context" role="function" condition="deprecated:1.22: Use pango_font_map_create_context() instead.|since:1.10">
<title>pango_cairo_font_map_create_context&#160;()</title>
<indexterm zone="pango-cairo-font-map-create-context" role="deprecated"><primary>pango_cairo_font_map_create_context</primary></indexterm><indexterm zone="pango-cairo-font-map-create-context" role="1.10"><primary>pango_cairo_font_map_create_context</primary></indexterm>
<programlisting language="C"><link linkend="PangoContext"><returnvalue>PangoContext</returnvalue></link>&#160;*
pango_cairo_font_map_create_context (<parameter><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> *fontmap</parameter>);</programlisting>
<warning><para><literal>pango_cairo_font_map_create_context</literal> has been deprecated since version 1.22 and should not be used in newly-written code.</para> <para>Use <link linkend="pango-font-map-create-context"><function>pango_font_map_create_context()</function></link> instead.</para>
</warning>
<para>Create a <link linkend="PangoContext"><type>PangoContext</type></link> for the given fontmap.</para>

<para><emphasis role="annotation">[<acronym>skip</acronym>]</emphasis></para><refsect3 id="pango-cairo-font-map-create-context.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>fontmap</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-font-map-create-context.returns" role="returns">
<title>Returns</title>
<para> the newly created context; free with <link linkend="g-object-unref"><function>g_object_unref()</function></link>.</para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-font-get-scaled-font" role="function" condition="since:1.18">
<title>pango_cairo_font_get_scaled_font&#160;()</title>
<indexterm zone="pango-cairo-font-get-scaled-font" role="1.18"><primary>pango_cairo_font_get_scaled_font</primary></indexterm>
<programlisting language="C"><link linkend="cairo-scaled-font-t"><returnvalue>cairo_scaled_font_t</returnvalue></link>&#160;*
pango_cairo_font_get_scaled_font (<parameter><link linkend="PangoCairoFont"><type>PangoCairoFont</type></link> *font</parameter>);</programlisting>
<para>Gets the <link linkend="cairo-scaled-font-t"><type>cairo_scaled_font_t</type></link> used by <parameter>font</parameter>
.
The scaled font can be referenced and kept using
<link linkend="cairo-scaled-font-reference"><function>cairo_scaled_font_reference()</function></link>.</para>
<refsect3 id="pango-cairo-font-get-scaled-font.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>font</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoFont"><type>PangoFont</type></link> from a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-font-get-scaled-font.returns" role="returns">
<title>Returns</title>
<para>the <link linkend="cairo-scaled-font-t"><type>cairo_scaled_font_t</type></link> used by <parameter>font</parameter>
,
or <link linkend="NULL:CAPS"><literal>NULL</literal></link> if <parameter>font</parameter>
is <link linkend="NULL:CAPS"><literal>NULL</literal></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>][<acronym>nullable</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="pango-cairo-context-set-resolution" role="function" condition="since:1.10">
<title>pango_cairo_context_set_resolution&#160;()</title>
<indexterm zone="pango-cairo-context-set-resolution" role="1.10"><primary>pango_cairo_context_set_resolution</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_context_set_resolution (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>,
                                    <parameter><link linkend="double"><type>double</type></link> dpi</parameter>);</programlisting>
<para>Sets the resolution for the context. This is a scale factor between
points specified in a <link linkend="PangoFontDescription"><type>PangoFontDescription</type></link> and Cairo units. The
default value is 96, meaning that a 10 point font will be 13
units high. (10 * 96. / 72. = 13.3).</para>
<refsect3 id="pango-cairo-context-set-resolution.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>dpi</para></entry>
<entry role="parameter_description"><para>the resolution in "dots per inch". (Physical inches aren't actually
involved; the terminology is conventional.) A 0 or negative value
means to use the resolution from the font map.</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-context-get-resolution" role="function" condition="since:1.10">
<title>pango_cairo_context_get_resolution&#160;()</title>
<indexterm zone="pango-cairo-context-get-resolution" role="1.10"><primary>pango_cairo_context_get_resolution</primary></indexterm>
<programlisting language="C"><link linkend="double"><returnvalue>double</returnvalue></link>
pango_cairo_context_get_resolution (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>);</programlisting>
<para>Gets the resolution for the context. See <link linkend="pango-cairo-context-set-resolution"><function>pango_cairo_context_set_resolution()</function></link></para>
<refsect3 id="pango-cairo-context-get-resolution.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-context-get-resolution.returns" role="returns">
<title>Returns</title>
<para> the resolution in "dots per inch". A negative value will
be returned if no resolution has previously been set.</para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-context-set-font-options" role="function" condition="since:1.10">
<title>pango_cairo_context_set_font_options&#160;()</title>
<indexterm zone="pango-cairo-context-set-font-options" role="1.10"><primary>pango_cairo_context_set_font_options</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_context_set_font_options (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>,
                                      <parameter>const <link linkend="cairo-font-options-t"><type>cairo_font_options_t</type></link> *options</parameter>);</programlisting>
<para>Sets the font options used when rendering text with this context.
These options override any options that <link linkend="pango-cairo-update-context"><function>pango_cairo_update_context()</function></link>
derives from the target surface.</para>
<refsect3 id="pango-cairo-context-set-font-options.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>options</para></entry>
<entry role="parameter_description"><para>a <link linkend="cairo-font-options-t"><type>cairo_font_options_t</type></link>, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> to unset
any previously set options. A copy is made. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>nullable</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-context-get-font-options" role="function" condition="since:1.10">
<title>pango_cairo_context_get_font_options&#160;()</title>
<indexterm zone="pango-cairo-context-get-font-options" role="1.10"><primary>pango_cairo_context_get_font_options</primary></indexterm>
<programlisting language="C">const <link linkend="cairo-font-options-t"><returnvalue>cairo_font_options_t</returnvalue></link>&#160;*
pango_cairo_context_get_font_options (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>);</programlisting>
<para>Retrieves any font rendering options previously set with
<link linkend="pango-cairo-context-set-font-options"><function>pango_cairo_context_set_font_options()</function></link>. This function does not report options
that are derived from the target surface by <link linkend="pango-cairo-update-context"><function>pango_cairo_update_context()</function></link></para>
<refsect3 id="pango-cairo-context-get-font-options.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-context-get-font-options.returns" role="returns">
<title>Returns</title>
<para>the font options previously set on the
context, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> if no options have been set. This value is
owned by the context and must not be modified or freed. </para>
<para><emphasis role="annotation">[<acronym>nullable</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="PangoCairoShapeRendererFunc" role="function">
<title>PangoCairoShapeRendererFunc&#160;()</title>
<indexterm zone="PangoCairoShapeRendererFunc"><primary>PangoCairoShapeRendererFunc</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
<phrase role="c_punctuation">(</phrase>*PangoCairoShapeRendererFunc<phrase role="c_punctuation">)</phrase> (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                                <parameter><link linkend="PangoAttrShape"><type>PangoAttrShape</type></link> *attr</parameter>,
                                <parameter><link linkend="gboolean"><type>gboolean</type></link> do_path</parameter>,
                                <parameter><link linkend="gpointer"><type>gpointer</type></link> data</parameter>);</programlisting>
<para>Function type for rendering attributes of type <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link>
with Pango's Cairo renderer.</para>
<refsect3 id="PangoCairoShapeRendererFunc.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context with current point set to where the shape should
be rendered</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>attr</para></entry>
<entry role="parameter_description"><para>the <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link> to render</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>do_path</para></entry>
<entry role="parameter_description"><para>whether only the shape path should be appended to current
path of <parameter>cr</parameter>
and no filling/stroking done.  This will be set
to <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> when called from <link linkend="pango-cairo-layout-path"><function>pango_cairo_layout_path()</function></link> and
<link linkend="pango-cairo-layout-line-path"><function>pango_cairo_layout_line_path()</function></link> rendering functions.</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>data</para></entry>
<entry role="parameter_description"><para>user data passed to <link linkend="pango-cairo-context-set-shape-renderer"><function>pango_cairo_context_set_shape_renderer()</function></link>. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>closure</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>
<refsect2 id="pango-cairo-context-set-shape-renderer" role="function" condition="since:1.18">
<title>pango_cairo_context_set_shape_renderer&#160;()</title>
<indexterm zone="pango-cairo-context-set-shape-renderer" role="1.18"><primary>pango_cairo_context_set_shape_renderer</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_context_set_shape_renderer
                               (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>,
                                <parameter><link linkend="PangoCairoShapeRendererFunc"><type>PangoCairoShapeRendererFunc</type></link> func</parameter>,
                                <parameter><link linkend="gpointer"><type>gpointer</type></link> data</parameter>,
                                <parameter><link linkend="GDestroyNotify"><type>GDestroyNotify</type></link> dnotify</parameter>);</programlisting>
<para>Sets callback function for context to use for rendering attributes
of type <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link>.  See <link linkend="PangoCairoShapeRendererFunc"><type>PangoCairoShapeRendererFunc</type></link> for
details.</para>
<refsect3 id="pango-cairo-context-set-shape-renderer.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>func</para></entry>
<entry role="parameter_description"><para>Callback function for rendering attributes of
type <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link>, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> to disable shape rendering. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>nullable</acronym>]</emphasis></entry></row>
<row><entry role="parameter_name"><para>data</para></entry>
<entry role="parameter_description"><para>User data that will be passed to <parameter>func</parameter>
.</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>dnotify</para></entry>
<entry role="parameter_description"><para>Callback that will be called when the
context is freed to release <parameter>data</parameter>
, or <link linkend="NULL:CAPS"><literal>NULL</literal></link>.</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="pango-cairo-context-get-shape-renderer" role="function" condition="since:1.18">
<title>pango_cairo_context_get_shape_renderer&#160;()</title>
<indexterm zone="pango-cairo-context-get-shape-renderer" role="1.18"><primary>pango_cairo_context_get_shape_renderer</primary></indexterm>
<programlisting language="C"><link linkend="PangoCairoShapeRendererFunc"><returnvalue>PangoCairoShapeRendererFunc</returnvalue></link>
pango_cairo_context_get_shape_renderer
                               (<parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>,
                                <parameter><link linkend="gpointer"><type>gpointer</type></link> *data</parameter>);</programlisting>
<para>Sets callback function for context to use for rendering attributes
of type <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link>.  See <link linkend="PangoCairoShapeRendererFunc"><type>PangoCairoShapeRendererFunc</type></link> for
details.</para>
<para>Retrieves callback function and associated user data for rendering
attributes of type <link linkend="PANGO-ATTR-SHAPE:CAPS"><literal>PANGO_ATTR_SHAPE</literal></link> as set by
<link linkend="pango-cairo-context-set-shape-renderer"><function>pango_cairo_context_set_shape_renderer()</function></link>, if any.</para>

<para><emphasis role="annotation">[<acronym>skip</acronym>]</emphasis></para><refsect3 id="pango-cairo-context-get-shape-renderer.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>data</para></entry>
<entry role="parameter_description"><para>Pointer to <link linkend="gpointer"><type>gpointer</type></link> to return user data</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-context-get-shape-renderer.returns" role="returns">
<title>Returns</title>
<para>the shape rendering callback previously
set on the context, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> if no shape rendering callback have
been set. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>][<acronym>nullable</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="pango-cairo-create-context" role="function" condition="since:1.22">
<title>pango_cairo_create_context&#160;()</title>
<indexterm zone="pango-cairo-create-context" role="1.22"><primary>pango_cairo_create_context</primary></indexterm>
<programlisting language="C"><link linkend="PangoContext"><returnvalue>PangoContext</returnvalue></link>&#160;*
pango_cairo_create_context (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>);</programlisting>
<para>Creates a context object set up to match the current transformation
and target surface of the Cairo context.  This context can then be
used to create a layout using <link linkend="pango-layout-new"><function>pango_layout_new()</function></link>.</para>
<para>This function is a convenience function that creates a context using
the default font map, then updates it to <parameter>cr</parameter>
.  If you just need to
create a layout for use with <parameter>cr</parameter>
 and do not need to access <link linkend="PangoContext"><type>PangoContext</type></link>
directly, you can use <link linkend="pango-cairo-create-layout"><function>pango_cairo_create_layout()</function></link> instead.</para>
<refsect3 id="pango-cairo-create-context.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-create-context.returns" role="returns">
<title>Returns</title>
<para>the newly created <link linkend="PangoContext"><type>PangoContext</type></link>. Free with
<link linkend="g-object-unref"><function>g_object_unref()</function></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.22">1.22</link></para></refsect2>
<refsect2 id="pango-cairo-update-context" role="function" condition="since:1.10">
<title>pango_cairo_update_context&#160;()</title>
<indexterm zone="pango-cairo-update-context" role="1.10"><primary>pango_cairo_update_context</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_update_context (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                            <parameter><link linkend="PangoContext"><type>PangoContext</type></link> *context</parameter>);</programlisting>
<para>Updates a <link linkend="PangoContext"><type>PangoContext</type></link> previously created for use with Cairo to
match the current transformation and target surface of a Cairo
context. If any layouts have been created for the context,
it's necessary to call <link linkend="pango-layout-context-changed"><function>pango_layout_context_changed()</function></link> on those
layouts.</para>
<refsect3 id="pango-cairo-update-context.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>context</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoContext"><type>PangoContext</type></link>, from a pangocairo font map</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-create-layout" role="function" condition="since:1.10">
<title>pango_cairo_create_layout&#160;()</title>
<indexterm zone="pango-cairo-create-layout" role="1.10"><primary>pango_cairo_create_layout</primary></indexterm>
<programlisting language="C"><link linkend="PangoLayout"><returnvalue>PangoLayout</returnvalue></link>&#160;*
pango_cairo_create_layout (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>);</programlisting>
<para>Creates a layout object set up to match the current transformation
and target surface of the Cairo context.  This layout can then be
used for text measurement with functions like
<link linkend="pango-layout-get-size"><function>pango_layout_get_size()</function></link> or drawing with functions like
<link linkend="pango-cairo-show-layout"><function>pango_cairo_show_layout()</function></link>. If you change the transformation
or target surface for <parameter>cr</parameter>
, you need to call <link linkend="pango-cairo-update-layout"><function>pango_cairo_update_layout()</function></link></para>
<para>This function is the most convenient way to use Cairo with Pango,
however it is slightly inefficient since it creates a separate
<link linkend="PangoContext"><type>PangoContext</type></link> object for each layout. This might matter in an
application that was laying out large amounts of text.</para>
<refsect3 id="pango-cairo-create-layout.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="pango-cairo-create-layout.returns" role="returns">
<title>Returns</title>
<para>the newly created <link linkend="PangoLayout"><type>PangoLayout</type></link>. Free with
<link linkend="g-object-unref"><function>g_object_unref()</function></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-update-layout" role="function" condition="since:1.10">
<title>pango_cairo_update_layout&#160;()</title>
<indexterm zone="pango-cairo-update-layout" role="1.10"><primary>pango_cairo_update_layout</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_update_layout (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                           <parameter><link linkend="PangoLayout"><type>PangoLayout</type></link> *layout</parameter>);</programlisting>
<para>Updates the private <link linkend="PangoContext"><type>PangoContext</type></link> of a <link linkend="PangoLayout"><type>PangoLayout</type></link> created with
<link linkend="pango-cairo-create-layout"><function>pango_cairo_create_layout()</function></link> to match the current transformation
and target surface of a Cairo context.</para>
<refsect3 id="pango-cairo-update-layout.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>layout</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoLayout"><type>PangoLayout</type></link>, from <link linkend="pango-cairo-create-layout"><function>pango_cairo_create_layout()</function></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-show-glyph-string" role="function" condition="since:1.10">
<title>pango_cairo_show_glyph_string&#160;()</title>
<indexterm zone="pango-cairo-show-glyph-string" role="1.10"><primary>pango_cairo_show_glyph_string</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_show_glyph_string (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                               <parameter><link linkend="PangoFont"><type>PangoFont</type></link> *font</parameter>,
                               <parameter><link linkend="PangoGlyphString"><type>PangoGlyphString</type></link> *glyphs</parameter>);</programlisting>
<para>Draws the glyphs in <parameter>glyphs</parameter>
 in the specified cairo context.
The origin of the glyphs (the left edge of the baseline) will
be drawn at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-show-glyph-string.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>font</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoFont"><type>PangoFont</type></link> from a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>glyphs</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-show-glyph-item" role="function" condition="since:1.22">
<title>pango_cairo_show_glyph_item&#160;()</title>
<indexterm zone="pango-cairo-show-glyph-item" role="1.22"><primary>pango_cairo_show_glyph_item</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_show_glyph_item (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                             <parameter>const <link linkend="char"><type>char</type></link> *text</parameter>,
                             <parameter><link linkend="PangoGlyphItem"><type>PangoGlyphItem</type></link> *glyph_item</parameter>);</programlisting>
<para>Draws the glyphs in <parameter>glyph_item</parameter>
 in the specified cairo context,
embedding the text associated with the glyphs in the output if the
output format supports it (PDF for example), otherwise it acts
similar to <link linkend="pango-cairo-show-glyph-string"><function>pango_cairo_show_glyph_string()</function></link>.</para>
<para>The origin of the glyphs (the left edge of the baseline) will
be drawn at the current point of the cairo context.</para>
<para>Note that <parameter>text</parameter>
 is the start of the text for layout, which is then
indexed by <literal><parameter>glyph_item->item->offset</parameter>
</literal>.</para>
<refsect3 id="pango-cairo-show-glyph-item.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>text</para></entry>
<entry role="parameter_description"><para>the UTF-8 text that <parameter>glyph_item</parameter>
refers to</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>glyph_item</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoGlyphItem"><type>PangoGlyphItem</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.22">1.22</link></para></refsect2>
<refsect2 id="pango-cairo-show-layout-line" role="function" condition="since:1.10">
<title>pango_cairo_show_layout_line&#160;()</title>
<indexterm zone="pango-cairo-show-layout-line" role="1.10"><primary>pango_cairo_show_layout_line</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_show_layout_line (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                              <parameter><link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link> *line</parameter>);</programlisting>
<para>Draws a <link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link> in the specified cairo context.
The origin of the glyphs (the left edge of the line) will
be drawn at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-show-layout-line.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>line</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-show-layout" role="function" condition="since:1.10">
<title>pango_cairo_show_layout&#160;()</title>
<indexterm zone="pango-cairo-show-layout" role="1.10"><primary>pango_cairo_show_layout</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_show_layout (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                         <parameter><link linkend="PangoLayout"><type>PangoLayout</type></link> *layout</parameter>);</programlisting>
<para>Draws a <link linkend="PangoLayout"><type>PangoLayout</type></link> in the specified cairo context.
The top-left corner of the <link linkend="PangoLayout"><type>PangoLayout</type></link> will be drawn
at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-show-layout.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>layout</para></entry>
<entry role="parameter_description"><para>a Pango layout</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-show-error-underline" role="function" condition="since:1.14">
<title>pango_cairo_show_error_underline&#160;()</title>
<indexterm zone="pango-cairo-show-error-underline" role="1.14"><primary>pango_cairo_show_error_underline</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_show_error_underline (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> x</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> y</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> width</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> height</parameter>);</programlisting>
<para>Draw a squiggly line in the specified cairo context that approximately
covers the given rectangle in the style of an underline used to indicate a
spelling error.  (The width of the underline is rounded to an integer
number of up/down segments and the resulting rectangle is centered in the
original rectangle)</para>
<refsect3 id="pango-cairo-show-error-underline.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>x</para></entry>
<entry role="parameter_description"><para>The X coordinate of one corner of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>y</para></entry>
<entry role="parameter_description"><para>The Y coordinate of one corner of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>width</para></entry>
<entry role="parameter_description"><para>Non-negative width of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>height</para></entry>
<entry role="parameter_description"><para>Non-negative height of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.14">1.14</link></para></refsect2>
<refsect2 id="pango-cairo-glyph-string-path" role="function" condition="since:1.10">
<title>pango_cairo_glyph_string_path&#160;()</title>
<indexterm zone="pango-cairo-glyph-string-path" role="1.10"><primary>pango_cairo_glyph_string_path</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_glyph_string_path (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                               <parameter><link linkend="PangoFont"><type>PangoFont</type></link> *font</parameter>,
                               <parameter><link linkend="PangoGlyphString"><type>PangoGlyphString</type></link> *glyphs</parameter>);</programlisting>
<para>Adds the glyphs in <parameter>glyphs</parameter>
 to the current path in the specified
cairo context. The origin of the glyphs (the left edge of the baseline)
will be at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-glyph-string-path.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>font</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoFont"><type>PangoFont</type></link> from a <link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>glyphs</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-layout-line-path" role="function" condition="since:1.10">
<title>pango_cairo_layout_line_path&#160;()</title>
<indexterm zone="pango-cairo-layout-line-path" role="1.10"><primary>pango_cairo_layout_line_path</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_layout_line_path (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                              <parameter><link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link> *line</parameter>);</programlisting>
<para>Adds the text in <link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link> to the current path in the
specified cairo context.  The origin of the glyphs (the left edge
of the line) will be at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-layout-line-path.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>line</para></entry>
<entry role="parameter_description"><para>a <link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-layout-path" role="function" condition="since:1.10">
<title>pango_cairo_layout_path&#160;()</title>
<indexterm zone="pango-cairo-layout-path" role="1.10"><primary>pango_cairo_layout_path</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_layout_path (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                         <parameter><link linkend="PangoLayout"><type>PangoLayout</type></link> *layout</parameter>);</programlisting>
<para>Adds the text in a <link linkend="PangoLayout"><type>PangoLayout</type></link> to the current path in the
specified cairo context.  The top-left corner of the <link linkend="PangoLayout"><type>PangoLayout</type></link>
will be at the current point of the cairo context.</para>
<refsect3 id="pango-cairo-layout-path.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>layout</para></entry>
<entry role="parameter_description"><para>a Pango layout</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>
<refsect2 id="pango-cairo-error-underline-path" role="function" condition="since:1.14">
<title>pango_cairo_error_underline_path&#160;()</title>
<indexterm zone="pango-cairo-error-underline-path" role="1.14"><primary>pango_cairo_error_underline_path</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
pango_cairo_error_underline_path (<parameter><link linkend="cairo-t"><type>cairo_t</type></link> *cr</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> x</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> y</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> width</parameter>,
                                  <parameter><link linkend="double"><type>double</type></link> height</parameter>);</programlisting>
<para>Add a squiggly line to the current path in the specified cairo context that
approximately covers the given rectangle in the style of an underline used
to indicate a spelling error.  (The width of the underline is rounded to an
integer number of up/down segments and the resulting rectangle is centered
in the original rectangle)</para>
<refsect3 id="pango-cairo-error-underline-path.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>cr</para></entry>
<entry role="parameter_description"><para>a Cairo context</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>x</para></entry>
<entry role="parameter_description"><para>The X coordinate of one corner of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>y</para></entry>
<entry role="parameter_description"><para>The Y coordinate of one corner of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>width</para></entry>
<entry role="parameter_description"><para>Non-negative width of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>height</para></entry>
<entry role="parameter_description"><para>Non-negative height of the rectangle</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><para role="since">Since: <link linkend="api-index-1.14">1.14</link></para></refsect2>

</refsect1>
<refsect1 id="pango-Cairo-Rendering.other_details" role="details">
<title role="details.title">Types and Values</title>
<refsect2 id="PangoCairoFont-struct" role="struct">
<title>PangoCairoFont</title>
<indexterm zone="PangoCairoFont-struct" role="1.18"><primary>PangoCairoFont</primary></indexterm>
<programlisting language="C">typedef struct _PangoCairoFont PangoCairoFont;</programlisting>
<para><link linkend="PangoCairoFont"><type>PangoCairoFont</type></link> is an interface exported by fonts for
use with Cairo. The actual type of the font will depend
on the particular font technology Cairo was compiled to use.</para>
<para role="since">Since: <link linkend="api-index-1.18">1.18</link></para></refsect2>
<refsect2 id="PangoCairoFontMap-struct" role="struct">
<title>PangoCairoFontMap</title>
<indexterm zone="PangoCairoFontMap-struct" role="1.10"><primary>PangoCairoFontMap</primary></indexterm>
<programlisting language="C">typedef struct _PangoCairoFontMap PangoCairoFontMap;</programlisting>
<para><link linkend="PangoCairoFontMap"><type>PangoCairoFontMap</type></link> is an interface exported by font maps for
use with Cairo. The actual type of the font map will depend
on the particular font technology Cairo was compiled to use.</para>
<para role="since">Since: <link linkend="api-index-1.10">1.10</link></para></refsect2>

</refsect1>

</refentry>
