cairo 1.8.5-x86-mingw32 → 1.10.0-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of cairo might be problematic. Click here for more details.
- data/NEWS +2 -2
- data/Rakefile +44 -7
- data/ext/cairo/cairo.def +28 -1
- data/ext/cairo/extconf.rb +14 -16
- data/ext/cairo/rb_cairo.c +4 -1
- data/ext/cairo/rb_cairo.h +65 -1
- data/ext/cairo/rb_cairo_constants.c +150 -3
- data/ext/cairo/rb_cairo_context.c +17 -0
- data/ext/cairo/rb_cairo_device.c +406 -0
- data/ext/cairo/rb_cairo_exception.c +83 -32
- data/ext/cairo/rb_cairo_io.c +166 -0
- data/ext/cairo/rb_cairo_io.h +44 -0
- data/ext/cairo/rb_cairo_matrix.c +1 -1
- data/ext/cairo/rb_cairo_private.h +3 -0
- data/ext/cairo/rb_cairo_region.c +385 -0
- data/ext/cairo/rb_cairo_surface.c +674 -199
- data/lib/1.8/cairo.so +0 -0
- data/lib/1.9/cairo.so +0 -0
- data/samples/blur.rb +2 -3
- data/samples/{pac2.rb → pac-nomralize.rb} +5 -6
- data/samples/pac-tee.rb +170 -0
- data/samples/pac.rb +2 -3
- data/samples/png.rb +2 -3
- data/samples/scalable.rb +2 -3
- data/samples/text-on-path.rb +2 -3
- data/samples/text2.rb +2 -3
- data/test/cairo-test-utils.rb +15 -0
- data/test/run-test.rb +5 -4
- data/test/test_context.rb +4 -4
- data/test/test_font_face.rb +34 -21
- data/test/test_recording_surface.rb +18 -0
- data/test/test_region.rb +102 -0
- data/test/test_script_device.rb +46 -0
- data/test/test_script_surface.rb +13 -0
- data/test/test_surface.rb +14 -4
- data/test/test_tee_surface.rb +32 -0
- data/test/test_xml_device.rb +22 -0
- data/test/test_xml_surface.rb +32 -0
- data/tmp/i386-mingw32/cairo/1.9.2/rbconfig.rb +1 -1
- data/vendor/local/bin/libcairo-2.dll +0 -0
- data/vendor/local/include/cairo/cairo-deprecated.h +1 -16
- data/vendor/local/include/cairo/cairo-features.h +7 -0
- data/vendor/local/include/cairo/cairo-ft.h +16 -9
- data/vendor/local/include/cairo/cairo-gobject.h +186 -0
- data/vendor/local/include/cairo/cairo-pdf.h +27 -1
- data/vendor/local/include/cairo/cairo-ps.h +1 -1
- data/vendor/local/include/cairo/cairo-script-interpreter.h +117 -0
- data/vendor/local/include/cairo/cairo-svg.h +1 -1
- data/vendor/local/include/cairo/cairo-version.h +2 -2
- data/vendor/local/include/cairo/cairo-win32.h +1 -1
- data/vendor/local/include/cairo/cairo.h +382 -26
- data/vendor/local/lib/cairo.def +44 -0
- data/vendor/local/lib/cairo.lib +0 -0
- data/vendor/local/lib/libcairo.dll.a +0 -0
- data/vendor/local/lib/pkgconfig/cairo-fc.pc +12 -0
- data/vendor/local/lib/pkgconfig/cairo-ft.pc +4 -4
- data/vendor/local/lib/pkgconfig/cairo-gobject.pc +12 -0
- data/vendor/local/lib/pkgconfig/cairo-pdf.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo-png.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo-ps.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo-svg.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo-win32-font.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo-win32.pc +3 -3
- data/vendor/local/lib/pkgconfig/cairo.pc +4 -4
- data/vendor/local/manifest/{cairo-dev_1.8.10-4_win32.mft → cairo-dev_1.10.0-1_win32.mft} +34 -27
- data/vendor/local/manifest/cairo_1.10.0-1_win32.mft +5 -0
- data/vendor/local/share/doc/{cairo_1.8.10-4_win32 → cairo_1.10.0-1_win32}/COPYING +9 -8
- data/vendor/local/share/doc/{cairo_1.8.10-4_win32 → cairo_1.10.0-1_win32}/COPYING-LGPL-2.1 +2 -2
- data/vendor/local/share/doc/{cairo_1.8.10-4_win32 → cairo_1.10.0-1_win32}/COPYING-MPL-1.1 +0 -0
- data/vendor/local/share/gtk-doc/html/cairo/bindings-errors.html +4 -14
- data/vendor/local/share/gtk-doc/html/cairo/bindings-fonts.html +5 -15
- data/vendor/local/share/gtk-doc/html/cairo/bindings-memory.html +7 -17
- data/vendor/local/share/gtk-doc/html/cairo/bindings-overloading.html +6 -16
- data/vendor/local/share/gtk-doc/html/cairo/bindings-path.html +6 -16
- data/vendor/local/share/gtk-doc/html/cairo/bindings-patterns.html +23 -28
- data/vendor/local/share/gtk-doc/html/cairo/bindings-return-values.html +3 -13
- data/vendor/local/share/gtk-doc/html/cairo/bindings-streams.html +3 -13
- data/vendor/local/share/gtk-doc/html/cairo/bindings-surfaces.html +7 -17
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Error-handling.html +373 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-FreeType-Fonts.html +330 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Image-Surfaces.html +478 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PDF-Surfaces.html +344 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PNG-Support.html +320 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Paths.html +1291 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-PostScript-Surfaces.html +622 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Quartz-(CGFont)-Fonts.html +134 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Quartz-Surfaces.html +210 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Regions.html +834 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-SVG-Surfaces.html +318 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Transformations.html +410 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Types.html +169 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-User-Fonts.html +715 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Version-Information.html +410 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Win32-Fonts.html +335 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-Win32-Surfaces.html +291 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-XLib-Surfaces.html +470 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-device-t.html +595 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-font-face-t.html +384 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-font-options-t.html +644 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-matrix-t.html +574 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-pattern-t.html +1457 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-scaled-font-t.html +1076 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-surface-t.html +1396 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-cairo-t.html +2743 -0
- data/vendor/local/share/gtk-doc/html/cairo/cairo-drawing.html +13 -20
- data/vendor/local/share/gtk-doc/html/cairo/cairo-fonts.html +13 -23
- data/vendor/local/share/gtk-doc/html/cairo/cairo-support.html +11 -21
- data/vendor/local/share/gtk-doc/html/cairo/cairo-surfaces.html +19 -26
- data/vendor/local/share/gtk-doc/html/cairo/cairo-text.html +279 -326
- data/vendor/local/share/gtk-doc/html/cairo/cairo.devhelp +411 -355
- data/vendor/local/share/gtk-doc/html/cairo/cairo.devhelp2 +579 -480
- data/vendor/local/share/gtk-doc/html/cairo/index-1.10.html +147 -0
- data/vendor/local/share/gtk-doc/html/cairo/index-1.2.html +88 -65
- data/vendor/local/share/gtk-doc/html/cairo/index-1.4.html +72 -47
- data/vendor/local/share/gtk-doc/html/cairo/index-1.6.html +43 -32
- data/vendor/local/share/gtk-doc/html/cairo/index-1.8.html +42 -41
- data/vendor/local/share/gtk-doc/html/cairo/index-all.html +542 -345
- data/vendor/local/share/gtk-doc/html/cairo/index.html +36 -39
- data/vendor/local/share/gtk-doc/html/cairo/index.sgml +674 -444
- data/vendor/local/share/gtk-doc/html/cairo/language-bindings.html +6 -16
- data/vendor/local/share/gtk-doc/html/cairo/style.css +152 -54
- data/vendor/local/src/tml/packaging/cairo_1.10.0-1_win32.log +1262 -0
- data/vendor/local/src/tml/packaging/{cairo_1.8.10-4_win32.sh → cairo_1.10.0-1_win32.sh} +3 -3
- metadata +137 -389
- data/doc/doc.css +0 -91
- data/doc/en/cairo-antialias.html +0 -38
- data/doc/en/cairo-clip-not-representable-error.html +0 -47
- data/doc/en/cairo-color-base.html +0 -69
- data/doc/en/cairo-color-cmyk.html +0 -157
- data/doc/en/cairo-color-hsv.html +0 -137
- data/doc/en/cairo-color-rgb.html +0 -142
- data/doc/en/cairo-color-x11.html +0 -173
- data/doc/en/cairo-color.html +0 -238
- data/doc/en/cairo-content.html +0 -37
- data/doc/en/cairo-context-blur.html +0 -39
- data/doc/en/cairo-context-circle.html +0 -39
- data/doc/en/cairo-context-color.html +0 -39
- data/doc/en/cairo-context-path.html +0 -44
- data/doc/en/cairo-context-rectangle.html +0 -39
- data/doc/en/cairo-context-triangle.html +0 -39
- data/doc/en/cairo-context.html +0 -643
- data/doc/en/cairo-error.html +0 -44
- data/doc/en/cairo-extend.html +0 -38
- data/doc/en/cairo-file-not-found.html +0 -47
- data/doc/en/cairo-fill-rule.html +0 -36
- data/doc/en/cairo-filter.html +0 -40
- data/doc/en/cairo-font-extents.html +0 -129
- data/doc/en/cairo-font-face.html +0 -38
- data/doc/en/cairo-font-options.html +0 -139
- data/doc/en/cairo-font-slant.html +0 -37
- data/doc/en/cairo-font-type-mismatch.html +0 -47
- data/doc/en/cairo-font-weight.html +0 -36
- data/doc/en/cairo-format.html +0 -46
- data/doc/en/cairo-glyph.html +0 -99
- data/doc/en/cairo-gradient-pattern.html +0 -74
- data/doc/en/cairo-hint-metrics.html +0 -37
- data/doc/en/cairo-hint-style.html +0 -39
- data/doc/en/cairo-image-surface.html +0 -82
- data/doc/en/cairo-invalid-clusters.html +0 -47
- data/doc/en/cairo-invalid-content-error.html +0 -47
- data/doc/en/cairo-invalid-dash-error.html +0 -47
- data/doc/en/cairo-invalid-dsc-comment-error.html +0 -47
- data/doc/en/cairo-invalid-format-error.html +0 -47
- data/doc/en/cairo-invalid-index-error.html +0 -47
- data/doc/en/cairo-invalid-matrix-error.html +0 -47
- data/doc/en/cairo-invalid-path-data-error.html +0 -47
- data/doc/en/cairo-invalid-pop-group-error.html +0 -47
- data/doc/en/cairo-invalid-restore-error.html +0 -47
- data/doc/en/cairo-invalid-slant.html +0 -47
- data/doc/en/cairo-invalid-status-error.html +0 -47
- data/doc/en/cairo-invalid-stride-error.html +0 -47
- data/doc/en/cairo-invalid-string-error.html +0 -47
- data/doc/en/cairo-invalid-visual-error.html +0 -47
- data/doc/en/cairo-invalid-weight.html +0 -47
- data/doc/en/cairo-line-cap.html +0 -37
- data/doc/en/cairo-line-join.html +0 -37
- data/doc/en/cairo-linear-pattern.html +0 -60
- data/doc/en/cairo-matrix.html +0 -259
- data/doc/en/cairo-negative-count.html +0 -47
- data/doc/en/cairo-no-current-point-error.html +0 -47
- data/doc/en/cairo-null-pointer-error.html +0 -47
- data/doc/en/cairo-operator.html +0 -48
- data/doc/en/cairo-paper-parse-error.html +0 -47
- data/doc/en/cairo-paper-unknown-paper-name.html +0 -66
- data/doc/en/cairo-paper-unknown-unit.html +0 -66
- data/doc/en/cairo-paper-unrecognized-paper-description.html +0 -66
- data/doc/en/cairo-paper.html +0 -184
- data/doc/en/cairo-path-close-path.html +0 -49
- data/doc/en/cairo-path-curve-to.html +0 -49
- data/doc/en/cairo-path-data-type.html +0 -38
- data/doc/en/cairo-path-data.html +0 -98
- data/doc/en/cairo-path-line-to.html +0 -49
- data/doc/en/cairo-path-move-to.html +0 -49
- data/doc/en/cairo-path.html +0 -155
- data/doc/en/cairo-pattern-type-mismatch-error.html +0 -47
- data/doc/en/cairo-pattern.html +0 -99
- data/doc/en/cairo-pdf-surface.html +0 -57
- data/doc/en/cairo-point.html +0 -74
- data/doc/en/cairo-ps-level.html +0 -49
- data/doc/en/cairo-ps-surface.html +0 -92
- data/doc/en/cairo-quartz-image-surface.html +0 -57
- data/doc/en/cairo-quartz-surface.html +0 -57
- data/doc/en/cairo-radial-pattern.html +0 -60
- data/doc/en/cairo-read-error.html +0 -47
- data/doc/en/cairo-rectangle.html +0 -89
- data/doc/en/cairo-scaled-font.html +0 -94
- data/doc/en/cairo-solid-pattern.html +0 -62
- data/doc/en/cairo-subpixel-order.html +0 -39
- data/doc/en/cairo-surface-finished-error.html +0 -47
- data/doc/en/cairo-surface-pattern.html +0 -57
- data/doc/en/cairo-surface-type-mismatch-error.html +0 -47
- data/doc/en/cairo-surface.html +0 -121
- data/doc/en/cairo-svg-surface.html +0 -77
- data/doc/en/cairo-svg-version.html +0 -49
- data/doc/en/cairo-temp-file-error.html +0 -47
- data/doc/en/cairo-text-cluster-flag.html +0 -35
- data/doc/en/cairo-text-cluster.html +0 -84
- data/doc/en/cairo-text-extents.html +0 -144
- data/doc/en/cairo-toy-font-face.html +0 -67
- data/doc/en/cairo-user-font-error.html +0 -47
- data/doc/en/cairo-user-font-face-text-to-glyphs-data.html +0 -94
- data/doc/en/cairo-user-font-face.html +0 -72
- data/doc/en/cairo-user-font-immutable.html +0 -47
- data/doc/en/cairo-win32-printing-surface.html +0 -57
- data/doc/en/cairo-win32-surface.html +0 -62
- data/doc/en/cairo-write-error.html +0 -47
- data/doc/en/cairo.html +0 -131
- data/doc/en/index.html +0 -1154
- data/doc/index.html +0 -18
- data/doc/ja/cairo-antialias.html +0 -57
- data/doc/ja/cairo-clip-not-representable-error.html +0 -56
- data/doc/ja/cairo-color-base.html +0 -75
- data/doc/ja/cairo-color-cmyk.html +0 -152
- data/doc/ja/cairo-color-hsv.html +0 -135
- data/doc/ja/cairo-color-rgb.html +0 -145
- data/doc/ja/cairo-color-x11.html +0 -183
- data/doc/ja/cairo-color.html +0 -317
- data/doc/ja/cairo-content.html +0 -51
- data/doc/ja/cairo-context-blur.html +0 -53
- data/doc/ja/cairo-context-circle.html +0 -54
- data/doc/ja/cairo-context-color.html +0 -52
- data/doc/ja/cairo-context-path.html +0 -77
- data/doc/ja/cairo-context-rectangle.html +0 -60
- data/doc/ja/cairo-context-triangle.html +0 -47
- data/doc/ja/cairo-context.html +0 -1542
- data/doc/ja/cairo-error.html +0 -56
- data/doc/ja/cairo-extend.html +0 -56
- data/doc/ja/cairo-file-not-found.html +0 -51
- data/doc/ja/cairo-fill-rule.html +0 -58
- data/doc/ja/cairo-filter.html +0 -43
- data/doc/ja/cairo-font-extents.html +0 -164
- data/doc/ja/cairo-font-face.html +0 -55
- data/doc/ja/cairo-font-options.html +0 -189
- data/doc/ja/cairo-font-slant.html +0 -50
- data/doc/ja/cairo-font-type-mismatch.html +0 -52
- data/doc/ja/cairo-font-weight.html +0 -47
- data/doc/ja/cairo-format.html +0 -81
- data/doc/ja/cairo-glyph.html +0 -115
- data/doc/ja/cairo-gradient-pattern.html +0 -119
- data/doc/ja/cairo-hint-metrics.html +0 -57
- data/doc/ja/cairo-hint-style.html +0 -64
- data/doc/ja/cairo-image-surface.html +0 -131
- data/doc/ja/cairo-invalid-clusters.html +0 -55
- data/doc/ja/cairo-invalid-content-error.html +0 -54
- data/doc/ja/cairo-invalid-dash-error.html +0 -54
- data/doc/ja/cairo-invalid-dsc-comment-error.html +0 -54
- data/doc/ja/cairo-invalid-format-error.html +0 -54
- data/doc/ja/cairo-invalid-index-error.html +0 -54
- data/doc/ja/cairo-invalid-matrix-error.html +0 -54
- data/doc/ja/cairo-invalid-path-data-error.html +0 -54
- data/doc/ja/cairo-invalid-pop-group-error.html +0 -54
- data/doc/ja/cairo-invalid-restore-error.html +0 -55
- data/doc/ja/cairo-invalid-slant.html +0 -57
- data/doc/ja/cairo-invalid-status-error.html +0 -55
- data/doc/ja/cairo-invalid-stride-error.html +0 -55
- data/doc/ja/cairo-invalid-string-error.html +0 -54
- data/doc/ja/cairo-invalid-visual-error.html +0 -57
- data/doc/ja/cairo-invalid-weight.html +0 -57
- data/doc/ja/cairo-line-cap.html +0 -50
- data/doc/ja/cairo-line-join.html +0 -53
- data/doc/ja/cairo-linear-pattern.html +0 -87
- data/doc/ja/cairo-matrix.html +0 -354
- data/doc/ja/cairo-negative-count.html +0 -52
- data/doc/ja/cairo-no-current-point-error.html +0 -54
- data/doc/ja/cairo-null-pointer-error.html +0 -54
- data/doc/ja/cairo-operator.html +0 -51
- data/doc/ja/cairo-paper-parse-error.html +0 -55
- data/doc/ja/cairo-paper-unknown-paper-name.html +0 -76
- data/doc/ja/cairo-paper-unknown-unit.html +0 -75
- data/doc/ja/cairo-paper-unrecognized-paper-description.html +0 -76
- data/doc/ja/cairo-paper.html +0 -357
- data/doc/ja/cairo-path-close-path.html +0 -57
- data/doc/ja/cairo-path-curve-to.html +0 -70
- data/doc/ja/cairo-path-data-type.html +0 -53
- data/doc/ja/cairo-path-data.html +0 -127
- data/doc/ja/cairo-path-line-to.html +0 -62
- data/doc/ja/cairo-path-move-to.html +0 -62
- data/doc/ja/cairo-path.html +0 -144
- data/doc/ja/cairo-pattern-type-mismatch-error.html +0 -56
- data/doc/ja/cairo-pattern.html +0 -128
- data/doc/ja/cairo-pdf-surface.html +0 -86
- data/doc/ja/cairo-point.html +0 -90
- data/doc/ja/cairo-ps-level.html +0 -62
- data/doc/ja/cairo-ps-surface.html +0 -214
- data/doc/ja/cairo-quartz-image-surface.html +0 -75
- data/doc/ja/cairo-quartz-surface.html +0 -93
- data/doc/ja/cairo-radial-pattern.html +0 -93
- data/doc/ja/cairo-read-error.html +0 -55
- data/doc/ja/cairo-rectangle.html +0 -109
- data/doc/ja/cairo-scaled-font.html +0 -180
- data/doc/ja/cairo-solid-pattern.html +0 -87
- data/doc/ja/cairo-subpixel-order.html +0 -57
- data/doc/ja/cairo-surface-finished-error.html +0 -54
- data/doc/ja/cairo-surface-pattern.html +0 -68
- data/doc/ja/cairo-surface-type-mismatch-error.html +0 -56
- data/doc/ja/cairo-surface.html +0 -213
- data/doc/ja/cairo-svg-surface.html +0 -114
- data/doc/ja/cairo-svg-version.html +0 -66
- data/doc/ja/cairo-temp-file-error.html +0 -50
- data/doc/ja/cairo-text-cluster-flag.html +0 -46
- data/doc/ja/cairo-text-cluster.html +0 -102
- data/doc/ja/cairo-text-extents.html +0 -163
- data/doc/ja/cairo-toy-font-face.html +0 -107
- data/doc/ja/cairo-user-font-error.html +0 -55
- data/doc/ja/cairo-user-font-face-text-to-glyphs-data.html +0 -156
- data/doc/ja/cairo-user-font-face.html +0 -268
- data/doc/ja/cairo-user-font-immutable.html +0 -54
- data/doc/ja/cairo-win32-printing-surface.html +0 -80
- data/doc/ja/cairo-win32-surface.html +0 -100
- data/doc/ja/cairo-write-error.html +0 -55
- data/doc/ja/cairo.html +0 -177
- data/doc/ja/index.html +0 -1156
- data/pkg-config.rb +0 -313
- data/test-unit/Rakefile +0 -30
- data/test-unit/bin/testrb +0 -5
- data/test-unit/lib/test/unit.rb +0 -280
- data/test-unit/lib/test/unit/assertionfailederror.rb +0 -14
- data/test-unit/lib/test/unit/assertions.rb +0 -722
- data/test-unit/lib/test/unit/attribute.rb +0 -125
- data/test-unit/lib/test/unit/autorunner.rb +0 -254
- data/test-unit/lib/test/unit/collector.rb +0 -43
- data/test-unit/lib/test/unit/collector/descendant.rb +0 -23
- data/test-unit/lib/test/unit/collector/dir.rb +0 -108
- data/test-unit/lib/test/unit/collector/load.rb +0 -135
- data/test-unit/lib/test/unit/collector/objectspace.rb +0 -34
- data/test-unit/lib/test/unit/color.rb +0 -61
- data/test-unit/lib/test/unit/diff.rb +0 -524
- data/test-unit/lib/test/unit/error.rb +0 -124
- data/test-unit/lib/test/unit/exceptionhandler.rb +0 -39
- data/test-unit/lib/test/unit/failure.rb +0 -110
- data/test-unit/lib/test/unit/fixture.rb +0 -185
- data/test-unit/lib/test/unit/notification.rb +0 -125
- data/test-unit/lib/test/unit/omission.rb +0 -143
- data/test-unit/lib/test/unit/pending.rb +0 -146
- data/test-unit/lib/test/unit/priority.rb +0 -146
- data/test-unit/lib/test/unit/runner/console.rb +0 -46
- data/test-unit/lib/test/unit/runner/emacs.rb +0 -8
- data/test-unit/lib/test/unit/testcase.rb +0 -281
- data/test-unit/lib/test/unit/testresult.rb +0 -89
- data/test-unit/lib/test/unit/testsuite.rb +0 -110
- data/test-unit/lib/test/unit/ui/console/outputlevel.rb +0 -14
- data/test-unit/lib/test/unit/ui/console/testrunner.rb +0 -195
- data/test-unit/lib/test/unit/ui/emacs/testrunner.rb +0 -49
- data/test-unit/lib/test/unit/ui/testrunner.rb +0 -20
- data/test-unit/lib/test/unit/ui/testrunnermediator.rb +0 -77
- data/test-unit/lib/test/unit/ui/testrunnerutilities.rb +0 -41
- data/test-unit/lib/test/unit/util/backtracefilter.rb +0 -41
- data/test-unit/lib/test/unit/util/observable.rb +0 -90
- data/test-unit/lib/test/unit/util/procwrapper.rb +0 -48
- data/test-unit/lib/test/unit/version.rb +0 -7
- data/test-unit/sample/adder.rb +0 -13
- data/test-unit/sample/subtracter.rb +0 -12
- data/test-unit/sample/tc_adder.rb +0 -18
- data/test-unit/sample/tc_subtracter.rb +0 -18
- data/test-unit/sample/ts_examples.rb +0 -7
- data/test-unit/test/collector/test_descendant.rb +0 -135
- data/test-unit/test/collector/test_dir.rb +0 -406
- data/test-unit/test/collector/test_load.rb +0 -333
- data/test-unit/test/collector/test_objectspace.rb +0 -98
- data/test-unit/test/run-test.rb +0 -13
- data/test-unit/test/test_assertions.rb +0 -693
- data/test-unit/test/test_attribute.rb +0 -86
- data/test-unit/test/test_color.rb +0 -37
- data/test-unit/test/test_diff.rb +0 -477
- data/test-unit/test/test_emacs_runner.rb +0 -60
- data/test-unit/test/test_error.rb +0 -26
- data/test-unit/test/test_failure.rb +0 -33
- data/test-unit/test/test_fixture.rb +0 -252
- data/test-unit/test/test_notification.rb +0 -33
- data/test-unit/test/test_omission.rb +0 -81
- data/test-unit/test/test_pending.rb +0 -70
- data/test-unit/test/test_priority.rb +0 -89
- data/test-unit/test/test_testcase.rb +0 -430
- data/test-unit/test/test_testresult.rb +0 -113
- data/test-unit/test/test_testsuite.rb +0 -129
- data/test-unit/test/testunit_test_util.rb +0 -14
- data/test-unit/test/ui/test_testrunmediator.rb +0 -20
- data/test-unit/test/util/test_backtracefilter.rb +0 -41
- data/test-unit/test/util/test_observable.rb +0 -102
- data/test-unit/test/util/test_procwrapper.rb +0 -36
- data/test/test_pkg_config.rb +0 -123
- data/vendor/local/include/libpng14/png.h +0 -2701
- data/vendor/local/include/libpng14/pngconf.h +0 -1525
- data/vendor/local/include/png.h +0 -2701
- data/vendor/local/include/pngconf.h +0 -1525
- data/vendor/local/include/zconf.h +0 -461
- data/vendor/local/include/zlib.h +0 -1589
- data/vendor/local/lib/libpng.def +0 -192
- data/vendor/local/lib/libpng.lib +0 -0
- data/vendor/local/lib/libpng14.dll.a +0 -0
- data/vendor/local/lib/libz.dll.a +0 -0
- data/vendor/local/lib/pkgconfig/libpng.pc +0 -11
- data/vendor/local/lib/pkgconfig/libpng14.pc +0 -11
- data/vendor/local/lib/zdll.lib +0 -0
- data/vendor/local/lib/zlib.def +0 -67
- data/vendor/local/manifest/cairo_1.8.10-4_win32.mft +0 -5
- data/vendor/local/manifest/libpng-dev_1.4.3-1_win32.mft +0 -15
- data/vendor/local/manifest/zlib-dev_1.2.5-2_win32.mft +0 -8
- data/vendor/local/share/gtk-doc/html/cairo/cairo-context.html +0 -2643
- data/vendor/local/share/gtk-doc/html/cairo/cairo-error-status.html +0 -360
- data/vendor/local/share/gtk-doc/html/cairo/cairo-font-face.html +0 -408
- data/vendor/local/share/gtk-doc/html/cairo/cairo-font-options.html +0 -678
- data/vendor/local/share/gtk-doc/html/cairo/cairo-ft-font.html +0 -319
- data/vendor/local/share/gtk-doc/html/cairo/cairo-image-surface.html +0 -473
- data/vendor/local/share/gtk-doc/html/cairo/cairo-matrix.html +0 -596
- data/vendor/local/share/gtk-doc/html/cairo/cairo-paths.html +0 -1274
- data/vendor/local/share/gtk-doc/html/cairo/cairo-pattern.html +0 -1485
- data/vendor/local/share/gtk-doc/html/cairo/cairo-pdf-surface.html +0 -238
- data/vendor/local/share/gtk-doc/html/cairo/cairo-png-functions.html +0 -341
- data/vendor/local/share/gtk-doc/html/cairo/cairo-ps-surface.html +0 -622
- data/vendor/local/share/gtk-doc/html/cairo/cairo-quartz-font.html +0 -151
- data/vendor/local/share/gtk-doc/html/cairo/cairo-quartz-surface.html +0 -219
- data/vendor/local/share/gtk-doc/html/cairo/cairo-scaled-font.html +0 -1023
- data/vendor/local/share/gtk-doc/html/cairo/cairo-surface.html +0 -1026
- data/vendor/local/share/gtk-doc/html/cairo/cairo-svg-surface.html +0 -321
- data/vendor/local/share/gtk-doc/html/cairo/cairo-transformations.html +0 -436
- data/vendor/local/share/gtk-doc/html/cairo/cairo-types.html +0 -133
- data/vendor/local/share/gtk-doc/html/cairo/cairo-user-font.html +0 -735
- data/vendor/local/share/gtk-doc/html/cairo/cairo-version-info.html +0 -345
- data/vendor/local/share/gtk-doc/html/cairo/cairo-win32-font.html +0 -358
- data/vendor/local/share/gtk-doc/html/cairo/cairo-win32-surface.html +0 -312
- data/vendor/local/share/gtk-doc/html/cairo/cairo-xlib-surface.html +0 -492
- data/vendor/local/share/man/man3/libpng.3 +0 -4455
- data/vendor/local/share/man/man3/libpngpf.3 +0 -808
- data/vendor/local/share/man/man5/png.5 +0 -74
- data/vendor/local/src/tml/packaging/cairo_1.8.10-4_win32.log +0 -920
- data/vendor/local/src/tml/packaging/libpng_1.4.3-1_win32.log +0 -272
- data/vendor/local/src/tml/packaging/libpng_1.4.3-1_win32.sh +0 -71
- data/vendor/local/src/tml/packaging/zlib_1.2.5-2_win32.log +0 -42
- data/vendor/local/src/tml/packaging/zlib_1.2.5-2_win32.sh +0 -189
@@ -0,0 +1,595 @@
|
|
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_device_t</title>
|
6
|
+
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
|
7
|
+
<link rel="home" href="index.html" title="Cairo: A Vector Graphics Library">
|
8
|
+
<link rel="up" href="cairo-surfaces.html" title="Surfaces">
|
9
|
+
<link rel="prev" href="cairo-surfaces.html" title="Surfaces">
|
10
|
+
<link rel="next" href="cairo-cairo-surface-t.html" title="cairo_surface_t">
|
11
|
+
<meta name="generator" content="GTK-Doc V1.15 (XML mode)">
|
12
|
+
<link rel="stylesheet" href="style.css" type="text/css">
|
13
|
+
</head>
|
14
|
+
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
15
|
+
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
|
16
|
+
<tr valign="middle">
|
17
|
+
<td><a accesskey="p" href="cairo-surfaces.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
|
18
|
+
<td><a accesskey="u" href="cairo-surfaces.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
|
19
|
+
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
|
20
|
+
<th width="100%" align="center">Cairo: A Vector Graphics Library</th>
|
21
|
+
<td><a accesskey="n" href="cairo-cairo-surface-t.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
|
22
|
+
</tr>
|
23
|
+
<tr><td colspan="5" class="shortcuts">
|
24
|
+
<a href="#cairo-cairo-device-t.synopsis" class="shortcut">Top</a>
|
25
|
+
|
|
26
|
+
<a href="#cairo-cairo-device-t.description" class="shortcut">Description</a>
|
27
|
+
</td></tr>
|
28
|
+
</table>
|
29
|
+
<div class="refentry" title="cairo_device_t">
|
30
|
+
<a name="cairo-cairo-device-t"></a><div class="titlepage"></div>
|
31
|
+
<div class="refnamediv"><table width="100%"><tr>
|
32
|
+
<td valign="top">
|
33
|
+
<h2><span class="refentrytitle"><a name="cairo-cairo-device-t.top_of_page"></a>cairo_device_t</span></h2>
|
34
|
+
<p>cairo_device_t — interface to underlying rendering system</p>
|
35
|
+
</td>
|
36
|
+
<td valign="top" align="right"></td>
|
37
|
+
</tr></table></div>
|
38
|
+
<div class="refsynopsisdiv" title="Synopsis">
|
39
|
+
<a name="cairo-cairo-device-t.synopsis"></a><h2>Synopsis</h2>
|
40
|
+
<pre class="synopsis">typedef <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t">cairo_device_t</a>;
|
41
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="returnvalue">cairo_device_t</span></a> * <a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()">cairo_device_reference</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
42
|
+
<span class="returnvalue">void</span> <a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()">cairo_device_destroy</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
43
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> <a class="link" href="cairo-cairo-device-t.html#cairo-device-status" title="cairo_device_status ()">cairo_device_status</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
44
|
+
<span class="returnvalue">void</span> <a class="link" href="cairo-cairo-device-t.html#cairo-device-finish" title="cairo_device_finish ()">cairo_device_finish</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
45
|
+
<span class="returnvalue">void</span> <a class="link" href="cairo-cairo-device-t.html#cairo-device-flush" title="cairo_device_flush ()">cairo_device_flush</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
46
|
+
enum <a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t">cairo_device_type_t</a>;
|
47
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="returnvalue">cairo_device_type_t</span></a> <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()">cairo_device_get_type</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
48
|
+
unsigned <span class="returnvalue">int</span> <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-reference-count" title="cairo_device_get_reference_count ()">cairo_device_get_reference_count</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
49
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> <a class="link" href="cairo-cairo-device-t.html#cairo-device-set-user-data" title="cairo_device_set_user_data ()">cairo_device_set_user_data</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
50
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>,
|
51
|
+
<em class="parameter"><code><span class="type">void</span> *user_data</code></em>,
|
52
|
+
<em class="parameter"><code><a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> destroy</code></em>);
|
53
|
+
<span class="returnvalue">void</span> * <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-user-data" title="cairo_device_get_user_data ()">cairo_device_get_user_data</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
54
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>);
|
55
|
+
<a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()">cairo_device_acquire</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
56
|
+
<span class="returnvalue">void</span> <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()">cairo_device_release</a> (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);
|
57
|
+
</pre>
|
58
|
+
</div>
|
59
|
+
<div class="refsect1" title="Description">
|
60
|
+
<a name="cairo-cairo-device-t.description"></a><h2>Description</h2>
|
61
|
+
<p>
|
62
|
+
Devices are the abstraction Cairo employs for the rendering system
|
63
|
+
used by a <a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>. You can get the device of a surface using
|
64
|
+
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-get-device" title="cairo_surface_get_device ()"><code class="function">cairo_surface_get_device()</code></a>.
|
65
|
+
</p>
|
66
|
+
<p>
|
67
|
+
Devices are created using custom functions specific to the rendering
|
68
|
+
system you want to use. See the documentation for the surface types
|
69
|
+
for those functions.
|
70
|
+
</p>
|
71
|
+
<p>
|
72
|
+
An important function that devices fulfill is sharing access to the
|
73
|
+
rendering system between Cairo and your application. If you want to
|
74
|
+
access a device directly that you used to draw to with Cairo, you must
|
75
|
+
first call <a class="link" href="cairo-cairo-device-t.html#cairo-device-flush" title="cairo_device_flush ()"><code class="function">cairo_device_flush()</code></a> to ensure that Cairo finishes all
|
76
|
+
operations on the device and resets it to a clean state.
|
77
|
+
</p>
|
78
|
+
<p>
|
79
|
+
Cairo also provides the functions <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a> and
|
80
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a> to synchronize access to the rendering system
|
81
|
+
in a multithreaded environment. This is done internally, but can also
|
82
|
+
be used by applications.
|
83
|
+
</p>
|
84
|
+
<p>
|
85
|
+
Putting this all together, a function that works with devices should
|
86
|
+
look something like this:
|
87
|
+
</p>
|
88
|
+
<div class="informalexample">
|
89
|
+
<table class="listing_frame" border="0" cellpadding="0" cellspacing="0">
|
90
|
+
<tbody>
|
91
|
+
<tr>
|
92
|
+
<td class="listing_lines" align="right"><pre>1
|
93
|
+
2
|
94
|
+
3
|
95
|
+
4
|
96
|
+
5
|
97
|
+
6
|
98
|
+
7
|
99
|
+
8
|
100
|
+
9
|
101
|
+
10
|
102
|
+
11
|
103
|
+
12
|
104
|
+
13
|
105
|
+
14
|
106
|
+
15
|
107
|
+
16
|
108
|
+
17
|
109
|
+
18
|
110
|
+
19
|
111
|
+
20</pre></td>
|
112
|
+
<td class="listing_code"><pre class="programlisting"><span class="type">void</span>
|
113
|
+
<span class="function">my_device_modifying_function</span><span class="normal"> </span><span class="symbol">(</span><span class="usertype">cairo_device_t</span><span class="normal"> </span><span class="symbol">*</span><span class="normal">device</span><span class="symbol">)</span>
|
114
|
+
<span class="cbracket">{</span>
|
115
|
+
<span class="normal"> </span><span class="usertype">cairo_status_t</span><span class="normal"> status</span><span class="symbol">;</span>
|
116
|
+
|
117
|
+
<span class="normal"> </span><span class="comment">// Ensure the device is properly reset</span>
|
118
|
+
<span class="normal"> </span><span class="function"><a href="/usr/share/gtk-doc/html/cairo/cairo-cairo-device-t.html#cairo-device-flush">cairo_device_flush</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">device</span><span class="symbol">);</span>
|
119
|
+
<span class="normal"> </span><span class="comment">// Try to acquire the device</span>
|
120
|
+
<span class="normal"> status </span><span class="symbol">=</span><span class="normal"> </span><span class="function"><a href="/usr/share/gtk-doc/html/cairo/cairo-cairo-device-t.html#cairo-device-acquire">cairo_device_acquire</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">device</span><span class="symbol">);</span>
|
121
|
+
<span class="normal"> </span><span class="keyword">if</span><span class="normal"> </span><span class="symbol">(</span><span class="normal">status </span><span class="symbol">!=</span><span class="normal"> <a href="/usr/share/gtk-doc/html/cairo/cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS">CAIRO_STATUS_SUCCESS</a></span><span class="symbol">)</span><span class="normal"> </span><span class="cbracket">{</span>
|
122
|
+
<span class="normal"> </span><span class="function">printf</span><span class="normal"> </span><span class="symbol">(</span><span class="string">"Failed to acquire the device: %s</span><span class="specialchar">\n</span><span class="string">"</span><span class="symbol">,</span><span class="normal"> </span><span class="function"><a href="/usr/share/gtk-doc/html/cairo/cairo-Error-handling.html#cairo-status-to-string">cairo_status_to_string</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">status</span><span class="symbol">));</span>
|
123
|
+
<span class="normal"> </span><span class="keyword">return</span><span class="symbol">;</span>
|
124
|
+
<span class="normal"> </span><span class="cbracket">}</span>
|
125
|
+
|
126
|
+
<span class="normal"> </span><span class="comment">// Do the custom operations on the device here.</span>
|
127
|
+
<span class="normal"> </span><span class="comment">// But do not call any Cairo functions that might acquire devices.</span>
|
128
|
+
<span class="normal"> </span>
|
129
|
+
<span class="normal"> </span><span class="comment">// Release the device when done.</span>
|
130
|
+
<span class="normal"> </span><span class="function"><a href="/usr/share/gtk-doc/html/cairo/cairo-cairo-device-t.html#cairo-device-release">cairo_device_release</a></span><span class="normal"> </span><span class="symbol">(</span><span class="normal">device</span><span class="symbol">);</span>
|
131
|
+
<span class="cbracket">}</span></pre></td>
|
132
|
+
</tr>
|
133
|
+
</tbody>
|
134
|
+
</table>
|
135
|
+
</div>
|
136
|
+
|
137
|
+
<p>
|
138
|
+
</p>
|
139
|
+
<p>
|
140
|
+
</p>
|
141
|
+
<div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;">
|
142
|
+
<h3 class="title">Note</h3>
|
143
|
+
<p>Please refer to the documentation of each backend for
|
144
|
+
additional usage requirements, guarantees provided, and
|
145
|
+
interactions with existing surface API of the device functions for
|
146
|
+
surfaces of that type.
|
147
|
+
</p>
|
148
|
+
</div>
|
149
|
+
<p>
|
150
|
+
</p>
|
151
|
+
</div>
|
152
|
+
<div class="refsect1" title="Details">
|
153
|
+
<a name="cairo-cairo-device-t.details"></a><h2>Details</h2>
|
154
|
+
<div class="refsect2" title="cairo_device_t">
|
155
|
+
<a name="cairo-device-t"></a><h3>cairo_device_t</h3>
|
156
|
+
<pre class="programlisting">typedef struct _cairo_device cairo_device_t;
|
157
|
+
</pre>
|
158
|
+
<p>
|
159
|
+
A <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> represents the driver interface for drawing
|
160
|
+
operations to a <a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>. There are different subtypes of
|
161
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> for different drawing backends; for example,
|
162
|
+
<code class="function">cairo_xcb_device_create()</code> creates a device that wraps the connection
|
163
|
+
to an X Windows System using the XCB library.
|
164
|
+
</p>
|
165
|
+
<p>
|
166
|
+
The type of a device can be queried with <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()"><code class="function">cairo_device_get_type()</code></a>.
|
167
|
+
</p>
|
168
|
+
<p>
|
169
|
+
Memory management of <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> is done with
|
170
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()"><code class="function">cairo_device_reference()</code></a> and <a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a>.
|
171
|
+
</p>
|
172
|
+
<p class="since">Since 1.10</p>
|
173
|
+
</div>
|
174
|
+
<hr>
|
175
|
+
<div class="refsect2" title="cairo_device_reference ()">
|
176
|
+
<a name="cairo-device-reference"></a><h3>cairo_device_reference ()</h3>
|
177
|
+
<pre class="programlisting"><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="returnvalue">cairo_device_t</span></a> * cairo_device_reference (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
178
|
+
<p>
|
179
|
+
Increases the reference count on <em class="parameter"><code>device</code></em> by one. This prevents
|
180
|
+
<em class="parameter"><code>device</code></em> from being destroyed until a matching call to
|
181
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a> is made.
|
182
|
+
</p>
|
183
|
+
<p>
|
184
|
+
The number of references to a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> can be get using
|
185
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-get-reference-count" title="cairo_device_get_reference_count ()"><code class="function">cairo_device_get_reference_count()</code></a>.
|
186
|
+
</p>
|
187
|
+
<div class="variablelist"><table border="0">
|
188
|
+
<col align="left" valign="top">
|
189
|
+
<tbody>
|
190
|
+
<tr>
|
191
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
192
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
193
|
+
</td>
|
194
|
+
</tr>
|
195
|
+
<tr>
|
196
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
197
|
+
<td> the referenced <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>.
|
198
|
+
|
199
|
+
</td>
|
200
|
+
</tr>
|
201
|
+
</tbody>
|
202
|
+
</table></div>
|
203
|
+
<p class="since">Since 1.10</p>
|
204
|
+
</div>
|
205
|
+
<hr>
|
206
|
+
<div class="refsect2" title="cairo_device_destroy ()">
|
207
|
+
<a name="cairo-device-destroy"></a><h3>cairo_device_destroy ()</h3>
|
208
|
+
<pre class="programlisting"><span class="returnvalue">void</span> cairo_device_destroy (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
209
|
+
<p>
|
210
|
+
Decreases the reference count on <em class="parameter"><code>device</code></em> by one. If the result is
|
211
|
+
zero, then <em class="parameter"><code>device</code></em> and all associated resources are freed. See
|
212
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-reference" title="cairo_device_reference ()"><code class="function">cairo_device_reference()</code></a>.
|
213
|
+
</p>
|
214
|
+
<p>
|
215
|
+
This function may acquire devices if the last reference was dropped.
|
216
|
+
</p>
|
217
|
+
<div class="variablelist"><table border="0">
|
218
|
+
<col align="left" valign="top">
|
219
|
+
<tbody><tr>
|
220
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
221
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
222
|
+
</td>
|
223
|
+
</tr></tbody>
|
224
|
+
</table></div>
|
225
|
+
<p class="since">Since 1.10</p>
|
226
|
+
</div>
|
227
|
+
<hr>
|
228
|
+
<div class="refsect2" title="cairo_device_status ()">
|
229
|
+
<a name="cairo-device-status"></a><h3>cairo_device_status ()</h3>
|
230
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> cairo_device_status (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
231
|
+
<p>
|
232
|
+
Checks whether an error has previously occurred for this
|
233
|
+
device.
|
234
|
+
</p>
|
235
|
+
<div class="variablelist"><table border="0">
|
236
|
+
<col align="left" valign="top">
|
237
|
+
<tbody>
|
238
|
+
<tr>
|
239
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
240
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
241
|
+
</td>
|
242
|
+
</tr>
|
243
|
+
<tr>
|
244
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
245
|
+
<td> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> on success or an error code if
|
246
|
+
the device is in an error state.
|
247
|
+
|
248
|
+
</td>
|
249
|
+
</tr>
|
250
|
+
</tbody>
|
251
|
+
</table></div>
|
252
|
+
<p class="since">Since 1.10</p>
|
253
|
+
</div>
|
254
|
+
<hr>
|
255
|
+
<div class="refsect2" title="cairo_device_finish ()">
|
256
|
+
<a name="cairo-device-finish"></a><h3>cairo_device_finish ()</h3>
|
257
|
+
<pre class="programlisting"><span class="returnvalue">void</span> cairo_device_finish (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
258
|
+
<p>
|
259
|
+
This function finishes the device and drops all references to
|
260
|
+
external resources. All surfaces, fonts and other objects created
|
261
|
+
for this <em class="parameter"><code>device</code></em> will be finished, too.
|
262
|
+
Further operations on the <em class="parameter"><code>device</code></em> will not affect the <em class="parameter"><code>device</code></em> but
|
263
|
+
will instead trigger a <code class="literal">CAIRO_STATUS_DEVICE_FINISHED</code> error.
|
264
|
+
</p>
|
265
|
+
<p>
|
266
|
+
When the last call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-destroy" title="cairo_device_destroy ()"><code class="function">cairo_device_destroy()</code></a> decreases the
|
267
|
+
reference count to zero, cairo will call <a class="link" href="cairo-cairo-device-t.html#cairo-device-finish" title="cairo_device_finish ()"><code class="function">cairo_device_finish()</code></a> if
|
268
|
+
it hasn't been called already, before freeing the resources
|
269
|
+
associated with the device.
|
270
|
+
</p>
|
271
|
+
<p>
|
272
|
+
This function may acquire devices.
|
273
|
+
</p>
|
274
|
+
<div class="variablelist"><table border="0">
|
275
|
+
<col align="left" valign="top">
|
276
|
+
<tbody><tr>
|
277
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
278
|
+
<td>the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> to finish
|
279
|
+
</td>
|
280
|
+
</tr></tbody>
|
281
|
+
</table></div>
|
282
|
+
<p class="since">Since 1.10</p>
|
283
|
+
</div>
|
284
|
+
<hr>
|
285
|
+
<div class="refsect2" title="cairo_device_flush ()">
|
286
|
+
<a name="cairo-device-flush"></a><h3>cairo_device_flush ()</h3>
|
287
|
+
<pre class="programlisting"><span class="returnvalue">void</span> cairo_device_flush (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
288
|
+
<p>
|
289
|
+
Finish any pending operations for the device and also restore any
|
290
|
+
temporary modifications cairo has made to the device's state.
|
291
|
+
This function must be called before switching from using the
|
292
|
+
device with Cairo to operating on it directly with native APIs.
|
293
|
+
If the device doesn't support direct access, then this function
|
294
|
+
does nothing.
|
295
|
+
</p>
|
296
|
+
<p>
|
297
|
+
This function may acquire devices.
|
298
|
+
</p>
|
299
|
+
<div class="variablelist"><table border="0">
|
300
|
+
<col align="left" valign="top">
|
301
|
+
<tbody><tr>
|
302
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
303
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
304
|
+
</td>
|
305
|
+
</tr></tbody>
|
306
|
+
</table></div>
|
307
|
+
<p class="since">Since 1.10</p>
|
308
|
+
</div>
|
309
|
+
<hr>
|
310
|
+
<div class="refsect2" title="enum cairo_device_type_t">
|
311
|
+
<a name="cairo-device-type-t"></a><h3>enum cairo_device_type_t</h3>
|
312
|
+
<pre class="programlisting">typedef enum _cairo_device_type {
|
313
|
+
CAIRO_DEVICE_TYPE_DRM,
|
314
|
+
CAIRO_DEVICE_TYPE_GL,
|
315
|
+
CAIRO_DEVICE_TYPE_SCRIPT,
|
316
|
+
CAIRO_DEVICE_TYPE_XCB,
|
317
|
+
CAIRO_DEVICE_TYPE_XLIB,
|
318
|
+
CAIRO_DEVICE_TYPE_XML,
|
319
|
+
} cairo_device_type_t;
|
320
|
+
</pre>
|
321
|
+
<p>
|
322
|
+
<a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a> is used to describe the type of a given
|
323
|
+
device. The devices types are also known as "backends" within cairo.
|
324
|
+
</p>
|
325
|
+
<p>
|
326
|
+
The device type can be queried with <a class="link" href="cairo-cairo-device-t.html#cairo-device-get-type" title="cairo_device_get_type ()"><code class="function">cairo_device_get_type()</code></a>
|
327
|
+
</p>
|
328
|
+
<p>
|
329
|
+
The various <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> functions can be used with surfaces of
|
330
|
+
any type, but some backends also provide type-specific functions
|
331
|
+
that must only be called with a device of the appropriate
|
332
|
+
type. These functions have names that begin with
|
333
|
+
cairo_<span class="emphasis"><em>type</em></span>_device such as <code class="function">cairo_xcb_device_debug_set_render_version()</code>.
|
334
|
+
</p>
|
335
|
+
<p>
|
336
|
+
The behavior of calling a type-specific function with a surface of
|
337
|
+
the wrong type is undefined.
|
338
|
+
</p>
|
339
|
+
<p>
|
340
|
+
New entries may be added in future versions.
|
341
|
+
</p>
|
342
|
+
<div class="variablelist"><table border="0">
|
343
|
+
<col align="left" valign="top">
|
344
|
+
<tbody>
|
345
|
+
<tr>
|
346
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-DRM:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_DRM</code></span></p></td>
|
347
|
+
<td>The surface is of type Direct Render Manager
|
348
|
+
</td>
|
349
|
+
</tr>
|
350
|
+
<tr>
|
351
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-GL:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_GL</code></span></p></td>
|
352
|
+
<td>The surface is of type OpenGL
|
353
|
+
</td>
|
354
|
+
</tr>
|
355
|
+
<tr>
|
356
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-SCRIPT:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_SCRIPT</code></span></p></td>
|
357
|
+
<td>The surface is of type script
|
358
|
+
</td>
|
359
|
+
</tr>
|
360
|
+
<tr>
|
361
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-XCB:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XCB</code></span></p></td>
|
362
|
+
<td>The surface is of type xcb
|
363
|
+
</td>
|
364
|
+
</tr>
|
365
|
+
<tr>
|
366
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-XLIB:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XLIB</code></span></p></td>
|
367
|
+
<td>The surface is of type xlib
|
368
|
+
</td>
|
369
|
+
</tr>
|
370
|
+
<tr>
|
371
|
+
<td><p><a name="CAIRO-DEVICE-TYPE-XML:CAPS"></a><span class="term"><code class="literal">CAIRO_DEVICE_TYPE_XML</code></span></p></td>
|
372
|
+
<td>The surface is of type XML
|
373
|
+
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-create-for-rectangle" title="cairo_surface_create_for_rectangle ()"><code class="function">cairo_surface_create_for_rectangle()</code></a>
|
374
|
+
</td>
|
375
|
+
</tr>
|
376
|
+
</tbody>
|
377
|
+
</table></div>
|
378
|
+
<p class="since">Since 1.10</p>
|
379
|
+
</div>
|
380
|
+
<hr>
|
381
|
+
<div class="refsect2" title="cairo_device_get_type ()">
|
382
|
+
<a name="cairo-device-get-type"></a><h3>cairo_device_get_type ()</h3>
|
383
|
+
<pre class="programlisting"><a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="returnvalue">cairo_device_type_t</span></a> cairo_device_get_type (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
384
|
+
<p>
|
385
|
+
This function returns the type of the device. See <a class="link" href="cairo-cairo-device-t.html#cairo-device-type-t" title="enum cairo_device_type_t"><span class="type">cairo_device_type_t</span></a>
|
386
|
+
for available types.
|
387
|
+
</p>
|
388
|
+
<div class="variablelist"><table border="0">
|
389
|
+
<col align="left" valign="top">
|
390
|
+
<tbody>
|
391
|
+
<tr>
|
392
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
393
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
394
|
+
</td>
|
395
|
+
</tr>
|
396
|
+
<tr>
|
397
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
398
|
+
<td> The type of <em class="parameter"><code>device</code></em>.
|
399
|
+
|
400
|
+
</td>
|
401
|
+
</tr>
|
402
|
+
</tbody>
|
403
|
+
</table></div>
|
404
|
+
<p class="since">Since 1.10</p>
|
405
|
+
</div>
|
406
|
+
<hr>
|
407
|
+
<div class="refsect2" title="cairo_device_get_reference_count ()">
|
408
|
+
<a name="cairo-device-get-reference-count"></a><h3>cairo_device_get_reference_count ()</h3>
|
409
|
+
<pre class="programlisting">unsigned <span class="returnvalue">int</span> cairo_device_get_reference_count (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
410
|
+
<p>
|
411
|
+
Returns the current reference count of <em class="parameter"><code>device</code></em>.
|
412
|
+
</p>
|
413
|
+
<div class="variablelist"><table border="0">
|
414
|
+
<col align="left" valign="top">
|
415
|
+
<tbody>
|
416
|
+
<tr>
|
417
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
418
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
419
|
+
</td>
|
420
|
+
</tr>
|
421
|
+
<tr>
|
422
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
423
|
+
<td> the current reference count of <em class="parameter"><code>device</code></em>. If the
|
424
|
+
object is a nil object, 0 will be returned.
|
425
|
+
|
426
|
+
</td>
|
427
|
+
</tr>
|
428
|
+
</tbody>
|
429
|
+
</table></div>
|
430
|
+
<p class="since">Since 1.10</p>
|
431
|
+
</div>
|
432
|
+
<hr>
|
433
|
+
<div class="refsect2" title="cairo_device_set_user_data ()">
|
434
|
+
<a name="cairo-device-set-user-data"></a><h3>cairo_device_set_user_data ()</h3>
|
435
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> cairo_device_set_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
436
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>,
|
437
|
+
<em class="parameter"><code><span class="type">void</span> *user_data</code></em>,
|
438
|
+
<em class="parameter"><code><a class="link" href="cairo-Types.html#cairo-destroy-func-t" title="cairo_destroy_func_t ()"><span class="type">cairo_destroy_func_t</span></a> destroy</code></em>);</pre>
|
439
|
+
<p>
|
440
|
+
Attach user data to <em class="parameter"><code>device</code></em>. To remove user data from a surface,
|
441
|
+
call this function with the key that was used to set it and <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>
|
442
|
+
for <em class="parameter"><code>data</code></em>.
|
443
|
+
</p>
|
444
|
+
<div class="variablelist"><table border="0">
|
445
|
+
<col align="left" valign="top">
|
446
|
+
<tbody>
|
447
|
+
<tr>
|
448
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
449
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
450
|
+
</td>
|
451
|
+
</tr>
|
452
|
+
<tr>
|
453
|
+
<td><p><span class="term"><em class="parameter"><code>key</code></em> :</span></p></td>
|
454
|
+
<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
|
455
|
+
</td>
|
456
|
+
</tr>
|
457
|
+
<tr>
|
458
|
+
<td><p><span class="term"><em class="parameter"><code>user_data</code></em> :</span></p></td>
|
459
|
+
<td>the user data to attach to the <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
460
|
+
</td>
|
461
|
+
</tr>
|
462
|
+
<tr>
|
463
|
+
<td><p><span class="term"><em class="parameter"><code>destroy</code></em> :</span></p></td>
|
464
|
+
<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
|
465
|
+
<a class="link" href="cairo-cairo-t.html#cairo-t" title="cairo_t"><span class="type">cairo_t</span></a> is destroyed or when new user data is attached using the
|
466
|
+
same key.
|
467
|
+
</td>
|
468
|
+
</tr>
|
469
|
+
<tr>
|
470
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
471
|
+
<td> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> or <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a> if a
|
472
|
+
slot could not be allocated for the user data.
|
473
|
+
|
474
|
+
</td>
|
475
|
+
</tr>
|
476
|
+
</tbody>
|
477
|
+
</table></div>
|
478
|
+
<p class="since">Since 1.10</p>
|
479
|
+
</div>
|
480
|
+
<hr>
|
481
|
+
<div class="refsect2" title="cairo_device_get_user_data ()">
|
482
|
+
<a name="cairo-device-get-user-data"></a><h3>cairo_device_get_user_data ()</h3>
|
483
|
+
<pre class="programlisting"><span class="returnvalue">void</span> * cairo_device_get_user_data (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>,
|
484
|
+
<em class="parameter"><code>const <a class="link" href="cairo-Types.html#cairo-user-data-key-t" title="cairo_user_data_key_t"><span class="type">cairo_user_data_key_t</span></a> *key</code></em>);</pre>
|
485
|
+
<p>
|
486
|
+
Return user data previously attached to <em class="parameter"><code>device</code></em> using the
|
487
|
+
specified key. If no user data has been attached with the given
|
488
|
+
key this function returns <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.
|
489
|
+
</p>
|
490
|
+
<div class="variablelist"><table border="0">
|
491
|
+
<col align="left" valign="top">
|
492
|
+
<tbody>
|
493
|
+
<tr>
|
494
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
495
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
496
|
+
</td>
|
497
|
+
</tr>
|
498
|
+
<tr>
|
499
|
+
<td><p><span class="term"><em class="parameter"><code>key</code></em> :</span></p></td>
|
500
|
+
<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
|
501
|
+
attached to
|
502
|
+
</td>
|
503
|
+
</tr>
|
504
|
+
<tr>
|
505
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
506
|
+
<td> the user data previously attached or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>.
|
507
|
+
|
508
|
+
</td>
|
509
|
+
</tr>
|
510
|
+
</tbody>
|
511
|
+
</table></div>
|
512
|
+
<p class="since">Since 1.10</p>
|
513
|
+
</div>
|
514
|
+
<hr>
|
515
|
+
<div class="refsect2" title="cairo_device_acquire ()">
|
516
|
+
<a name="cairo-device-acquire"></a><h3>cairo_device_acquire ()</h3>
|
517
|
+
<pre class="programlisting"><a class="link" href="cairo-Error-handling.html#cairo-status-t" title="enum cairo_status_t"><span class="returnvalue">cairo_status_t</span></a> cairo_device_acquire (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
518
|
+
<p>
|
519
|
+
Acquires the <em class="parameter"><code>device</code></em> for the current thread. This function will block
|
520
|
+
until no other thread has acquired the device.
|
521
|
+
</p>
|
522
|
+
<p>
|
523
|
+
If the return value is <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a>, you successfully acquired the
|
524
|
+
device. From now on your thread owns the device and no other thread will be
|
525
|
+
able to acquire it until a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a>. It is
|
526
|
+
allowed to recursively acquire the device multiple times from the same
|
527
|
+
thread.
|
528
|
+
</p>
|
529
|
+
<p>
|
530
|
+
</p>
|
531
|
+
<div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;">
|
532
|
+
<h3 class="title">Note</h3>
|
533
|
+
<p>You must never acquire two different devices at the same time
|
534
|
+
unless this is explicitly allowed. Otherwise the possibility of deadlocks
|
535
|
+
exist.
|
536
|
+
</p>
|
537
|
+
<p>
|
538
|
+
As various Cairo functions can acquire devices when called, these functions
|
539
|
+
may also cause deadlocks when you call them with an acquired device. So you
|
540
|
+
must not have a device acquired when calling them. These functions are
|
541
|
+
marked in the documentation.
|
542
|
+
</p>
|
543
|
+
</div>
|
544
|
+
<p>
|
545
|
+
</p>
|
546
|
+
<div class="variablelist"><table border="0">
|
547
|
+
<col align="left" valign="top">
|
548
|
+
<tbody>
|
549
|
+
<tr>
|
550
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
551
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
552
|
+
</td>
|
553
|
+
</tr>
|
554
|
+
<tr>
|
555
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
556
|
+
<td> <a class="link" href="cairo-Error-handling.html#CAIRO-STATUS-SUCCESS:CAPS"><code class="literal">CAIRO_STATUS_SUCCESS</code></a> on success or an error code if
|
557
|
+
the device is in an error state and could not be
|
558
|
+
acquired. After a successful call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a>,
|
559
|
+
a matching call to <a class="link" href="cairo-cairo-device-t.html#cairo-device-release" title="cairo_device_release ()"><code class="function">cairo_device_release()</code></a> is required.
|
560
|
+
|
561
|
+
</td>
|
562
|
+
</tr>
|
563
|
+
</tbody>
|
564
|
+
</table></div>
|
565
|
+
<p class="since">Since 1.10</p>
|
566
|
+
</div>
|
567
|
+
<hr>
|
568
|
+
<div class="refsect2" title="cairo_device_release ()">
|
569
|
+
<a name="cairo-device-release"></a><h3>cairo_device_release ()</h3>
|
570
|
+
<pre class="programlisting"><span class="returnvalue">void</span> cairo_device_release (<em class="parameter"><code><a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a> *device</code></em>);</pre>
|
571
|
+
<p>
|
572
|
+
Releases a <em class="parameter"><code>device</code></em> previously acquired using <a class="link" href="cairo-cairo-device-t.html#cairo-device-acquire" title="cairo_device_acquire ()"><code class="function">cairo_device_acquire()</code></a>. See
|
573
|
+
that function for details.
|
574
|
+
</p>
|
575
|
+
<div class="variablelist"><table border="0">
|
576
|
+
<col align="left" valign="top">
|
577
|
+
<tbody><tr>
|
578
|
+
<td><p><span class="term"><em class="parameter"><code>device</code></em> :</span></p></td>
|
579
|
+
<td>a <a class="link" href="cairo-cairo-device-t.html#cairo-device-t" title="cairo_device_t"><span class="type">cairo_device_t</span></a>
|
580
|
+
</td>
|
581
|
+
</tr></tbody>
|
582
|
+
</table></div>
|
583
|
+
<p class="since">Since 1.10</p>
|
584
|
+
</div>
|
585
|
+
</div>
|
586
|
+
<div class="refsect1" title="See Also">
|
587
|
+
<a name="cairo-cairo-device-t.see-also"></a><h2>See Also</h2>
|
588
|
+
<a class="link" href="cairo-cairo-surface-t.html#cairo-surface-t" title="cairo_surface_t"><span class="type">cairo_surface_t</span></a>
|
589
|
+
</div>
|
590
|
+
</div>
|
591
|
+
<div class="footer">
|
592
|
+
<hr>
|
593
|
+
Generated by GTK-Doc V1.15</div>
|
594
|
+
</body>
|
595
|
+
</html>
|