cairo 1.7.0-x86-mswin32 → 1.8.0-x86-mswin32
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.
- data/ChangeLog +32 -0
- data/NEWS +9 -1
- data/README +1 -0
- data/Rakefile +2 -2
- data/cairo/DLL_FAQ.txt +397 -0
- data/cairo/README.txt +53 -0
- data/cairo/USAGE.txt +94 -0
- data/cairo/bin/libcairo-2.dll +0 -0
- data/cairo/bin/libpng12-0.dll +0 -0
- data/cairo/bin/zlib1.dll +0 -0
- data/cairo/include/cairo/cairo-deprecated.h +0 -4
- data/cairo/include/cairo/cairo-features.h +7 -22
- data/cairo/include/cairo/cairo-pdf.h +1 -1
- data/cairo/include/cairo/cairo-ps.h +1 -1
- data/cairo/include/cairo/cairo-svg.h +1 -1
- data/cairo/include/cairo/cairo-version.h +8 -0
- data/cairo/include/cairo/cairo-win32.h +9 -1
- data/cairo/include/cairo/cairo.h +420 -32
- data/cairo/include/libpng12/png.h +3592 -0
- data/cairo/include/libpng12/pngconf.h +1481 -0
- data/cairo/include/png.h +36 -13
- data/cairo/include/pngconf.h +3 -3
- data/cairo/include/zconf.h +332 -0
- data/cairo/include/zlib.h +1357 -0
- data/cairo/lib/cairo.def +22 -0
- data/cairo/lib/cairo.lib +0 -0
- data/cairo/lib/libcairo.dll.a +0 -0
- data/cairo/lib/libpng.def +1 -0
- data/cairo/lib/libpng.lib +0 -0
- data/cairo/lib/libpng12.dll.a +0 -0
- data/cairo/lib/pkgconfig/cairo-pdf.pc +5 -5
- data/cairo/lib/pkgconfig/cairo-png.pc +5 -5
- data/cairo/lib/pkgconfig/cairo-ps.pc +5 -5
- data/cairo/lib/pkgconfig/cairo-svg.pc +4 -4
- data/cairo/lib/pkgconfig/cairo-win32-font.pc +4 -4
- data/cairo/lib/pkgconfig/cairo-win32.pc +4 -4
- data/cairo/lib/pkgconfig/cairo.pc +4 -4
- data/cairo/lib/pkgconfig/libpng.pc +3 -2
- data/cairo/lib/pkgconfig/libpng12.pc +3 -2
- data/cairo/lib/zdll.exp +0 -0
- data/cairo/lib/zdll.lib +0 -0
- data/cairo/lib/zlib.def +60 -0
- data/cairo/manifest/cairo-dev_1.8.0-1_win32.mft +76 -0
- data/cairo/manifest/cairo_1.8.0-1_win32.mft +5 -0
- data/cairo/manifest/{libpng-dev-1.2.29.mft → libpng-dev_1.2.32-1_win32.mft} +5 -2
- data/cairo/manifest/libpng_1.2.32-1_win32.mft +2 -0
- data/cairo/share/doc/{cairo-1.6.4-2 → cairo_1.8.0-1_win32}/COPYING +0 -0
- data/cairo/share/doc/{cairo-1.6.4-2 → cairo_1.8.0-1_win32}/COPYING-LGPL-2.1 +0 -0
- data/cairo/share/doc/{cairo-1.6.4-2 → cairo_1.8.0-1_win32}/COPYING-MPL-1.1 +0 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-errors.html +15 -11
- data/cairo/share/gtk-doc/html/cairo/bindings-fonts.html +15 -11
- data/cairo/share/gtk-doc/html/cairo/bindings-memory.html +20 -16
- data/cairo/share/gtk-doc/html/cairo/bindings-overloading.html +16 -12
- data/cairo/share/gtk-doc/html/cairo/bindings-path.html +17 -13
- data/cairo/share/gtk-doc/html/cairo/bindings-patterns.html +25 -21
- data/cairo/share/gtk-doc/html/cairo/bindings-return-values.html +17 -13
- data/cairo/share/gtk-doc/html/cairo/bindings-streams.html +14 -10
- data/cairo/share/gtk-doc/html/cairo/bindings-surfaces.html +19 -15
- data/cairo/share/gtk-doc/html/cairo/cairo-context.html +2721 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-drawing.html +57 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-error-status.html +361 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-font-face.html +418 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-font-options.html +695 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-fonts.html +63 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-ft-font.html +318 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-image-surface.html +486 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-cairo-matrix-t.html → cairo-matrix.html} +137 -156
- data/cairo/share/gtk-doc/html/cairo/{cairo-Paths.html → cairo-paths.html} +275 -306
- data/cairo/share/gtk-doc/html/cairo/cairo-pattern.html +1524 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-PDF-Surfaces.html → cairo-pdf-surface.html} +60 -70
- data/cairo/share/gtk-doc/html/cairo/cairo-png-functions.html +332 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-PostScript-Surfaces.html → cairo-ps-surface.html} +131 -150
- data/cairo/share/gtk-doc/html/cairo/cairo-quartz-font.html +153 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-Quartz-Surfaces.html → cairo-quartz-surface.html} +53 -62
- data/cairo/share/gtk-doc/html/cairo/cairo-scaled-font.html +1051 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-support.html +54 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-surface.html +1064 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-surfaces.html +69 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-svg-surface.html +324 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-text.html +1264 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-Transformations.html → cairo-transformations.html} +98 -115
- data/cairo/share/gtk-doc/html/cairo/cairo-types.html +134 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-user-font.html +769 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-version-info.html +355 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-win32-font.html +366 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-win32-surface.html +321 -0
- data/cairo/share/gtk-doc/html/cairo/{cairo-XLib-Surfaces.html → cairo-xlib-surface.html} +104 -121
- data/cairo/share/gtk-doc/html/cairo/cairo.devhelp +390 -405
- data/cairo/share/gtk-doc/html/cairo/cairo.devhelp2 +390 -405
- data/cairo/share/gtk-doc/html/cairo/index-1.2.html +63 -59
- data/cairo/share/gtk-doc/html/cairo/index-1.4.html +45 -41
- data/cairo/share/gtk-doc/html/cairo/index-1.6.html +29 -23
- data/cairo/share/gtk-doc/html/cairo/index-1.8.html +107 -0
- data/cairo/share/gtk-doc/html/cairo/index-all.html +759 -0
- data/cairo/share/gtk-doc/html/cairo/index.html +51 -41
- data/cairo/share/gtk-doc/html/cairo/index.sgml +478 -466
- data/cairo/share/gtk-doc/html/cairo/language-bindings.html +22 -18
- data/cairo/share/gtk-doc/html/cairo/style.css +14 -2
- data/cairo/share/man/man3/libpng.3 +443 -17
- data/cairo/share/man/man3/libpngpf.3 +618 -102
- data/cairo/share/man/man5/png.5 +1 -1
- data/cairo/src/tml/make/cairo_1.8.0-1_win32.log +1021 -0
- data/cairo/src/tml/make/cairo_1.8.0-1_win32.sh +68 -0
- data/cairo/src/tml/make/libpng_1.2.32-1_win32.log +269 -0
- data/cairo/src/tml/make/libpng_1.2.32-1_win32.sh +63 -0
- data/cairo/test/example_d.exe +0 -0
- data/cairo/test/minigzip_d.exe +0 -0
- data/cairo/test/testzlib_d.exe +0 -0
- data/cairo/test/untgz_d.exe +0 -0
- data/doc/en/cairo-context.html +81 -91
- data/doc/en/cairo-font-options.html +11 -26
- data/doc/en/cairo-text-cluster-flag.html +35 -0
- data/doc/en/cairo-user-font-face-text-to-glyphs-data.html +3 -3
- data/doc/en/cairo.html +38 -42
- data/doc/en/index.html +129 -142
- data/doc/ja/cairo-font-options.html +3 -25
- data/doc/ja/cairo-text-cluster-flag.html +46 -0
- data/doc/ja/cairo-user-font-face-text-to-glyphs-data.html +16 -15
- data/doc/ja/cairo.html +3 -7
- data/doc/ja/index.html +9 -17
- data/src/cairo.def +1 -1
- data/src/cairo.so +0 -0
- data/src/lib/cairo/constants.rb +3 -1
- data/src/libruby-cairo.a +0 -0
- data/src/rb_cairo.c +2 -2
- data/src/rb_cairo.h +5 -5
- data/src/rb_cairo_constants.c +12 -19
- data/src/rb_cairo_context.c +25 -21
- data/src/rb_cairo_font_face.c +44 -29
- data/src/rb_cairo_font_options.c +1 -23
- data/src/rb_cairo_scaled_font.c +5 -5
- data/test/test_constants.rb +6 -9
- data/test/test_context.rb +0 -12
- data/test/test_font_face.rb +7 -7
- data/test/test_font_options.rb +2 -21
- data/test/test_scaled_font.rb +3 -3
- data/test/test_text_to_glyphs_data.rb +19 -15
- metadata +68 -45
- data/cairo/make/cairo-1.6.4-2.sh +0 -55
- data/cairo/make/libpng-1.2.29.sh +0 -35
- data/cairo/manifest/cairo-1.6.4-2.mft +0 -6
- data/cairo/manifest/cairo-dev-1.6.4-2.mft +0 -72
- data/cairo/manifest/libpng-1.2.29.mft +0 -2
- data/cairo/share/gtk-doc/html/cairo/Drawing.html +0 -53
- data/cairo/share/gtk-doc/html/cairo/Fonts.html +0 -56
- data/cairo/share/gtk-doc/html/cairo/Support.html +0 -50
- data/cairo/share/gtk-doc/html/cairo/Surfaces.html +0 -65
- data/cairo/share/gtk-doc/html/cairo/cairo-Error-Handling.html +0 -328
- data/cairo/share/gtk-doc/html/cairo/cairo-Font-Options.html +0 -720
- data/cairo/share/gtk-doc/html/cairo/cairo-FreeType-Fonts.html +0 -297
- data/cairo/share/gtk-doc/html/cairo/cairo-Image-Surfaces.html +0 -484
- data/cairo/share/gtk-doc/html/cairo/cairo-PNG-Support.html +0 -345
- data/cairo/share/gtk-doc/html/cairo/cairo-Patterns.html +0 -1560
- data/cairo/share/gtk-doc/html/cairo/cairo-Quartz-Fonts.html +0 -161
- data/cairo/share/gtk-doc/html/cairo/cairo-SVG-Surfaces.html +0 -337
- data/cairo/share/gtk-doc/html/cairo/cairo-Scaled-Fonts.html +0 -823
- data/cairo/share/gtk-doc/html/cairo/cairo-Text.html +0 -836
- data/cairo/share/gtk-doc/html/cairo/cairo-Types.html +0 -143
- data/cairo/share/gtk-doc/html/cairo/cairo-Version-Information.html +0 -325
- data/cairo/share/gtk-doc/html/cairo/cairo-Win32-Fonts.html +0 -381
- data/cairo/share/gtk-doc/html/cairo/cairo-Win32-Surfaces.html +0 -331
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-font-face-t.html +0 -427
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-surface-t.html +0 -995
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-t.html +0 -2795
- data/cairo/share/gtk-doc/html/cairo/ix01.html +0 -693
- data/doc/en/cairo-lcd-filter.html +0 -39
- data/doc/ja/cairo-lcd-filter.html +0 -63
@@ -0,0 +1,1524 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
5
|
+
<title>cairo_pattern_t</title>
|
6
|
+
<meta name="generator" content="DocBook XSL Stylesheets V1.73.2">
|
7
|
+
<link rel="start" href="index.html" title="Cairo: A Vector Graphics Library">
|
8
|
+
<link rel="up" href="cairo-drawing.html" title="Drawing">
|
9
|
+
<link rel="prev" href="cairo-paths.html" title="Paths">
|
10
|
+
<link rel="next" href="cairo-transformations.html" title="Transformations">
|
11
|
+
<meta name="generator" content="GTK-Doc V1.10 (XML mode)">
|
12
|
+
<link rel="stylesheet" href="style.css" type="text/css">
|
13
|
+
<link rel="chapter" href="cairo-drawing.html" title="Drawing">
|
14
|
+
<link rel="chapter" href="cairo-fonts.html" title="Fonts">
|
15
|
+
<link rel="chapter" href="cairo-surfaces.html" title="Surfaces">
|
16
|
+
<link rel="chapter" href="cairo-support.html" title="Utilities">
|
17
|
+
<link rel="index" href="index-all.html" title="Index">
|
18
|
+
<link rel="index" href="index-1.2.html" title="Index of new symbols in 1.2">
|
19
|
+
<link rel="index" href="index-1.4.html" title="Index of new symbols in 1.4">
|
20
|
+
<link rel="index" href="index-1.6.html" title="Index of new symbols in 1.6">
|
21
|
+
<link rel="index" href="index-1.8.html" title="Index of new symbols in 1.8">
|
22
|
+
<link rel="appendix" href="language-bindings.html" title="Appendix A. Creating a language binding for cairo">
|
23
|
+
</head>
|
24
|
+
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
25
|
+
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
|
26
|
+
<tr valign="middle">
|
27
|
+
<td><a accesskey="p" href="cairo-paths.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
|
28
|
+
<td><a accesskey="u" href="cairo-drawing.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
|
29
|
+
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
|
30
|
+
<th width="100%" align="center">Cairo: A Vector Graphics Library</th>
|
31
|
+
<td><a accesskey="n" href="cairo-transformations.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
|
32
|
+
</tr>
|
33
|
+
<tr><td colspan="5" class="shortcuts"><nobr><a href="#cairo-pattern.synopsis" class="shortcut">Top</a>
|
34
|
+
|
|
35
|
+
<a href="#cairo-pattern.description" class="shortcut">Description</a></nobr></td></tr>
|
36
|
+
</table>
|
37
|
+
<div class="refentry" lang="en">
|
38
|
+
<a name="cairo-pattern"></a><div class="titlepage"></div>
|
39
|
+
<div class="refnamediv"><table width="100%"><tr>
|
40
|
+
<td valign="top">
|
41
|
+
<h2><span class="refentrytitle"><a name="cairo-pattern.top_of_page"></a>cairo_pattern_t</span></h2>
|
42
|
+
<p>cairo_pattern_t — Sources for drawing</p>
|
43
|
+
</td>
|
44
|
+
<td valign="top" align="right"></td>
|
45
|
+
</tr></table></div>
|
46
|
+
<div class="refsynopsisdiv">
|
47
|
+
<a name="cairo-pattern.synopsis"></a><h2>Synopsis</h2>
|
48
|
+
<pre class="synopsis">
|
49
|
+
typedef <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>;
|
50
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgb" title="cairo_pattern_add_color_stop_rgb ()">cairo_pattern_add_color_stop_rgb</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
51
|
+
double offset,
|
52
|
+
double red,
|
53
|
+
double green,
|
54
|
+
double blue);
|
55
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgba" title="cairo_pattern_add_color_stop_rgba ()">cairo_pattern_add_color_stop_rgba</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
56
|
+
double offset,
|
57
|
+
double red,
|
58
|
+
double green,
|
59
|
+
double blue,
|
60
|
+
double alpha);
|
61
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-color-stop-count" title="cairo_pattern_get_color_stop_count ()">cairo_pattern_get_color_stop_count</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
62
|
+
int *count);
|
63
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-color-stop-rgba" title="cairo_pattern_get_color_stop_rgba ()">cairo_pattern_get_color_stop_rgba</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
64
|
+
int index,
|
65
|
+
double *offset,
|
66
|
+
double *red,
|
67
|
+
double *green,
|
68
|
+
double *blue,
|
69
|
+
double *alpha);
|
70
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-create-rgb" title="cairo_pattern_create_rgb ()">cairo_pattern_create_rgb</a> (double red,
|
71
|
+
double green,
|
72
|
+
double blue);
|
73
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-create-rgba" title="cairo_pattern_create_rgba ()">cairo_pattern_create_rgba</a> (double red,
|
74
|
+
double green,
|
75
|
+
double blue,
|
76
|
+
double alpha);
|
77
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-rgba" title="cairo_pattern_get_rgba ()">cairo_pattern_get_rgba</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
78
|
+
double *red,
|
79
|
+
double *green,
|
80
|
+
double *blue,
|
81
|
+
double *alpha);
|
82
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-create-for-surface" title="cairo_pattern_create_for_surface ()">cairo_pattern_create_for_surface</a> (<a class="link" href="cairo-surface.html#cairo-surface-t" title="cairo_surface_t">cairo_surface_t</a> *surface);
|
83
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-surface" title="cairo_pattern_get_surface ()">cairo_pattern_get_surface</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
84
|
+
<a class="link" href="cairo-surface.html#cairo-surface-t" title="cairo_surface_t">cairo_surface_t</a> **surface);
|
85
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-create-linear" title="cairo_pattern_create_linear ()">cairo_pattern_create_linear</a> (double x0,
|
86
|
+
double y0,
|
87
|
+
double x1,
|
88
|
+
double y1);
|
89
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-linear-points" title="cairo_pattern_get_linear_points ()">cairo_pattern_get_linear_points</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
90
|
+
double *x0,
|
91
|
+
double *y0,
|
92
|
+
double *x1,
|
93
|
+
double *y1);
|
94
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-create-radial" title="cairo_pattern_create_radial ()">cairo_pattern_create_radial</a> (double cx0,
|
95
|
+
double cy0,
|
96
|
+
double radius0,
|
97
|
+
double cx1,
|
98
|
+
double cy1,
|
99
|
+
double radius1);
|
100
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-radial-circles" title="cairo_pattern_get_radial_circles ()">cairo_pattern_get_radial_circles</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
101
|
+
double *x0,
|
102
|
+
double *y0,
|
103
|
+
double *r0,
|
104
|
+
double *x1,
|
105
|
+
double *y1,
|
106
|
+
double *r1);
|
107
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* <a class="link" href="cairo-pattern.html#cairo-pattern-reference" title="cairo_pattern_reference ()">cairo_pattern_reference</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
108
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()">cairo_pattern_destroy</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
109
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()">cairo_pattern_status</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
110
|
+
enum <a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t">cairo_extend_t</a>;
|
111
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-set-extend" title="cairo_pattern_set_extend ()">cairo_pattern_set_extend</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
112
|
+
<a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t">cairo_extend_t</a> extend);
|
113
|
+
<a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t">cairo_extend_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-extend" title="cairo_pattern_get_extend ()">cairo_pattern_get_extend</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
114
|
+
enum <a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t">cairo_filter_t</a>;
|
115
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-set-filter" title="cairo_pattern_set_filter ()">cairo_pattern_set_filter</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
116
|
+
<a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t">cairo_filter_t</a> filter);
|
117
|
+
<a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t">cairo_filter_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-filter" title="cairo_pattern_get_filter ()">cairo_pattern_get_filter</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
118
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-set-matrix" title="cairo_pattern_set_matrix ()">cairo_pattern_set_matrix</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
119
|
+
const <a class="link" href="cairo-matrix.html#cairo-matrix-t" title="cairo_matrix_t">cairo_matrix_t</a> *matrix);
|
120
|
+
void <a class="link" href="cairo-pattern.html#cairo-pattern-get-matrix" title="cairo_pattern_get_matrix ()">cairo_pattern_get_matrix</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
121
|
+
<a class="link" href="cairo-matrix.html#cairo-matrix-t" title="cairo_matrix_t">cairo_matrix_t</a> *matrix);
|
122
|
+
enum <a class="link" href="cairo-pattern.html#cairo-pattern-type-t" title="enum cairo_pattern_type_t">cairo_pattern_type_t</a>;
|
123
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-type-t" title="enum cairo_pattern_type_t">cairo_pattern_type_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-get-type" title="cairo_pattern_get_type ()">cairo_pattern_get_type</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
124
|
+
unsigned int <a class="link" href="cairo-pattern.html#cairo-pattern-get-reference-count" title="cairo_pattern_get_reference_count ()">cairo_pattern_get_reference_count</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);
|
125
|
+
<a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> <a class="link" href="cairo-pattern.html#cairo-pattern-set-user-data" title="cairo_pattern_set_user_data ()">cairo_pattern_set_user_data</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
126
|
+
const <a class="link" href="cairo-types.html#cairo-user-data-key-t" title="cairo_user_data_key_t">cairo_user_data_key_t</a> *key,
|
127
|
+
void *user_data,
|
128
|
+
<a class="link" href="cairo-types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()">cairo_destroy_func_t</a> destroy);
|
129
|
+
void* <a class="link" href="cairo-pattern.html#cairo-pattern-get-user-data" title="cairo_pattern_get_user_data ()">cairo_pattern_get_user_data</a> (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
130
|
+
const <a class="link" href="cairo-types.html#cairo-user-data-key-t" title="cairo_user_data_key_t">cairo_user_data_key_t</a> *key);
|
131
|
+
</pre>
|
132
|
+
</div>
|
133
|
+
<div class="refsect1" lang="en">
|
134
|
+
<a name="cairo-pattern.description"></a><h2>Description</h2>
|
135
|
+
<p>
|
136
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> is the paint with which cairo draws.
|
137
|
+
The primary use of patterns is as the source for all cairo drawing operations,
|
138
|
+
although they can also be used as masks, that is, as the brush too.
|
139
|
+
</p>
|
140
|
+
<p>
|
141
|
+
A cairo pattern is created by using one of the many constructors,
|
142
|
+
of the form cairo_pattern_create_<span class="emphasis"><em>type</em></span>()
|
143
|
+
or implicitly through
|
144
|
+
cairo_set_source_<span class="emphasis"><em>type</em></span>() functions.
|
145
|
+
</p>
|
146
|
+
</div>
|
147
|
+
<div class="refsect1" lang="en">
|
148
|
+
<a name="cairo-pattern.details"></a><h2>Details</h2>
|
149
|
+
<div class="refsect2" lang="en">
|
150
|
+
<a name="cairo-pattern-t"></a><h3>cairo_pattern_t</h3>
|
151
|
+
<pre class="programlisting">typedef struct _cairo_pattern cairo_pattern_t;
|
152
|
+
</pre>
|
153
|
+
<p>
|
154
|
+
A <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> represents a source when drawing onto a
|
155
|
+
surface. There are different subtypes of <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>,
|
156
|
+
for different types of sources; for example,
|
157
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-create-rgb" title="cairo_pattern_create_rgb ()"><code class="function">cairo_pattern_create_rgb()</code></a> creates a pattern for a solid
|
158
|
+
opaque color.
|
159
|
+
</p>
|
160
|
+
<p>
|
161
|
+
Other than various cairo_pattern_create_<span class="emphasis"><em>type</em></span>()
|
162
|
+
functions, some of the pattern types can be implicitly created
|
163
|
+
using various cairo_set_source_<span class="emphasis"><em>type</em></span>() functions;
|
164
|
+
for example <a class="link" href="cairo-context.html#cairo-set-source-rgb" title="cairo_set_source_rgb ()"><code class="function">cairo_set_source_rgb()</code></a>.
|
165
|
+
</p>
|
166
|
+
<p>
|
167
|
+
The type of a pattern can be queried with <a class="link" href="cairo-pattern.html#cairo-pattern-get-type" title="cairo_pattern_get_type ()"><code class="function">cairo_pattern_get_type()</code></a>.
|
168
|
+
</p>
|
169
|
+
<p>
|
170
|
+
Memory management of <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> is done with
|
171
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-reference" title="cairo_pattern_reference ()"><code class="function">cairo_pattern_reference()</code></a> and <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a>.</p>
|
172
|
+
<p>
|
173
|
+
|
174
|
+
</p>
|
175
|
+
</div>
|
176
|
+
<hr>
|
177
|
+
<div class="refsect2" lang="en">
|
178
|
+
<a name="cairo-pattern-add-color-stop-rgb"></a><h3>cairo_pattern_add_color_stop_rgb ()</h3>
|
179
|
+
<pre class="programlisting">void cairo_pattern_add_color_stop_rgb (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
180
|
+
double offset,
|
181
|
+
double red,
|
182
|
+
double green,
|
183
|
+
double blue);</pre>
|
184
|
+
<p>
|
185
|
+
Adds an opaque color stop to a gradient pattern. The offset
|
186
|
+
specifies the location along the gradient's control vector. For
|
187
|
+
example, a linear gradient's control vector is from (x0,y0) to
|
188
|
+
(x1,y1) while a radial gradient's control vector is from any point
|
189
|
+
on the start circle to the corresponding point on the end circle.
|
190
|
+
</p>
|
191
|
+
<p>
|
192
|
+
The color is specified in the same way as in <a class="link" href="cairo-context.html#cairo-set-source-rgb" title="cairo_set_source_rgb ()"><code class="function">cairo_set_source_rgb()</code></a>.
|
193
|
+
</p>
|
194
|
+
<p>
|
195
|
+
If two (or more) stops are specified with identical offset values,
|
196
|
+
they will be sorted according to the order in which the stops are
|
197
|
+
added, (stops added earlier will compare less than stops added
|
198
|
+
later). This can be useful for reliably making sharp color
|
199
|
+
transitions instead of the typical blend.
|
200
|
+
</p>
|
201
|
+
<p>
|
202
|
+
Note: If the pattern is not a gradient pattern, (eg. a linear or
|
203
|
+
radial pattern), then the pattern will be put into an error status
|
204
|
+
with a status of <a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a>.</p>
|
205
|
+
<p>
|
206
|
+
|
207
|
+
</p>
|
208
|
+
<div class="variablelist"><table border="0">
|
209
|
+
<col align="left" valign="top">
|
210
|
+
<tbody>
|
211
|
+
<tr>
|
212
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
213
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
214
|
+
</td>
|
215
|
+
</tr>
|
216
|
+
<tr>
|
217
|
+
<td><p><span class="term"><em class="parameter"><code>offset</code></em> :</span></p></td>
|
218
|
+
<td> an offset in the range [0.0 .. 1.0]
|
219
|
+
</td>
|
220
|
+
</tr>
|
221
|
+
<tr>
|
222
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
223
|
+
<td> red component of color
|
224
|
+
</td>
|
225
|
+
</tr>
|
226
|
+
<tr>
|
227
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
228
|
+
<td> green component of color
|
229
|
+
</td>
|
230
|
+
</tr>
|
231
|
+
<tr>
|
232
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
233
|
+
<td> blue component of color
|
234
|
+
</td>
|
235
|
+
</tr>
|
236
|
+
</tbody>
|
237
|
+
</table></div>
|
238
|
+
</div>
|
239
|
+
<hr>
|
240
|
+
<div class="refsect2" lang="en">
|
241
|
+
<a name="cairo-pattern-add-color-stop-rgba"></a><h3>cairo_pattern_add_color_stop_rgba ()</h3>
|
242
|
+
<pre class="programlisting">void cairo_pattern_add_color_stop_rgba (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
243
|
+
double offset,
|
244
|
+
double red,
|
245
|
+
double green,
|
246
|
+
double blue,
|
247
|
+
double alpha);</pre>
|
248
|
+
<p>
|
249
|
+
Adds a translucent color stop to a gradient pattern. The offset
|
250
|
+
specifies the location along the gradient's control vector. For
|
251
|
+
example, a linear gradient's control vector is from (x0,y0) to
|
252
|
+
(x1,y1) while a radial gradient's control vector is from any point
|
253
|
+
on the start circle to the corresponding point on the end circle.
|
254
|
+
</p>
|
255
|
+
<p>
|
256
|
+
The color is specified in the same way as in <a class="link" href="cairo-context.html#cairo-set-source-rgba" title="cairo_set_source_rgba ()"><code class="function">cairo_set_source_rgba()</code></a>.
|
257
|
+
</p>
|
258
|
+
<p>
|
259
|
+
If two (or more) stops are specified with identical offset values,
|
260
|
+
they will be sorted according to the order in which the stops are
|
261
|
+
added, (stops added earlier will compare less than stops added
|
262
|
+
later). This can be useful for reliably making sharp color
|
263
|
+
transitions instead of the typical blend.
|
264
|
+
</p>
|
265
|
+
<p>
|
266
|
+
Note: If the pattern is not a gradient pattern, (eg. a linear or
|
267
|
+
radial pattern), then the pattern will be put into an error status
|
268
|
+
with a status of <a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a>.</p>
|
269
|
+
<p>
|
270
|
+
|
271
|
+
</p>
|
272
|
+
<div class="variablelist"><table border="0">
|
273
|
+
<col align="left" valign="top">
|
274
|
+
<tbody>
|
275
|
+
<tr>
|
276
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
277
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
278
|
+
</td>
|
279
|
+
</tr>
|
280
|
+
<tr>
|
281
|
+
<td><p><span class="term"><em class="parameter"><code>offset</code></em> :</span></p></td>
|
282
|
+
<td> an offset in the range [0.0 .. 1.0]
|
283
|
+
</td>
|
284
|
+
</tr>
|
285
|
+
<tr>
|
286
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
287
|
+
<td> red component of color
|
288
|
+
</td>
|
289
|
+
</tr>
|
290
|
+
<tr>
|
291
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
292
|
+
<td> green component of color
|
293
|
+
</td>
|
294
|
+
</tr>
|
295
|
+
<tr>
|
296
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
297
|
+
<td> blue component of color
|
298
|
+
</td>
|
299
|
+
</tr>
|
300
|
+
<tr>
|
301
|
+
<td><p><span class="term"><em class="parameter"><code>alpha</code></em> :</span></p></td>
|
302
|
+
<td> alpha component of color
|
303
|
+
</td>
|
304
|
+
</tr>
|
305
|
+
</tbody>
|
306
|
+
</table></div>
|
307
|
+
</div>
|
308
|
+
<hr>
|
309
|
+
<div class="refsect2" lang="en">
|
310
|
+
<a name="cairo-pattern-get-color-stop-count"></a><h3>cairo_pattern_get_color_stop_count ()</h3>
|
311
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_color_stop_count (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
312
|
+
int *count);</pre>
|
313
|
+
<p>
|
314
|
+
Gets the number of color stops specified in the given gradient
|
315
|
+
pattern.</p>
|
316
|
+
<p>
|
317
|
+
|
318
|
+
</p>
|
319
|
+
<div class="variablelist"><table border="0">
|
320
|
+
<col align="left" valign="top">
|
321
|
+
<tbody>
|
322
|
+
<tr>
|
323
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
324
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
325
|
+
</td>
|
326
|
+
</tr>
|
327
|
+
<tr>
|
328
|
+
<td><p><span class="term"><em class="parameter"><code>count</code></em> :</span></p></td>
|
329
|
+
<td> return value for the number of color stops, or <code class="literal">NULL</code>
|
330
|
+
</td>
|
331
|
+
</tr>
|
332
|
+
<tr>
|
333
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
334
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or
|
335
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> if <em class="parameter"><code>pattern</code></em> is not a gradient
|
336
|
+
pattern.
|
337
|
+
|
338
|
+
</td>
|
339
|
+
</tr>
|
340
|
+
</tbody>
|
341
|
+
</table></div>
|
342
|
+
<p class="since">Since 1.4
|
343
|
+
</p>
|
344
|
+
</div>
|
345
|
+
<hr>
|
346
|
+
<div class="refsect2" lang="en">
|
347
|
+
<a name="cairo-pattern-get-color-stop-rgba"></a><h3>cairo_pattern_get_color_stop_rgba ()</h3>
|
348
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_color_stop_rgba (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
349
|
+
int index,
|
350
|
+
double *offset,
|
351
|
+
double *red,
|
352
|
+
double *green,
|
353
|
+
double *blue,
|
354
|
+
double *alpha);</pre>
|
355
|
+
<p>
|
356
|
+
Gets the color and offset information at the given <em class="parameter"><code>index</code></em> for a
|
357
|
+
gradient pattern. Values of <em class="parameter"><code>index</code></em> are 0 to 1 less than the number
|
358
|
+
returned by <a class="link" href="cairo-pattern.html#cairo-pattern-get-color-stop-count" title="cairo_pattern_get_color_stop_count ()"><code class="function">cairo_pattern_get_color_stop_count()</code></a>.</p>
|
359
|
+
<p>
|
360
|
+
|
361
|
+
</p>
|
362
|
+
<div class="variablelist"><table border="0">
|
363
|
+
<col align="left" valign="top">
|
364
|
+
<tbody>
|
365
|
+
<tr>
|
366
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
367
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
368
|
+
</td>
|
369
|
+
</tr>
|
370
|
+
<tr>
|
371
|
+
<td><p><span class="term"><em class="parameter"><code>index</code></em> :</span></p></td>
|
372
|
+
<td> index of the stop to return data for
|
373
|
+
</td>
|
374
|
+
</tr>
|
375
|
+
<tr>
|
376
|
+
<td><p><span class="term"><em class="parameter"><code>offset</code></em> :</span></p></td>
|
377
|
+
<td> return value for the offset of the stop, or <code class="literal">NULL</code>
|
378
|
+
</td>
|
379
|
+
</tr>
|
380
|
+
<tr>
|
381
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
382
|
+
<td> return value for red component of color, or <code class="literal">NULL</code>
|
383
|
+
</td>
|
384
|
+
</tr>
|
385
|
+
<tr>
|
386
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
387
|
+
<td> return value for green component of color, or <code class="literal">NULL</code>
|
388
|
+
</td>
|
389
|
+
</tr>
|
390
|
+
<tr>
|
391
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
392
|
+
<td> return value for blue component of color, or <code class="literal">NULL</code>
|
393
|
+
</td>
|
394
|
+
</tr>
|
395
|
+
<tr>
|
396
|
+
<td><p><span class="term"><em class="parameter"><code>alpha</code></em> :</span></p></td>
|
397
|
+
<td> return value for alpha component of color, or <code class="literal">NULL</code>
|
398
|
+
</td>
|
399
|
+
</tr>
|
400
|
+
<tr>
|
401
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
402
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or <a class="link" href="cairo-error-status.html#CAIRO-STATUS-INVALID-INDEX:CAPS"><code class="literal">CAIRO_STATUS_INVALID_INDEX</code></a>
|
403
|
+
if <em class="parameter"><code>index</code></em> is not valid for the given pattern. If the pattern is
|
404
|
+
not a gradient pattern, <a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> is
|
405
|
+
returned.
|
406
|
+
|
407
|
+
</td>
|
408
|
+
</tr>
|
409
|
+
</tbody>
|
410
|
+
</table></div>
|
411
|
+
<p class="since">Since 1.4
|
412
|
+
</p>
|
413
|
+
</div>
|
414
|
+
<hr>
|
415
|
+
<div class="refsect2" lang="en">
|
416
|
+
<a name="cairo-pattern-create-rgb"></a><h3>cairo_pattern_create_rgb ()</h3>
|
417
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_create_rgb (double red,
|
418
|
+
double green,
|
419
|
+
double blue);</pre>
|
420
|
+
<p>
|
421
|
+
Creates a new <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> corresponding to an opaque color. The
|
422
|
+
color components are floating point numbers in the range 0 to 1.
|
423
|
+
If the values passed in are outside that range, they will be
|
424
|
+
clamped.</p>
|
425
|
+
<p>
|
426
|
+
|
427
|
+
</p>
|
428
|
+
<div class="variablelist"><table border="0">
|
429
|
+
<col align="left" valign="top">
|
430
|
+
<tbody>
|
431
|
+
<tr>
|
432
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
433
|
+
<td> red component of the color
|
434
|
+
</td>
|
435
|
+
</tr>
|
436
|
+
<tr>
|
437
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
438
|
+
<td> green component of the color
|
439
|
+
</td>
|
440
|
+
</tr>
|
441
|
+
<tr>
|
442
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
443
|
+
<td> blue component of the color
|
444
|
+
</td>
|
445
|
+
</tr>
|
446
|
+
<tr>
|
447
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
448
|
+
<td> the newly created <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> if successful, or
|
449
|
+
an error pattern in case of no memory. The caller owns the
|
450
|
+
returned object and should call <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> when
|
451
|
+
finished with it.
|
452
|
+
|
453
|
+
This function will always return a valid pointer, but if an error
|
454
|
+
occurred the pattern status will be set to an error. To inspect
|
455
|
+
the status of a pattern use <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()"><code class="function">cairo_pattern_status()</code></a>.
|
456
|
+
</td>
|
457
|
+
</tr>
|
458
|
+
</tbody>
|
459
|
+
</table></div>
|
460
|
+
</div>
|
461
|
+
<hr>
|
462
|
+
<div class="refsect2" lang="en">
|
463
|
+
<a name="cairo-pattern-create-rgba"></a><h3>cairo_pattern_create_rgba ()</h3>
|
464
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_create_rgba (double red,
|
465
|
+
double green,
|
466
|
+
double blue,
|
467
|
+
double alpha);</pre>
|
468
|
+
<p>
|
469
|
+
Creates a new <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> corresponding to a translucent color.
|
470
|
+
The color components are floating point numbers in the range 0 to
|
471
|
+
1. If the values passed in are outside that range, they will be
|
472
|
+
clamped.</p>
|
473
|
+
<p>
|
474
|
+
|
475
|
+
</p>
|
476
|
+
<div class="variablelist"><table border="0">
|
477
|
+
<col align="left" valign="top">
|
478
|
+
<tbody>
|
479
|
+
<tr>
|
480
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
481
|
+
<td> red component of the color
|
482
|
+
</td>
|
483
|
+
</tr>
|
484
|
+
<tr>
|
485
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
486
|
+
<td> green component of the color
|
487
|
+
</td>
|
488
|
+
</tr>
|
489
|
+
<tr>
|
490
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
491
|
+
<td> blue component of the color
|
492
|
+
</td>
|
493
|
+
</tr>
|
494
|
+
<tr>
|
495
|
+
<td><p><span class="term"><em class="parameter"><code>alpha</code></em> :</span></p></td>
|
496
|
+
<td> alpha component of the color
|
497
|
+
</td>
|
498
|
+
</tr>
|
499
|
+
<tr>
|
500
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
501
|
+
<td> the newly created <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> if successful, or
|
502
|
+
an error pattern in case of no memory. The caller owns the
|
503
|
+
returned object and should call <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> when
|
504
|
+
finished with it.
|
505
|
+
|
506
|
+
This function will always return a valid pointer, but if an error
|
507
|
+
occurred the pattern status will be set to an error. To inspect
|
508
|
+
the status of a pattern use <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()"><code class="function">cairo_pattern_status()</code></a>.
|
509
|
+
</td>
|
510
|
+
</tr>
|
511
|
+
</tbody>
|
512
|
+
</table></div>
|
513
|
+
</div>
|
514
|
+
<hr>
|
515
|
+
<div class="refsect2" lang="en">
|
516
|
+
<a name="cairo-pattern-get-rgba"></a><h3>cairo_pattern_get_rgba ()</h3>
|
517
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_rgba (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
518
|
+
double *red,
|
519
|
+
double *green,
|
520
|
+
double *blue,
|
521
|
+
double *alpha);</pre>
|
522
|
+
<p>
|
523
|
+
Gets the solid color for a solid color pattern.</p>
|
524
|
+
<p>
|
525
|
+
|
526
|
+
</p>
|
527
|
+
<div class="variablelist"><table border="0">
|
528
|
+
<col align="left" valign="top">
|
529
|
+
<tbody>
|
530
|
+
<tr>
|
531
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
532
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
533
|
+
</td>
|
534
|
+
</tr>
|
535
|
+
<tr>
|
536
|
+
<td><p><span class="term"><em class="parameter"><code>red</code></em> :</span></p></td>
|
537
|
+
<td> return value for red component of color, or <code class="literal">NULL</code>
|
538
|
+
</td>
|
539
|
+
</tr>
|
540
|
+
<tr>
|
541
|
+
<td><p><span class="term"><em class="parameter"><code>green</code></em> :</span></p></td>
|
542
|
+
<td> return value for green component of color, or <code class="literal">NULL</code>
|
543
|
+
</td>
|
544
|
+
</tr>
|
545
|
+
<tr>
|
546
|
+
<td><p><span class="term"><em class="parameter"><code>blue</code></em> :</span></p></td>
|
547
|
+
<td> return value for blue component of color, or <code class="literal">NULL</code>
|
548
|
+
</td>
|
549
|
+
</tr>
|
550
|
+
<tr>
|
551
|
+
<td><p><span class="term"><em class="parameter"><code>alpha</code></em> :</span></p></td>
|
552
|
+
<td> return value for alpha component of color, or <code class="literal">NULL</code>
|
553
|
+
</td>
|
554
|
+
</tr>
|
555
|
+
<tr>
|
556
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
557
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or
|
558
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> if the pattern is not a solid
|
559
|
+
color pattern.
|
560
|
+
|
561
|
+
</td>
|
562
|
+
</tr>
|
563
|
+
</tbody>
|
564
|
+
</table></div>
|
565
|
+
<p class="since">Since 1.4
|
566
|
+
</p>
|
567
|
+
</div>
|
568
|
+
<hr>
|
569
|
+
<div class="refsect2" lang="en">
|
570
|
+
<a name="cairo-pattern-create-for-surface"></a><h3>cairo_pattern_create_for_surface ()</h3>
|
571
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_create_for_surface (<a class="link" href="cairo-surface.html#cairo-surface-t" title="cairo_surface_t">cairo_surface_t</a> *surface);</pre>
|
572
|
+
<p>
|
573
|
+
Create a new <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> for the given surface.</p>
|
574
|
+
<p>
|
575
|
+
|
576
|
+
</p>
|
577
|
+
<div class="variablelist"><table border="0">
|
578
|
+
<col align="left" valign="top">
|
579
|
+
<tbody>
|
580
|
+
<tr>
|
581
|
+
<td><p><span class="term"><em class="parameter"><code>surface</code></em> :</span></p></td>
|
582
|
+
<td> the surface
|
583
|
+
</td>
|
584
|
+
</tr>
|
585
|
+
<tr>
|
586
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
587
|
+
<td> the newly created <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> if successful, or
|
588
|
+
an error pattern in case of no memory. The caller owns the
|
589
|
+
returned object and should call <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> when
|
590
|
+
finished with it.
|
591
|
+
|
592
|
+
This function will always return a valid pointer, but if an error
|
593
|
+
occurred the pattern status will be set to an error. To inspect
|
594
|
+
the status of a pattern use <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()"><code class="function">cairo_pattern_status()</code></a>.
|
595
|
+
</td>
|
596
|
+
</tr>
|
597
|
+
</tbody>
|
598
|
+
</table></div>
|
599
|
+
</div>
|
600
|
+
<hr>
|
601
|
+
<div class="refsect2" lang="en">
|
602
|
+
<a name="cairo-pattern-get-surface"></a><h3>cairo_pattern_get_surface ()</h3>
|
603
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_surface (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
604
|
+
<a class="link" href="cairo-surface.html#cairo-surface-t" title="cairo_surface_t">cairo_surface_t</a> **surface);</pre>
|
605
|
+
<p>
|
606
|
+
Gets the surface of a surface pattern. The reference returned in
|
607
|
+
<em class="parameter"><code>surface</code></em> is owned by the pattern; the caller should call
|
608
|
+
<a class="link" href="cairo-surface.html#cairo-surface-reference" title="cairo_surface_reference ()"><code class="function">cairo_surface_reference()</code></a> if the surface is to be retained.</p>
|
609
|
+
<p>
|
610
|
+
|
611
|
+
</p>
|
612
|
+
<div class="variablelist"><table border="0">
|
613
|
+
<col align="left" valign="top">
|
614
|
+
<tbody>
|
615
|
+
<tr>
|
616
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
617
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
618
|
+
</td>
|
619
|
+
</tr>
|
620
|
+
<tr>
|
621
|
+
<td><p><span class="term"><em class="parameter"><code>surface</code></em> :</span></p></td>
|
622
|
+
<td> return value for surface of pattern, or <code class="literal">NULL</code>
|
623
|
+
</td>
|
624
|
+
</tr>
|
625
|
+
<tr>
|
626
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
627
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or
|
628
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> if the pattern is not a surface
|
629
|
+
pattern.
|
630
|
+
|
631
|
+
</td>
|
632
|
+
</tr>
|
633
|
+
</tbody>
|
634
|
+
</table></div>
|
635
|
+
<p class="since">Since 1.4
|
636
|
+
</p>
|
637
|
+
</div>
|
638
|
+
<hr>
|
639
|
+
<div class="refsect2" lang="en">
|
640
|
+
<a name="cairo-pattern-create-linear"></a><h3>cairo_pattern_create_linear ()</h3>
|
641
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_create_linear (double x0,
|
642
|
+
double y0,
|
643
|
+
double x1,
|
644
|
+
double y1);</pre>
|
645
|
+
<p>
|
646
|
+
Create a new linear gradient <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> along the line defined
|
647
|
+
by (x0, y0) and (x1, y1). Before using the gradient pattern, a
|
648
|
+
number of color stops should be defined using
|
649
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgb" title="cairo_pattern_add_color_stop_rgb ()"><code class="function">cairo_pattern_add_color_stop_rgb()</code></a> or
|
650
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgba" title="cairo_pattern_add_color_stop_rgba ()"><code class="function">cairo_pattern_add_color_stop_rgba()</code></a>.
|
651
|
+
</p>
|
652
|
+
<p>
|
653
|
+
Note: The coordinates here are in pattern space. For a new pattern,
|
654
|
+
pattern space is identical to user space, but the relationship
|
655
|
+
between the spaces can be changed with <a class="link" href="cairo-pattern.html#cairo-pattern-set-matrix" title="cairo_pattern_set_matrix ()"><code class="function">cairo_pattern_set_matrix()</code></a>.</p>
|
656
|
+
<p>
|
657
|
+
|
658
|
+
</p>
|
659
|
+
<div class="variablelist"><table border="0">
|
660
|
+
<col align="left" valign="top">
|
661
|
+
<tbody>
|
662
|
+
<tr>
|
663
|
+
<td><p><span class="term"><em class="parameter"><code>x0</code></em> :</span></p></td>
|
664
|
+
<td> x coordinate of the start point
|
665
|
+
</td>
|
666
|
+
</tr>
|
667
|
+
<tr>
|
668
|
+
<td><p><span class="term"><em class="parameter"><code>y0</code></em> :</span></p></td>
|
669
|
+
<td> y coordinate of the start point
|
670
|
+
</td>
|
671
|
+
</tr>
|
672
|
+
<tr>
|
673
|
+
<td><p><span class="term"><em class="parameter"><code>x1</code></em> :</span></p></td>
|
674
|
+
<td> x coordinate of the end point
|
675
|
+
</td>
|
676
|
+
</tr>
|
677
|
+
<tr>
|
678
|
+
<td><p><span class="term"><em class="parameter"><code>y1</code></em> :</span></p></td>
|
679
|
+
<td> y coordinate of the end point
|
680
|
+
</td>
|
681
|
+
</tr>
|
682
|
+
<tr>
|
683
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
684
|
+
<td> the newly created <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> if successful, or
|
685
|
+
an error pattern in case of no memory. The caller owns the
|
686
|
+
returned object and should call <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> when
|
687
|
+
finished with it.
|
688
|
+
|
689
|
+
This function will always return a valid pointer, but if an error
|
690
|
+
occurred the pattern status will be set to an error. To inspect
|
691
|
+
the status of a pattern use <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()"><code class="function">cairo_pattern_status()</code></a>.
|
692
|
+
</td>
|
693
|
+
</tr>
|
694
|
+
</tbody>
|
695
|
+
</table></div>
|
696
|
+
</div>
|
697
|
+
<hr>
|
698
|
+
<div class="refsect2" lang="en">
|
699
|
+
<a name="cairo-pattern-get-linear-points"></a><h3>cairo_pattern_get_linear_points ()</h3>
|
700
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_linear_points (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
701
|
+
double *x0,
|
702
|
+
double *y0,
|
703
|
+
double *x1,
|
704
|
+
double *y1);</pre>
|
705
|
+
<p>
|
706
|
+
Gets the gradient endpoints for a linear gradient.</p>
|
707
|
+
<p>
|
708
|
+
|
709
|
+
</p>
|
710
|
+
<div class="variablelist"><table border="0">
|
711
|
+
<col align="left" valign="top">
|
712
|
+
<tbody>
|
713
|
+
<tr>
|
714
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
715
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
716
|
+
</td>
|
717
|
+
</tr>
|
718
|
+
<tr>
|
719
|
+
<td><p><span class="term"><em class="parameter"><code>x0</code></em> :</span></p></td>
|
720
|
+
<td> return value for the x coordinate of the first point, or <code class="literal">NULL</code>
|
721
|
+
</td>
|
722
|
+
</tr>
|
723
|
+
<tr>
|
724
|
+
<td><p><span class="term"><em class="parameter"><code>y0</code></em> :</span></p></td>
|
725
|
+
<td> return value for the y coordinate of the first point, or <code class="literal">NULL</code>
|
726
|
+
</td>
|
727
|
+
</tr>
|
728
|
+
<tr>
|
729
|
+
<td><p><span class="term"><em class="parameter"><code>x1</code></em> :</span></p></td>
|
730
|
+
<td> return value for the x coordinate of the second point, or <code class="literal">NULL</code>
|
731
|
+
</td>
|
732
|
+
</tr>
|
733
|
+
<tr>
|
734
|
+
<td><p><span class="term"><em class="parameter"><code>y1</code></em> :</span></p></td>
|
735
|
+
<td> return value for the y coordinate of the second point, or <code class="literal">NULL</code>
|
736
|
+
</td>
|
737
|
+
</tr>
|
738
|
+
<tr>
|
739
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
740
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or
|
741
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> if <em class="parameter"><code>pattern</code></em> is not a linear
|
742
|
+
gradient pattern.
|
743
|
+
|
744
|
+
</td>
|
745
|
+
</tr>
|
746
|
+
</tbody>
|
747
|
+
</table></div>
|
748
|
+
<p class="since">Since 1.4
|
749
|
+
</p>
|
750
|
+
</div>
|
751
|
+
<hr>
|
752
|
+
<div class="refsect2" lang="en">
|
753
|
+
<a name="cairo-pattern-create-radial"></a><h3>cairo_pattern_create_radial ()</h3>
|
754
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_create_radial (double cx0,
|
755
|
+
double cy0,
|
756
|
+
double radius0,
|
757
|
+
double cx1,
|
758
|
+
double cy1,
|
759
|
+
double radius1);</pre>
|
760
|
+
<p>
|
761
|
+
Creates a new radial gradient <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> between the two
|
762
|
+
circles defined by (cx0, cy0, radius0) and (cx1, cy1, radius1). Before using the
|
763
|
+
gradient pattern, a number of color stops should be defined using
|
764
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgb" title="cairo_pattern_add_color_stop_rgb ()"><code class="function">cairo_pattern_add_color_stop_rgb()</code></a> or
|
765
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgba" title="cairo_pattern_add_color_stop_rgba ()"><code class="function">cairo_pattern_add_color_stop_rgba()</code></a>.
|
766
|
+
</p>
|
767
|
+
<p>
|
768
|
+
Note: The coordinates here are in pattern space. For a new pattern,
|
769
|
+
pattern space is identical to user space, but the relationship
|
770
|
+
between the spaces can be changed with <a class="link" href="cairo-pattern.html#cairo-pattern-set-matrix" title="cairo_pattern_set_matrix ()"><code class="function">cairo_pattern_set_matrix()</code></a>.</p>
|
771
|
+
<p>
|
772
|
+
|
773
|
+
</p>
|
774
|
+
<div class="variablelist"><table border="0">
|
775
|
+
<col align="left" valign="top">
|
776
|
+
<tbody>
|
777
|
+
<tr>
|
778
|
+
<td><p><span class="term"><em class="parameter"><code>cx0</code></em> :</span></p></td>
|
779
|
+
<td> x coordinate for the center of the start circle
|
780
|
+
</td>
|
781
|
+
</tr>
|
782
|
+
<tr>
|
783
|
+
<td><p><span class="term"><em class="parameter"><code>cy0</code></em> :</span></p></td>
|
784
|
+
<td> y coordinate for the center of the start circle
|
785
|
+
</td>
|
786
|
+
</tr>
|
787
|
+
<tr>
|
788
|
+
<td><p><span class="term"><em class="parameter"><code>radius0</code></em> :</span></p></td>
|
789
|
+
<td> radius of the start circle
|
790
|
+
</td>
|
791
|
+
</tr>
|
792
|
+
<tr>
|
793
|
+
<td><p><span class="term"><em class="parameter"><code>cx1</code></em> :</span></p></td>
|
794
|
+
<td> x coordinate for the center of the end circle
|
795
|
+
</td>
|
796
|
+
</tr>
|
797
|
+
<tr>
|
798
|
+
<td><p><span class="term"><em class="parameter"><code>cy1</code></em> :</span></p></td>
|
799
|
+
<td> y coordinate for the center of the end circle
|
800
|
+
</td>
|
801
|
+
</tr>
|
802
|
+
<tr>
|
803
|
+
<td><p><span class="term"><em class="parameter"><code>radius1</code></em> :</span></p></td>
|
804
|
+
<td> radius of the end circle
|
805
|
+
</td>
|
806
|
+
</tr>
|
807
|
+
<tr>
|
808
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
809
|
+
<td> the newly created <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> if successful, or
|
810
|
+
an error pattern in case of no memory. The caller owns the
|
811
|
+
returned object and should call <a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> when
|
812
|
+
finished with it.
|
813
|
+
|
814
|
+
This function will always return a valid pointer, but if an error
|
815
|
+
occurred the pattern status will be set to an error. To inspect
|
816
|
+
the status of a pattern use <a class="link" href="cairo-pattern.html#cairo-pattern-status" title="cairo_pattern_status ()"><code class="function">cairo_pattern_status()</code></a>.
|
817
|
+
</td>
|
818
|
+
</tr>
|
819
|
+
</tbody>
|
820
|
+
</table></div>
|
821
|
+
</div>
|
822
|
+
<hr>
|
823
|
+
<div class="refsect2" lang="en">
|
824
|
+
<a name="cairo-pattern-get-radial-circles"></a><h3>cairo_pattern_get_radial_circles ()</h3>
|
825
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_get_radial_circles (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
826
|
+
double *x0,
|
827
|
+
double *y0,
|
828
|
+
double *r0,
|
829
|
+
double *x1,
|
830
|
+
double *y1,
|
831
|
+
double *r1);</pre>
|
832
|
+
<p>
|
833
|
+
Gets the gradient endpoint circles for a radial gradient, each
|
834
|
+
specified as a center coordinate and a radius.</p>
|
835
|
+
<p>
|
836
|
+
|
837
|
+
</p>
|
838
|
+
<div class="variablelist"><table border="0">
|
839
|
+
<col align="left" valign="top">
|
840
|
+
<tbody>
|
841
|
+
<tr>
|
842
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
843
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
844
|
+
</td>
|
845
|
+
</tr>
|
846
|
+
<tr>
|
847
|
+
<td><p><span class="term"><em class="parameter"><code>x0</code></em> :</span></p></td>
|
848
|
+
<td> return value for the x coordinate of the center of the first circle, or <code class="literal">NULL</code>
|
849
|
+
</td>
|
850
|
+
</tr>
|
851
|
+
<tr>
|
852
|
+
<td><p><span class="term"><em class="parameter"><code>y0</code></em> :</span></p></td>
|
853
|
+
<td> return value for the y coordinate of the center of the first circle, or <code class="literal">NULL</code>
|
854
|
+
</td>
|
855
|
+
</tr>
|
856
|
+
<tr>
|
857
|
+
<td><p><span class="term"><em class="parameter"><code>r0</code></em> :</span></p></td>
|
858
|
+
<td> return value for the radius of the first circle, or <code class="literal">NULL</code>
|
859
|
+
</td>
|
860
|
+
</tr>
|
861
|
+
<tr>
|
862
|
+
<td><p><span class="term"><em class="parameter"><code>x1</code></em> :</span></p></td>
|
863
|
+
<td> return value for the x coordinate of the center of the second circle, or <code class="literal">NULL</code>
|
864
|
+
</td>
|
865
|
+
</tr>
|
866
|
+
<tr>
|
867
|
+
<td><p><span class="term"><em class="parameter"><code>y1</code></em> :</span></p></td>
|
868
|
+
<td> return value for the y coordinate of the center of the second circle, or <code class="literal">NULL</code>
|
869
|
+
</td>
|
870
|
+
</tr>
|
871
|
+
<tr>
|
872
|
+
<td><p><span class="term"><em class="parameter"><code>r1</code></em> :</span></p></td>
|
873
|
+
<td> return value for the radius of the second circle, or <code class="literal">NULL</code>
|
874
|
+
</td>
|
875
|
+
</tr>
|
876
|
+
<tr>
|
877
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
878
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, or
|
879
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a> if <em class="parameter"><code>pattern</code></em> is not a radial
|
880
|
+
gradient pattern.
|
881
|
+
|
882
|
+
</td>
|
883
|
+
</tr>
|
884
|
+
</tbody>
|
885
|
+
</table></div>
|
886
|
+
<p class="since">Since 1.4
|
887
|
+
</p>
|
888
|
+
</div>
|
889
|
+
<hr>
|
890
|
+
<div class="refsect2" lang="en">
|
891
|
+
<a name="cairo-pattern-reference"></a><h3>cairo_pattern_reference ()</h3>
|
892
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a>* cairo_pattern_reference (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
893
|
+
<p>
|
894
|
+
Increases the reference count on <em class="parameter"><code>pattern</code></em> by one. This prevents
|
895
|
+
<em class="parameter"><code>pattern</code></em> from being destroyed until a matching call to
|
896
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-destroy" title="cairo_pattern_destroy ()"><code class="function">cairo_pattern_destroy()</code></a> is made.
|
897
|
+
</p>
|
898
|
+
<p>
|
899
|
+
The number of references to a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> can be get using
|
900
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-get-reference-count" title="cairo_pattern_get_reference_count ()"><code class="function">cairo_pattern_get_reference_count()</code></a>.</p>
|
901
|
+
<p>
|
902
|
+
|
903
|
+
</p>
|
904
|
+
<div class="variablelist"><table border="0">
|
905
|
+
<col align="left" valign="top">
|
906
|
+
<tbody>
|
907
|
+
<tr>
|
908
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
909
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
910
|
+
</td>
|
911
|
+
</tr>
|
912
|
+
<tr>
|
913
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
914
|
+
<td> the referenced <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>.
|
915
|
+
</td>
|
916
|
+
</tr>
|
917
|
+
</tbody>
|
918
|
+
</table></div>
|
919
|
+
</div>
|
920
|
+
<hr>
|
921
|
+
<div class="refsect2" lang="en">
|
922
|
+
<a name="cairo-pattern-destroy"></a><h3>cairo_pattern_destroy ()</h3>
|
923
|
+
<pre class="programlisting">void cairo_pattern_destroy (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
924
|
+
<p>
|
925
|
+
Decreases the reference count on <em class="parameter"><code>pattern</code></em> by one. If the result is
|
926
|
+
zero, then <em class="parameter"><code>pattern</code></em> and all associated resources are freed. See
|
927
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-reference" title="cairo_pattern_reference ()"><code class="function">cairo_pattern_reference()</code></a>.</p>
|
928
|
+
<p>
|
929
|
+
|
930
|
+
</p>
|
931
|
+
<div class="variablelist"><table border="0">
|
932
|
+
<col align="left" valign="top">
|
933
|
+
<tbody><tr>
|
934
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
935
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
936
|
+
</td>
|
937
|
+
</tr></tbody>
|
938
|
+
</table></div>
|
939
|
+
</div>
|
940
|
+
<hr>
|
941
|
+
<div class="refsect2" lang="en">
|
942
|
+
<a name="cairo-pattern-status"></a><h3>cairo_pattern_status ()</h3>
|
943
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_status (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
944
|
+
<p>
|
945
|
+
Checks whether an error has previously occurred for this
|
946
|
+
pattern.</p>
|
947
|
+
<p>
|
948
|
+
|
949
|
+
</p>
|
950
|
+
<div class="variablelist"><table border="0">
|
951
|
+
<col align="left" valign="top">
|
952
|
+
<tbody>
|
953
|
+
<tr>
|
954
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
955
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
956
|
+
</td>
|
957
|
+
</tr>
|
958
|
+
<tr>
|
959
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
960
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, <a class="link" href="cairo-error-status.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a>, or
|
961
|
+
<a class="link" href="cairo-error-status.html#CAIRO-STATUS-PATTERN-TYPE-MISMATCH:CAPS"><code class="literal">CAIRO_STATUS_PATTERN_TYPE_MISMATCH</code></a>.
|
962
|
+
</td>
|
963
|
+
</tr>
|
964
|
+
</tbody>
|
965
|
+
</table></div>
|
966
|
+
</div>
|
967
|
+
<hr>
|
968
|
+
<div class="refsect2" lang="en">
|
969
|
+
<a name="cairo-extend-t"></a><h3>enum cairo_extend_t</h3>
|
970
|
+
<pre class="programlisting">typedef enum _cairo_extend {
|
971
|
+
CAIRO_EXTEND_NONE,
|
972
|
+
CAIRO_EXTEND_REPEAT,
|
973
|
+
CAIRO_EXTEND_REFLECT,
|
974
|
+
CAIRO_EXTEND_PAD
|
975
|
+
} cairo_extend_t;
|
976
|
+
</pre>
|
977
|
+
<p>
|
978
|
+
<a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t"><span class="type">cairo_extend_t</span></a> is used to describe how pattern color/alpha will be
|
979
|
+
determined for areas "outside" the pattern's natural area, (for
|
980
|
+
example, outside the surface bounds or outside the gradient
|
981
|
+
geometry).
|
982
|
+
</p>
|
983
|
+
<p>
|
984
|
+
The default extend mode is <a class="link" href="cairo-pattern.html#CAIRO-EXTEND-NONE:CAPS"><code class="literal">CAIRO_EXTEND_NONE</code></a> for surface patterns
|
985
|
+
and <a class="link" href="cairo-pattern.html#CAIRO-EXTEND-PAD:CAPS"><code class="literal">CAIRO_EXTEND_PAD</code></a> for gradient patterns.
|
986
|
+
</p>
|
987
|
+
<p>
|
988
|
+
New entries may be added in future versions.</p>
|
989
|
+
<p>
|
990
|
+
|
991
|
+
</p>
|
992
|
+
<div class="variablelist"><table border="0">
|
993
|
+
<col align="left" valign="top">
|
994
|
+
<tbody>
|
995
|
+
<tr>
|
996
|
+
<td><p><a name="CAIRO-EXTEND-NONE:CAPS"></a><span class="term"><code class="literal">CAIRO_EXTEND_NONE</code></span></p></td>
|
997
|
+
<td> pixels outside of the source pattern
|
998
|
+
are fully transparent
|
999
|
+
</td>
|
1000
|
+
</tr>
|
1001
|
+
<tr>
|
1002
|
+
<td><p><a name="CAIRO-EXTEND-REPEAT:CAPS"></a><span class="term"><code class="literal">CAIRO_EXTEND_REPEAT</code></span></p></td>
|
1003
|
+
<td> the pattern is tiled by repeating
|
1004
|
+
</td>
|
1005
|
+
</tr>
|
1006
|
+
<tr>
|
1007
|
+
<td><p><a name="CAIRO-EXTEND-REFLECT:CAPS"></a><span class="term"><code class="literal">CAIRO_EXTEND_REFLECT</code></span></p></td>
|
1008
|
+
<td> the pattern is tiled by reflecting
|
1009
|
+
at the edges (Implemented for surface patterns since 1.6)
|
1010
|
+
</td>
|
1011
|
+
</tr>
|
1012
|
+
<tr>
|
1013
|
+
<td><p><a name="CAIRO-EXTEND-PAD:CAPS"></a><span class="term"><code class="literal">CAIRO_EXTEND_PAD</code></span></p></td>
|
1014
|
+
<td> pixels outside of the pattern copy
|
1015
|
+
the closest pixel from the source (Since 1.2; but only
|
1016
|
+
implemented for surface patterns since 1.6)
|
1017
|
+
</td>
|
1018
|
+
</tr>
|
1019
|
+
</tbody>
|
1020
|
+
</table></div>
|
1021
|
+
</div>
|
1022
|
+
<hr>
|
1023
|
+
<div class="refsect2" lang="en">
|
1024
|
+
<a name="cairo-pattern-set-extend"></a><h3>cairo_pattern_set_extend ()</h3>
|
1025
|
+
<pre class="programlisting">void cairo_pattern_set_extend (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1026
|
+
<a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t">cairo_extend_t</a> extend);</pre>
|
1027
|
+
<p>
|
1028
|
+
Sets the mode to be used for drawing outside the area of a pattern.
|
1029
|
+
See <a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t"><span class="type">cairo_extend_t</span></a> for details on the semantics of each extend
|
1030
|
+
strategy.
|
1031
|
+
</p>
|
1032
|
+
<p>
|
1033
|
+
The default extend mode is <a class="link" href="cairo-pattern.html#CAIRO-EXTEND-NONE:CAPS"><code class="literal">CAIRO_EXTEND_NONE</code></a> for surface patterns
|
1034
|
+
and <a class="link" href="cairo-pattern.html#CAIRO-EXTEND-PAD:CAPS"><code class="literal">CAIRO_EXTEND_PAD</code></a> for gradient patterns.</p>
|
1035
|
+
<p>
|
1036
|
+
|
1037
|
+
</p>
|
1038
|
+
<div class="variablelist"><table border="0">
|
1039
|
+
<col align="left" valign="top">
|
1040
|
+
<tbody>
|
1041
|
+
<tr>
|
1042
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1043
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1044
|
+
</td>
|
1045
|
+
</tr>
|
1046
|
+
<tr>
|
1047
|
+
<td><p><span class="term"><em class="parameter"><code>extend</code></em> :</span></p></td>
|
1048
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t"><span class="type">cairo_extend_t</span></a> describing how the area outside of the
|
1049
|
+
pattern will be drawn
|
1050
|
+
</td>
|
1051
|
+
</tr>
|
1052
|
+
</tbody>
|
1053
|
+
</table></div>
|
1054
|
+
</div>
|
1055
|
+
<hr>
|
1056
|
+
<div class="refsect2" lang="en">
|
1057
|
+
<a name="cairo-pattern-get-extend"></a><h3>cairo_pattern_get_extend ()</h3>
|
1058
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t">cairo_extend_t</a> cairo_pattern_get_extend (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
1059
|
+
<p>
|
1060
|
+
Gets the current extend mode for a pattern. See <a class="link" href="cairo-pattern.html#cairo-extend-t" title="enum cairo_extend_t"><span class="type">cairo_extend_t</span></a>
|
1061
|
+
for details on the semantics of each extend strategy.</p>
|
1062
|
+
<p>
|
1063
|
+
|
1064
|
+
</p>
|
1065
|
+
<div class="variablelist"><table border="0">
|
1066
|
+
<col align="left" valign="top">
|
1067
|
+
<tbody>
|
1068
|
+
<tr>
|
1069
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1070
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1071
|
+
</td>
|
1072
|
+
</tr>
|
1073
|
+
<tr>
|
1074
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1075
|
+
<td> the current extend strategy used for drawing the
|
1076
|
+
pattern.
|
1077
|
+
</td>
|
1078
|
+
</tr>
|
1079
|
+
</tbody>
|
1080
|
+
</table></div>
|
1081
|
+
</div>
|
1082
|
+
<hr>
|
1083
|
+
<div class="refsect2" lang="en">
|
1084
|
+
<a name="cairo-filter-t"></a><h3>enum cairo_filter_t</h3>
|
1085
|
+
<pre class="programlisting">typedef enum _cairo_filter {
|
1086
|
+
CAIRO_FILTER_FAST,
|
1087
|
+
CAIRO_FILTER_GOOD,
|
1088
|
+
CAIRO_FILTER_BEST,
|
1089
|
+
CAIRO_FILTER_NEAREST,
|
1090
|
+
CAIRO_FILTER_BILINEAR,
|
1091
|
+
CAIRO_FILTER_GAUSSIAN
|
1092
|
+
} cairo_filter_t;
|
1093
|
+
</pre>
|
1094
|
+
<p>
|
1095
|
+
<a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t"><span class="type">cairo_filter_t</span></a> is used to indicate what filtering should be
|
1096
|
+
applied when reading pixel values from patterns. See
|
1097
|
+
<code class="function">cairo_pattern_set_source()</code> for indicating the desired filter to be
|
1098
|
+
used with a particular pattern.</p>
|
1099
|
+
<p>
|
1100
|
+
|
1101
|
+
</p>
|
1102
|
+
<div class="variablelist"><table border="0">
|
1103
|
+
<col align="left" valign="top">
|
1104
|
+
<tbody>
|
1105
|
+
<tr>
|
1106
|
+
<td><p><a name="CAIRO-FILTER-FAST:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_FAST</code></span></p></td>
|
1107
|
+
<td> A high-performance filter, with quality similar
|
1108
|
+
to <a class="link" href="cairo-pattern.html#CAIRO-FILTER-NEAREST:CAPS"><code class="literal">CAIRO_FILTER_NEAREST</code></a>
|
1109
|
+
</td>
|
1110
|
+
</tr>
|
1111
|
+
<tr>
|
1112
|
+
<td><p><a name="CAIRO-FILTER-GOOD:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_GOOD</code></span></p></td>
|
1113
|
+
<td> A reasonable-performance filter, with quality
|
1114
|
+
similar to <a class="link" href="cairo-pattern.html#CAIRO-FILTER-BILINEAR:CAPS"><code class="literal">CAIRO_FILTER_BILINEAR</code></a>
|
1115
|
+
</td>
|
1116
|
+
</tr>
|
1117
|
+
<tr>
|
1118
|
+
<td><p><a name="CAIRO-FILTER-BEST:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_BEST</code></span></p></td>
|
1119
|
+
<td> The highest-quality available, performance may
|
1120
|
+
not be suitable for interactive use.
|
1121
|
+
</td>
|
1122
|
+
</tr>
|
1123
|
+
<tr>
|
1124
|
+
<td><p><a name="CAIRO-FILTER-NEAREST:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_NEAREST</code></span></p></td>
|
1125
|
+
<td> Nearest-neighbor filtering
|
1126
|
+
</td>
|
1127
|
+
</tr>
|
1128
|
+
<tr>
|
1129
|
+
<td><p><a name="CAIRO-FILTER-BILINEAR:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_BILINEAR</code></span></p></td>
|
1130
|
+
<td> Linear interpolation in two dimensions
|
1131
|
+
</td>
|
1132
|
+
</tr>
|
1133
|
+
<tr>
|
1134
|
+
<td><p><a name="CAIRO-FILTER-GAUSSIAN:CAPS"></a><span class="term"><code class="literal">CAIRO_FILTER_GAUSSIAN</code></span></p></td>
|
1135
|
+
<td> This filter value is currently
|
1136
|
+
unimplemented, and should not be used in current code.
|
1137
|
+
</td>
|
1138
|
+
</tr>
|
1139
|
+
</tbody>
|
1140
|
+
</table></div>
|
1141
|
+
</div>
|
1142
|
+
<hr>
|
1143
|
+
<div class="refsect2" lang="en">
|
1144
|
+
<a name="cairo-pattern-set-filter"></a><h3>cairo_pattern_set_filter ()</h3>
|
1145
|
+
<pre class="programlisting">void cairo_pattern_set_filter (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1146
|
+
<a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t">cairo_filter_t</a> filter);</pre>
|
1147
|
+
<p>
|
1148
|
+
Sets the filter to be used for resizing when using this pattern.
|
1149
|
+
See <a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t"><span class="type">cairo_filter_t</span></a> for details on each filter.
|
1150
|
+
</p>
|
1151
|
+
<p>
|
1152
|
+
* Note that you might want to control filtering even when you do not
|
1153
|
+
have an explicit <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> object, (for example when using
|
1154
|
+
<a class="link" href="cairo-context.html#cairo-set-source-surface" title="cairo_set_source_surface ()"><code class="function">cairo_set_source_surface()</code></a>). In these cases, it is convenient to
|
1155
|
+
use <a class="link" href="cairo-context.html#cairo-get-source" title="cairo_get_source ()"><code class="function">cairo_get_source()</code></a> to get access to the pattern that cairo
|
1156
|
+
creates implicitly. For example:
|
1157
|
+
</p>
|
1158
|
+
<p>
|
1159
|
+
</p>
|
1160
|
+
<div class="informalexample"><pre class="programlisting">
|
1161
|
+
cairo_set_source_surface (cr, image, x, y);
|
1162
|
+
cairo_pattern_set_filter (cairo_get_source (cr), %CAIRO_FILTER_NEAREST);
|
1163
|
+
</pre></div>
|
1164
|
+
<p>
|
1165
|
+
|
1166
|
+
</p>
|
1167
|
+
<div class="variablelist"><table border="0">
|
1168
|
+
<col align="left" valign="top">
|
1169
|
+
<tbody>
|
1170
|
+
<tr>
|
1171
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1172
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1173
|
+
</td>
|
1174
|
+
</tr>
|
1175
|
+
<tr>
|
1176
|
+
<td><p><span class="term"><em class="parameter"><code>filter</code></em> :</span></p></td>
|
1177
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t"><span class="type">cairo_filter_t</span></a> describing the filter to use for resizing
|
1178
|
+
the pattern
|
1179
|
+
</td>
|
1180
|
+
</tr>
|
1181
|
+
</tbody>
|
1182
|
+
</table></div>
|
1183
|
+
</div>
|
1184
|
+
<hr>
|
1185
|
+
<div class="refsect2" lang="en">
|
1186
|
+
<a name="cairo-pattern-get-filter"></a><h3>cairo_pattern_get_filter ()</h3>
|
1187
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t">cairo_filter_t</a> cairo_pattern_get_filter (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
1188
|
+
<p>
|
1189
|
+
Gets the current filter for a pattern. See <a class="link" href="cairo-pattern.html#cairo-filter-t" title="enum cairo_filter_t"><span class="type">cairo_filter_t</span></a>
|
1190
|
+
for details on each filter.</p>
|
1191
|
+
<p>
|
1192
|
+
|
1193
|
+
</p>
|
1194
|
+
<div class="variablelist"><table border="0">
|
1195
|
+
<col align="left" valign="top">
|
1196
|
+
<tbody>
|
1197
|
+
<tr>
|
1198
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1199
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1200
|
+
</td>
|
1201
|
+
</tr>
|
1202
|
+
<tr>
|
1203
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1204
|
+
<td> the current filter used for resizing the pattern.
|
1205
|
+
</td>
|
1206
|
+
</tr>
|
1207
|
+
</tbody>
|
1208
|
+
</table></div>
|
1209
|
+
</div>
|
1210
|
+
<hr>
|
1211
|
+
<div class="refsect2" lang="en">
|
1212
|
+
<a name="cairo-pattern-set-matrix"></a><h3>cairo_pattern_set_matrix ()</h3>
|
1213
|
+
<pre class="programlisting">void cairo_pattern_set_matrix (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1214
|
+
const <a class="link" href="cairo-matrix.html#cairo-matrix-t" title="cairo_matrix_t">cairo_matrix_t</a> *matrix);</pre>
|
1215
|
+
<p>
|
1216
|
+
Sets the pattern's transformation matrix to <em class="parameter"><code>matrix</code></em>. This matrix is
|
1217
|
+
a transformation from user space to pattern space.
|
1218
|
+
</p>
|
1219
|
+
<p>
|
1220
|
+
When a pattern is first created it always has the identity matrix
|
1221
|
+
for its transformation matrix, which means that pattern space is
|
1222
|
+
initially identical to user space.
|
1223
|
+
</p>
|
1224
|
+
<p>
|
1225
|
+
Important: Please note that the direction of this transformation
|
1226
|
+
matrix is from user space to pattern space. This means that if you
|
1227
|
+
imagine the flow from a pattern to user space (and on to device
|
1228
|
+
space), then coordinates in that flow will be transformed by the
|
1229
|
+
inverse of the pattern matrix.
|
1230
|
+
</p>
|
1231
|
+
<p>
|
1232
|
+
For example, if you want to make a pattern appear twice as large as
|
1233
|
+
it does by default the correct code to use is:
|
1234
|
+
</p>
|
1235
|
+
<p>
|
1236
|
+
</p>
|
1237
|
+
<div class="informalexample"><pre class="programlisting">
|
1238
|
+
cairo_matrix_init_scale (&matrix, 0.5, 0.5);
|
1239
|
+
cairo_pattern_set_matrix (pattern, &matrix);
|
1240
|
+
</pre></div>
|
1241
|
+
<p>
|
1242
|
+
</p>
|
1243
|
+
<p>
|
1244
|
+
Meanwhile, using values of 2.0 rather than 0.5 in the code above
|
1245
|
+
would cause the pattern to appear at half of its default size.
|
1246
|
+
</p>
|
1247
|
+
<p>
|
1248
|
+
Also, please note the discussion of the user-space locking
|
1249
|
+
semantics of <a class="link" href="cairo-context.html#cairo-set-source" title="cairo_set_source ()"><code class="function">cairo_set_source()</code></a>.</p>
|
1250
|
+
<p>
|
1251
|
+
|
1252
|
+
</p>
|
1253
|
+
<div class="variablelist"><table border="0">
|
1254
|
+
<col align="left" valign="top">
|
1255
|
+
<tbody>
|
1256
|
+
<tr>
|
1257
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1258
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1259
|
+
</td>
|
1260
|
+
</tr>
|
1261
|
+
<tr>
|
1262
|
+
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
|
1263
|
+
<td> a <a class="link" href="cairo-matrix.html#cairo-matrix-t" title="cairo_matrix_t"><span class="type">cairo_matrix_t</span></a>
|
1264
|
+
</td>
|
1265
|
+
</tr>
|
1266
|
+
</tbody>
|
1267
|
+
</table></div>
|
1268
|
+
</div>
|
1269
|
+
<hr>
|
1270
|
+
<div class="refsect2" lang="en">
|
1271
|
+
<a name="cairo-pattern-get-matrix"></a><h3>cairo_pattern_get_matrix ()</h3>
|
1272
|
+
<pre class="programlisting">void cairo_pattern_get_matrix (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1273
|
+
<a class="link" href="cairo-matrix.html#cairo-matrix-t" title="cairo_matrix_t">cairo_matrix_t</a> *matrix);</pre>
|
1274
|
+
<p>
|
1275
|
+
Stores the pattern's transformation matrix into <em class="parameter"><code>matrix</code></em>.</p>
|
1276
|
+
<p>
|
1277
|
+
|
1278
|
+
</p>
|
1279
|
+
<div class="variablelist"><table border="0">
|
1280
|
+
<col align="left" valign="top">
|
1281
|
+
<tbody>
|
1282
|
+
<tr>
|
1283
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1284
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1285
|
+
</td>
|
1286
|
+
</tr>
|
1287
|
+
<tr>
|
1288
|
+
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
|
1289
|
+
<td> return value for the matrix
|
1290
|
+
</td>
|
1291
|
+
</tr>
|
1292
|
+
</tbody>
|
1293
|
+
</table></div>
|
1294
|
+
</div>
|
1295
|
+
<hr>
|
1296
|
+
<div class="refsect2" lang="en">
|
1297
|
+
<a name="cairo-pattern-type-t"></a><h3>enum cairo_pattern_type_t</h3>
|
1298
|
+
<pre class="programlisting">typedef enum _cairo_pattern_type {
|
1299
|
+
CAIRO_PATTERN_TYPE_SOLID,
|
1300
|
+
CAIRO_PATTERN_TYPE_SURFACE,
|
1301
|
+
CAIRO_PATTERN_TYPE_LINEAR,
|
1302
|
+
CAIRO_PATTERN_TYPE_RADIAL
|
1303
|
+
} cairo_pattern_type_t;
|
1304
|
+
</pre>
|
1305
|
+
<p>
|
1306
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-type-t" title="enum cairo_pattern_type_t"><span class="type">cairo_pattern_type_t</span></a> is used to describe the type of a given pattern.
|
1307
|
+
</p>
|
1308
|
+
<p>
|
1309
|
+
The type of a pattern is determined by the function used to create
|
1310
|
+
it. The <a class="link" href="cairo-pattern.html#cairo-pattern-create-rgb" title="cairo_pattern_create_rgb ()"><code class="function">cairo_pattern_create_rgb()</code></a> and <a class="link" href="cairo-pattern.html#cairo-pattern-create-rgba" title="cairo_pattern_create_rgba ()"><code class="function">cairo_pattern_create_rgba()</code></a>
|
1311
|
+
functions create SOLID patterns. The remaining
|
1312
|
+
cairo_pattern_create functions map to pattern types in obvious
|
1313
|
+
ways.
|
1314
|
+
</p>
|
1315
|
+
<p>
|
1316
|
+
The pattern type can be queried with <a class="link" href="cairo-pattern.html#cairo-pattern-get-type" title="cairo_pattern_get_type ()"><code class="function">cairo_pattern_get_type()</code></a>
|
1317
|
+
</p>
|
1318
|
+
<p>
|
1319
|
+
Most <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a> functions can be called with a pattern of any
|
1320
|
+
type, (though trying to change the extend or filter for a solid
|
1321
|
+
pattern will have no effect). A notable exception is
|
1322
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgb" title="cairo_pattern_add_color_stop_rgb ()"><code class="function">cairo_pattern_add_color_stop_rgb()</code></a> and
|
1323
|
+
<a class="link" href="cairo-pattern.html#cairo-pattern-add-color-stop-rgba" title="cairo_pattern_add_color_stop_rgba ()"><code class="function">cairo_pattern_add_color_stop_rgba()</code></a> which must only be called with
|
1324
|
+
gradient patterns (either LINEAR or RADIAL). Otherwise the pattern
|
1325
|
+
will be shutdown and put into an error state.
|
1326
|
+
</p>
|
1327
|
+
<p>
|
1328
|
+
New entries may be added in future versions.</p>
|
1329
|
+
<p>
|
1330
|
+
|
1331
|
+
</p>
|
1332
|
+
<div class="variablelist"><table border="0">
|
1333
|
+
<col align="left" valign="top">
|
1334
|
+
<tbody>
|
1335
|
+
<tr>
|
1336
|
+
<td><p><a name="CAIRO-PATTERN-TYPE-SOLID:CAPS"></a><span class="term"><code class="literal">CAIRO_PATTERN_TYPE_SOLID</code></span></p></td>
|
1337
|
+
<td> The pattern is a solid (uniform)
|
1338
|
+
color. It may be opaque or translucent.
|
1339
|
+
</td>
|
1340
|
+
</tr>
|
1341
|
+
<tr>
|
1342
|
+
<td><p><a name="CAIRO-PATTERN-TYPE-SURFACE:CAPS"></a><span class="term"><code class="literal">CAIRO_PATTERN_TYPE_SURFACE</code></span></p></td>
|
1343
|
+
<td> The pattern is a based on a surface (an image).
|
1344
|
+
</td>
|
1345
|
+
</tr>
|
1346
|
+
<tr>
|
1347
|
+
<td><p><a name="CAIRO-PATTERN-TYPE-LINEAR:CAPS"></a><span class="term"><code class="literal">CAIRO_PATTERN_TYPE_LINEAR</code></span></p></td>
|
1348
|
+
<td> The pattern is a linear gradient.
|
1349
|
+
</td>
|
1350
|
+
</tr>
|
1351
|
+
<tr>
|
1352
|
+
<td><p><a name="CAIRO-PATTERN-TYPE-RADIAL:CAPS"></a><span class="term"><code class="literal">CAIRO_PATTERN_TYPE_RADIAL</code></span></p></td>
|
1353
|
+
<td> The pattern is a radial gradient.
|
1354
|
+
</td>
|
1355
|
+
</tr>
|
1356
|
+
</tbody>
|
1357
|
+
</table></div>
|
1358
|
+
<p class="since">Since 1.2
|
1359
|
+
</p>
|
1360
|
+
</div>
|
1361
|
+
<hr>
|
1362
|
+
<div class="refsect2" lang="en">
|
1363
|
+
<a name="cairo-pattern-get-type"></a><h3>cairo_pattern_get_type ()</h3>
|
1364
|
+
<pre class="programlisting"><a class="link" href="cairo-pattern.html#cairo-pattern-type-t" title="enum cairo_pattern_type_t">cairo_pattern_type_t</a> cairo_pattern_get_type (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
1365
|
+
<p>
|
1366
|
+
This function returns the type a pattern.
|
1367
|
+
See <a class="link" href="cairo-pattern.html#cairo-pattern-type-t" title="enum cairo_pattern_type_t"><span class="type">cairo_pattern_type_t</span></a> for available types.</p>
|
1368
|
+
<p>
|
1369
|
+
|
1370
|
+
</p>
|
1371
|
+
<div class="variablelist"><table border="0">
|
1372
|
+
<col align="left" valign="top">
|
1373
|
+
<tbody>
|
1374
|
+
<tr>
|
1375
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1376
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1377
|
+
</td>
|
1378
|
+
</tr>
|
1379
|
+
<tr>
|
1380
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1381
|
+
<td> The type of <em class="parameter"><code>pattern</code></em>.
|
1382
|
+
|
1383
|
+
</td>
|
1384
|
+
</tr>
|
1385
|
+
</tbody>
|
1386
|
+
</table></div>
|
1387
|
+
<p class="since">Since 1.2
|
1388
|
+
</p>
|
1389
|
+
</div>
|
1390
|
+
<hr>
|
1391
|
+
<div class="refsect2" lang="en">
|
1392
|
+
<a name="cairo-pattern-get-reference-count"></a><h3>cairo_pattern_get_reference_count ()</h3>
|
1393
|
+
<pre class="programlisting">unsigned int cairo_pattern_get_reference_count (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern);</pre>
|
1394
|
+
<p>
|
1395
|
+
Returns the current reference count of <em class="parameter"><code>pattern</code></em>.</p>
|
1396
|
+
<p>
|
1397
|
+
|
1398
|
+
</p>
|
1399
|
+
<div class="variablelist"><table border="0">
|
1400
|
+
<col align="left" valign="top">
|
1401
|
+
<tbody>
|
1402
|
+
<tr>
|
1403
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1404
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1405
|
+
</td>
|
1406
|
+
</tr>
|
1407
|
+
<tr>
|
1408
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1409
|
+
<td> the current reference count of <em class="parameter"><code>pattern</code></em>. If the
|
1410
|
+
object is a nil object, 0 will be returned.
|
1411
|
+
|
1412
|
+
</td>
|
1413
|
+
</tr>
|
1414
|
+
</tbody>
|
1415
|
+
</table></div>
|
1416
|
+
<p class="since">Since 1.4
|
1417
|
+
</p>
|
1418
|
+
</div>
|
1419
|
+
<hr>
|
1420
|
+
<div class="refsect2" lang="en">
|
1421
|
+
<a name="cairo-pattern-set-user-data"></a><h3>cairo_pattern_set_user_data ()</h3>
|
1422
|
+
<pre class="programlisting"><a class="link" href="cairo-error-status.html#cairo-status-t" title="enum cairo_status_t">cairo_status_t</a> cairo_pattern_set_user_data (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1423
|
+
const <a class="link" href="cairo-types.html#cairo-user-data-key-t" title="cairo_user_data_key_t">cairo_user_data_key_t</a> *key,
|
1424
|
+
void *user_data,
|
1425
|
+
<a class="link" href="cairo-types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()">cairo_destroy_func_t</a> destroy);</pre>
|
1426
|
+
<p>
|
1427
|
+
Attach user data to <em class="parameter"><code>pattern</code></em>. To remove user data from a surface,
|
1428
|
+
call this function with the key that was used to set it and <code class="literal">NULL</code>
|
1429
|
+
for <em class="parameter"><code>data</code></em>.</p>
|
1430
|
+
<p>
|
1431
|
+
|
1432
|
+
</p>
|
1433
|
+
<div class="variablelist"><table border="0">
|
1434
|
+
<col align="left" valign="top">
|
1435
|
+
<tbody>
|
1436
|
+
<tr>
|
1437
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1438
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1439
|
+
</td>
|
1440
|
+
</tr>
|
1441
|
+
<tr>
|
1442
|
+
<td><p><span class="term"><em class="parameter"><code>key</code></em> :</span></p></td>
|
1443
|
+
<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
|
1444
|
+
</td>
|
1445
|
+
</tr>
|
1446
|
+
<tr>
|
1447
|
+
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
|
1448
|
+
<td> the user data to attach to the <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1449
|
+
</td>
|
1450
|
+
</tr>
|
1451
|
+
<tr>
|
1452
|
+
<td><p><span class="term"><em class="parameter"><code>destroy</code></em> :</span></p></td>
|
1453
|
+
<td> 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
|
1454
|
+
<a class="link" href="cairo-context.html#cairo-t" title="cairo_t"><span class="type">cairo_t</span></a> is destroyed or when new user data is attached using the
|
1455
|
+
same key.
|
1456
|
+
</td>
|
1457
|
+
</tr>
|
1458
|
+
<tr>
|
1459
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1460
|
+
<td> <a class="link" href="cairo-error-status.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or <a class="link" href="cairo-error-status.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a> if a
|
1461
|
+
slot could not be allocated for the user data.
|
1462
|
+
|
1463
|
+
</td>
|
1464
|
+
</tr>
|
1465
|
+
</tbody>
|
1466
|
+
</table></div>
|
1467
|
+
<p class="since">Since 1.4
|
1468
|
+
</p>
|
1469
|
+
</div>
|
1470
|
+
<hr>
|
1471
|
+
<div class="refsect2" lang="en">
|
1472
|
+
<a name="cairo-pattern-get-user-data"></a><h3>cairo_pattern_get_user_data ()</h3>
|
1473
|
+
<pre class="programlisting">void* cairo_pattern_get_user_data (<a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t">cairo_pattern_t</a> *pattern,
|
1474
|
+
const <a class="link" href="cairo-types.html#cairo-user-data-key-t" title="cairo_user_data_key_t">cairo_user_data_key_t</a> *key);</pre>
|
1475
|
+
<p>
|
1476
|
+
Return user data previously attached to <em class="parameter"><code>pattern</code></em> using the
|
1477
|
+
specified key. If no user data has been attached with the given
|
1478
|
+
key this function returns <code class="literal">NULL</code>.</p>
|
1479
|
+
<p>
|
1480
|
+
|
1481
|
+
</p>
|
1482
|
+
<div class="variablelist"><table border="0">
|
1483
|
+
<col align="left" valign="top">
|
1484
|
+
<tbody>
|
1485
|
+
<tr>
|
1486
|
+
<td><p><span class="term"><em class="parameter"><code>pattern</code></em> :</span></p></td>
|
1487
|
+
<td> a <a class="link" href="cairo-pattern.html#cairo-pattern-t" title="cairo_pattern_t"><span class="type">cairo_pattern_t</span></a>
|
1488
|
+
</td>
|
1489
|
+
</tr>
|
1490
|
+
<tr>
|
1491
|
+
<td><p><span class="term"><em class="parameter"><code>key</code></em> :</span></p></td>
|
1492
|
+
<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
|
1493
|
+
attached to
|
1494
|
+
</td>
|
1495
|
+
</tr>
|
1496
|
+
<tr>
|
1497
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
1498
|
+
<td> the user data previously attached or <code class="literal">NULL</code>.
|
1499
|
+
|
1500
|
+
</td>
|
1501
|
+
</tr>
|
1502
|
+
</tbody>
|
1503
|
+
</table></div>
|
1504
|
+
<p class="since">Since 1.4
|
1505
|
+
</p>
|
1506
|
+
</div>
|
1507
|
+
</div>
|
1508
|
+
<div class="refsect1" lang="en">
|
1509
|
+
<a name="cairo-pattern.see-also"></a><h2>See Also</h2>
|
1510
|
+
<p>
|
1511
|
+
</p>
|
1512
|
+
<div class="itemizedlist"><ul type="disc">
|
1513
|
+
<li><a class="link" href="cairo-context.html#cairo-t" title="cairo_t"><span class="type">cairo_t</span></a></li>
|
1514
|
+
<li><a class="link" href="cairo-surface.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a></li>
|
1515
|
+
</ul></div>
|
1516
|
+
<p>
|
1517
|
+
</p>
|
1518
|
+
</div>
|
1519
|
+
</div>
|
1520
|
+
<div class="footer">
|
1521
|
+
<hr>
|
1522
|
+
Generated by GTK-Doc V1.10</div>
|
1523
|
+
</body>
|
1524
|
+
</html>
|