{"id":6907,"date":"2022-12-20T19:34:19","date_gmt":"2022-12-20T22:34:19","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/cairo-man3\/"},"modified":"2022-12-20T19:34:19","modified_gmt":"2022-12-20T22:34:19","slug":"cairo-man3","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/cairo-man3\/","title":{"rendered":"Cairo (man3)"},"content":{"rendered":"<h1 align=\"center\">Cairo<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#ABSTRACT\">ABSTRACT<\/a><br \/> <a href=\"#API DOCUMENTATION\">API DOCUMENTATION<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a><br \/> <a href=\"#AUTHORS\">AUTHORS<\/a><br \/> <a href=\"#COPYRIGHT\">COPYRIGHT<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Cairo \u2212 Perl interface to the cairo 2d vector graphics library<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">use Cairo; <br \/> my $surface = Cairo::ImageSurface\u2212>create (&#8216;argb32&#8217;, 100, 100); <br \/> my $cr = Cairo::Context\u2212>create ($surface); <br \/> $cr\u2212>rectangle (10, 10, 40, 40); <br \/> $cr\u2212>set_source_rgb (0, 0, 0); <br \/> $cr\u2212>fill; <br \/> $cr\u2212>rectangle (50, 50, 40, 40); <br \/> $cr\u2212>set_source_rgb (1, 1, 1); <br \/> $cr\u2212>fill; <br \/> $cr\u2212>show_page; <br \/> $surface\u2212>write_to_png (&#8216;output.png&#8217;);<\/p>\n<h2>ABSTRACT <a name=\"ABSTRACT\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Cairo provides Perl bindings for the vector graphics library cairo. It supports multiple output targets, including <small>PNG, PDF<\/small> and <small>SVG.<\/small> Cairo produces identical output on all those targets.<\/p>\n<h2>API DOCUMENTATION <a name=\"API DOCUMENTATION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">This is a listing of the <small>API<\/small> Cairo provides. For more verbose information, refer to the cairo manual at <http:\/\/cairographics.org\/manual\/>.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Drawing<\/b> <i><br \/> Cairo::Context &#8212; The cairo drawing context<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Cairo::Context<\/i> is the main object used when drawing with Cairo. To draw with Cairo, you create a <i>Cairo::Context<\/i>, set the target surface, and drawing options for the <i>Cairo::Context<\/i>, create shapes with methods like &#8220;$cr\u2212>move_to&#8221; and &#8220;$cr\u2212>line_to&#8221;, and then draw shapes with &#8220;$cr\u2212>stroke&#8221; or &#8220;$cr\u2212>fill&#8221;.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Cairo::Context<\/i>\u2019s can be pushed to a stack via &#8220;$cr\u2212>save&#8221;. They may then safely be changed, without loosing the current state. Use &#8220;$cr\u2212>restore&#8221; to restore to the saved state. <br \/> $cr = Cairo::Context\u2212>create ($surface)<\/p>\n<p style=\"margin-left:17%;\">$surface: <i>Cairo::Surface<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>save <br \/> $cr\u2212>restore <br \/> $status = $cr\u2212>status <br \/> $surface = $cr\u2212>get_target <br \/> $cr\u2212>push_group [1.2] <br \/> $cr\u2212>push_group_with_content ($content) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$content: <i>Cairo::Content<\/i><\/p>\n<p style=\"margin-left:11%;\">$pattern = $cr\u2212>pop_group [1.2] <br \/> $cr\u2212>pop_group_to_source [1.2] <br \/> $surface = $cr\u2212>get_group_target [1.2] <br \/> $cr\u2212>set_source_rgb ($red, $green, $blue)<\/p>\n<p style=\"margin-left:17%;\">$red: double <br \/> $green: double <br \/> $blue: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_source_rgba ($red, $green, $blue, $alpha)<\/p>\n<p style=\"margin-left:17%;\">$red: double <br \/> $green: double <br \/> $blue: double <br \/> $alpha: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_source ($source)<\/p>\n<p style=\"margin-left:17%;\">$source: <i>Cairo::Pattern<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_source_surface ($surface, $x, $y)<\/p>\n<p style=\"margin-left:17%;\">$surface: <i>Cairo::Surface<\/i> <br \/> $x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">$source = $cr\u2212>get_source <br \/> $cr\u2212>set_antialias ($antialias)<\/p>\n<p style=\"margin-left:17%;\">$antialias: <i>Cairo::Antialias<\/i><\/p>\n<p style=\"margin-left:11%;\">$antialias = $cr\u2212>get_antialias <br \/> $cr\u2212>set_dash ($offset, &#8230;)<\/p>\n<p style=\"margin-left:17%;\">$offset: double <br \/> &#8230;: list of doubles<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_fill_rule ($fill_rule)<\/p>\n<p style=\"margin-left:17%;\">$fill_rule: <i>Cairo::FillRule<\/i><\/p>\n<p style=\"margin-left:11%;\">$fill_rule = $cr\u2212>get_fill_rule <br \/> $cr\u2212>set_line_cap ($line_cap)<\/p>\n<p style=\"margin-left:17%;\">$line_cap: <i>Cairo::LineCap<\/i><\/p>\n<p style=\"margin-left:11%;\">$line_cap = $cr\u2212>get_line_cap <br \/> $cr\u2212>set_line_join ($line_join)<\/p>\n<p style=\"margin-left:17%;\">$line_join: <i>Cairo::LineJoin<\/i><\/p>\n<p style=\"margin-left:11%;\">$line_join = $cr\u2212>get_line_join <br \/> $cr\u2212>set_line_width ($width)<\/p>\n<p style=\"margin-left:17%;\">$width: double<\/p>\n<p style=\"margin-left:11%;\">$width = $cr\u2212>get_line_width <br \/> $cr\u2212>set_miter_limit ($limit)<\/p>\n<p style=\"margin-left:17%;\">$limit: double<\/p>\n<p style=\"margin-left:11%;\">($offset, @dashes) = $cr\u2212>get_dash [1.4] <br \/> $limit = $cr\u2212>get_miter_limit <br \/> $cr\u2212>set_operator ($op)<\/p>\n<p style=\"margin-left:17%;\">$op: <i>Cairo::Operator<\/i><\/p>\n<p style=\"margin-left:11%;\">$op = $cr\u2212>get_operator <br \/> $cr\u2212>set_tolerance ($tolerance)<\/p>\n<p style=\"margin-left:17%;\">$tolerance: double<\/p>\n<p style=\"margin-left:11%;\">$tolerance = $cr\u2212>get_tolerance <br \/> $cr\u2212>clip <br \/> $cr\u2212>clip_preserve <br \/> ($x1, $y1, $x2, $y2) = $cr\u2212>clip_extents [1.4] <br \/> $bool = $cr\u2212>in_clip ($x, $y) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">@rectangles = $cr\u2212>copy_clip_rectangle_list [1.4] <br \/> $cr\u2212>reset_clip <br \/> $cr\u2212>fill <br \/> $cr\u2212>fill_preserve <br \/> ($x1, $y1, $x2, $y2) = $cr\u2212>fill_extents <br \/> $bool = $cr\u2212>in_fill ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>mask ($pattern)<\/p>\n<p style=\"margin-left:17%;\">$pattern: <i>Cairo::Pattern<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>mask_surface ($surface, $surface_x, $surface_y)<\/p>\n<p style=\"margin-left:17%;\">$surface: <i>Cairo::Surface<\/i> <br \/> $surface_x: double <br \/> $surface_y: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>paint <br \/> $cr\u2212>paint_with_alpha ($alpha)<\/p>\n<p style=\"margin-left:17%;\">$alpha: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>stroke <br \/> $cr\u2212>stroke_preserve <br \/> ($x1, $y1, $x2, $y2) = $cr\u2212>stroke_extents <br \/> $bool = $cr\u2212>in_stroke ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>tag_begin($name, $atts) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$name: string <br \/> $atts: string<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>tag_end($name) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$name: string<\/p>\n<p style=\"margin-left:11%;\">Predefined names:<\/p>\n<p style=\"margin-left:17%;\">Cairo::TAG_DEST [1.16] <br \/> Cairo::TAG_LINK [1.16]<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>copy_page <br \/> $cr\u2212>show_page<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Paths &#8212; Creating paths and manipulating path data<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">$path = [ <br \/> { type => &#8220;move\u2212to&#8221;, points => [[1, 2]] }, <br \/> { type => &#8220;line\u2212to&#8221;, points => [[3, 4]] }, <br \/> { type => &#8220;curve\u2212to&#8221;, points => [[5, 6], [7, 8], [9, 10]] }, <br \/> &#8230; <br \/> { type => &#8220;close\u2212path&#8221;, points => [] }, <br \/> ];<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Cairo::Path<\/i> is a data structure for holding a path. This data structure serves as the return value for &#8220;$cr\u2212>copy_path&#8221; and &#8220;$cr\u2212>copy_path_flat&#8221; as well the input value for &#8220;$cr\u2212>append_path&#8221;.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Cairo::Path<\/i> is represented as an array reference that contains path elements, represented by hash references with two keys: <i>type<\/i> and <i>points<\/i>. The value for <i>type<\/i> can be either of the following: <br \/> &#8220;move\u2212to&#8221; <br \/> &#8220;line\u2212to&#8221; <br \/> &#8220;curve\u2212to&#8221; <br \/> &#8220;close\u2212path&#8221;<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">The value for <i>points<\/i> is an array reference which contains zero or more points. Points are represented as array references that contain two doubles: <i>x<\/i> and <i>y<\/i>. The necessary number of points depends on the <i>type<\/i> of the path element: <br \/> &#8220;move\u2212to&#8221;: 1 point <br \/> &#8220;line_to&#8221;: 1 point <br \/> &#8220;curve\u2212to&#8221;: 3 points <br \/> &#8220;close\u2212path&#8221;: 0 points<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">The semantics and ordering of the coordinate values are consistent with &#8220;$cr\u2212>move_to&#8221;, &#8220;$cr\u2212>line_to&#8221;, &#8220;$cr\u2212>curve_to&#8221;, and &#8220;$cr\u2212>close_path&#8221;.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Note that the paths returned by Cairo are implemented as tied array references which do <b>not<\/b> support adding, removing or shuffling of path segments. For these operations, you need to make a shallow copy first:<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">my @path_clone = @{$path}; <br \/> # now you can alter @path_clone which ever way you want<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">The points of a single path element can be changed directly, however, without the need for a shallow copy:<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">$path\u2212>[$i]{points} = [[3, 4], [5, 6], [7, 8]]; <br \/> $path = $cr\u2212>copy_path <br \/> $path = $cr\u2212>copy_path_flat <br \/> $cr\u2212>append_path ($path)<\/p>\n<p style=\"margin-left:17%;\">$path: <i>Cairo::Path<\/i><\/p>\n<p style=\"margin-left:11%;\">$bool = $cr\u2212>has_current_point [1.6] <br \/> ($x, $y) = $cr\u2212>get_current_point <br \/> $cr\u2212>new_path <br \/> $cr\u2212>new_sub_path [1.2] <br \/> $cr\u2212>close_path <br \/> ($x1, $y1, $x2, $y2) = $cr\u2212>path_extents [1.6] <br \/> $cr\u2212>arc ($xc, $yc, $radius, $angle1, $angle2)<\/p>\n<p style=\"margin-left:17%;\">$xc: double <br \/> $yc: double <br \/> $radius: double <br \/> $angle1: double <br \/> $angle2: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>arc_negative ($xc, $yc, $radius, $angle1, $angle2)<\/p>\n<p style=\"margin-left:17%;\">$xc: double <br \/> $yc: double <br \/> $radius: double <br \/> $angle1: double <br \/> $angle2: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>curve_to ($x1, $y1, $x2, $y2, $x3, $y3)<\/p>\n<p style=\"margin-left:17%;\">$x1: double <br \/> $y1: double <br \/> $x2: double <br \/> $y2: double <br \/> $x3: double <br \/> $y3: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>line_to ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>move_to ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>rectangle ($x, $y, $width, $height)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double <br \/> $width: double <br \/> $height: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>glyph_path (&#8230;)<\/p>\n<p style=\"margin-left:17%;\">&#8230;: list of <i>Cairo::Glyph<\/i>\u2019s<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>text_path ($utf8)<\/p>\n<p style=\"margin-left:17%;\">$utf8: string in utf8 encoding<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>rel_curve_to ($dx1, $dy1, $dx2, $dy2, $dx3, $dy3)<\/p>\n<p style=\"margin-left:17%;\">$dx1: double <br \/> $dy1: double <br \/> $dx2: double <br \/> $dy2: double <br \/> $dx3: double <br \/> $dy3: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>rel_line_to ($dx, $dy)<\/p>\n<p style=\"margin-left:17%;\">$dx: double <br \/> $dy: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>rel_move_to ($dx, $dy)<\/p>\n<p style=\"margin-left:17%;\">$dx: double <br \/> $dy: double<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Patterns &#8212; Gradients and filtered sources<\/i> <br \/> $status = $pattern\u2212>status <br \/> $type = $pattern\u2212>get_type [1.2] <br \/> $pattern\u2212>set_extend ($extend)<\/p>\n<p style=\"margin-left:17%;\">$extend: <i>Cairo::Extend<\/i><\/p>\n<p style=\"margin-left:11%;\">$extend = $pattern\u2212>get_extend <br \/> $pattern\u2212>set_filter ($filter)<\/p>\n<p style=\"margin-left:17%;\">$filter: <i>Cairo::Filter<\/i><\/p>\n<p style=\"margin-left:11%;\">$filter = $pattern\u2212>get_filter <br \/> $pattern\u2212>set_matrix ($matrix)<\/p>\n<p style=\"margin-left:17%;\">$matrix: <i>Cairo::Matrix<\/i><\/p>\n<p style=\"margin-left:11%;\">$matrix = $pattern\u2212>get_matrix <br \/> $pattern = Cairo::SolidPattern\u2212>create_rgb ($red, $green, $blue)<\/p>\n<p style=\"margin-left:17%;\">$red: double <br \/> $green: double <br \/> $blue: double<\/p>\n<p style=\"margin-left:11%;\">$pattern = Cairo::SolidPattern\u2212>create_rgba ($red, $green, $blue, <br \/> $alpha)<\/p>\n<p style=\"margin-left:17%;\">$red: double <br \/> $green: double <br \/> $blue: double <br \/> $alpha: double<\/p>\n<p style=\"margin-left:11%;\">($r, $g, $b, $a) = $pattern\u2212>get_rgba [1.4] <br \/> $pattern = Cairo::SurfacePattern\u2212>create ($surface)<\/p>\n<p style=\"margin-left:17%;\">$surface: <i>Cairo::Surface<\/i><\/p>\n<p style=\"margin-left:11%;\">$surface = $pattern\u2212>get_surface [1.4] <br \/> $pattern = Cairo::LinearGradient\u2212>create ($x0, $y0, $x1, $y1)<\/p>\n<p style=\"margin-left:17%;\">$x0: double <br \/> $y0: double <br \/> $x1: double <br \/> $y1: double<\/p>\n<p style=\"margin-left:11%;\">($x0, $y0, $x1, $y1) = $pattern\u2212>get_points [1.4] <br \/> $pattern = Cairo::RadialGradient\u2212>create ($cx0, $cy0, $radius0, $cx1, <br \/> $cy1, $radius1)<\/p>\n<p style=\"margin-left:17%;\">$cx0: double <br \/> $cy0: double <br \/> $radius0: double <br \/> $cx1: double <br \/> $cy1: double <br \/> $radius1: double<\/p>\n<p style=\"margin-left:11%;\">($x0, $y0, $r0, $x1, $y1, $r1) = $pattern\u2212>get_circles [1.4] <br \/> $pattern\u2212>add_color_stop_rgb ($offset, $red, $green, $blue)<\/p>\n<p style=\"margin-left:17%;\">$offset: double <br \/> $red: double <br \/> $green: double <br \/> $blue: double<\/p>\n<p style=\"margin-left:11%;\">$pattern\u2212>add_color_stop_rgba ($offset, $red, $green, $blue, $alpha)<\/p>\n<p style=\"margin-left:17%;\">$offset: double <br \/> $red: double <br \/> $green: double <br \/> $blue: double <br \/> $alpha: double<\/p>\n<p style=\"margin-left:11%;\">@stops = $pattern\u2212>get_color_stops [1.4]<\/p>\n<p style=\"margin-left:17%;\">A color stop is represented as an array reference with five elements: offset, red, green, blue, and alpha.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Regions &#8212; Representing a pixel-aligned area<\/i> <br \/> $region = Cairo::Region\u2212>create (&#8230;) [1.10]<\/p>\n<p style=\"margin-left:17%;\">&#8230;: zero or more <i>Cairo::RectangleInt<\/i><\/p>\n<p style=\"margin-left:11%;\">$status = $region\u2212>status [1.10] <br \/> $num = $region\u2212>num_rectangles [1.10] <br \/> $rect = $region\u2212>get_rectangle ($i) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$i: integer<\/p>\n<p style=\"margin-left:11%;\">$bool = $region\u2212>is_empty [1.10] <br \/> $bool = $region\u2212>contains_point ($x, $y) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$x: integer <br \/> $y: integer<\/p>\n<p style=\"margin-left:11%;\">$bool = $region_one\u2212>equal ($region_two) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$region_two: <i>Cairo::Region<\/i><\/p>\n<p style=\"margin-left:11%;\">$region\u2212>translate ($dx, $dy) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$dx: integer <br \/> $dy: integer<\/p>\n<p style=\"margin-left:11%;\">$status = $dst\u2212>intersect ($other) [1.10] <br \/> $status = $dst\u2212>intersect_rectangle ($rect) [1.10] <br \/> $status = $dst\u2212>subtract ($other) [1.10] <br \/> $status = $dst\u2212>subtract_rectangle ($rect) [1.10] <br \/> $status = $dst\u2212>union ($other) [1.10] <br \/> $status = $dst\u2212>union_rectangle ($rect) [1.10] <br \/> $status = $dst\u2212>xor ($other) [1.10] <br \/> $status = $dst\u2212>xor_rectangle ($rect) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$other: <i>Cairo::Region<\/i> <br \/> $rect: <i>Cairo::RectangleInt<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Transformations &#8212; Manipulating the current transformation matrix<\/i> <br \/> $cr\u2212>translate ($tx, $ty)<\/p>\n<p style=\"margin-left:17%;\">$tx: double <br \/> $ty: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>scale ($sx, $sy)<\/p>\n<p style=\"margin-left:17%;\">$sx: double <br \/> $sy: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>rotate ($angle)<\/p>\n<p style=\"margin-left:17%;\">$angle: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>transform ($matrix)<\/p>\n<p style=\"margin-left:17%;\">$matrix: <i>Cairo::Matrix<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_matrix ($matrix)<\/p>\n<p style=\"margin-left:17%;\">$matrix: <i>Cairo::Matrix<\/i><\/p>\n<p style=\"margin-left:11%;\">$matrix = $cr\u2212>get_matrix <br \/> $cr\u2212>identity_matrix <br \/> ($x, $y) = $cr\u2212>user_to_device ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">($dx, $dy) = $cr\u2212>user_to_device_distance ($dx, $dy)<\/p>\n<p style=\"margin-left:17%;\">$dx: double <br \/> $dy: double<\/p>\n<p style=\"margin-left:11%;\">($x, $y) = $cr\u2212>device_to_user ($x, $y)<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double<\/p>\n<p style=\"margin-left:11%;\">($dx, $dy) = $cr\u2212>device_to_user_distance ($dx, $dy)<\/p>\n<p style=\"margin-left:17%;\">$dx: double <br \/> $dy: double<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Text &#8212; Rendering text and sets of glyphs<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Glyphs are represented as anonymous hash references with three keys: <i>index<\/i>, <i>x<\/i> and <i>y<\/i>. Example:<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">my @glyphs = ({ index => 1, x => 2, y => 3 }, <br \/> { index => 2, x => 3, y => 4 }, <br \/> { index => 3, x => 4, y => 5 }); <br \/> $cr\u2212>select_font_face ($family, $slant, $weight)<\/p>\n<p style=\"margin-left:17%;\">$family: string <br \/> $slant: <i>Cairo::FontSlant<\/i> <br \/> $weight: <i>Cairo::FontWeight<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_font_size ($size)<\/p>\n<p style=\"margin-left:17%;\">$size: double<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_font_matrix ($matrix)<\/p>\n<p style=\"margin-left:17%;\">$matrix: <i>Cairo::Matrix<\/i><\/p>\n<p style=\"margin-left:11%;\">$matrix = $cr\u2212>get_font_matrix <br \/> $cr\u2212>set_font_options ($options)<\/p>\n<p style=\"margin-left:17%;\">$options: <i>Cairo::FontOptions<\/i><\/p>\n<p style=\"margin-left:11%;\">$options = $cr\u2212>get_font_options <br \/> $cr\u2212>set_scaled_font ($scaled_font) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$scaled_font: <i>Cairo::ScaledFont<\/i><\/p>\n<p style=\"margin-left:11%;\">$scaled_font = $cr\u2212>get_scaled_font [1.4] <br \/> $cr\u2212>show_text ($utf8)<\/p>\n<p style=\"margin-left:17%;\">$utf8: string<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>show_glyphs (&#8230;)<\/p>\n<p style=\"margin-left:17%;\">&#8230;: list of glyphs<\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>show_text_glyphs ($utf8, $glyphs, $clusters, $cluster_flags) [1.8]<\/p>\n<p style=\"margin-left:17%;\">$utf8: string <br \/> $glyphs: array ref of glyphs <br \/> $clusters: array ref of clusters <br \/> $cluster_flags: <i>Cairo::TextClusterFlags<\/i><\/p>\n<p style=\"margin-left:11%;\">$face = $cr\u2212>get_font_face <br \/> $extents = $cr\u2212>font_extents <br \/> $cr\u2212>set_font_face ($font_face)<\/p>\n<p style=\"margin-left:17%;\">$font_face: <i>Cairo::FontFace<\/i><\/p>\n<p style=\"margin-left:11%;\">$cr\u2212>set_scaled_font ($scaled_font)<\/p>\n<p style=\"margin-left:17%;\">$scaled_font: <i>Cairo::ScaledFont<\/i><\/p>\n<p style=\"margin-left:11%;\">$extents = $cr\u2212>text_extents ($utf8)<\/p>\n<p style=\"margin-left:17%;\">$utf8: string<\/p>\n<p style=\"margin-left:11%;\">$extents = $cr\u2212>glyph_extents (&#8230;)<\/p>\n<p style=\"margin-left:17%;\">&#8230;: list of glyphs<\/p>\n<p style=\"margin-left:11%;\">$face = Cairo::ToyFontFace\u2212>create ($family, $slant, $weight) [1.8]<\/p>\n<p style=\"margin-left:17%;\">$family: string <br \/> $slant: <i>Cairo::FontSlant<\/i> <br \/> $weight: <i>Cairo::FontWeight<\/i><\/p>\n<p style=\"margin-left:11%;\">$family = $face\u2212>get_family [1.8] <br \/> $slang = $face\u2212>get_slant [1.8] <br \/> $weight = $face\u2212>get_weight [1.8]<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Fonts<\/b> <i><br \/> Cairo::FontFace &#8212; Base class for fonts<\/i> <br \/> $status = $font_face\u2212>status <br \/> $type = $font_face\u2212>get_type [1.2]<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Scaled Fonts &#8212; Caching metrics for a particular font size<\/i> <br \/> $scaled_font = Cairo::ScaledFont\u2212>create ($font_face, $font_matrix, <br \/> $ctm, $options)<\/p>\n<p style=\"margin-left:17%;\">$font_face: <i>Cairo::FontFace<\/i> <br \/> $font_matrix: <i>Cairo::Matrix<\/i> <br \/> $ctm: <i>Cairo::Matrix<\/i> <br \/> $options: <i>Cairo::FontOptions<\/i><\/p>\n<p style=\"margin-left:11%;\">$status = $scaled_font\u2212>status <br \/> $extents = $scaled_font\u2212>extents <br \/> $extents = $scaled_font\u2212>text_extents ($utf8) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$utf8: string<\/p>\n<p style=\"margin-left:11%;\">$extents = $scaled_font\u2212>glyph_extents (&#8230;)<\/p>\n<p style=\"margin-left:17%;\">&#8230;: list of glyphs<\/p>\n<p style=\"margin-left:11%;\">($status, $glyphs, $clusters, $cluster_flags) = <br \/> $scaled_font\u2212>text_to_glyphs ($x, $y, $utf8) [1.8]<\/p>\n<p style=\"margin-left:17%;\">$x: double <br \/> $y: double <br \/> $utf8: string<\/p>\n<p style=\"margin-left:11%;\">$font_face = $scaled_font\u2212>get_font_face [1.2] <br \/> $options = $scaled_font\u2212>get_font_options [1.2] <br \/> $font_matrix = $scaled_font\u2212>get_font_matrix [1.2] <br \/> $ctm = $scaled_font\u2212>get_ctm [1.2] <br \/> $scale_matrix = $scaled_font\u2212>get_scale_matrix [1.8] <br \/> $type = $scaled_font\u2212>get_type [1.2]<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Font Options &#8212; How a font should be rendered<\/i> <br \/> $font_options = Cairo::FontOptions\u2212>create <br \/> $status = $font_options\u2212>status <br \/> $font_options\u2212>merge ($other)<\/p>\n<p style=\"margin-left:17%;\">$other: <i>Cairo::FontOptions<\/i><\/p>\n<p style=\"margin-left:11%;\">$hash = $font_options\u2212>hash <br \/> $bools = $font_options\u2212>equal ($other)<\/p>\n<p style=\"margin-left:17%;\">$other: <i>Cairo::FontOptions<\/i><\/p>\n<p style=\"margin-left:11%;\">$font_options\u2212>set_antialias ($antialias)<\/p>\n<p style=\"margin-left:17%;\">$antialias: <i>Cairo::AntiAlias<\/i><\/p>\n<p style=\"margin-left:11%;\">$antialias = $font_options\u2212>get_antialias <br \/> $font_options\u2212>set_subpixel_order ($subpixel_order)<\/p>\n<p style=\"margin-left:17%;\">$subpixel_order: <i>Cairo::SubpixelOrder<\/i><\/p>\n<p style=\"margin-left:11%;\">$subpixel_order = $font_options\u2212>get_subpixel_order <br \/> $font_options\u2212>set_hint_style ($hint_style)<\/p>\n<p style=\"margin-left:17%;\">$hint_style: <i>Cairo::HintStyle<\/i><\/p>\n<p style=\"margin-left:11%;\">$hint_style = $font_options\u2212>get_hint_style <br \/> $font_options\u2212>set_hint_metrics ($hint_metrics)<\/p>\n<p style=\"margin-left:17%;\">$hint_metrics: <i>Cairo::HintMetrics<\/i><\/p>\n<p style=\"margin-left:11%;\">$hint_metrics = $font_options\u2212>get_hint_metrics<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>FreeType Fonts &#8212; Font support for FreeType<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">If your cairo library supports it, the FreeType integration allows you to load font faces from font files. You can query for this capability with &#8220;Cairo::HAS_FT_FONT&#8221;. To actually use this, you\u2019ll need the Font::FreeType module. <br \/> my $face = Cairo::FtFontFace\u2212>create ($ft_face, $load_flags=0)<\/p>\n<p style=\"margin-left:17%;\">$ft_face: <i>Font::FreeType::Face<\/i> <br \/> $load_flags: integer<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">This method allows you to create a <i>Cairo::FontFace<\/i> from a <i>Font::FreeType::Face<\/i>. To obtain the latter, you can for example load it from a file:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">my $file = &#8216;\/usr\/share\/fonts\/truetype\/ttf\u2212bitstream\u2212vera\/Vera.ttf&#8217;; <br \/> my $ft_face = Font::FreeType\u2212>new\u2212>face ($file); <br \/> my $face = Cairo::FtFontFace\u2212>create ($ft_face);<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Surfaces<\/b> <i><br \/> Cairo::Surface &#8212; Base class for surfaces<\/i> <br \/> $similar = Cairo::Surface\u2212>create_similar ($other, $content, $width, <br \/> $height)<\/p>\n<p style=\"margin-left:17%;\">$other: <i>Cairo::Surface<\/i> <br \/> $content: <i>Cairo::Content<\/i> <br \/> $width: integer <br \/> $height: integer<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">For hysterical reasons, you can also use the following syntax:<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">$similar = $other\u2212>create_similar ($content, $width, $height)<\/p>\n<p style=\"margin-left:11%;\">$new = Cairo::Surface\u2212>create_for_rectangle ($target, $x, $y, $width, <br \/> $height) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$target: <i>Cairo::Surface<\/i> <br \/> $x: double <br \/> $y: double <br \/> $width: double <br \/> $height: double<\/p>\n<p style=\"margin-left:11%;\">$status = $surface\u2212>status <br \/> $surface\u2212>finish <br \/> $surface\u2212>flush <br \/> $font_options = $surface\u2212>get_font_options <br \/> $content = $surface\u2212>get_content [1.2] <br \/> $surface\u2212>mark_dirty <br \/> $surface\u2212>mark_dirty_rectangle ($x, $y, $width, $height)<\/p>\n<p style=\"margin-left:17%;\">$x: integer <br \/> $y: integer <br \/> $width: integer <br \/> $height: integer<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_device_offset ($x_offset, $y_offset)<\/p>\n<p style=\"margin-left:17%;\">$x_offset: integer <br \/> $y_offset: integer<\/p>\n<p style=\"margin-left:11%;\">($x_offset, $y_offset) = $surface\u2212>get_device_offset [1.2] <br \/> $surface\u2212>set_fallback_resolution ($x_pixels_per_inch, <br \/> $y_pixels_per_inch) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$x_pixels_per_inch: double <br \/> $y_pixels_per_inch: double<\/p>\n<p style=\"margin-left:11%;\">($x_pixels_per_inch, $y_pixels_per_inch) = <br \/> $surface\u2212>get_fallback_resolution [1.8] <br \/> $type = $surface\u2212>get_type [1.2] <br \/> $surface\u2212>set_mime_data ($mime_type, $mime_data) [1.10] <br \/> $mime_data = $surface\u2212>get_mime_data ($mime_type) [1.10] <br \/> $bool = $surface\u2212>supports_mime_type ($mime_type) [1.12]<\/p>\n<p style=\"margin-left:17%;\">$mime_type: string<\/p>\n<p style=\"margin-left:23%;\">Predefined <small>MIME<\/small> types:<\/p>\n<p style=\"margin-left:29%;\">Cairo::Surface::MIME_TYPE_JP2 [1.10] <br \/> Cairo::Surface::MIME_TYPE_JPEG [1.10] <br \/> Cairo::Surface::MIME_TYPE_PNG [1.10] <br \/> Cairo::Surface::MIME_TYPE_URI [1.10] <br \/> Cairo::Surface::MIME_TYPE_UNIQUE_ID [1.12] <br \/> Cairo::Surface::MIME_TYPE_JBIG2 [1.14] <br \/> Cairo::Surface::MIME_TYPE_JBIG2_GLOBAL [1.14] <br \/> Cairo::Surface::MIME_TYPE_JBIG2_GLOBAL_PARAMS [1.14] <br \/> Cairo::Surface::MIME_TYPE_CCITT_FAX [1.16] <br \/> Cairo::Surface::MIME_TYPE_CCITT_FAX_PARAMS [1.16] <br \/> Cairo::Surface::MIME_TYPE_EPS [1.16] <br \/> Cairo::Surface::MIME_TYPE_EPS_PARAMS [1.16]<\/p>\n<p style=\"margin-left:17%;\">$mime_data: binary data string<\/p>\n<p style=\"margin-left:11%;\">$status = $surface\u2212>copy_page [1.6]<\/p>\n<p style=\"margin-left:17%;\">$status: <i>Cairo::Status<\/i><\/p>\n<p style=\"margin-left:11%;\">$status = $surface\u2212>show_page [1.6]<\/p>\n<p style=\"margin-left:17%;\">$status: <i>Cairo::Status<\/i><\/p>\n<p style=\"margin-left:11%;\">$boolean = $surface\u2212>has_show_text_glyphs [1.8]<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Image Surfaces &#8212; Rendering to memory buffers<\/i> <br \/> $surface = Cairo::ImageSurface\u2212>create ($format, $width, $height)<\/p>\n<p style=\"margin-left:17%;\">$format: <i>Cairo::Format<\/i> <br \/> $width: integer <br \/> $height: integer<\/p>\n<p style=\"margin-left:11%;\">$surface = Cairo::ImageSurface\u2212>create_for_data ($data, $format, <br \/> $width, $height, $stride)<\/p>\n<p style=\"margin-left:17%;\">$data: image data <br \/> $format: <i>Cairo::Format<\/i> <br \/> $width: integer <br \/> $height: integer <br \/> $stride: integer<\/p>\n<p style=\"margin-left:11%;\">$data = $surface\u2212>get_data [1.2] <br \/> $format = $surface\u2212>get_format [1.2] <br \/> $width = $surface\u2212>get_width <br \/> $height = $surface\u2212>get_height <br \/> $stride = $surface\u2212>get_stride [1.2] <br \/> $stride = Cairo::Format::stride_for_width ($format, $width) [1.6]<\/p>\n<p style=\"margin-left:17%;\">$format: <i>Cairo::Format<\/i> <br \/> $width: integer<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i><small>PDF<\/small> Surfaces &#8212; Rendering <small>PDF<\/small> documents<\/i> <br \/> $surface = Cairo::PdfSurface\u2212>create ($filename, $width_in_points, <br \/> $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$filename: string <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface = Cairo::PdfSurface\u2212>create_for_stream ($callback, <br \/> $callback_data, $width_in_points, $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$callback: <i>Cairo::WriteFunc<\/i> <br \/> $callback_data: scalar <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_size ($width_in_points, $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>restrict_to_version ($version) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$version: <i>Cairo::PdfVersion<\/i><\/p>\n<p style=\"margin-left:11%;\">@versions = Cairo::PdfSurface::get_versions [1.10] <br \/> $string = Cairo::PdfSurface::version_to_string ($version) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$version: <i>Cairo::PdfVersion<\/i><\/p>\n<p style=\"margin-left:11%;\">$item_id = $surface\u2212>add_outline($parent_id, $name, $attributes, <br \/> $flags) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$item_id: int, item <small>ID<\/small> <br \/> $parent_id: parent item id or Cairo::PdfSurface::OUTLINE_ROOT <br \/> $name: string, item display <br \/> $attributes: string, item attributes <br \/> $flags: list reference, item flags<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_metadata($name, $value) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$name: string <br \/> $value: string<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_page_label($label) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$label: string, page label<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_thumbnail_size($width, $height) [1.16]<\/p>\n<p style=\"margin-left:17%;\">$width: int, thumbnail width <br \/> $height: int, thumbnail height<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i><small>PNG<\/small> Support &#8212; Reading and writing <small>PNG<\/small> images<\/i> <br \/> $surface = Cairo::ImageSurface\u2212>create_from_png ($filename)<\/p>\n<p style=\"margin-left:17%;\">$filename: string<\/p>\n<p style=\"margin-left:11%;\">Cairo::ReadFunc: $data = sub { my ($callback_data, $length) = @_; }<\/p>\n<p style=\"margin-left:17%;\">$data: binary image data, of length $length <br \/> $callback_data: scalar, user data <br \/> $length: integer, bytes to read<\/p>\n<p style=\"margin-left:11%;\">$surface = Cairo::ImageSurface\u2212>create_from_png_stream ($callback, <br \/> $callback_data)<\/p>\n<p style=\"margin-left:17%;\">$callback: <i>Cairo::ReadFunc<\/i> <br \/> $callback_data: scalar<\/p>\n<p style=\"margin-left:11%;\">$status = $surface\u2212>write_to_png ($filename)<\/p>\n<p style=\"margin-left:17%;\">$filename: string<\/p>\n<p style=\"margin-left:11%;\">Cairo::WriteFunc: sub { my ($callback_data, $data) = @_; }<\/p>\n<p style=\"margin-left:17%;\">$callback_data: scalar, user data <br \/> $data: binary image data, to be written<\/p>\n<p style=\"margin-left:11%;\">$status = $surface\u2212>write_to_png_stream ($callback, $callback_data)<\/p>\n<p style=\"margin-left:17%;\">$callback: <i>Cairo::WriteFunc<\/i> <br \/> $callback_data: scalar<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>PostScript Surfaces &#8212; Rendering PostScript documents<\/i> <br \/> $surface = Cairo::PsSurface\u2212>create ($filename, $width_in_points, <br \/> $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$filename: string <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface = Cairo::PsSurface\u2212>create_for_stream ($callback, <br \/> $callback_data, $width_in_points, $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$callback: <i>Cairo::WriteFunc<\/i> <br \/> $callback_data: scalar <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_size ($width_in_points, $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>dsc_begin_setup [1.2] <br \/> $surface\u2212>dsc_begin_page_setup [1.2] <br \/> $surface\u2212>dsc_comment ($comment) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$comment: string<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>restrict_to_level ($level) [1.6]<\/p>\n<p style=\"margin-left:17%;\">$level: <i>Cairo::PsLevel<\/i><\/p>\n<p style=\"margin-left:11%;\">@levels = Cairo::PsSurface::get_levels [1.6] <br \/> $string = Cairo::PsSurface::level_to_string ($level) [1.6]<\/p>\n<p style=\"margin-left:17%;\">$level: <i>Cairo::PsLevel<\/i><\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>set_eps ($eps) [1.6]<\/p>\n<p style=\"margin-left:17%;\">$eps: boolean<\/p>\n<p style=\"margin-left:11%;\">$eps = $surface\u2212>get_eps [1.6]<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>Recording Surfaces &#8212; Records all drawing operations<\/i> <br \/> $surface = Cairo::RecordingSurface\u2212>create ($content, $extents) [1.10]<\/p>\n<p style=\"margin-left:17%;\">$content: <i>Cairo::Content<\/i> <br \/> $extents: <i>Cairo::Rectangle<\/i><\/p>\n<p style=\"margin-left:11%;\">($x0, $y0, $width, $height) = $surface\u2212>ink_extents [1.10] <br \/> $extents_ref = $surface\u2212>get_extents [1.12]<\/p>\n<p style=\"margin-left:17%;\">$extents_ref: <i>Cairo::Rectangle<\/i> reference<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><i><small>SVG<\/small> Surfaces &#8212; Rendering <small>SVG<\/small> documents<\/i> <br \/> $surface = Cairo::SvgSurface\u2212>create ($filename, $width_in_points, <br \/> $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$filename: string <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface = Cairo::SvgSurface\u2212>create_for_stream ($callback, <br \/> $callback_data, $width_in_points, $height_in_points) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$callback: <i>Cairo::WriteFunc<\/i> <br \/> $callback_data: scalar <br \/> $width_in_points: double <br \/> $height_in_points: double<\/p>\n<p style=\"margin-left:11%;\">$surface\u2212>restrict_to_version ($version) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$version: <i>Cairo::SvgVersion<\/i><\/p>\n<p style=\"margin-left:11%;\">@versions = Cairo::SvgSurface::get_versions [1.2] <br \/> $string = Cairo::SvgSurface::version_to_string ($version) [1.2]<\/p>\n<p style=\"margin-left:17%;\">$version: <i>Cairo::SvgVersion<\/i><\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Utilities<\/b> <i><br \/> Version Information &#8212; Run-time and compile-time version checks.<\/i> <br \/> $version_code = Cairo\u2212>lib_version <br \/> $version_string = Cairo\u2212>lib_version_string<\/p>\n<p style=\"margin-left:17%;\">These two functions return the version of libcairo that the program is currently running against.<\/p>\n<p style=\"margin-left:11%;\">$version_code = Cairo\u2212> <small>LIB_VERSION<\/small><\/p>\n<p style=\"margin-left:17%;\">Returns the version of libcairo that Cairo was compiled against.<\/p>\n<p style=\"margin-left:11%;\">$version_code = Cairo\u2212> <small>LIB_VERSION_ENCODE<\/small> ($major, $minor, $micro)<\/p>\n<p style=\"margin-left:17%;\">$major: integer <br \/> $minor: integer <br \/> $micro: integer<\/p>\n<p style=\"margin-left:17%; margin-top: 1em\">Encodes the version &#8220;$major.$minor.$micro&#8221; as an integer suitable for comparison against &#8220;Cairo\u2212>lib_version&#8221; and &#8220;Cairo\u2212>LIB_VERSION&#8221;.<\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><http:\/\/cairographics.org\/documentation><\/p>\n<p style=\"margin-left:17%;\">Lists many available resources including tutorials and examples<\/p>\n<p style=\"margin-left:11%;\"><http:\/\/cairographics.org\/manual\/><\/p>\n<p style=\"margin-left:17%;\">Contains the reference manual<\/p>\n<h2>AUTHORS <a name=\"AUTHORS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Ross McFarland <rwmcfa1 at neces dot com> <br \/> Torsten Schoenfeld <kaffeetisch at gmx dot de><\/p>\n<h2>COPYRIGHT <a name=\"COPYRIGHT\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Copyright (C) 2004\u22122013 by the cairo perl team<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  Cairo \u2212 Perl interface to the cairo 2d vector graphics library <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[3266,3007],"class_list":["post-6907","post","type-post","status-publish","format-standard","hentry","category-sin-categoria","tag-cairo","tag-man3"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6907","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=6907"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/6907\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=6907"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=6907"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=6907"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}