cairo 1.14.1-x86-mingw32 → 1.14.2-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of cairo might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/NEWS +21 -0
- data/Rakefile +18 -7
- data/ext/cairo/cairo.def +1 -0
- data/ext/cairo/extconf.rb +23 -10
- data/ext/cairo/rb_cairo.c +3 -0
- data/ext/cairo/rb_cairo.h +3 -3
- data/ext/cairo/rb_cairo_context.c +1 -1
- data/ext/cairo/rb_cairo_io.c +4 -0
- data/ext/cairo/rb_cairo_io.h +2 -0
- data/ext/cairo/rb_cairo_pattern.c +4 -4
- data/ext/cairo/rb_cairo_private.h +2 -0
- data/ext/cairo/rb_cairo_surface.c +64 -232
- data/lib/2.0/cairo.so +0 -0
- data/lib/2.1/cairo.so +0 -0
- data/lib/2.2/cairo.so +0 -0
- data/lib/cairo.rb +20 -19
- data/lib/cairo/region.rb +14 -0
- data/test/test_region.rb +26 -0
- data/vendor/local/bin/fc-cache.exe +0 -0
- data/vendor/local/bin/fc-cat.exe +0 -0
- data/vendor/local/bin/fc-list.exe +0 -0
- data/vendor/local/bin/fc-match.exe +0 -0
- data/vendor/local/bin/fc-pattern.exe +0 -0
- data/vendor/local/bin/fc-query.exe +0 -0
- data/vendor/local/bin/fc-scan.exe +0 -0
- data/vendor/local/bin/fc-validate.exe +0 -0
- data/vendor/local/bin/freetype-config +2 -2
- data/vendor/local/bin/libcairo-2.dll +0 -0
- data/vendor/local/bin/libcairo-gobject-2.dll +0 -0
- data/vendor/local/bin/libcairo-script-interpreter-2.dll +0 -0
- data/vendor/local/bin/libfontconfig-1.dll +0 -0
- data/vendor/local/bin/libfreetype-6.dll +0 -0
- data/vendor/local/bin/libgcc_s_sjlj-1.dll +0 -0
- data/vendor/local/bin/libpixman-1-0.dll +0 -0
- data/vendor/local/bin/libpng-config +1 -1
- data/vendor/local/bin/libpng16-16.dll +0 -0
- data/vendor/local/bin/libpng16-config +1 -1
- data/vendor/local/bin/libstdc++-6.dll +0 -0
- data/vendor/local/bin/libwinpthread-1.dll +0 -0
- data/vendor/local/bin/libxml2-2.dll +0 -0
- data/vendor/local/bin/png-fix-itxt.exe +0 -0
- data/vendor/local/bin/pngfix.exe +0 -0
- data/vendor/local/bin/xmlcatalog.exe +0 -0
- data/vendor/local/bin/xmllint.exe +0 -0
- data/vendor/local/bin/zlib1.dll +0 -0
- data/vendor/local/include/cairo/cairo-version.h +1 -1
- data/vendor/local/include/freetype2/config/ftconfig.h +19 -2
- data/vendor/local/include/freetype2/config/ftheader.h +7 -5
- data/vendor/local/include/freetype2/config/ftoption.h +9 -22
- data/vendor/local/include/freetype2/config/ftstdlib.h +2 -3
- data/vendor/local/include/freetype2/freetype.h +38 -17
- data/vendor/local/include/freetype2/ft2build.h +1 -1
- data/vendor/local/include/freetype2/ftadvanc.h +2 -2
- data/vendor/local/include/freetype2/ftautoh.h +50 -2
- data/vendor/local/include/freetype2/ftbbox.h +1 -1
- data/vendor/local/include/freetype2/ftbdf.h +1 -1
- data/vendor/local/include/freetype2/ftbitmap.h +11 -3
- data/vendor/local/include/freetype2/ftbzip2.h +1 -1
- data/vendor/local/include/freetype2/ftcache.h +3 -3
- data/vendor/local/include/freetype2/ftcffdrv.h +1 -1
- data/vendor/local/include/freetype2/ftcid.h +2 -1
- data/vendor/local/include/freetype2/fterrdef.h +1 -1
- data/vendor/local/include/freetype2/fterrors.h +1 -1
- data/vendor/local/include/freetype2/{ftxf86.h → ftfntfmt.h} +22 -14
- data/vendor/local/include/freetype2/ftgasp.h +1 -1
- data/vendor/local/include/freetype2/ftglyph.h +1 -1
- data/vendor/local/include/freetype2/ftgxval.h +1 -1
- data/vendor/local/include/freetype2/ftgzip.h +1 -1
- data/vendor/local/include/freetype2/ftimage.h +7 -13
- data/vendor/local/include/freetype2/ftincrem.h +1 -1
- data/vendor/local/include/freetype2/ftlcdfil.h +2 -2
- data/vendor/local/include/freetype2/ftlist.h +1 -1
- data/vendor/local/include/freetype2/ftlzw.h +1 -1
- data/vendor/local/include/freetype2/ftmac.h +1 -1
- data/vendor/local/include/freetype2/ftmm.h +17 -11
- data/vendor/local/include/freetype2/ftmodapi.h +4 -2
- data/vendor/local/include/freetype2/ftmoderr.h +1 -1
- data/vendor/local/include/freetype2/ftotval.h +1 -1
- data/vendor/local/include/freetype2/ftoutln.h +1 -1
- data/vendor/local/include/freetype2/ftpfr.h +1 -1
- data/vendor/local/include/freetype2/ftrender.h +3 -8
- data/vendor/local/include/freetype2/ftsizes.h +1 -1
- data/vendor/local/include/freetype2/ftsnames.h +1 -1
- data/vendor/local/include/freetype2/ftstroke.h +1 -1
- data/vendor/local/include/freetype2/ftsynth.h +5 -3
- data/vendor/local/include/freetype2/ftsystem.h +10 -1
- data/vendor/local/include/freetype2/fttrigon.h +1 -1
- data/vendor/local/include/freetype2/ftttdrv.h +85 -22
- data/vendor/local/include/freetype2/fttypes.h +1 -1
- data/vendor/local/include/freetype2/ftwinfnt.h +3 -3
- data/vendor/local/include/freetype2/t1tables.h +4 -3
- data/vendor/local/include/freetype2/ttnameid.h +116 -116
- data/vendor/local/include/freetype2/tttables.h +2 -2
- data/vendor/local/include/freetype2/tttags.h +1 -1
- data/vendor/local/include/freetype2/ttunpat.h +1 -1
- data/vendor/local/include/libpng16/png.h +63 -80
- data/vendor/local/include/libpng16/pngconf.h +8 -30
- data/vendor/local/include/libpng16/pnglibconf.h +10 -4
- data/vendor/local/include/png.h +63 -80
- data/vendor/local/include/pngconf.h +8 -30
- data/vendor/local/include/pnglibconf.h +10 -4
- data/vendor/local/lib/libcairo-gobject.a +0 -0
- data/vendor/local/lib/libcairo-gobject.dll.a +0 -0
- data/vendor/local/lib/libcairo-gobject.la +2 -2
- data/vendor/local/lib/libcairo-script-interpreter.a +0 -0
- data/vendor/local/lib/libcairo-script-interpreter.dll.a +0 -0
- data/vendor/local/lib/libcairo-script-interpreter.la +2 -2
- data/vendor/local/lib/libcairo.a +0 -0
- data/vendor/local/lib/libcairo.dll.a +0 -0
- data/vendor/local/lib/libcairo.la +2 -2
- data/vendor/local/lib/libfontconfig.dll.a +0 -0
- data/vendor/local/lib/libfreetype.a +0 -0
- data/vendor/local/lib/libfreetype.dll.a +0 -0
- data/vendor/local/lib/libfreetype.la +4 -4
- data/vendor/local/lib/libpixman-1.a +0 -0
- data/vendor/local/lib/libpixman-1.dll.a +0 -0
- data/vendor/local/lib/libpng.a +0 -0
- data/vendor/local/lib/libpng.dll.a +0 -0
- data/vendor/local/lib/libpng.la +4 -4
- data/vendor/local/lib/libpng16.a +0 -0
- data/vendor/local/lib/libpng16.dll.a +0 -0
- data/vendor/local/lib/libpng16.la +4 -4
- data/vendor/local/lib/libxml2.a +0 -0
- data/vendor/local/lib/libxml2.dll.a +0 -0
- data/vendor/local/lib/libz.a +0 -0
- data/vendor/local/lib/libz.dll.a +0 -0
- data/vendor/local/lib/pkgconfig/cairo-fc.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-ft.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-gobject.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-pdf.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-png.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-ps.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-script.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-svg.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-win32-font.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo-win32.pc +1 -1
- data/vendor/local/lib/pkgconfig/cairo.pc +1 -1
- data/vendor/local/lib/pkgconfig/freetype2.pc +1 -1
- data/vendor/local/lib/pkgconfig/libpng.pc +1 -1
- data/vendor/local/lib/pkgconfig/libpng16.pc +1 -1
- data/vendor/local/share/aclocal/freetype2.m4 +1 -1
- data/vendor/local/share/gtk-doc/html/cairo/bindings-errors.html +12 -12
- data/vendor/local/share/gtk-doc/html/cairo/bindings-fonts.html +12 -12
- data/vendor/local/share/gtk-doc/html/cairo/bindings-memory.html +12 -12
- data/vendor/local/share/gtk-doc/html/cairo/bindings-overloading.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/bindings-path.html +12 -12
- data/vendor/local/share/gtk-doc/html/cairo/bindings-patterns.html +35 -35
- data/vendor/local/share/gtk-doc/html/cairo/bindings-return-values.html +10 -10
- data/vendor/local/share/gtk-doc/html/cairo/bindings-streams.html +11 -11
- data/vendor/local/share/gtk-doc/html/cairo/bindings-surfaces.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Error-handling.html +294 -225
- data/vendor/local/share/gtk-doc/html/cairo/cairo-FreeType-Fonts.html +387 -269
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Image-Surfaces.html +432 -302
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PDF-Surfaces.html +325 -217
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PNG-Support.html +298 -193
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Paths.html +1121 -812
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PostScript-Surfaces.html +513 -383
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Quartz-(CGFont)-Fonts.html +126 -83
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Quartz-Surfaces.html +172 -119
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Raster-Sources.html +581 -372
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Recording-Surfaces.html +179 -130
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Regions.html +888 -539
- data/vendor/local/share/gtk-doc/html/cairo/cairo-SVG-Surfaces.html +287 -192
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Script-Surfaces.html +374 -231
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Transformations.html +395 -219
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Types.html +125 -75
- data/vendor/local/share/gtk-doc/html/cairo/cairo-User-Fonts.html +630 -464
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Version-Information.html +225 -200
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Win32-Fonts.html +336 -214
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Win32-Surfaces.html +277 -186
- data/vendor/local/share/gtk-doc/html/cairo/cairo-XCB-Surfaces.html +495 -350
- data/vendor/local/share/gtk-doc/html/cairo/cairo-XLib-Surfaces.html +557 -362
- data/vendor/local/share/gtk-doc/html/cairo/cairo-XLib-XRender-Backend.html +158 -111
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-device-t.html +655 -441
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-font-face-t.html +389 -280
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-font-options-t.html +667 -451
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-matrix-t.html +579 -351
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-pattern-t.html +2006 -1545
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-scaled-font-t.html +892 -618
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-surface-t.html +1624 -1188
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-t.html +2903 -2104
- data/vendor/local/share/gtk-doc/html/cairo/cairo-drawing.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/cairo-fonts.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/cairo-support.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/cairo-surfaces.html +13 -13
- data/vendor/local/share/gtk-doc/html/cairo/cairo-text.html +1115 -758
- data/vendor/local/share/gtk-doc/html/cairo/cairo.devhelp2 +419 -604
- data/vendor/local/share/gtk-doc/html/cairo/home.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/index-1.10.html +56 -56
- data/vendor/local/share/gtk-doc/html/cairo/index-1.12.html +70 -70
- data/vendor/local/share/gtk-doc/html/cairo/index-1.2.html +58 -58
- data/vendor/local/share/gtk-doc/html/cairo/index-1.4.html +39 -39
- data/vendor/local/share/gtk-doc/html/cairo/index-1.6.html +30 -30
- data/vendor/local/share/gtk-doc/html/cairo/index-1.8.html +38 -38
- data/vendor/local/share/gtk-doc/html/cairo/index-all.html +426 -426
- data/vendor/local/share/gtk-doc/html/cairo/index.html +6 -6
- data/vendor/local/share/gtk-doc/html/cairo/index.sgml +234 -325
- data/vendor/local/share/gtk-doc/html/cairo/language-bindings.html +12 -12
- data/vendor/local/share/gtk-doc/html/cairo/left-insensitive.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/left.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/right-insensitive.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/right.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/style.css +221 -26
- data/vendor/local/share/gtk-doc/html/cairo/up-insensitive.png +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/up.png +0 -0
- data/vendor/local/share/license/cairo/README +1 -1
- data/vendor/local/share/license/freetype/README +6 -6
- data/vendor/local/share/license/freetype/README.git +1 -1
- data/vendor/local/share/license/libpng/README +2 -2
- data/vendor/local/share/man/man1/freetype-config.1 +1 -1
- data/vendor/local/share/man/man3/libpng.3 +85 -92
- data/vendor/local/share/man/man3/libpngpf.3 +2 -2
- data/vendor/local/share/man/man5/png.5 +1 -1
- metadata +23 -19
@@ -2,30 +2,27 @@
|
|
2
2
|
<html>
|
3
3
|
<head>
|
4
4
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
5
|
-
<title>XLib-XRender Backend</title>
|
6
|
-
<meta name="generator" content="DocBook XSL Stylesheets V1.
|
5
|
+
<title>Cairo: A Vector Graphics Library: XLib-XRender Backend</title>
|
6
|
+
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
|
7
7
|
<link rel="home" href="index.html" title="Cairo: A Vector Graphics Library">
|
8
8
|
<link rel="up" href="cairo-surfaces.html" title="Surfaces">
|
9
9
|
<link rel="prev" href="cairo-XLib-Surfaces.html" title="XLib Surfaces">
|
10
10
|
<link rel="next" href="cairo-Script-Surfaces.html" title="Script Surfaces">
|
11
|
-
<meta name="generator" content="GTK-Doc V1.
|
11
|
+
<meta name="generator" content="GTK-Doc V1.20 (XML mode)">
|
12
12
|
<link rel="stylesheet" href="style.css" type="text/css">
|
13
13
|
</head>
|
14
14
|
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
15
|
-
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="
|
16
|
-
<
|
17
|
-
<
|
18
|
-
<
|
19
|
-
<
|
20
|
-
|
21
|
-
<td><a accesskey="
|
22
|
-
|
23
|
-
<
|
24
|
-
<a href="
|
25
|
-
|
26
|
-
<a href="#cairo-XLib-XRender-Backend.description" class="shortcut">Description</a>
|
27
|
-
</td></tr>
|
28
|
-
</table>
|
15
|
+
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="10"><tr valign="middle">
|
16
|
+
<td width="100%" align="left" class="shortcuts">
|
17
|
+
<a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span>
|
18
|
+
<a href="#cairo-XLib-XRender-Backend.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span>
|
19
|
+
<a href="#cairo-XLib-XRender-Backend.object-hierarchy" class="shortcut">Object Hierarchy</a></span>
|
20
|
+
</td>
|
21
|
+
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
|
22
|
+
<td><a accesskey="u" href="cairo-surfaces.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
|
23
|
+
<td><a accesskey="p" href="cairo-XLib-Surfaces.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
|
24
|
+
<td><a accesskey="n" href="cairo-Script-Surfaces.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
|
25
|
+
</tr></table>
|
29
26
|
<div class="refentry">
|
30
27
|
<a name="cairo-XLib-XRender-Backend"></a><div class="titlepage"></div>
|
31
28
|
<div class="refnamediv"><table width="100%"><tr>
|
@@ -33,138 +30,188 @@
|
|
33
30
|
<h2><span class="refentrytitle"><a name="cairo-XLib-XRender-Backend.top_of_page"></a>XLib-XRender Backend</span></h2>
|
34
31
|
<p>XLib-XRender Backend — X Window System rendering using XLib and the X Render extension</p>
|
35
32
|
</td>
|
36
|
-
<td valign="top" align="right"></td>
|
33
|
+
<td class="gallery_image" valign="top" align="right"></td>
|
37
34
|
</tr></table></div>
|
38
|
-
<div class="
|
39
|
-
<a name="cairo-XLib-XRender-Backend.
|
40
|
-
<
|
41
|
-
<
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
<
|
49
|
-
|
50
|
-
|
35
|
+
<div class="refsect1">
|
36
|
+
<a name="cairo-XLib-XRender-Backend.functions"></a><h2>Functions</h2>
|
37
|
+
<div class="informaltable"><table width="100%" border="0">
|
38
|
+
<colgroup>
|
39
|
+
<col width="150px" class="functions_return">
|
40
|
+
<col class="functions_name">
|
41
|
+
</colgroup>
|
42
|
+
<tbody>
|
43
|
+
<tr>
|
44
|
+
<td class="function_type">
|
45
|
+
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="returnvalue">cairo_surface_t</span></a> *
|
46
|
+
</td>
|
47
|
+
<td class="function_name">
|
48
|
+
<a class="link" href="cairo-XLib-XRender-Backend.html#cairo-xlib-surface-create-with-xrender-format" title="cairo_xlib_surface_create_with_xrender_format ()">cairo_xlib_surface_create_with_xrender_format</a> <span class="c_punctuation">()</span>
|
49
|
+
</td>
|
50
|
+
</tr>
|
51
|
+
<tr>
|
52
|
+
<td class="function_type">
|
53
|
+
<span class="returnvalue">XRenderPictFormat</span> *
|
54
|
+
</td>
|
55
|
+
<td class="function_name">
|
56
|
+
<a class="link" href="cairo-XLib-XRender-Backend.html#cairo-xlib-surface-get-xrender-format" title="cairo_xlib_surface_get_xrender_format ()">cairo_xlib_surface_get_xrender_format</a> <span class="c_punctuation">()</span>
|
57
|
+
</td>
|
58
|
+
</tr>
|
59
|
+
</tbody>
|
60
|
+
</table></div>
|
51
61
|
</div>
|
52
62
|
<div class="refsect1">
|
53
|
-
<a name="cairo-XLib-XRender-Backend.
|
54
|
-
<
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
</
|
63
|
+
<a name="cairo-XLib-XRender-Backend.other"></a><h2>Types and Values</h2>
|
64
|
+
<div class="informaltable"><table width="100%" border="0">
|
65
|
+
<colgroup>
|
66
|
+
<col width="150px" class="name">
|
67
|
+
<col class="description">
|
68
|
+
</colgroup>
|
69
|
+
<tbody><tr>
|
70
|
+
<td class="define_keyword">#define</td>
|
71
|
+
<td class="function_name"><a class="link" href="cairo-XLib-XRender-Backend.html#CAIRO-HAS-XLIB-XRENDER-SURFACE:CAPS" title="CAIRO_HAS_XLIB_XRENDER_SURFACE">CAIRO_HAS_XLIB_XRENDER_SURFACE</a></td>
|
72
|
+
</tr></tbody>
|
73
|
+
</table></div>
|
62
74
|
</div>
|
63
75
|
<div class="refsect1">
|
64
|
-
<a name="cairo-XLib-XRender-Backend.
|
65
|
-
<
|
66
|
-
<a name="CAIRO-HAS-XLIB-XRENDER-SURFACE:CAPS"></a><h3>CAIRO_HAS_XLIB_XRENDER_SURFACE</h3>
|
67
|
-
<pre class="programlisting">#define CAIRO_HAS_XLIB_XRENDER_SURFACE 1
|
76
|
+
<a name="cairo-XLib-XRender-Backend.object-hierarchy"></a><h2>Object Hierarchy</h2>
|
77
|
+
<pre class="screen">
|
68
78
|
</pre>
|
69
|
-
<p>
|
70
|
-
Defined if the XLib/XRender surface functions are available.
|
71
|
-
This macro can be used to conditionally compile backend-specific code.
|
72
|
-
</p>
|
73
|
-
<p class="since">Since 1.6</p>
|
74
79
|
</div>
|
75
|
-
<
|
80
|
+
<div class="refsect1">
|
81
|
+
<a name="cairo-XLib-XRender-Backend.description"></a><h2>Description</h2>
|
82
|
+
<p>The XLib surface is used to render cairo graphics to X Window System
|
83
|
+
windows and pixmaps using the XLib and Xrender libraries.</p>
|
84
|
+
<p>Note that the XLib surface automatically takes advantage of X Render extension
|
85
|
+
if it is available.</p>
|
86
|
+
</div>
|
87
|
+
<div class="refsect1">
|
88
|
+
<a name="cairo-XLib-XRender-Backend.functions_details"></a><h2>Functions</h2>
|
76
89
|
<div class="refsect2">
|
77
|
-
<a name="cairo-xlib-surface-create-with-xrender-format"></a><h3>cairo_xlib_surface_create_with_xrender_format
|
78
|
-
<pre class="programlisting"><a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="returnvalue">cairo_surface_t</span></a>
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
<
|
86
|
-
Creates an Xlib surface that draws to the given drawable.
|
90
|
+
<a name="cairo-xlib-surface-create-with-xrender-format"></a><h3>cairo_xlib_surface_create_with_xrender_format ()</h3>
|
91
|
+
<pre class="programlisting"><a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="returnvalue">cairo_surface_t</span></a> *
|
92
|
+
cairo_xlib_surface_create_with_xrender_format
|
93
|
+
(<em class="parameter"><code><span class="type">Display</span> *dpy</code></em>,
|
94
|
+
<em class="parameter"><code><span class="type">Drawable</span> drawable</code></em>,
|
95
|
+
<em class="parameter"><code><span class="type">Screen</span> *screen</code></em>,
|
96
|
+
<em class="parameter"><code><span class="type">XRenderPictFormat</span> *format</code></em>,
|
97
|
+
<em class="parameter"><code><span class="type">int</span> width</code></em>,
|
98
|
+
<em class="parameter"><code><span class="type">int</span> height</code></em>);</pre>
|
99
|
+
<p>Creates an Xlib surface that draws to the given drawable.
|
87
100
|
The way that colors are represented in the drawable is specified
|
88
|
-
by the provided picture format
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
</
|
95
|
-
<div class="
|
96
|
-
<
|
101
|
+
by the provided picture format.</p>
|
102
|
+
<p>Note: If <em class="parameter"><code>drawable</code></em>
|
103
|
+
is a Window, then the function
|
104
|
+
<a class="link" href="cairo-XLib-Surfaces.html#cairo-xlib-surface-set-size" title="cairo_xlib_surface_set_size ()"><code class="function">cairo_xlib_surface_set_size()</code></a> must be called whenever the size of the
|
105
|
+
window changes.</p>
|
106
|
+
<div class="refsect3">
|
107
|
+
<a name="id-1.5.14.7.2.6"></a><h4>Parameters</h4>
|
108
|
+
<div class="informaltable"><table width="100%" border="0">
|
109
|
+
<colgroup>
|
110
|
+
<col width="150px" class="parameters_name">
|
111
|
+
<col class="parameters_description">
|
112
|
+
<col width="200px" class="parameters_annotations">
|
113
|
+
</colgroup>
|
97
114
|
<tbody>
|
98
115
|
<tr>
|
99
|
-
<td
|
100
|
-
<td>an X Display</td>
|
101
|
-
</
|
102
|
-
<tr>
|
103
|
-
<td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td>
|
104
|
-
<td>an X Drawable, (a Pixmap or a Window)</td>
|
116
|
+
<td class="parameter_name"><p>dpy</p></td>
|
117
|
+
<td class="parameter_description"><p>an X Display</p></td>
|
118
|
+
<td class="parameter_annotations"> </td>
|
105
119
|
</tr>
|
106
120
|
<tr>
|
107
|
-
<td
|
108
|
-
<td>
|
109
|
-
</td>
|
121
|
+
<td class="parameter_name"><p>drawable</p></td>
|
122
|
+
<td class="parameter_description"><p>an X Drawable, (a Pixmap or a Window)</p></td>
|
123
|
+
<td class="parameter_annotations"> </td>
|
110
124
|
</tr>
|
111
125
|
<tr>
|
112
|
-
<td
|
113
|
-
<td>the
|
114
|
-
|
126
|
+
<td class="parameter_name"><p>screen</p></td>
|
127
|
+
<td class="parameter_description"><p>the X Screen associated with <em class="parameter"><code>drawable</code></em>
|
128
|
+
</p></td>
|
129
|
+
<td class="parameter_annotations"> </td>
|
115
130
|
</tr>
|
116
131
|
<tr>
|
117
|
-
<td
|
118
|
-
<td>the
|
132
|
+
<td class="parameter_name"><p>format</p></td>
|
133
|
+
<td class="parameter_description"><p>the picture format to use for drawing to <em class="parameter"><code>drawable</code></em>
|
134
|
+
. The depth
|
135
|
+
of <em class="parameter"><code>format</code></em>
|
136
|
+
must match the depth of the drawable.</p></td>
|
137
|
+
<td class="parameter_annotations"> </td>
|
119
138
|
</tr>
|
120
139
|
<tr>
|
121
|
-
<td
|
122
|
-
<td>the current
|
140
|
+
<td class="parameter_name"><p>width</p></td>
|
141
|
+
<td class="parameter_description"><p>the current width of <em class="parameter"><code>drawable</code></em>
|
142
|
+
.</p></td>
|
143
|
+
<td class="parameter_annotations"> </td>
|
123
144
|
</tr>
|
124
145
|
<tr>
|
125
|
-
<td
|
126
|
-
<td>the
|
146
|
+
<td class="parameter_name"><p>height</p></td>
|
147
|
+
<td class="parameter_description"><p>the current height of <em class="parameter"><code>drawable</code></em>
|
148
|
+
.</p></td>
|
149
|
+
<td class="parameter_annotations"> </td>
|
127
150
|
</tr>
|
128
151
|
</tbody>
|
129
152
|
</table></div>
|
153
|
+
</div>
|
154
|
+
<div class="refsect3">
|
155
|
+
<a name="id-1.5.14.7.2.7"></a><h4>Returns</h4>
|
156
|
+
<p> the newly created surface</p>
|
157
|
+
<p></p>
|
158
|
+
</div>
|
130
159
|
<p class="since">Since 1.0</p>
|
131
160
|
</div>
|
132
161
|
<hr>
|
133
162
|
<div class="refsect2">
|
134
|
-
<a name="cairo-xlib-surface-get-xrender-format"></a><h3>cairo_xlib_surface_get_xrender_format
|
135
|
-
<pre class="programlisting"><span class="returnvalue">XRenderPictFormat</span>
|
136
|
-
|
137
|
-
<p>
|
138
|
-
|
163
|
+
<a name="cairo-xlib-surface-get-xrender-format"></a><h3>cairo_xlib_surface_get_xrender_format ()</h3>
|
164
|
+
<pre class="programlisting"><span class="returnvalue">XRenderPictFormat</span> *
|
165
|
+
cairo_xlib_surface_get_xrender_format (<em class="parameter"><code><a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a> *surface</code></em>);</pre>
|
166
|
+
<p>Gets the X Render picture format that <em class="parameter"><code>surface</code></em>
|
167
|
+
uses for rendering with the
|
139
168
|
X Render extension. If the surface was created by
|
140
|
-
<a class="link" href="cairo-XLib-XRender-Backend.html#cairo-xlib-surface-create-with-xrender-format" title="cairo_xlib_surface_create_with_xrender_format
|
141
|
-
value is the format passed to that constructor
|
142
|
-
|
143
|
-
<
|
144
|
-
<
|
145
|
-
<
|
146
|
-
<
|
147
|
-
<
|
148
|
-
<
|
149
|
-
</
|
150
|
-
<tr>
|
151
|
-
<td
|
152
|
-
<td
|
153
|
-
|
154
|
-
|
155
|
-
</tr>
|
156
|
-
</tbody>
|
169
|
+
<a class="link" href="cairo-XLib-XRender-Backend.html#cairo-xlib-surface-create-with-xrender-format" title="cairo_xlib_surface_create_with_xrender_format ()"><code class="function">cairo_xlib_surface_create_with_xrender_format()</code></a> originally, the return
|
170
|
+
value is the format passed to that constructor.</p>
|
171
|
+
<div class="refsect3">
|
172
|
+
<a name="id-1.5.14.7.3.5"></a><h4>Parameters</h4>
|
173
|
+
<div class="informaltable"><table width="100%" border="0">
|
174
|
+
<colgroup>
|
175
|
+
<col width="150px" class="parameters_name">
|
176
|
+
<col class="parameters_description">
|
177
|
+
<col width="200px" class="parameters_annotations">
|
178
|
+
</colgroup>
|
179
|
+
<tbody><tr>
|
180
|
+
<td class="parameter_name"><p>surface</p></td>
|
181
|
+
<td class="parameter_description"><p>an xlib surface</p></td>
|
182
|
+
<td class="parameter_annotations"> </td>
|
183
|
+
</tr></tbody>
|
157
184
|
</table></div>
|
185
|
+
</div>
|
186
|
+
<div class="refsect3">
|
187
|
+
<a name="id-1.5.14.7.3.6"></a><h4>Returns</h4>
|
188
|
+
<p> the XRenderPictFormat* associated with <em class="parameter"><code>surface</code></em>
|
189
|
+
,
|
190
|
+
or <code class="literal">NULL</code> if the surface is not an xlib surface
|
191
|
+
or if the X Render extension is not available.</p>
|
192
|
+
<p></p>
|
193
|
+
</div>
|
194
|
+
<p class="since">Since 1.6</p>
|
195
|
+
</div>
|
196
|
+
</div>
|
197
|
+
<div class="refsect1">
|
198
|
+
<a name="cairo-XLib-XRender-Backend.other_details"></a><h2>Types and Values</h2>
|
199
|
+
<div class="refsect2">
|
200
|
+
<a name="CAIRO-HAS-XLIB-XRENDER-SURFACE:CAPS"></a><h3>CAIRO_HAS_XLIB_XRENDER_SURFACE</h3>
|
201
|
+
<pre class="programlisting">#define CAIRO_HAS_XLIB_XRENDER_SURFACE 1
|
202
|
+
</pre>
|
203
|
+
<p>Defined if the XLib/XRender surface functions are available.
|
204
|
+
This macro can be used to conditionally compile backend-specific code.</p>
|
158
205
|
<p class="since">Since 1.6</p>
|
159
206
|
</div>
|
160
207
|
</div>
|
161
208
|
<div class="refsect1">
|
162
209
|
<a name="cairo-XLib-XRender-Backend.see-also"></a><h2>See Also</h2>
|
163
|
-
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>
|
210
|
+
<p><a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a></p>
|
164
211
|
</div>
|
165
212
|
</div>
|
166
213
|
<div class="footer">
|
167
214
|
<hr>
|
168
|
-
Generated by GTK-Doc V1.
|
215
|
+
Generated by GTK-Doc V1.20</div>
|
169
216
|
</body>
|
170
217
|
</html>
|
@@ -2,30 +2,27 @@
|
|
2
2
|
<html>
|
3
3
|
<head>
|
4
4
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
5
|
-
<title>cairo_device_t</title>
|
6
|
-
<meta name="generator" content="DocBook XSL Stylesheets V1.
|
5
|
+
<title>Cairo: A Vector Graphics Library: cairo_device_t</title>
|
6
|
+
<meta name="generator" content="DocBook XSL Stylesheets V1.78.1">
|
7
7
|
<link rel="home" href="index.html" title="Cairo: A Vector Graphics Library">
|
8
8
|
<link rel="up" href="cairo-surfaces.html" title="Surfaces">
|
9
9
|
<link rel="prev" href="cairo-surfaces.html" title="Surfaces">
|
10
10
|
<link rel="next" href="cairo-cairo-surface-t.html" title="cairo_surface_t">
|
11
|
-
<meta name="generator" content="GTK-Doc V1.
|
11
|
+
<meta name="generator" content="GTK-Doc V1.20 (XML mode)">
|
12
12
|
<link rel="stylesheet" href="style.css" type="text/css">
|
13
13
|
</head>
|
14
14
|
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
15
|
-
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="
|
16
|
-
<
|
17
|
-
<
|
18
|
-
<
|
19
|
-
<
|
20
|
-
|
21
|
-
<td><a accesskey="
|
22
|
-
|
23
|
-
<
|
24
|
-
<a href="
|
25
|
-
|
26
|
-
<a href="#cairo-cairo-device-t.description" class="shortcut">Description</a>
|
27
|
-
</td></tr>
|
28
|
-
</table>
|
15
|
+
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="10"><tr valign="middle">
|
16
|
+
<td width="100%" align="left" class="shortcuts">
|
17
|
+
<a href="#" class="shortcut">Top</a><span id="nav_description"> <span class="dim">|</span>
|
18
|
+
<a href="#cairo-cairo-device-t.description" class="shortcut">Description</a></span><span id="nav_hierarchy"> <span class="dim">|</span>
|
19
|
+
<a href="#cairo-cairo-device-t.object-hierarchy" class="shortcut">Object Hierarchy</a></span>
|
20
|
+
</td>
|
21
|
+
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
|
22
|
+
<td><a accesskey="u" href="cairo-surfaces.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
|
23
|
+
<td><a accesskey="p" href="cairo-surfaces.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
|
24
|
+
<td><a accesskey="n" href="cairo-cairo-surface-t.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
|
25
|
+
</tr></table>
|
29
26
|
<div class="refentry">
|
30
27
|
<a name="cairo-cairo-device-t"></a><div class="titlepage"></div>
|
31
28
|
<div class="refnamediv"><table width="100%"><tr>
|
@@ -33,69 +30,205 @@
|
|
33
30
|
<h2><span class="refentrytitle"><a name="cairo-cairo-device-t.top_of_page"></a>cairo_device_t</span></h2>
|
34
31
|
<p>cairo_device_t — interface to underlying rendering system</p>
|
35
32
|
</td>
|
36
|
-
<td valign="top" align="right"></td>
|
33
|
+
<td class="gallery_image" valign="top" align="right"></td>
|
37
34
|
</tr></table></div>
|
38
|
-
<div class="
|
39
|
-
<a name="cairo-cairo-device-t.
|
40
|
-
<
|
41
|
-
<
|
42
|
-
<
|
43
|
-
<
|
44
|
-
|
45
|
-
<
|
46
|
-
|
47
|
-
<
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
<
|
56
|
-
<span class="returnvalue">void</span>
|
57
|
-
|
58
|
-
<
|
59
|
-
<
|
60
|
-
|
61
|
-
|
62
|
-
<
|
63
|
-
<
|
64
|
-
|
65
|
-
|
66
|
-
<
|
67
|
-
|
35
|
+
<div class="refsect1">
|
36
|
+
<a name="cairo-cairo-device-t.functions"></a><h2>Functions</h2>
|
37
|
+
<div class="informaltable"><table width="100%" border="0">
|
38
|
+
<colgroup>
|
39
|
+
<col width="150px" class="functions_return">
|
40
|
+
<col class="functions_name">
|
41
|
+
</colgroup>
|
42
|
+
<tbody>
|
43
|
+
<tr>
|
44
|
+
<td class="function_type">
|
45
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="returnvalue">cairo_device_t</span></a> *
|
46
|
+
</td>
|
47
|
+
<td class="function_name">
|
48
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()">cairo_device_reference</a> <span class="c_punctuation">()</span>
|
49
|
+
</td>
|
50
|
+
</tr>
|
51
|
+
<tr>
|
52
|
+
<td class="function_type">
|
53
|
+
<span class="returnvalue">void</span>
|
54
|
+
</td>
|
55
|
+
<td class="function_name">
|
56
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()">cairo_device_destroy</a> <span class="c_punctuation">()</span>
|
57
|
+
</td>
|
58
|
+
</tr>
|
59
|
+
<tr>
|
60
|
+
<td class="function_type">
|
61
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
62
|
+
</td>
|
63
|
+
<td class="function_name">
|
64
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-status" title="cairo_device_status ()">cairo_device_status</a> <span class="c_punctuation">()</span>
|
65
|
+
</td>
|
66
|
+
</tr>
|
67
|
+
<tr>
|
68
|
+
<td class="function_type">
|
69
|
+
<span class="returnvalue">void</span>
|
70
|
+
</td>
|
71
|
+
<td class="function_name">
|
72
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-finish" title="cairo_device_finish ()">cairo_device_finish</a> <span class="c_punctuation">()</span>
|
73
|
+
</td>
|
74
|
+
</tr>
|
75
|
+
<tr>
|
76
|
+
<td class="function_type">
|
77
|
+
<span class="returnvalue">void</span>
|
78
|
+
</td>
|
79
|
+
<td class="function_name">
|
80
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-flush" title="cairo_device_flush ()">cairo_device_flush</a> <span class="c_punctuation">()</span>
|
81
|
+
</td>
|
82
|
+
</tr>
|
83
|
+
<tr>
|
84
|
+
<td class="function_type">
|
85
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="returnvalue">cairo_device_type_t</span></a>
|
86
|
+
</td>
|
87
|
+
<td class="function_name">
|
88
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()">cairo_device_get_type</a> <span class="c_punctuation">()</span>
|
89
|
+
</td>
|
90
|
+
</tr>
|
91
|
+
<tr>
|
92
|
+
<td class="function_type">unsigned <span class="returnvalue">int</span>
|
93
|
+
</td>
|
94
|
+
<td class="function_name">
|
95
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-reference-count" title="cairo_device_get_reference_count ()">cairo_device_get_reference_count</a> <span class="c_punctuation">()</span>
|
96
|
+
</td>
|
97
|
+
</tr>
|
98
|
+
<tr>
|
99
|
+
<td class="function_type">
|
100
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
101
|
+
</td>
|
102
|
+
<td class="function_name">
|
103
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-set-user-data" title="cairo_device_set_user_data ()">cairo_device_set_user_data</a> <span class="c_punctuation">()</span>
|
104
|
+
</td>
|
105
|
+
</tr>
|
106
|
+
<tr>
|
107
|
+
<td class="function_type">
|
108
|
+
<span class="returnvalue">void</span> *
|
109
|
+
</td>
|
110
|
+
<td class="function_name">
|
111
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-user-data" title="cairo_device_get_user_data ()">cairo_device_get_user_data</a> <span class="c_punctuation">()</span>
|
112
|
+
</td>
|
113
|
+
</tr>
|
114
|
+
<tr>
|
115
|
+
<td class="function_type">
|
116
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
117
|
+
</td>
|
118
|
+
<td class="function_name">
|
119
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()">cairo_device_acquire</a> <span class="c_punctuation">()</span>
|
120
|
+
</td>
|
121
|
+
</tr>
|
122
|
+
<tr>
|
123
|
+
<td class="function_type">
|
124
|
+
<span class="returnvalue">void</span>
|
125
|
+
</td>
|
126
|
+
<td class="function_name">
|
127
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()">cairo_device_release</a> <span class="c_punctuation">()</span>
|
128
|
+
</td>
|
129
|
+
</tr>
|
130
|
+
<tr>
|
131
|
+
<td class="function_type">
|
132
|
+
<span class="returnvalue">double</span>
|
133
|
+
</td>
|
134
|
+
<td class="function_name">
|
135
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-elapsed" title="cairo_device_observer_elapsed ()">cairo_device_observer_elapsed</a> <span class="c_punctuation">()</span>
|
136
|
+
</td>
|
137
|
+
</tr>
|
138
|
+
<tr>
|
139
|
+
<td class="function_type">
|
140
|
+
<span class="returnvalue">double</span>
|
141
|
+
</td>
|
142
|
+
<td class="function_name">
|
143
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-fill-elapsed" title="cairo_device_observer_fill_elapsed ()">cairo_device_observer_fill_elapsed</a> <span class="c_punctuation">()</span>
|
144
|
+
</td>
|
145
|
+
</tr>
|
146
|
+
<tr>
|
147
|
+
<td class="function_type">
|
148
|
+
<span class="returnvalue">double</span>
|
149
|
+
</td>
|
150
|
+
<td class="function_name">
|
151
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-glyphs-elapsed" title="cairo_device_observer_glyphs_elapsed ()">cairo_device_observer_glyphs_elapsed</a> <span class="c_punctuation">()</span>
|
152
|
+
</td>
|
153
|
+
</tr>
|
154
|
+
<tr>
|
155
|
+
<td class="function_type">
|
156
|
+
<span class="returnvalue">double</span>
|
157
|
+
</td>
|
158
|
+
<td class="function_name">
|
159
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-mask-elapsed" title="cairo_device_observer_mask_elapsed ()">cairo_device_observer_mask_elapsed</a> <span class="c_punctuation">()</span>
|
160
|
+
</td>
|
161
|
+
</tr>
|
162
|
+
<tr>
|
163
|
+
<td class="function_type">
|
164
|
+
<span class="returnvalue">double</span>
|
165
|
+
</td>
|
166
|
+
<td class="function_name">
|
167
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-paint-elapsed" title="cairo_device_observer_paint_elapsed ()">cairo_device_observer_paint_elapsed</a> <span class="c_punctuation">()</span>
|
168
|
+
</td>
|
169
|
+
</tr>
|
170
|
+
<tr>
|
171
|
+
<td class="function_type">
|
172
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
173
|
+
</td>
|
174
|
+
<td class="function_name">
|
175
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-print" title="cairo_device_observer_print ()">cairo_device_observer_print</a> <span class="c_punctuation">()</span>
|
176
|
+
</td>
|
177
|
+
</tr>
|
178
|
+
<tr>
|
179
|
+
<td class="function_type">
|
180
|
+
<span class="returnvalue">double</span>
|
181
|
+
</td>
|
182
|
+
<td class="function_name">
|
183
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-observer-stroke-elapsed" title="cairo_device_observer_stroke_elapsed ()">cairo_device_observer_stroke_elapsed</a> <span class="c_punctuation">()</span>
|
184
|
+
</td>
|
185
|
+
</tr>
|
186
|
+
</tbody>
|
187
|
+
</table></div>
|
188
|
+
</div>
|
189
|
+
<div class="refsect1">
|
190
|
+
<a name="cairo-cairo-device-t.other"></a><h2>Types and Values</h2>
|
191
|
+
<div class="informaltable"><table width="100%" border="0">
|
192
|
+
<colgroup>
|
193
|
+
<col width="150px" class="name">
|
194
|
+
<col class="description">
|
195
|
+
</colgroup>
|
196
|
+
<tbody>
|
197
|
+
<tr>
|
198
|
+
<td class="typedef_keyword">typedef</td>
|
199
|
+
<td class="function_name"><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t">cairo_device_t</a></td>
|
200
|
+
</tr>
|
201
|
+
<tr>
|
202
|
+
<td class="datatype_keyword">enum</td>
|
203
|
+
<td class="function_name"><a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t">cairo_device_type_t</a></td>
|
204
|
+
</tr>
|
205
|
+
</tbody>
|
206
|
+
</table></div>
|
207
|
+
</div>
|
208
|
+
<div class="refsect1">
|
209
|
+
<a name="cairo-cairo-device-t.object-hierarchy"></a><h2>Object Hierarchy</h2>
|
210
|
+
<pre class="screen">
|
68
211
|
</pre>
|
69
212
|
</div>
|
70
213
|
<div class="refsect1">
|
71
214
|
<a name="cairo-cairo-device-t.description"></a><h2>Description</h2>
|
72
|
-
<p>
|
73
|
-
Devices are the abstraction Cairo employs for the rendering system
|
215
|
+
<p>Devices are the abstraction Cairo employs for the rendering system
|
74
216
|
used by a <a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>. You can get the device of a surface using
|
75
|
-
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-get-device" title="cairo_surface_get_device
|
76
|
-
|
77
|
-
<p>
|
78
|
-
Devices are created using custom functions specific to the rendering
|
217
|
+
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-get-device" title="cairo_surface_get_device ()"><code class="function">cairo_surface_get_device()</code></a>.</p>
|
218
|
+
<p>Devices are created using custom functions specific to the rendering
|
79
219
|
system you want to use. See the documentation for the surface types
|
80
|
-
for those functions
|
81
|
-
|
82
|
-
<p>
|
83
|
-
An important function that devices fulfill is sharing access to the
|
220
|
+
for those functions.</p>
|
221
|
+
<p>An important function that devices fulfill is sharing access to the
|
84
222
|
rendering system between Cairo and your application. If you want to
|
85
223
|
access a device directly that you used to draw to with Cairo, you must
|
86
|
-
first call <a class="link" href="cairo-cairo-device-t.html#cairo-device-flush" title="cairo_device_flush
|
87
|
-
operations on the device and resets it to a clean state
|
88
|
-
|
89
|
-
<
|
90
|
-
Cairo also provides the functions <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a> and
|
91
|
-
<a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a> to synchronize access to the rendering system
|
224
|
+
first call <a class="link" href="cairo-cairo-device-t.html#cairo-device-flush" title="cairo_device_flush ()"><code class="function">cairo_device_flush()</code></a> to ensure that Cairo finishes all
|
225
|
+
operations on the device and resets it to a clean state.</p>
|
226
|
+
<p>Cairo also provides the functions <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a> and
|
227
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a> to synchronize access to the rendering system
|
92
228
|
in a multithreaded environment. This is done internally, but can also
|
93
|
-
be used by applications
|
94
|
-
|
95
|
-
|
96
|
-
Putting this all together, a function that works with devices should
|
97
|
-
look something like this:
|
98
|
-
</p>
|
229
|
+
be used by applications.</p>
|
230
|
+
<p>Putting this all together, a function that works with devices should
|
231
|
+
look something like this:</p>
|
99
232
|
<div class="informalexample"><pre class="programlisting">
|
100
233
|
void
|
101
234
|
my_device_modifying_function (cairo_device_t *device)
|
@@ -118,519 +251,600 @@ my_device_modifying_function (cairo_device_t *device)
|
|
118
251
|
cairo_device_release (device);
|
119
252
|
}
|
120
253
|
</pre></div>
|
121
|
-
<p>
|
122
|
-
</p>
|
123
|
-
<p>
|
124
|
-
</p>
|
125
|
-
<div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
|
126
|
-
<h3 class="title">Note</h3>
|
127
|
-
<p>Please refer to the documentation of each backend for
|
254
|
+
<div class="note"><p>Please refer to the documentation of each backend for
|
128
255
|
additional usage requirements, guarantees provided, and
|
129
256
|
interactions with existing surface API of the device functions for
|
130
257
|
surfaces of that type.
|
131
|
-
</p>
|
132
|
-
</div>
|
133
|
-
<p>
|
134
|
-
</p>
|
258
|
+
</p></div>
|
135
259
|
</div>
|
136
260
|
<div class="refsect1">
|
137
|
-
<a name="cairo-cairo-device-t.
|
261
|
+
<a name="cairo-cairo-device-t.functions_details"></a><h2>Functions</h2>
|
138
262
|
<div class="refsect2">
|
139
|
-
<a name="cairo-device-
|
140
|
-
<pre class="programlisting"
|
141
|
-
</pre>
|
142
|
-
<p>
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
<code class="function">
|
147
|
-
|
148
|
-
</p>
|
149
|
-
<
|
150
|
-
|
151
|
-
|
152
|
-
<
|
153
|
-
|
154
|
-
<
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
<
|
159
|
-
<
|
160
|
-
<
|
161
|
-
|
162
|
-
<p>
|
163
|
-
Increases the reference count on <em class="parameter"><code>device</code></em> by one. This prevents
|
164
|
-
<em class="parameter"><code>device</code></em> from being destroyed until a matching call to
|
165
|
-
<a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a> is made.
|
166
|
-
</p>
|
167
|
-
<p>
|
168
|
-
The number of references to a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> can be get using
|
169
|
-
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-reference-count" title="cairo_device_get_reference_count ()"><code class="function">cairo_device_get_reference_count()</code></a>.
|
170
|
-
</p>
|
171
|
-
<div class="variablelist"><table border="0">
|
172
|
-
<col align="left" valign="top">
|
173
|
-
<tbody>
|
174
|
-
<tr>
|
175
|
-
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
176
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
177
|
-
</td>
|
178
|
-
</tr>
|
179
|
-
<tr>
|
180
|
-
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
181
|
-
<td>the referenced <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>.</td>
|
182
|
-
</tr>
|
183
|
-
</tbody>
|
263
|
+
<a name="cairo-device-reference"></a><h3>cairo_device_reference ()</h3>
|
264
|
+
<pre class="programlisting"><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="returnvalue">cairo_device_t</span></a> *
|
265
|
+
cairo_device_reference (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
266
|
+
<p>Increases the reference count on <em class="parameter"><code>device</code></em>
|
267
|
+
by one. This prevents
|
268
|
+
<em class="parameter"><code>device</code></em>
|
269
|
+
from being destroyed until a matching call to
|
270
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a> is made.</p>
|
271
|
+
<p>The number of references to a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> can be get using
|
272
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-reference-count" title="cairo_device_get_reference_count ()"><code class="function">cairo_device_get_reference_count()</code></a>.</p>
|
273
|
+
<div class="refsect3">
|
274
|
+
<a name="id-1.5.2.7.2.6"></a><h4>Parameters</h4>
|
275
|
+
<div class="informaltable"><table width="100%" border="0">
|
276
|
+
<colgroup>
|
277
|
+
<col width="150px" class="parameters_name">
|
278
|
+
<col class="parameters_description">
|
279
|
+
<col width="200px" class="parameters_annotations">
|
280
|
+
</colgroup>
|
281
|
+
<tbody><tr>
|
282
|
+
<td class="parameter_name"><p>device</p></td>
|
283
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
284
|
+
<td class="parameter_annotations"> </td>
|
285
|
+
</tr></tbody>
|
184
286
|
</table></div>
|
287
|
+
</div>
|
288
|
+
<div class="refsect3">
|
289
|
+
<a name="id-1.5.2.7.2.7"></a><h4>Returns</h4>
|
290
|
+
<p> the referenced <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>.</p>
|
291
|
+
<p></p>
|
292
|
+
</div>
|
185
293
|
<p class="since">Since 1.10</p>
|
186
294
|
</div>
|
187
295
|
<hr>
|
188
296
|
<div class="refsect2">
|
189
|
-
<a name="cairo-device-destroy"></a><h3>cairo_device_destroy
|
190
|
-
<pre class="programlisting"><span class="returnvalue">void</span>
|
191
|
-
<
|
192
|
-
Decreases the reference count on <em class="parameter"><code>device</code></em>
|
193
|
-
|
194
|
-
<
|
195
|
-
|
196
|
-
<p>
|
197
|
-
This function may acquire devices if the last reference was dropped
|
198
|
-
|
199
|
-
<
|
200
|
-
<
|
297
|
+
<a name="cairo-device-destroy"></a><h3>cairo_device_destroy ()</h3>
|
298
|
+
<pre class="programlisting"><span class="returnvalue">void</span>
|
299
|
+
cairo_device_destroy (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
300
|
+
<p>Decreases the reference count on <em class="parameter"><code>device</code></em>
|
301
|
+
by one. If the result is
|
302
|
+
zero, then <em class="parameter"><code>device</code></em>
|
303
|
+
and all associated resources are freed. See
|
304
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()"><code class="function">cairo_device_reference()</code></a>.</p>
|
305
|
+
<p>This function may acquire devices if the last reference was dropped.</p>
|
306
|
+
<div class="refsect3">
|
307
|
+
<a name="id-1.5.2.7.3.6"></a><h4>Parameters</h4>
|
308
|
+
<div class="informaltable"><table width="100%" border="0">
|
309
|
+
<colgroup>
|
310
|
+
<col width="150px" class="parameters_name">
|
311
|
+
<col class="parameters_description">
|
312
|
+
<col width="200px" class="parameters_annotations">
|
313
|
+
</colgroup>
|
201
314
|
<tbody><tr>
|
202
|
-
<td
|
203
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
204
|
-
</td>
|
315
|
+
<td class="parameter_name"><p>device</p></td>
|
316
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
317
|
+
<td class="parameter_annotations"> </td>
|
205
318
|
</tr></tbody>
|
206
319
|
</table></div>
|
320
|
+
</div>
|
207
321
|
<p class="since">Since 1.10</p>
|
208
322
|
</div>
|
209
323
|
<hr>
|
210
324
|
<div class="refsect2">
|
211
|
-
<a name="cairo-device-status"></a><h3>cairo_device_status
|
212
|
-
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
213
|
-
<
|
214
|
-
Checks whether an error has previously occurred for this
|
215
|
-
device
|
216
|
-
|
217
|
-
<
|
218
|
-
<
|
219
|
-
<
|
220
|
-
<
|
221
|
-
<
|
222
|
-
<
|
223
|
-
</
|
224
|
-
|
225
|
-
<
|
226
|
-
<td><p
|
227
|
-
<td>
|
228
|
-
|
229
|
-
the device is in an error state.</td>
|
230
|
-
</tr>
|
231
|
-
</tbody>
|
325
|
+
<a name="cairo-device-status"></a><h3>cairo_device_status ()</h3>
|
326
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
327
|
+
cairo_device_status (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
328
|
+
<p>Checks whether an error has previously occurred for this
|
329
|
+
device.</p>
|
330
|
+
<div class="refsect3">
|
331
|
+
<a name="id-1.5.2.7.4.5"></a><h4>Parameters</h4>
|
332
|
+
<div class="informaltable"><table width="100%" border="0">
|
333
|
+
<colgroup>
|
334
|
+
<col width="150px" class="parameters_name">
|
335
|
+
<col class="parameters_description">
|
336
|
+
<col width="200px" class="parameters_annotations">
|
337
|
+
</colgroup>
|
338
|
+
<tbody><tr>
|
339
|
+
<td class="parameter_name"><p>device</p></td>
|
340
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
341
|
+
<td class="parameter_annotations"> </td>
|
342
|
+
</tr></tbody>
|
232
343
|
</table></div>
|
344
|
+
</div>
|
345
|
+
<div class="refsect3">
|
346
|
+
<a name="id-1.5.2.7.4.6"></a><h4>Returns</h4>
|
347
|
+
<p> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> on success or an error code if
|
348
|
+
the device is in an error state.</p>
|
349
|
+
<p></p>
|
350
|
+
</div>
|
233
351
|
<p class="since">Since 1.10</p>
|
234
352
|
</div>
|
235
353
|
<hr>
|
236
354
|
<div class="refsect2">
|
237
|
-
<a name="cairo-device-finish"></a><h3>cairo_device_finish
|
238
|
-
<pre class="programlisting"><span class="returnvalue">void</span>
|
239
|
-
<
|
240
|
-
This function finishes the device and drops all references to
|
355
|
+
<a name="cairo-device-finish"></a><h3>cairo_device_finish ()</h3>
|
356
|
+
<pre class="programlisting"><span class="returnvalue">void</span>
|
357
|
+
cairo_device_finish (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
358
|
+
<p>This function finishes the device and drops all references to
|
241
359
|
external resources. All surfaces, fonts and other objects created
|
242
|
-
for this <em class="parameter"><code>device</code></em>
|
243
|
-
|
244
|
-
|
245
|
-
</
|
246
|
-
|
247
|
-
|
248
|
-
|
360
|
+
for this <em class="parameter"><code>device</code></em>
|
361
|
+
will be finished, too.
|
362
|
+
Further operations on the <em class="parameter"><code>device</code></em>
|
363
|
+
will not affect the <em class="parameter"><code>device</code></em>
|
364
|
+
but
|
365
|
+
will instead trigger a <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-DEVICE-FINISHED:CAPS"><code class="literal">CAIRO_STATUS_DEVICE_FINISHED</code></a> error.</p>
|
366
|
+
<p>When the last call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a> decreases the
|
367
|
+
reference count to zero, cairo will call <a class="link" href="cairo-cairo-device-t.html#cairo-device-finish" title="cairo_device_finish ()"><code class="function">cairo_device_finish()</code></a> if
|
249
368
|
it hasn't been called already, before freeing the resources
|
250
|
-
associated with the device
|
251
|
-
|
252
|
-
<
|
253
|
-
|
254
|
-
|
255
|
-
<
|
256
|
-
<col
|
369
|
+
associated with the device.</p>
|
370
|
+
<p>This function may acquire devices.</p>
|
371
|
+
<div class="refsect3">
|
372
|
+
<a name="id-1.5.2.7.5.7"></a><h4>Parameters</h4>
|
373
|
+
<div class="informaltable"><table width="100%" border="0">
|
374
|
+
<colgroup>
|
375
|
+
<col width="150px" class="parameters_name">
|
376
|
+
<col class="parameters_description">
|
377
|
+
<col width="200px" class="parameters_annotations">
|
378
|
+
</colgroup>
|
257
379
|
<tbody><tr>
|
258
|
-
<td
|
259
|
-
<td>the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> to finish</td>
|
380
|
+
<td class="parameter_name"><p>device</p></td>
|
381
|
+
<td class="parameter_description"><p>the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> to finish</p></td>
|
382
|
+
<td class="parameter_annotations"> </td>
|
260
383
|
</tr></tbody>
|
261
384
|
</table></div>
|
385
|
+
</div>
|
262
386
|
<p class="since">Since 1.10</p>
|
263
387
|
</div>
|
264
388
|
<hr>
|
265
389
|
<div class="refsect2">
|
266
|
-
<a name="cairo-device-flush"></a><h3>cairo_device_flush
|
267
|
-
<pre class="programlisting"><span class="returnvalue">void</span>
|
268
|
-
<
|
269
|
-
Finish any pending operations for the device and also restore any
|
390
|
+
<a name="cairo-device-flush"></a><h3>cairo_device_flush ()</h3>
|
391
|
+
<pre class="programlisting"><span class="returnvalue">void</span>
|
392
|
+
cairo_device_flush (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
393
|
+
<p>Finish any pending operations for the device and also restore any
|
270
394
|
temporary modifications cairo has made to the device's state.
|
271
395
|
This function must be called before switching from using the
|
272
396
|
device with Cairo to operating on it directly with native APIs.
|
273
397
|
If the device doesn't support direct access, then this function
|
274
|
-
does nothing
|
275
|
-
|
276
|
-
<
|
277
|
-
|
278
|
-
|
279
|
-
<
|
280
|
-
<col
|
398
|
+
does nothing.</p>
|
399
|
+
<p>This function may acquire devices.</p>
|
400
|
+
<div class="refsect3">
|
401
|
+
<a name="id-1.5.2.7.6.6"></a><h4>Parameters</h4>
|
402
|
+
<div class="informaltable"><table width="100%" border="0">
|
403
|
+
<colgroup>
|
404
|
+
<col width="150px" class="parameters_name">
|
405
|
+
<col class="parameters_description">
|
406
|
+
<col width="200px" class="parameters_annotations">
|
407
|
+
</colgroup>
|
281
408
|
<tbody><tr>
|
282
|
-
<td
|
283
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
284
|
-
</td>
|
409
|
+
<td class="parameter_name"><p>device</p></td>
|
410
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
411
|
+
<td class="parameter_annotations"> </td>
|
285
412
|
</tr></tbody>
|
286
413
|
</table></div>
|
287
|
-
<p class="since">Since 1.10</p>
|
288
414
|
</div>
|
289
|
-
<hr>
|
290
|
-
<div class="refsect2">
|
291
|
-
<a name="cairo-device-type-t"></a><h3>enum cairo_device_type_t</h3>
|
292
|
-
<pre class="programlisting">typedef enum {
|
293
|
-
CAIRO_DEVICE_TYPE_DRM,
|
294
|
-
CAIRO_DEVICE_TYPE_GL,
|
295
|
-
CAIRO_DEVICE_TYPE_SCRIPT,
|
296
|
-
CAIRO_DEVICE_TYPE_XCB,
|
297
|
-
CAIRO_DEVICE_TYPE_XLIB,
|
298
|
-
CAIRO_DEVICE_TYPE_XML,
|
299
|
-
CAIRO_DEVICE_TYPE_COGL,
|
300
|
-
CAIRO_DEVICE_TYPE_WIN32,
|
301
|
-
|
302
|
-
CAIRO_DEVICE_TYPE_INVALID = -1
|
303
|
-
} cairo_device_type_t;
|
304
|
-
</pre>
|
305
|
-
<p>
|
306
|
-
<a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a> is used to describe the type of a given
|
307
|
-
device. The devices types are also known as "backends" within cairo.
|
308
|
-
</p>
|
309
|
-
<p>
|
310
|
-
The device type can be queried with <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()"><code class="function">cairo_device_get_type()</code></a>
|
311
|
-
</p>
|
312
|
-
<p>
|
313
|
-
The various <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> functions can be used with devices of
|
314
|
-
any type, but some backends also provide type-specific functions
|
315
|
-
that must only be called with a device of the appropriate
|
316
|
-
type. These functions have names that begin with
|
317
|
-
<code class="literal">cairo_<span class="emphasis"><em>type</em></span>_device</code> such as
|
318
|
-
<a class="link" href="cairo-XCB-Surfaces.html#cairo-xcb-device-debug-cap-xrender-version" title="cairo_xcb_device_debug_cap_xrender_version ()"><code class="function">cairo_xcb_device_debug_cap_xrender_version()</code></a>.
|
319
|
-
</p>
|
320
|
-
<p>
|
321
|
-
The behavior of calling a type-specific function with a device of
|
322
|
-
the wrong type is undefined.
|
323
|
-
</p>
|
324
|
-
<p>
|
325
|
-
New entries may be added in future versions.
|
326
|
-
</p>
|
327
|
-
<div class="variablelist"><table border="0">
|
328
|
-
<col align="left" valign="top">
|
329
|
-
<tbody>
|
330
|
-
<tr>
|
331
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-DRM:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_DRM</code></span></p></td>
|
332
|
-
<td>The device is of type Direct Render Manager, since 1.10
|
333
|
-
</td>
|
334
|
-
</tr>
|
335
|
-
<tr>
|
336
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-GL:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_GL</code></span></p></td>
|
337
|
-
<td>The device is of type OpenGL, since 1.10
|
338
|
-
</td>
|
339
|
-
</tr>
|
340
|
-
<tr>
|
341
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-SCRIPT:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_SCRIPT</code></span></p></td>
|
342
|
-
<td>The device is of type script, since 1.10
|
343
|
-
</td>
|
344
|
-
</tr>
|
345
|
-
<tr>
|
346
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-XCB:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XCB</code></span></p></td>
|
347
|
-
<td>The device is of type xcb, since 1.10
|
348
|
-
</td>
|
349
|
-
</tr>
|
350
|
-
<tr>
|
351
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-XLIB:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XLIB</code></span></p></td>
|
352
|
-
<td>The device is of type xlib, since 1.10
|
353
|
-
</td>
|
354
|
-
</tr>
|
355
|
-
<tr>
|
356
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-XML:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XML</code></span></p></td>
|
357
|
-
<td>The device is of type XML, since 1.10
|
358
|
-
</td>
|
359
|
-
</tr>
|
360
|
-
<tr>
|
361
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-COGL:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_COGL</code></span></p></td>
|
362
|
-
<td>The device is of type cogl, since 1.12
|
363
|
-
</td>
|
364
|
-
</tr>
|
365
|
-
<tr>
|
366
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-WIN32:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_WIN32</code></span></p></td>
|
367
|
-
<td>The device is of type win32, since 1.12
|
368
|
-
</td>
|
369
|
-
</tr>
|
370
|
-
<tr>
|
371
|
-
<td><p><a name="CAIRO-DEVICE-TYPE-INVALID:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_INVALID</code></span></p></td>
|
372
|
-
<td>The device is invalid, since 1.10
|
373
|
-
</td>
|
374
|
-
</tr>
|
375
|
-
</tbody>
|
376
|
-
</table></div>
|
377
415
|
<p class="since">Since 1.10</p>
|
378
416
|
</div>
|
379
417
|
<hr>
|
380
418
|
<div class="refsect2">
|
381
|
-
<a name="cairo-device-get-type"></a><h3>cairo_device_get_type
|
382
|
-
<pre class="programlisting"><a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="returnvalue">cairo_device_type_t</span></a>
|
383
|
-
<
|
384
|
-
This function returns the type of the device. See <a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a>
|
385
|
-
for available types
|
386
|
-
|
387
|
-
<
|
388
|
-
<
|
389
|
-
<
|
390
|
-
<
|
391
|
-
<
|
392
|
-
<
|
393
|
-
</
|
394
|
-
|
395
|
-
<
|
396
|
-
<td><p
|
397
|
-
<td
|
398
|
-
</tr>
|
399
|
-
</tbody>
|
419
|
+
<a name="cairo-device-get-type"></a><h3>cairo_device_get_type ()</h3>
|
420
|
+
<pre class="programlisting"><a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="returnvalue">cairo_device_type_t</span></a>
|
421
|
+
cairo_device_get_type (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
422
|
+
<p>This function returns the type of the device. See <a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a>
|
423
|
+
for available types.</p>
|
424
|
+
<div class="refsect3">
|
425
|
+
<a name="id-1.5.2.7.7.5"></a><h4>Parameters</h4>
|
426
|
+
<div class="informaltable"><table width="100%" border="0">
|
427
|
+
<colgroup>
|
428
|
+
<col width="150px" class="parameters_name">
|
429
|
+
<col class="parameters_description">
|
430
|
+
<col width="200px" class="parameters_annotations">
|
431
|
+
</colgroup>
|
432
|
+
<tbody><tr>
|
433
|
+
<td class="parameter_name"><p>device</p></td>
|
434
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
435
|
+
<td class="parameter_annotations"> </td>
|
436
|
+
</tr></tbody>
|
400
437
|
</table></div>
|
438
|
+
</div>
|
439
|
+
<div class="refsect3">
|
440
|
+
<a name="id-1.5.2.7.7.6"></a><h4>Returns</h4>
|
441
|
+
<p> The type of <em class="parameter"><code>device</code></em>
|
442
|
+
.</p>
|
443
|
+
<p></p>
|
444
|
+
</div>
|
401
445
|
<p class="since">Since 1.10</p>
|
402
446
|
</div>
|
403
447
|
<hr>
|
404
448
|
<div class="refsect2">
|
405
|
-
<a name="cairo-device-get-reference-count"></a><h3>cairo_device_get_reference_count
|
406
|
-
<pre class="programlisting">unsigned <span class="returnvalue">int</span>
|
407
|
-
<
|
408
|
-
Returns the current reference count of <em class="parameter"><code>device</code></em
|
409
|
-
|
410
|
-
<div class="
|
411
|
-
<
|
412
|
-
<
|
413
|
-
<
|
414
|
-
<
|
415
|
-
<
|
416
|
-
|
417
|
-
</
|
418
|
-
<tr>
|
419
|
-
<td
|
420
|
-
<td>
|
421
|
-
|
422
|
-
</tr>
|
423
|
-
</tbody>
|
449
|
+
<a name="cairo-device-get-reference-count"></a><h3>cairo_device_get_reference_count ()</h3>
|
450
|
+
<pre class="programlisting">unsigned <span class="returnvalue">int</span>
|
451
|
+
cairo_device_get_reference_count (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
452
|
+
<p>Returns the current reference count of <em class="parameter"><code>device</code></em>
|
453
|
+
.</p>
|
454
|
+
<div class="refsect3">
|
455
|
+
<a name="id-1.5.2.7.8.5"></a><h4>Parameters</h4>
|
456
|
+
<div class="informaltable"><table width="100%" border="0">
|
457
|
+
<colgroup>
|
458
|
+
<col width="150px" class="parameters_name">
|
459
|
+
<col class="parameters_description">
|
460
|
+
<col width="200px" class="parameters_annotations">
|
461
|
+
</colgroup>
|
462
|
+
<tbody><tr>
|
463
|
+
<td class="parameter_name"><p>device</p></td>
|
464
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
465
|
+
<td class="parameter_annotations"> </td>
|
466
|
+
</tr></tbody>
|
424
467
|
</table></div>
|
468
|
+
</div>
|
469
|
+
<div class="refsect3">
|
470
|
+
<a name="id-1.5.2.7.8.6"></a><h4>Returns</h4>
|
471
|
+
<p> the current reference count of <em class="parameter"><code>device</code></em>
|
472
|
+
. If the
|
473
|
+
object is a nil object, 0 will be returned.</p>
|
474
|
+
<p></p>
|
475
|
+
</div>
|
425
476
|
<p class="since">Since 1.10</p>
|
426
477
|
</div>
|
427
478
|
<hr>
|
428
479
|
<div class="refsect2">
|
429
|
-
<a name="cairo-device-set-user-data"></a><h3>cairo_device_set_user_data
|
430
|
-
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
<
|
435
|
-
Attach user data to <em class="parameter"><code>device</code></em
|
436
|
-
|
437
|
-
|
438
|
-
</
|
439
|
-
|
440
|
-
<
|
480
|
+
<a name="cairo-device-set-user-data"></a><h3>cairo_device_set_user_data ()</h3>
|
481
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
482
|
+
cairo_device_set_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
483
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>,
|
484
|
+
<em class="parameter"><code><span class="type">void</span> *user_data</code></em>,
|
485
|
+
<em class="parameter"><code><a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> destroy</code></em>);</pre>
|
486
|
+
<p>Attach user data to <em class="parameter"><code>device</code></em>
|
487
|
+
. To remove user data from a surface,
|
488
|
+
call this function with the key that was used to set it and <code class="literal">NULL</code>
|
489
|
+
for <em class="parameter"><code>data</code></em>
|
490
|
+
.</p>
|
491
|
+
<div class="refsect3">
|
492
|
+
<a name="id-1.5.2.7.9.5"></a><h4>Parameters</h4>
|
493
|
+
<div class="informaltable"><table width="100%" border="0">
|
494
|
+
<colgroup>
|
495
|
+
<col width="150px" class="parameters_name">
|
496
|
+
<col class="parameters_description">
|
497
|
+
<col width="200px" class="parameters_annotations">
|
498
|
+
</colgroup>
|
441
499
|
<tbody>
|
442
500
|
<tr>
|
443
|
-
<td
|
444
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
445
|
-
</td>
|
501
|
+
<td class="parameter_name"><p>device</p></td>
|
502
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
503
|
+
<td class="parameter_annotations"> </td>
|
446
504
|
</tr>
|
447
505
|
<tr>
|
448
|
-
<td
|
449
|
-
<td>the address of a <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> to attach the user data to</td>
|
506
|
+
<td class="parameter_name"><p>key</p></td>
|
507
|
+
<td class="parameter_description"><p>the address of a <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> to attach the user data to</p></td>
|
508
|
+
<td class="parameter_annotations"> </td>
|
450
509
|
</tr>
|
451
510
|
<tr>
|
452
|
-
<td
|
453
|
-
<td>the user data to attach to the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
454
|
-
</td>
|
511
|
+
<td class="parameter_name"><p>user_data</p></td>
|
512
|
+
<td class="parameter_description"><p>the user data to attach to the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
513
|
+
<td class="parameter_annotations"> </td>
|
455
514
|
</tr>
|
456
515
|
<tr>
|
457
|
-
<td
|
458
|
-
<td>a <a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t
|
516
|
+
<td class="parameter_name"><p>destroy</p></td>
|
517
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> which will be called when the
|
459
518
|
<a class="link" href="cairo-cairo-t.html#cairo-t" title="cairo_t"><span class="type">cairo_t</span></a> is destroyed or when new user data is attached using the
|
460
|
-
same key.</td>
|
461
|
-
</
|
462
|
-
<tr>
|
463
|
-
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
464
|
-
<td>
|
465
|
-
<a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a> if a
|
466
|
-
slot could not be allocated for the user data.</td>
|
519
|
+
same key.</p></td>
|
520
|
+
<td class="parameter_annotations"> </td>
|
467
521
|
</tr>
|
468
522
|
</tbody>
|
469
523
|
</table></div>
|
524
|
+
</div>
|
525
|
+
<div class="refsect3">
|
526
|
+
<a name="id-1.5.2.7.9.6"></a><h4>Returns</h4>
|
527
|
+
<p> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a> if a
|
528
|
+
slot could not be allocated for the user data.</p>
|
529
|
+
<p></p>
|
530
|
+
</div>
|
470
531
|
<p class="since">Since 1.10</p>
|
471
532
|
</div>
|
472
533
|
<hr>
|
473
534
|
<div class="refsect2">
|
474
|
-
<a name="cairo-device-get-user-data"></a><h3>cairo_device_get_user_data
|
475
|
-
<pre class="programlisting"><span class="returnvalue">void</span>
|
476
|
-
|
477
|
-
<
|
478
|
-
Return user data previously attached to <em class="parameter"><code>device</code></em>
|
535
|
+
<a name="cairo-device-get-user-data"></a><h3>cairo_device_get_user_data ()</h3>
|
536
|
+
<pre class="programlisting"><span class="returnvalue">void</span> *
|
537
|
+
cairo_device_get_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
538
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>);</pre>
|
539
|
+
<p>Return user data previously attached to <em class="parameter"><code>device</code></em>
|
540
|
+
using the
|
479
541
|
specified key. If no user data has been attached with the given
|
480
|
-
key this function returns <
|
481
|
-
|
482
|
-
<
|
483
|
-
<
|
542
|
+
key this function returns <code class="literal">NULL</code>.</p>
|
543
|
+
<div class="refsect3">
|
544
|
+
<a name="id-1.5.2.7.10.5"></a><h4>Parameters</h4>
|
545
|
+
<div class="informaltable"><table width="100%" border="0">
|
546
|
+
<colgroup>
|
547
|
+
<col width="150px" class="parameters_name">
|
548
|
+
<col class="parameters_description">
|
549
|
+
<col width="200px" class="parameters_annotations">
|
550
|
+
</colgroup>
|
484
551
|
<tbody>
|
485
552
|
<tr>
|
486
|
-
<td
|
487
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
488
|
-
</td>
|
489
|
-
</tr>
|
490
|
-
<tr>
|
491
|
-
<td><p><span class="term"><em class="parameter"><code>key</code></em> :</span></p></td>
|
492
|
-
<td>the address of the <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> the user data was
|
493
|
-
attached to</td>
|
553
|
+
<td class="parameter_name"><p>device</p></td>
|
554
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
555
|
+
<td class="parameter_annotations"> </td>
|
494
556
|
</tr>
|
495
557
|
<tr>
|
496
|
-
<td
|
497
|
-
<td>the
|
558
|
+
<td class="parameter_name"><p>key</p></td>
|
559
|
+
<td class="parameter_description"><p>the address of the <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> the user data was
|
560
|
+
attached to</p></td>
|
561
|
+
<td class="parameter_annotations"> </td>
|
498
562
|
</tr>
|
499
563
|
</tbody>
|
500
564
|
</table></div>
|
565
|
+
</div>
|
566
|
+
<div class="refsect3">
|
567
|
+
<a name="id-1.5.2.7.10.6"></a><h4>Returns</h4>
|
568
|
+
<p> the user data previously attached or <code class="literal">NULL</code>.</p>
|
569
|
+
<p></p>
|
570
|
+
</div>
|
501
571
|
<p class="since">Since 1.10</p>
|
502
572
|
</div>
|
503
573
|
<hr>
|
504
574
|
<div class="refsect2">
|
505
|
-
<a name="cairo-device-acquire"></a><h3>cairo_device_acquire
|
506
|
-
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
507
|
-
<
|
508
|
-
Acquires the <em class="parameter"><code>device</code></em>
|
509
|
-
|
510
|
-
|
511
|
-
<p>
|
512
|
-
If the return value is <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, you successfully acquired the
|
575
|
+
<a name="cairo-device-acquire"></a><h3>cairo_device_acquire ()</h3>
|
576
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
577
|
+
cairo_device_acquire (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
578
|
+
<p>Acquires the <em class="parameter"><code>device</code></em>
|
579
|
+
for the current thread. This function will block
|
580
|
+
until no other thread has acquired the device.</p>
|
581
|
+
<p>If the return value is <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, you successfully acquired the
|
513
582
|
device. From now on your thread owns the device and no other thread will be
|
514
|
-
able to acquire it until a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release
|
583
|
+
able to acquire it until a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a>. It is
|
515
584
|
allowed to recursively acquire the device multiple times from the same
|
516
|
-
thread
|
517
|
-
|
518
|
-
<p>
|
519
|
-
</p>
|
520
|
-
<div class="note" style="margin-left: 0.5in; margin-right: 0.5in;">
|
521
|
-
<h3 class="title">Note</h3>
|
522
|
-
<p>You must never acquire two different devices at the same time
|
585
|
+
thread.</p>
|
586
|
+
<div class="note"><p>You must never acquire two different devices at the same time
|
523
587
|
unless this is explicitly allowed. Otherwise the possibility of deadlocks
|
524
588
|
exist.
|
525
|
-
|
526
|
-
<p>
|
589
|
+
|
527
590
|
As various Cairo functions can acquire devices when called, these functions
|
528
591
|
may also cause deadlocks when you call them with an acquired device. So you
|
529
592
|
must not have a device acquired when calling them. These functions are
|
530
593
|
marked in the documentation.
|
531
|
-
</p>
|
594
|
+
</p></div>
|
595
|
+
<div class="refsect3">
|
596
|
+
<a name="id-1.5.2.7.11.7"></a><h4>Parameters</h4>
|
597
|
+
<div class="informaltable"><table width="100%" border="0">
|
598
|
+
<colgroup>
|
599
|
+
<col width="150px" class="parameters_name">
|
600
|
+
<col class="parameters_description">
|
601
|
+
<col width="200px" class="parameters_annotations">
|
602
|
+
</colgroup>
|
603
|
+
<tbody><tr>
|
604
|
+
<td class="parameter_name"><p>device</p></td>
|
605
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
606
|
+
<td class="parameter_annotations"> </td>
|
607
|
+
</tr></tbody>
|
608
|
+
</table></div>
|
532
609
|
</div>
|
533
|
-
<
|
534
|
-
</
|
535
|
-
<
|
536
|
-
<col align="left" valign="top">
|
537
|
-
<tbody>
|
538
|
-
<tr>
|
539
|
-
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
540
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
541
|
-
</td>
|
542
|
-
</tr>
|
543
|
-
<tr>
|
544
|
-
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
545
|
-
<td>
|
546
|
-
<a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> on success or an error code if
|
610
|
+
<div class="refsect3">
|
611
|
+
<a name="id-1.5.2.7.11.8"></a><h4>Returns</h4>
|
612
|
+
<p> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> on success or an error code if
|
547
613
|
the device is in an error state and could not be
|
548
|
-
acquired. After a successful call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire
|
549
|
-
a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release
|
550
|
-
|
551
|
-
</
|
552
|
-
</table></div>
|
614
|
+
acquired. After a successful call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a>,
|
615
|
+
a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a> is required.</p>
|
616
|
+
<p></p>
|
617
|
+
</div>
|
553
618
|
<p class="since">Since 1.10</p>
|
554
619
|
</div>
|
555
620
|
<hr>
|
556
621
|
<div class="refsect2">
|
557
|
-
<a name="cairo-device-release"></a><h3>cairo_device_release
|
558
|
-
<pre class="programlisting"><span class="returnvalue">void</span>
|
559
|
-
<
|
560
|
-
Releases a <em class="parameter"><code>device</code></em>
|
561
|
-
|
562
|
-
|
563
|
-
<div class="
|
564
|
-
<
|
622
|
+
<a name="cairo-device-release"></a><h3>cairo_device_release ()</h3>
|
623
|
+
<pre class="programlisting"><span class="returnvalue">void</span>
|
624
|
+
cairo_device_release (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
625
|
+
<p>Releases a <em class="parameter"><code>device</code></em>
|
626
|
+
previously acquired using <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a>. See
|
627
|
+
that function for details.</p>
|
628
|
+
<div class="refsect3">
|
629
|
+
<a name="id-1.5.2.7.12.5"></a><h4>Parameters</h4>
|
630
|
+
<div class="informaltable"><table width="100%" border="0">
|
631
|
+
<colgroup>
|
632
|
+
<col width="150px" class="parameters_name">
|
633
|
+
<col class="parameters_description">
|
634
|
+
<col width="200px" class="parameters_annotations">
|
635
|
+
</colgroup>
|
565
636
|
<tbody><tr>
|
566
|
-
<td
|
567
|
-
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
568
|
-
</td>
|
637
|
+
<td class="parameter_name"><p>device</p></td>
|
638
|
+
<td class="parameter_description"><p>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a></p></td>
|
639
|
+
<td class="parameter_annotations"> </td>
|
569
640
|
</tr></tbody>
|
570
641
|
</table></div>
|
642
|
+
</div>
|
571
643
|
<p class="since">Since 1.10</p>
|
572
644
|
</div>
|
573
645
|
<hr>
|
574
646
|
<div class="refsect2">
|
575
|
-
<a name="cairo-device-observer-elapsed"></a><h3>cairo_device_observer_elapsed
|
576
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
647
|
+
<a name="cairo-device-observer-elapsed"></a><h3>cairo_device_observer_elapsed ()</h3>
|
648
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
649
|
+
cairo_device_observer_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
577
650
|
<p>
|
578
651
|
</p>
|
652
|
+
<div class="refsect3">
|
653
|
+
<a name="id-1.5.2.7.13.5"></a><h4>Returns</h4>
|
654
|
+
<p></p>
|
655
|
+
</div>
|
579
656
|
</div>
|
580
657
|
<hr>
|
581
658
|
<div class="refsect2">
|
582
|
-
<a name="cairo-device-observer-fill-elapsed"></a><h3>cairo_device_observer_fill_elapsed
|
583
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
659
|
+
<a name="cairo-device-observer-fill-elapsed"></a><h3>cairo_device_observer_fill_elapsed ()</h3>
|
660
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
661
|
+
cairo_device_observer_fill_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
584
662
|
<p>
|
585
663
|
</p>
|
664
|
+
<div class="refsect3">
|
665
|
+
<a name="id-1.5.2.7.14.5"></a><h4>Returns</h4>
|
666
|
+
<p></p>
|
667
|
+
</div>
|
586
668
|
</div>
|
587
669
|
<hr>
|
588
670
|
<div class="refsect2">
|
589
|
-
<a name="cairo-device-observer-glyphs-elapsed"></a><h3>cairo_device_observer_glyphs_elapsed
|
590
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
591
|
-
|
671
|
+
<a name="cairo-device-observer-glyphs-elapsed"></a><h3>cairo_device_observer_glyphs_elapsed ()</h3>
|
672
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
673
|
+
cairo_device_observer_glyphs_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
592
674
|
<p>
|
593
675
|
</p>
|
676
|
+
<div class="refsect3">
|
677
|
+
<a name="id-1.5.2.7.15.5"></a><h4>Returns</h4>
|
678
|
+
<p></p>
|
679
|
+
</div>
|
594
680
|
</div>
|
595
681
|
<hr>
|
596
682
|
<div class="refsect2">
|
597
|
-
<a name="cairo-device-observer-mask-elapsed"></a><h3>cairo_device_observer_mask_elapsed
|
598
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
683
|
+
<a name="cairo-device-observer-mask-elapsed"></a><h3>cairo_device_observer_mask_elapsed ()</h3>
|
684
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
685
|
+
cairo_device_observer_mask_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
599
686
|
<p>
|
600
687
|
</p>
|
688
|
+
<div class="refsect3">
|
689
|
+
<a name="id-1.5.2.7.16.5"></a><h4>Returns</h4>
|
690
|
+
<p></p>
|
691
|
+
</div>
|
601
692
|
</div>
|
602
693
|
<hr>
|
603
694
|
<div class="refsect2">
|
604
|
-
<a name="cairo-device-observer-paint-elapsed"></a><h3>cairo_device_observer_paint_elapsed
|
605
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
695
|
+
<a name="cairo-device-observer-paint-elapsed"></a><h3>cairo_device_observer_paint_elapsed ()</h3>
|
696
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
697
|
+
cairo_device_observer_paint_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
606
698
|
<p>
|
607
699
|
</p>
|
700
|
+
<div class="refsect3">
|
701
|
+
<a name="id-1.5.2.7.17.5"></a><h4>Returns</h4>
|
702
|
+
<p></p>
|
703
|
+
</div>
|
608
704
|
</div>
|
609
705
|
<hr>
|
610
706
|
<div class="refsect2">
|
611
|
-
<a name="cairo-device-observer-print"></a><h3>cairo_device_observer_print
|
612
|
-
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
613
|
-
|
614
|
-
|
707
|
+
<a name="cairo-device-observer-print"></a><h3>cairo_device_observer_print ()</h3>
|
708
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a>
|
709
|
+
cairo_device_observer_print (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
710
|
+
<em class="parameter"><code><a class="link" href="cairo-PNG-Support.html#cairo-write-func-t" title="cairo_write_func_t ()"><span class="type">cairo_write_func_t</span></a> write_func</code></em>,
|
711
|
+
<em class="parameter"><code><span class="type">void</span> *closure</code></em>);</pre>
|
615
712
|
<p>
|
616
713
|
</p>
|
714
|
+
<div class="refsect3">
|
715
|
+
<a name="id-1.5.2.7.18.5"></a><h4>Returns</h4>
|
716
|
+
<p></p>
|
717
|
+
</div>
|
617
718
|
</div>
|
618
719
|
<hr>
|
619
720
|
<div class="refsect2">
|
620
|
-
<a name="cairo-device-observer-stroke-elapsed"></a><h3>cairo_device_observer_stroke_elapsed
|
621
|
-
<pre class="programlisting"><span class="returnvalue">double</span>
|
622
|
-
|
721
|
+
<a name="cairo-device-observer-stroke-elapsed"></a><h3>cairo_device_observer_stroke_elapsed ()</h3>
|
722
|
+
<pre class="programlisting"><span class="returnvalue">double</span>
|
723
|
+
cairo_device_observer_stroke_elapsed (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
623
724
|
<p>
|
624
725
|
</p>
|
726
|
+
<div class="refsect3">
|
727
|
+
<a name="id-1.5.2.7.19.5"></a><h4>Returns</h4>
|
728
|
+
<p></p>
|
729
|
+
</div>
|
730
|
+
</div>
|
731
|
+
</div>
|
732
|
+
<div class="refsect1">
|
733
|
+
<a name="cairo-cairo-device-t.other_details"></a><h2>Types and Values</h2>
|
734
|
+
<div class="refsect2">
|
735
|
+
<a name="cairo-device-t"></a><h3>cairo_device_t</h3>
|
736
|
+
<pre class="programlisting">typedef struct _cairo_device cairo_device_t;
|
737
|
+
</pre>
|
738
|
+
<p>A <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> represents the driver interface for drawing
|
739
|
+
operations to a <a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>. There are different subtypes of
|
740
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> for different drawing backends; for example,
|
741
|
+
<code class="function">cairo_egl_device_create()</code> creates a device that wraps an EGL display and
|
742
|
+
context.</p>
|
743
|
+
<p>The type of a device can be queried with <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()"><code class="function">cairo_device_get_type()</code></a>.</p>
|
744
|
+
<p>Memory management of <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> is done with
|
745
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()"><code class="function">cairo_device_reference()</code></a> and <a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a>.</p>
|
746
|
+
<p class="since">Since 1.10</p>
|
747
|
+
</div>
|
748
|
+
<hr>
|
749
|
+
<div class="refsect2">
|
750
|
+
<a name="cairo-device-type-t"></a><h3>enum cairo_device_type_t</h3>
|
751
|
+
<p><a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a> is used to describe the type of a given
|
752
|
+
device. The devices types are also known as "backends" within cairo.</p>
|
753
|
+
<p>The device type can be queried with <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()"><code class="function">cairo_device_get_type()</code></a></p>
|
754
|
+
<p>The various <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> functions can be used with devices of
|
755
|
+
any type, but some backends also provide type-specific functions
|
756
|
+
that must only be called with a device of the appropriate
|
757
|
+
type. These functions have names that begin with
|
758
|
+
<code class="literal">cairo_<span class="emphasis"><em>type</em></span>_device</code> such as
|
759
|
+
<a class="link" href="cairo-XCB-Surfaces.html#cairo-xcb-device-debug-cap-xrender-version" title="cairo_xcb_device_debug_cap_xrender_version ()"><code class="function">cairo_xcb_device_debug_cap_xrender_version()</code></a>.</p>
|
760
|
+
<p>The behavior of calling a type-specific function with a device of
|
761
|
+
the wrong type is undefined.</p>
|
762
|
+
<p>New entries may be added in future versions.</p>
|
763
|
+
<div class="refsect3">
|
764
|
+
<a name="id-1.5.2.8.3.8"></a><h4>Members</h4>
|
765
|
+
<div class="informaltable"><table width="100%" border="0">
|
766
|
+
<colgroup>
|
767
|
+
<col width="300px" class="enum_members_name">
|
768
|
+
<col class="enum_members_description">
|
769
|
+
<col width="200px" class="enum_members_annotations">
|
770
|
+
</colgroup>
|
771
|
+
<tbody>
|
772
|
+
<tr>
|
773
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-DRM:CAPS"></a>CAIRO_DEVICE_TYPE_DRM</p></td>
|
774
|
+
<td class="enum_member_description">
|
775
|
+
<p>The device is of type Direct Render Manager, since 1.10</p>
|
776
|
+
</td>
|
777
|
+
<td class="enum_member_annotations"> </td>
|
778
|
+
</tr>
|
779
|
+
<tr>
|
780
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-GL:CAPS"></a>CAIRO_DEVICE_TYPE_GL</p></td>
|
781
|
+
<td class="enum_member_description">
|
782
|
+
<p>The device is of type OpenGL, since 1.10</p>
|
783
|
+
</td>
|
784
|
+
<td class="enum_member_annotations"> </td>
|
785
|
+
</tr>
|
786
|
+
<tr>
|
787
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-SCRIPT:CAPS"></a>CAIRO_DEVICE_TYPE_SCRIPT</p></td>
|
788
|
+
<td class="enum_member_description">
|
789
|
+
<p>The device is of type script, since 1.10</p>
|
790
|
+
</td>
|
791
|
+
<td class="enum_member_annotations"> </td>
|
792
|
+
</tr>
|
793
|
+
<tr>
|
794
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-XCB:CAPS"></a>CAIRO_DEVICE_TYPE_XCB</p></td>
|
795
|
+
<td class="enum_member_description">
|
796
|
+
<p>The device is of type xcb, since 1.10</p>
|
797
|
+
</td>
|
798
|
+
<td class="enum_member_annotations"> </td>
|
799
|
+
</tr>
|
800
|
+
<tr>
|
801
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-XLIB:CAPS"></a>CAIRO_DEVICE_TYPE_XLIB</p></td>
|
802
|
+
<td class="enum_member_description">
|
803
|
+
<p>The device is of type xlib, since 1.10</p>
|
804
|
+
</td>
|
805
|
+
<td class="enum_member_annotations"> </td>
|
806
|
+
</tr>
|
807
|
+
<tr>
|
808
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-XML:CAPS"></a>CAIRO_DEVICE_TYPE_XML</p></td>
|
809
|
+
<td class="enum_member_description">
|
810
|
+
<p>The device is of type XML, since 1.10</p>
|
811
|
+
</td>
|
812
|
+
<td class="enum_member_annotations"> </td>
|
813
|
+
</tr>
|
814
|
+
<tr>
|
815
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-COGL:CAPS"></a>CAIRO_DEVICE_TYPE_COGL</p></td>
|
816
|
+
<td class="enum_member_description">
|
817
|
+
<p>The device is of type cogl, since 1.12</p>
|
818
|
+
</td>
|
819
|
+
<td class="enum_member_annotations"> </td>
|
820
|
+
</tr>
|
821
|
+
<tr>
|
822
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-WIN32:CAPS"></a>CAIRO_DEVICE_TYPE_WIN32</p></td>
|
823
|
+
<td class="enum_member_description">
|
824
|
+
<p>The device is of type win32, since 1.12</p>
|
825
|
+
</td>
|
826
|
+
<td class="enum_member_annotations"> </td>
|
827
|
+
</tr>
|
828
|
+
<tr>
|
829
|
+
<td class="enum_member_name"><p><a name="CAIRO-DEVICE-TYPE-INVALID:CAPS"></a>CAIRO_DEVICE_TYPE_INVALID</p></td>
|
830
|
+
<td class="enum_member_description">
|
831
|
+
<p>The device is invalid, since 1.10</p>
|
832
|
+
</td>
|
833
|
+
<td class="enum_member_annotations"> </td>
|
834
|
+
</tr>
|
835
|
+
</tbody>
|
836
|
+
</table></div>
|
837
|
+
</div>
|
838
|
+
<p class="since">Since 1.10</p>
|
625
839
|
</div>
|
626
840
|
</div>
|
627
841
|
<div class="refsect1">
|
628
842
|
<a name="cairo-cairo-device-t.see-also"></a><h2>See Also</h2>
|
629
|
-
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>
|
843
|
+
<p><a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a></p>
|
630
844
|
</div>
|
631
845
|
</div>
|
632
846
|
<div class="footer">
|
633
847
|
<hr>
|
634
|
-
Generated by GTK-Doc V1.
|
848
|
+
Generated by GTK-Doc V1.20</div>
|
635
849
|
</body>
|
636
850
|
</html>
|