cairo 1.6.1-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/AUTHORS +4 -0
- data/COPYING +59 -0
- data/ChangeLog +1320 -0
- data/GPL +340 -0
- data/NEWS +98 -0
- data/README +70 -0
- data/Rakefile +215 -0
- data/cairo/bin/libcairo-2.dll +0 -0
- data/cairo/bin/libpng13.dll +0 -0
- data/cairo/bin/zlib1.dll +0 -0
- data/cairo/include/cairo/cairo-deprecated.h +142 -0
- data/cairo/include/cairo/cairo-features.h +35 -0
- data/cairo/include/cairo/cairo-pdf.h +68 -0
- data/cairo/include/cairo/cairo-ps.h +114 -0
- data/cairo/include/cairo/cairo-svg.h +82 -0
- data/cairo/include/cairo/cairo-win32.h +104 -0
- data/cairo/include/cairo/cairo.h +1945 -0
- data/cairo/include/libpng13/png.h +3419 -0
- data/cairo/include/libpng13/pngconf.h +1437 -0
- data/cairo/lib/cairo.def +251 -0
- data/cairo/lib/cairo.lib +0 -0
- data/cairo/lib/libcairo.dll.a +0 -0
- data/cairo/lib/libpng.def +372 -0
- data/cairo/lib/libpng13.dll.a +0 -0
- data/cairo/lib/pkgconfig/cairo-pdf.pc +12 -0
- data/cairo/lib/pkgconfig/cairo-png.pc +12 -0
- data/cairo/lib/pkgconfig/cairo-ps.pc +12 -0
- data/cairo/lib/pkgconfig/cairo-svg.pc +12 -0
- data/cairo/lib/pkgconfig/cairo-win32-font.pc +12 -0
- data/cairo/lib/pkgconfig/cairo-win32.pc +12 -0
- data/cairo/lib/pkgconfig/cairo.pc +13 -0
- data/cairo/lib/pkgconfig/libpng.pc +14 -0
- data/cairo/lib/pkgconfig/libpng13.pc +14 -0
- data/cairo/make/cairo-1.6.4-1.sh +55 -0
- data/cairo/manifest/cairo-1.6.4-1.mft +6 -0
- data/cairo/manifest/cairo-dev-1.6.4-1.mft +72 -0
- data/cairo/manifest/libpng-dev-1.2.8.mft +7 -0
- data/cairo/share/doc/cairo-1.6.4-1/COPYING +32 -0
- data/cairo/share/doc/cairo-1.6.4-1/COPYING-LGPL-2.1 +510 -0
- data/cairo/share/doc/cairo-1.6.4-1/COPYING-MPL-1.1 +470 -0
- data/cairo/share/gtk-doc/html/cairo/Drawing.html +53 -0
- data/cairo/share/gtk-doc/html/cairo/Fonts.html +56 -0
- data/cairo/share/gtk-doc/html/cairo/Support.html +50 -0
- data/cairo/share/gtk-doc/html/cairo/Surfaces.html +65 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-errors.html +128 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-fonts.html +59 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-memory.html +129 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-overloading.html +127 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-path.html +123 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-patterns.html +63 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-return-values.html +126 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-streams.html +98 -0
- data/cairo/share/gtk-doc/html/cairo/bindings-surfaces.html +99 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Error-Handling.html +328 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Font-Options.html +720 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-FreeType-Fonts.html +297 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Image-Surfaces.html +484 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-PDF-Surfaces.html +246 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-PNG-Support.html +345 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Paths.html +1336 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Patterns.html +1560 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-PostScript-Surfaces.html +656 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Quartz-Fonts.html +161 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Quartz-Surfaces.html +232 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-SVG-Surfaces.html +337 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Scaled-Fonts.html +823 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Text.html +836 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Transformations.html +462 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Types.html +143 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Version-Information.html +325 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Win32-Fonts.html +381 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-Win32-Surfaces.html +331 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-XLib-Surfaces.html +525 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-font-face-t.html +427 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-matrix-t.html +626 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-surface-t.html +995 -0
- data/cairo/share/gtk-doc/html/cairo/cairo-cairo-t.html +2795 -0
- data/cairo/share/gtk-doc/html/cairo/cairo.devhelp +432 -0
- data/cairo/share/gtk-doc/html/cairo/cairo.devhelp2 +432 -0
- data/cairo/share/gtk-doc/html/cairo/home.png +0 -0
- data/cairo/share/gtk-doc/html/cairo/index-1.2.html +137 -0
- data/cairo/share/gtk-doc/html/cairo/index-1.4.html +105 -0
- data/cairo/share/gtk-doc/html/cairo/index-1.6.html +65 -0
- data/cairo/share/gtk-doc/html/cairo/index.html +134 -0
- data/cairo/share/gtk-doc/html/cairo/index.sgml +466 -0
- data/cairo/share/gtk-doc/html/cairo/ix01.html +693 -0
- data/cairo/share/gtk-doc/html/cairo/language-bindings.html +79 -0
- data/cairo/share/gtk-doc/html/cairo/left.png +0 -0
- data/cairo/share/gtk-doc/html/cairo/right.png +0 -0
- data/cairo/share/gtk-doc/html/cairo/style.css +148 -0
- data/cairo/share/gtk-doc/html/cairo/up.png +0 -0
- data/doc/doc.css +91 -0
- data/doc/en/cairo-antialias.html +41 -0
- data/doc/en/cairo-antialias.rd +16 -0
- data/doc/en/cairo-clip-not-representable-error.html +50 -0
- data/doc/en/cairo-clip-not-representable-error.rd +17 -0
- data/doc/en/cairo-color-base.html +72 -0
- data/doc/en/cairo-color-base.rd +38 -0
- data/doc/en/cairo-color-cmyk.html +160 -0
- data/doc/en/cairo-color-cmyk.rd +107 -0
- data/doc/en/cairo-color-hsv.html +140 -0
- data/doc/en/cairo-color-hsv.rd +91 -0
- data/doc/en/cairo-color-rgb.html +145 -0
- data/doc/en/cairo-color-rgb.rd +95 -0
- data/doc/en/cairo-color-x11.html +176 -0
- data/doc/en/cairo-color-x11.rd +151 -0
- data/doc/en/cairo-color.html +241 -0
- data/doc/en/cairo-color.rd +213 -0
- data/doc/en/cairo-content.html +40 -0
- data/doc/en/cairo-content.rd +15 -0
- data/doc/en/cairo-context-blur.html +42 -0
- data/doc/en/cairo-context-blur.rd +15 -0
- data/doc/en/cairo-context-circle.html +42 -0
- data/doc/en/cairo-context-circle.rd +15 -0
- data/doc/en/cairo-context-color.html +42 -0
- data/doc/en/cairo-context-color.rd +15 -0
- data/doc/en/cairo-context-path.html +47 -0
- data/doc/en/cairo-context-path.rd +19 -0
- data/doc/en/cairo-context-rectangle.html +42 -0
- data/doc/en/cairo-context-rectangle.rd +15 -0
- data/doc/en/cairo-context-triangle.html +42 -0
- data/doc/en/cairo-context-triangle.rd +15 -0
- data/doc/en/cairo-context.html +636 -0
- data/doc/en/cairo-context.rd +491 -0
- data/doc/en/cairo-error.html +47 -0
- data/doc/en/cairo-error.rd +16 -0
- data/doc/en/cairo-extend.html +41 -0
- data/doc/en/cairo-extend.rd +16 -0
- data/doc/en/cairo-file-not-found.html +50 -0
- data/doc/en/cairo-file-not-found.rd +17 -0
- data/doc/en/cairo-fill-rule.html +39 -0
- data/doc/en/cairo-fill-rule.rd +14 -0
- data/doc/en/cairo-filter.html +43 -0
- data/doc/en/cairo-filter.rd +18 -0
- data/doc/en/cairo-font-extents.html +74 -0
- data/doc/en/cairo-font-extents.rd +40 -0
- data/doc/en/cairo-font-face.html +41 -0
- data/doc/en/cairo-font-face.rd +14 -0
- data/doc/en/cairo-font-options.html +142 -0
- data/doc/en/cairo-font-options.rd +94 -0
- data/doc/en/cairo-font-slant.html +40 -0
- data/doc/en/cairo-font-slant.rd +15 -0
- data/doc/en/cairo-font-weight.html +39 -0
- data/doc/en/cairo-font-weight.rd +14 -0
- data/doc/en/cairo-format.html +49 -0
- data/doc/en/cairo-format.rd +22 -0
- data/doc/en/cairo-glyph.html +102 -0
- data/doc/en/cairo-glyph.rd +62 -0
- data/doc/en/cairo-gradient-pattern.html +77 -0
- data/doc/en/cairo-gradient-pattern.rd +41 -0
- data/doc/en/cairo-hint-metrics.html +40 -0
- data/doc/en/cairo-hint-metrics.rd +15 -0
- data/doc/en/cairo-hint-style.html +42 -0
- data/doc/en/cairo-hint-style.rd +17 -0
- data/doc/en/cairo-image-surface.html +85 -0
- data/doc/en/cairo-image-surface.rd +47 -0
- data/doc/en/cairo-invalid-content-error.html +50 -0
- data/doc/en/cairo-invalid-content-error.rd +17 -0
- data/doc/en/cairo-invalid-dash-error.html +50 -0
- data/doc/en/cairo-invalid-dash-error.rd +17 -0
- data/doc/en/cairo-invalid-dsc-comment-error.html +50 -0
- data/doc/en/cairo-invalid-dsc-comment-error.rd +17 -0
- data/doc/en/cairo-invalid-format-error.html +50 -0
- data/doc/en/cairo-invalid-format-error.rd +17 -0
- data/doc/en/cairo-invalid-index-error.html +50 -0
- data/doc/en/cairo-invalid-index-error.rd +17 -0
- data/doc/en/cairo-invalid-matrix-error.html +50 -0
- data/doc/en/cairo-invalid-matrix-error.rd +17 -0
- data/doc/en/cairo-invalid-path-data-error.html +50 -0
- data/doc/en/cairo-invalid-path-data-error.rd +17 -0
- data/doc/en/cairo-invalid-pop-group-error.html +50 -0
- data/doc/en/cairo-invalid-pop-group-error.rd +17 -0
- data/doc/en/cairo-invalid-restore-error.html +50 -0
- data/doc/en/cairo-invalid-restore-error.rd +17 -0
- data/doc/en/cairo-invalid-status-error.html +50 -0
- data/doc/en/cairo-invalid-status-error.rd +17 -0
- data/doc/en/cairo-invalid-stride-error.html +50 -0
- data/doc/en/cairo-invalid-stride-error.rd +17 -0
- data/doc/en/cairo-invalid-string-error.html +50 -0
- data/doc/en/cairo-invalid-string-error.rd +17 -0
- data/doc/en/cairo-invalid-visual-error.html +50 -0
- data/doc/en/cairo-invalid-visual-error.rd +17 -0
- data/doc/en/cairo-line-cap.html +40 -0
- data/doc/en/cairo-line-cap.rd +15 -0
- data/doc/en/cairo-line-join.html +40 -0
- data/doc/en/cairo-line-join.rd +15 -0
- data/doc/en/cairo-linear-pattern.html +63 -0
- data/doc/en/cairo-linear-pattern.rd +28 -0
- data/doc/en/cairo-matrix.html +257 -0
- data/doc/en/cairo-matrix.rd +186 -0
- data/doc/en/cairo-no-current-point-error.html +50 -0
- data/doc/en/cairo-no-current-point-error.rd +17 -0
- data/doc/en/cairo-null-pointer-error.html +50 -0
- data/doc/en/cairo-null-pointer-error.rd +17 -0
- data/doc/en/cairo-operator.html +51 -0
- data/doc/en/cairo-operator.rd +26 -0
- data/doc/en/cairo-paper-parse-error.html +50 -0
- data/doc/en/cairo-paper-parse-error.rd +17 -0
- data/doc/en/cairo-paper-unknown-paper-name.html +69 -0
- data/doc/en/cairo-paper-unknown-paper-name.rd +30 -0
- data/doc/en/cairo-paper-unknown-unit.html +69 -0
- data/doc/en/cairo-paper-unknown-unit.rd +30 -0
- data/doc/en/cairo-paper-unrecognized-paper-description.html +69 -0
- data/doc/en/cairo-paper-unrecognized-paper-description.rd +30 -0
- data/doc/en/cairo-paper.html +187 -0
- data/doc/en/cairo-paper.rd +141 -0
- data/doc/en/cairo-path-close-path.html +52 -0
- data/doc/en/cairo-path-close-path.rd +21 -0
- data/doc/en/cairo-path-curve-to.html +52 -0
- data/doc/en/cairo-path-curve-to.rd +21 -0
- data/doc/en/cairo-path-data-type.html +41 -0
- data/doc/en/cairo-path-data-type.rd +16 -0
- data/doc/en/cairo-path-data.html +101 -0
- data/doc/en/cairo-path-data.rd +62 -0
- data/doc/en/cairo-path-line-to.html +52 -0
- data/doc/en/cairo-path-line-to.rd +21 -0
- data/doc/en/cairo-path-move-to.html +52 -0
- data/doc/en/cairo-path-move-to.rd +21 -0
- data/doc/en/cairo-path.html +158 -0
- data/doc/en/cairo-path.rd +109 -0
- data/doc/en/cairo-pattern-type-mismatch-error.html +50 -0
- data/doc/en/cairo-pattern-type-mismatch-error.rd +17 -0
- data/doc/en/cairo-pattern.html +102 -0
- data/doc/en/cairo-pattern.rd +62 -0
- data/doc/en/cairo-pdf-surface.html +60 -0
- data/doc/en/cairo-pdf-surface.rd +27 -0
- data/doc/en/cairo-point.html +77 -0
- data/doc/en/cairo-point.rd +42 -0
- data/doc/en/cairo-ps-level.html +52 -0
- data/doc/en/cairo-ps-level.rd +24 -0
- data/doc/en/cairo-ps-surface.html +95 -0
- data/doc/en/cairo-ps-surface.rd +55 -0
- data/doc/en/cairo-quartz-image-surface.html +60 -0
- data/doc/en/cairo-quartz-image-surface.rd +27 -0
- data/doc/en/cairo-quartz-surface.html +60 -0
- data/doc/en/cairo-quartz-surface.rd +27 -0
- data/doc/en/cairo-radial-pattern.html +63 -0
- data/doc/en/cairo-radial-pattern.rd +28 -0
- data/doc/en/cairo-read-error.html +50 -0
- data/doc/en/cairo-read-error.rd +17 -0
- data/doc/en/cairo-rectangle.html +92 -0
- data/doc/en/cairo-rectangle.rd +54 -0
- data/doc/en/cairo-scaled-font.html +87 -0
- data/doc/en/cairo-scaled-font.rd +50 -0
- data/doc/en/cairo-solid-pattern.html +65 -0
- data/doc/en/cairo-solid-pattern.rd +31 -0
- data/doc/en/cairo-subpixel-order.html +42 -0
- data/doc/en/cairo-subpixel-order.rd +17 -0
- data/doc/en/cairo-surface-finished-error.html +50 -0
- data/doc/en/cairo-surface-finished-error.rd +17 -0
- data/doc/en/cairo-surface-pattern.html +60 -0
- data/doc/en/cairo-surface-pattern.rd +27 -0
- data/doc/en/cairo-surface-type-mismatch-error.html +50 -0
- data/doc/en/cairo-surface-type-mismatch-error.rd +17 -0
- data/doc/en/cairo-surface.html +114 -0
- data/doc/en/cairo-surface.rd +72 -0
- data/doc/en/cairo-svg-surface.html +80 -0
- data/doc/en/cairo-svg-surface.rd +44 -0
- data/doc/en/cairo-svg-version.html +52 -0
- data/doc/en/cairo-svg-version.rd +24 -0
- data/doc/en/cairo-temp-file-error.html +50 -0
- data/doc/en/cairo-temp-file-error.rd +17 -0
- data/doc/en/cairo-text-extents.html +79 -0
- data/doc/en/cairo-text-extents.rd +44 -0
- data/doc/en/cairo-win32-printing-surface.html +60 -0
- data/doc/en/cairo-win32-printing-surface.rd +27 -0
- data/doc/en/cairo-win32-surface.html +65 -0
- data/doc/en/cairo-win32-surface.rd +31 -0
- data/doc/en/cairo-write-error.html +50 -0
- data/doc/en/cairo-write-error.rd +17 -0
- data/doc/en/cairo.html +123 -0
- data/doc/en/cairo.rd +95 -0
- data/doc/en/index.html +1080 -0
- data/doc/en/index.rd +1051 -0
- data/doc/index.html +18 -0
- data/doc/ja/cairo-antialias.html +57 -0
- data/doc/ja/cairo-clip-not-representable-error.html +56 -0
- data/doc/ja/cairo-color-base.html +75 -0
- data/doc/ja/cairo-color-cmyk.html +152 -0
- data/doc/ja/cairo-color-hsv.html +135 -0
- data/doc/ja/cairo-color-rgb.html +145 -0
- data/doc/ja/cairo-color-x11.html +183 -0
- data/doc/ja/cairo-color.html +317 -0
- data/doc/ja/cairo-content.html +51 -0
- data/doc/ja/cairo-context-blur.html +53 -0
- data/doc/ja/cairo-context-circle.html +54 -0
- data/doc/ja/cairo-context-color.html +52 -0
- data/doc/ja/cairo-context-path.html +77 -0
- data/doc/ja/cairo-context-rectangle.html +60 -0
- data/doc/ja/cairo-context-triangle.html +47 -0
- data/doc/ja/cairo-context.html +1449 -0
- data/doc/ja/cairo-error.html +56 -0
- data/doc/ja/cairo-extend.html +56 -0
- data/doc/ja/cairo-file-not-found.html +51 -0
- data/doc/ja/cairo-fill-rule.html +58 -0
- data/doc/ja/cairo-filter.html +43 -0
- data/doc/ja/cairo-font-extents.html +110 -0
- data/doc/ja/cairo-font-face.html +55 -0
- data/doc/ja/cairo-font-options.html +186 -0
- data/doc/ja/cairo-font-slant.html +50 -0
- data/doc/ja/cairo-font-weight.html +47 -0
- data/doc/ja/cairo-format.html +81 -0
- data/doc/ja/cairo-glyph.html +115 -0
- data/doc/ja/cairo-gradient-pattern.html +119 -0
- data/doc/ja/cairo-hint-metrics.html +57 -0
- data/doc/ja/cairo-hint-style.html +64 -0
- data/doc/ja/cairo-image-surface.html +131 -0
- data/doc/ja/cairo-invalid-content-error.html +54 -0
- data/doc/ja/cairo-invalid-dash-error.html +54 -0
- data/doc/ja/cairo-invalid-dsc-comment-error.html +54 -0
- data/doc/ja/cairo-invalid-format-error.html +54 -0
- data/doc/ja/cairo-invalid-index-error.html +54 -0
- data/doc/ja/cairo-invalid-matrix-error.html +54 -0
- data/doc/ja/cairo-invalid-path-data-error.html +54 -0
- data/doc/ja/cairo-invalid-pop-group-error.html +54 -0
- data/doc/ja/cairo-invalid-restore-error.html +55 -0
- data/doc/ja/cairo-invalid-status-error.html +55 -0
- data/doc/ja/cairo-invalid-stride-error.html +55 -0
- data/doc/ja/cairo-invalid-string-error.html +54 -0
- data/doc/ja/cairo-invalid-visual-error.html +57 -0
- data/doc/ja/cairo-line-cap.html +50 -0
- data/doc/ja/cairo-line-join.html +53 -0
- data/doc/ja/cairo-linear-pattern.html +87 -0
- data/doc/ja/cairo-matrix.html +343 -0
- data/doc/ja/cairo-no-current-point-error.html +54 -0
- data/doc/ja/cairo-null-pointer-error.html +54 -0
- data/doc/ja/cairo-operator.html +51 -0
- data/doc/ja/cairo-paper-parse-error.html +55 -0
- data/doc/ja/cairo-paper-unknown-paper-name.html +76 -0
- data/doc/ja/cairo-paper-unknown-unit.html +75 -0
- data/doc/ja/cairo-paper-unrecognized-paper-description.html +76 -0
- data/doc/ja/cairo-paper.html +357 -0
- data/doc/ja/cairo-path-close-path.html +57 -0
- data/doc/ja/cairo-path-curve-to.html +70 -0
- data/doc/ja/cairo-path-data-type.html +53 -0
- data/doc/ja/cairo-path-data.html +127 -0
- data/doc/ja/cairo-path-line-to.html +62 -0
- data/doc/ja/cairo-path-move-to.html +62 -0
- data/doc/ja/cairo-path.html +144 -0
- data/doc/ja/cairo-pattern-type-mismatch-error.html +56 -0
- data/doc/ja/cairo-pattern.html +128 -0
- data/doc/ja/cairo-pdf-surface.html +86 -0
- data/doc/ja/cairo-point.html +90 -0
- data/doc/ja/cairo-ps-level.html +62 -0
- data/doc/ja/cairo-ps-surface.html +214 -0
- data/doc/ja/cairo-quartz-image-surface.html +75 -0
- data/doc/ja/cairo-quartz-surface.html +93 -0
- data/doc/ja/cairo-radial-pattern.html +93 -0
- data/doc/ja/cairo-read-error.html +55 -0
- data/doc/ja/cairo-rectangle.html +109 -0
- data/doc/ja/cairo-scaled-font.html +144 -0
- data/doc/ja/cairo-solid-pattern.html +87 -0
- data/doc/ja/cairo-subpixel-order.html +57 -0
- data/doc/ja/cairo-surface-finished-error.html +54 -0
- data/doc/ja/cairo-surface-pattern.html +68 -0
- data/doc/ja/cairo-surface-type-mismatch-error.html +56 -0
- data/doc/ja/cairo-surface.html +191 -0
- data/doc/ja/cairo-svg-surface.html +114 -0
- data/doc/ja/cairo-svg-version.html +66 -0
- data/doc/ja/cairo-temp-file-error.html +50 -0
- data/doc/ja/cairo-text-extents.html +101 -0
- data/doc/ja/cairo-win32-printing-surface.html +80 -0
- data/doc/ja/cairo-win32-surface.html +100 -0
- data/doc/ja/cairo-write-error.html +55 -0
- data/doc/ja/cairo.html +148 -0
- data/doc/ja/index.html +1080 -0
- data/extconf.rb +153 -0
- data/misc/update-colors.rb +143 -0
- data/pkg-config.rb +278 -0
- data/samples/agg/README +4 -0
- data/samples/agg/aa_demo.rb +47 -0
- data/samples/agg/aa_test.rb +304 -0
- data/samples/blur.rb +47 -0
- data/samples/pac.rb +99 -0
- data/samples/pac2.rb +171 -0
- data/samples/png.rb +45 -0
- data/samples/scalable.rb +56 -0
- data/samples/text-on-path.rb +60 -0
- data/samples/text2.rb +131 -0
- data/src/cairo.def +96 -0
- data/src/cairo.so +0 -0
- data/src/lib/cairo.rb +141 -0
- data/src/lib/cairo/color.rb +255 -0
- data/src/lib/cairo/colors.rb +656 -0
- data/src/lib/cairo/constants.rb +21 -0
- data/src/lib/cairo/context.rb +29 -0
- data/src/lib/cairo/context/blur.rb +45 -0
- data/src/lib/cairo/context/circle.rb +9 -0
- data/src/lib/cairo/context/color.rb +11 -0
- data/src/lib/cairo/context/path.rb +116 -0
- data/src/lib/cairo/context/rectangle.rb +33 -0
- data/src/lib/cairo/context/triangle.rb +12 -0
- data/src/lib/cairo/paper.rb +183 -0
- data/src/lib/cairo/papers.rb +41 -0
- data/src/lib/cairo/path.rb +15 -0
- data/src/lib/cairo/point.rb +7 -0
- data/src/libruby-cairo.a +0 -0
- data/src/rb_cairo.c +82 -0
- data/src/rb_cairo.h +264 -0
- data/src/rb_cairo_constants.c +456 -0
- data/src/rb_cairo_context.c +1548 -0
- data/src/rb_cairo_exception.c +214 -0
- data/src/rb_cairo_font_extents.c +125 -0
- data/src/rb_cairo_font_face.c +56 -0
- data/src/rb_cairo_font_options.c +197 -0
- data/src/rb_cairo_glyph.c +159 -0
- data/src/rb_cairo_matrix.c +350 -0
- data/src/rb_cairo_path.c +459 -0
- data/src/rb_cairo_pattern.c +540 -0
- data/src/rb_cairo_private.c +78 -0
- data/src/rb_cairo_private.h +72 -0
- data/src/rb_cairo_scaled_font.c +177 -0
- data/src/rb_cairo_surface.c +1252 -0
- data/src/rb_cairo_text_extents.c +138 -0
- data/test/run-test.rb +15 -0
- data/test/test_paper.rb +81 -0
- data/test/test_pkg_config.rb +122 -0
- metadata +490 -0
@@ -0,0 +1,836 @@
|
|
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=US-ASCII">
|
5
|
+
<title>Text</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="Drawing.html" title="Drawing">
|
9
|
+
<link rel="prev" href="cairo-Transformations.html" title="Transformations">
|
10
|
+
<link rel="next" href="Fonts.html" title="Fonts">
|
11
|
+
<meta name="generator" content="GTK-Doc V1.9 (XML mode)">
|
12
|
+
<link rel="stylesheet" href="style.css" type="text/css">
|
13
|
+
<link rel="chapter" href="Drawing.html" title="Drawing">
|
14
|
+
<link rel="chapter" href="Fonts.html" title="Fonts">
|
15
|
+
<link rel="chapter" href="Surfaces.html" title="Surfaces">
|
16
|
+
<link rel="chapter" href="Support.html" title="Utilities">
|
17
|
+
<link rel="index" href="ix01.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="appendix" href="language-bindings.html" title="Appendix A. Creating a language binding for cairo">
|
22
|
+
</head>
|
23
|
+
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
|
24
|
+
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
|
25
|
+
<tr valign="middle">
|
26
|
+
<td><a accesskey="p" href="cairo-Transformations.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
|
27
|
+
<td><a accesskey="u" href="Drawing.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
|
28
|
+
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
|
29
|
+
<th width="100%" align="center">Cairo: A Vector Graphics Library</th>
|
30
|
+
<td><a accesskey="n" href="Fonts.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
|
31
|
+
</tr>
|
32
|
+
<tr><td colspan="5" class="shortcuts"><nobr><a href="#id2613967" class="shortcut">Top</a>
|
33
|
+
 | 
|
34
|
+
<a href="#id2641905" class="shortcut">Description</a></nobr></td></tr>
|
35
|
+
</table>
|
36
|
+
<div class="refentry" lang="en">
|
37
|
+
<a name="cairo-Text"></a><div class="titlepage"></div>
|
38
|
+
<div class="refnamediv"><table width="100%"><tr>
|
39
|
+
<td valign="top">
|
40
|
+
<h2>
|
41
|
+
<a name="id2613967"></a><span class="refentrytitle">Text</span>
|
42
|
+
</h2>
|
43
|
+
<p>Text — Rendering text and glyphs</p>
|
44
|
+
</td>
|
45
|
+
<td valign="top" align="right"></td>
|
46
|
+
</tr></table></div>
|
47
|
+
<div class="refsynopsisdiv">
|
48
|
+
<h2>Synopsis</h2>
|
49
|
+
<pre class="synopsis">
|
50
|
+
|
51
|
+
|
52
|
+
|
53
|
+
<a class="link" href="cairo-Text.html#cairo-glyph-t">cairo_glyph_t</a>;
|
54
|
+
enum <a class="link" href="cairo-Text.html#cairo-font-slant-t">cairo_font_slant_t</a>;
|
55
|
+
enum <a class="link" href="cairo-Text.html#cairo-font-weight-t">cairo_font_weight_t</a>;
|
56
|
+
void <a class="link" href="cairo-Text.html#cairo-select-font-face">cairo_select_font_face</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
57
|
+
const char *family,
|
58
|
+
<a class="link" href="cairo-Text.html#cairo-font-slant-t">cairo_font_slant_t</a> slant,
|
59
|
+
<a class="link" href="cairo-Text.html#cairo-font-weight-t">cairo_font_weight_t</a> weight);
|
60
|
+
void <a class="link" href="cairo-Text.html#cairo-set-font-size">cairo_set_font_size</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
61
|
+
double size);
|
62
|
+
void <a class="link" href="cairo-Text.html#cairo-set-font-matrix">cairo_set_font_matrix</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
63
|
+
const <a class="link" href="cairo-cairo-matrix-t.html#cairo-matrix-t">cairo_matrix_t</a> *matrix);
|
64
|
+
void <a class="link" href="cairo-Text.html#cairo-get-font-matrix">cairo_get_font_matrix</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
65
|
+
<a class="link" href="cairo-cairo-matrix-t.html#cairo-matrix-t">cairo_matrix_t</a> *matrix);
|
66
|
+
void <a class="link" href="cairo-Text.html#cairo-set-font-options">cairo_set_font_options</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
67
|
+
const <a class="link" href="cairo-Font-Options.html#cairo-font-options-t">cairo_font_options_t</a> *options);
|
68
|
+
void <a class="link" href="cairo-Text.html#cairo-get-font-options">cairo_get_font_options</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
69
|
+
<a class="link" href="cairo-Font-Options.html#cairo-font-options-t">cairo_font_options_t</a> *options);
|
70
|
+
void <a class="link" href="cairo-Text.html#cairo-set-font-face">cairo_set_font_face</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
71
|
+
<a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t">cairo_font_face_t</a> *font_face);
|
72
|
+
<a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t">cairo_font_face_t</a>* <a class="link" href="cairo-Text.html#cairo-get-font-face">cairo_get_font_face</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr);
|
73
|
+
void <a class="link" href="cairo-Text.html#cairo-set-scaled-font">cairo_set_scaled_font</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
74
|
+
const <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t">cairo_scaled_font_t</a> *scaled_font);
|
75
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t">cairo_scaled_font_t</a>* <a class="link" href="cairo-Text.html#cairo-get-scaled-font">cairo_get_scaled_font</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr);
|
76
|
+
void <a class="link" href="cairo-Text.html#cairo-show-text">cairo_show_text</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
77
|
+
const char *utf8);
|
78
|
+
void <a class="link" href="cairo-Text.html#cairo-show-glyphs">cairo_show_glyphs</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
79
|
+
const <a class="link" href="cairo-Text.html#cairo-glyph-t">cairo_glyph_t</a> *glyphs,
|
80
|
+
int num_glyphs);
|
81
|
+
void <a class="link" href="cairo-Text.html#cairo-font-extents">cairo_font_extents</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
82
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-font-extents-t">cairo_font_extents_t</a> *extents);
|
83
|
+
void <a class="link" href="cairo-Text.html#cairo-text-extents">cairo_text_extents</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
84
|
+
const char *utf8,
|
85
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t">cairo_text_extents_t</a> *extents);
|
86
|
+
void <a class="link" href="cairo-Text.html#cairo-glyph-extents">cairo_glyph_extents</a> (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
87
|
+
const <a class="link" href="cairo-Text.html#cairo-glyph-t">cairo_glyph_t</a> *glyphs,
|
88
|
+
int num_glyphs,
|
89
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t">cairo_text_extents_t</a> *extents);
|
90
|
+
</pre>
|
91
|
+
</div>
|
92
|
+
<div class="refsect1" lang="en">
|
93
|
+
<a name="id2641905"></a><h2>Description</h2>
|
94
|
+
<p>
|
95
|
+
Cairo has two sets of text rendering capabilities:
|
96
|
+
</p>
|
97
|
+
<div class="itemizedlist"><ul type="disc">
|
98
|
+
<li>
|
99
|
+
The functions with <span class="emphasis"><em>text</em></span> in their name form cairo's
|
100
|
+
<em class="firstterm">toy</em> text API. The toy API takes UTF-8 encoded
|
101
|
+
text and is limited in its functionality to rendering simple
|
102
|
+
left-to-right text with no advanced features. That means for example
|
103
|
+
that most complex scripts like Hebrew, Arabic, and Indic scripts are
|
104
|
+
out of question. No kerning or correct positioning of diacritical marks
|
105
|
+
either. The font selection is pretty limited too and doesn't handle the
|
106
|
+
case that the selected font does not cover the characters in the text.
|
107
|
+
This set of functions are really that, a toy text API, for testing and
|
108
|
+
demonstration purposes. Any serious application should avoid them.
|
109
|
+
</li>
|
110
|
+
<li>
|
111
|
+
The functions with <span class="emphasis"><em>glyphs</em></span> in their name form cairo's
|
112
|
+
<em class="firstterm">low-level</em> text API. The low-level API relies on
|
113
|
+
the user to convert text to a set of glyph indexes and positions. This
|
114
|
+
is a very hard problem and is best handled by external libraries, like
|
115
|
+
the pangocairo that is part of the Pango text layout and rendering library.
|
116
|
+
Pango is available from <a class="ulink" href="http://www.pango.org/" target="_top">http://www.pango.org/</a>.
|
117
|
+
</li>
|
118
|
+
</ul></div>
|
119
|
+
<p>
|
120
|
+
</p>
|
121
|
+
</div>
|
122
|
+
<div class="refsect1" lang="en">
|
123
|
+
<a name="id2626335"></a><h2>Details</h2>
|
124
|
+
<div class="refsect2" lang="en">
|
125
|
+
<a name="id2641954"></a><h3>
|
126
|
+
<a name="cairo-glyph-t"></a>cairo_glyph_t</h3>
|
127
|
+
<a class="indexterm" name="id2641966"></a><pre class="programlisting">typedef struct {
|
128
|
+
unsigned long index;
|
129
|
+
double x;
|
130
|
+
double y;
|
131
|
+
} cairo_glyph_t;
|
132
|
+
</pre>
|
133
|
+
<p>
|
134
|
+
The <a class="link" href="cairo-Text.html#cairo-glyph-t"><span class="type">cairo_glyph_t</span></a> structure holds information about a single glyph
|
135
|
+
when drawing or measuring text. A font is (in simple terms) a
|
136
|
+
collection of shapes used to draw text. A glyph is one of these
|
137
|
+
shapes. There can be multiple glyphs for a single character
|
138
|
+
(alternates to be used in different contexts, for example), or a
|
139
|
+
glyph can be a <em class="firstterm">ligature</em> of multiple
|
140
|
+
characters. Cairo doesn't expose any way of converting input text
|
141
|
+
into glyphs, so in order to use the Cairo interfaces that take
|
142
|
+
arrays of glyphs, you must directly access the appropriate
|
143
|
+
underlying font system.
|
144
|
+
</p>
|
145
|
+
<p>
|
146
|
+
Note that the offsets given by <em class="parameter"><code>x</code></em> and <em class="parameter"><code>y</code></em> are not cumulative. When
|
147
|
+
drawing or measuring text, each glyph is individually positioned
|
148
|
+
with respect to the overall origin</p>
|
149
|
+
<p>
|
150
|
+
|
151
|
+
</p>
|
152
|
+
<div class="variablelist"><table border="0">
|
153
|
+
<col align="left" valign="top">
|
154
|
+
<tbody>
|
155
|
+
<tr>
|
156
|
+
<td><p><span class="term">double <em class="structfield"><code>x</code></em>;</span></p></td>
|
157
|
+
<td> the offset in the X direction between the origin used for
|
158
|
+
drawing or measuring the string and the origin of this glyph.
|
159
|
+
</td>
|
160
|
+
</tr>
|
161
|
+
<tr>
|
162
|
+
<td><p><span class="term">double <em class="structfield"><code>y</code></em>;</span></p></td>
|
163
|
+
<td> the offset in the Y direction between the origin used for
|
164
|
+
drawing or measuring the string and the origin of this glyph.
|
165
|
+
</td>
|
166
|
+
</tr>
|
167
|
+
</tbody>
|
168
|
+
</table></div>
|
169
|
+
</div>
|
170
|
+
<hr>
|
171
|
+
<div class="refsect2" lang="en">
|
172
|
+
<a name="id2642075"></a><h3>
|
173
|
+
<a name="cairo-font-slant-t"></a>enum cairo_font_slant_t</h3>
|
174
|
+
<a class="indexterm" name="id2642087"></a><pre class="programlisting">typedef enum _cairo_font_slant {
|
175
|
+
CAIRO_FONT_SLANT_NORMAL,
|
176
|
+
CAIRO_FONT_SLANT_ITALIC,
|
177
|
+
CAIRO_FONT_SLANT_OBLIQUE
|
178
|
+
} cairo_font_slant_t;
|
179
|
+
</pre>
|
180
|
+
<p>
|
181
|
+
Specifies variants of a font face based on their slant.</p>
|
182
|
+
<p>
|
183
|
+
|
184
|
+
</p>
|
185
|
+
<div class="variablelist"><table border="0">
|
186
|
+
<col align="left" valign="top">
|
187
|
+
<tbody>
|
188
|
+
<tr>
|
189
|
+
<td><p><span class="term"><a name="CAIRO-FONT-SLANT-NORMAL:CAPS"></a><code class="literal">CAIRO_FONT_SLANT_NORMAL</code></span></p></td>
|
190
|
+
<td> Upright font style
|
191
|
+
</td>
|
192
|
+
</tr>
|
193
|
+
<tr>
|
194
|
+
<td><p><span class="term"><a name="CAIRO-FONT-SLANT-ITALIC:CAPS"></a><code class="literal">CAIRO_FONT_SLANT_ITALIC</code></span></p></td>
|
195
|
+
<td> Italic font style
|
196
|
+
</td>
|
197
|
+
</tr>
|
198
|
+
<tr>
|
199
|
+
<td><p><span class="term"><a name="CAIRO-FONT-SLANT-OBLIQUE:CAPS"></a><code class="literal">CAIRO_FONT_SLANT_OBLIQUE</code></span></p></td>
|
200
|
+
<td> Oblique font style
|
201
|
+
</td>
|
202
|
+
</tr>
|
203
|
+
</tbody>
|
204
|
+
</table></div>
|
205
|
+
</div>
|
206
|
+
<hr>
|
207
|
+
<div class="refsect2" lang="en">
|
208
|
+
<a name="id2583383"></a><h3>
|
209
|
+
<a name="cairo-font-weight-t"></a>enum cairo_font_weight_t</h3>
|
210
|
+
<a class="indexterm" name="id2583395"></a><pre class="programlisting">typedef enum _cairo_font_weight {
|
211
|
+
CAIRO_FONT_WEIGHT_NORMAL,
|
212
|
+
CAIRO_FONT_WEIGHT_BOLD
|
213
|
+
} cairo_font_weight_t;
|
214
|
+
</pre>
|
215
|
+
<p>
|
216
|
+
Specifies variants of a font face based on their weight.</p>
|
217
|
+
<p>
|
218
|
+
|
219
|
+
</p>
|
220
|
+
<div class="variablelist"><table border="0">
|
221
|
+
<col align="left" valign="top">
|
222
|
+
<tbody>
|
223
|
+
<tr>
|
224
|
+
<td><p><span class="term"><a name="CAIRO-FONT-WEIGHT-NORMAL:CAPS"></a><code class="literal">CAIRO_FONT_WEIGHT_NORMAL</code></span></p></td>
|
225
|
+
<td> Normal font weight
|
226
|
+
</td>
|
227
|
+
</tr>
|
228
|
+
<tr>
|
229
|
+
<td><p><span class="term"><a name="CAIRO-FONT-WEIGHT-BOLD:CAPS"></a><code class="literal">CAIRO_FONT_WEIGHT_BOLD</code></span></p></td>
|
230
|
+
<td> Bold font weight
|
231
|
+
</td>
|
232
|
+
</tr>
|
233
|
+
</tbody>
|
234
|
+
</table></div>
|
235
|
+
</div>
|
236
|
+
<hr>
|
237
|
+
<div class="refsect2" lang="en">
|
238
|
+
<a name="id2583462"></a><h3>
|
239
|
+
<a name="cairo-select-font-face"></a>cairo_select_font_face ()</h3>
|
240
|
+
<a class="indexterm" name="id2583474"></a><pre class="programlisting">void cairo_select_font_face (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
241
|
+
const char *family,
|
242
|
+
<a class="link" href="cairo-Text.html#cairo-font-slant-t">cairo_font_slant_t</a> slant,
|
243
|
+
<a class="link" href="cairo-Text.html#cairo-font-weight-t">cairo_font_weight_t</a> weight);</pre>
|
244
|
+
<p>
|
245
|
+
Note: The <a class="link" href="cairo-Text.html#cairo-select-font-face"><code class="function">cairo_select_font_face()</code></a> function call is part of what
|
246
|
+
the cairo designers call the "toy" text API. It is convenient for
|
247
|
+
short demos and simple programs, but it is not expected to be
|
248
|
+
adequate for serious text-using applications.
|
249
|
+
</p>
|
250
|
+
<p>
|
251
|
+
Selects a family and style of font from a simplified description as
|
252
|
+
a family name, slant and weight. Cairo provides no operation to
|
253
|
+
list available family names on the system (this is a "toy",
|
254
|
+
remember"), but the standard CSS2 generic family names, ("serif",
|
255
|
+
"sans-serif", "cursive", "fantasy", "monospace"), are likely to
|
256
|
+
work as expected.
|
257
|
+
</p>
|
258
|
+
<p>
|
259
|
+
For "real" font selection, see the font-backend-specific
|
260
|
+
font_face_create functions for the font backend you are using. (For
|
261
|
+
example, if you are using the freetype-based cairo-ft font backend,
|
262
|
+
see <a class="link" href="cairo-FreeType-Fonts.html#cairo-ft-font-face-create-for-ft-face"><code class="function">cairo_ft_font_face_create_for_ft_face()</code></a> or
|
263
|
+
<a class="link" href="cairo-FreeType-Fonts.html#cairo-ft-font-face-create-for-pattern"><code class="function">cairo_ft_font_face_create_for_pattern()</code></a>.) The resulting font face
|
264
|
+
could then be used with <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-create"><code class="function">cairo_scaled_font_create()</code></a> and
|
265
|
+
<a class="link" href="cairo-Text.html#cairo-set-scaled-font"><code class="function">cairo_set_scaled_font()</code></a>.
|
266
|
+
</p>
|
267
|
+
<p>
|
268
|
+
Similarly, when using the "real" font support, you can call
|
269
|
+
directly into the underlying font system, (such as fontconfig or
|
270
|
+
freetype), for operations such as listing available fonts, etc.
|
271
|
+
</p>
|
272
|
+
<p>
|
273
|
+
It is expected that most applications will need to use a more
|
274
|
+
comprehensive font handling and text layout library, (for example,
|
275
|
+
pango), in conjunction with cairo.
|
276
|
+
</p>
|
277
|
+
<p>
|
278
|
+
If text is drawn without a call to <a class="link" href="cairo-Text.html#cairo-select-font-face"><code class="function">cairo_select_font_face()</code></a>, (nor
|
279
|
+
<a class="link" href="cairo-Text.html#cairo-set-font-face"><code class="function">cairo_set_font_face()</code></a> nor <a class="link" href="cairo-Text.html#cairo-set-scaled-font"><code class="function">cairo_set_scaled_font()</code></a>), the default
|
280
|
+
family is "sans", slant is <a class="link" href="cairo-Text.html#CAIRO-FONT-SLANT-NORMAL:CAPS"><code class="literal">CAIRO_FONT_SLANT_NORMAL</code></a>, and weight is
|
281
|
+
<a class="link" href="cairo-Text.html#CAIRO-FONT-WEIGHT-NORMAL:CAPS"><code class="literal">CAIRO_FONT_WEIGHT_NORMAL</code></a>.</p>
|
282
|
+
<p>
|
283
|
+
|
284
|
+
</p>
|
285
|
+
<div class="variablelist"><table border="0">
|
286
|
+
<col align="left" valign="top">
|
287
|
+
<tbody>
|
288
|
+
<tr>
|
289
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
290
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
291
|
+
</td>
|
292
|
+
</tr>
|
293
|
+
<tr>
|
294
|
+
<td><p><span class="term"><em class="parameter"><code>family</code></em> :</span></p></td>
|
295
|
+
<td> a font family name, encoded in UTF-8
|
296
|
+
</td>
|
297
|
+
</tr>
|
298
|
+
<tr>
|
299
|
+
<td><p><span class="term"><em class="parameter"><code>slant</code></em> :</span></p></td>
|
300
|
+
<td> the slant for the font
|
301
|
+
</td>
|
302
|
+
</tr>
|
303
|
+
<tr>
|
304
|
+
<td><p><span class="term"><em class="parameter"><code>weight</code></em> :</span></p></td>
|
305
|
+
<td> the weight for the font
|
306
|
+
</td>
|
307
|
+
</tr>
|
308
|
+
</tbody>
|
309
|
+
</table></div>
|
310
|
+
</div>
|
311
|
+
<hr>
|
312
|
+
<div class="refsect2" lang="en">
|
313
|
+
<a name="id2583720"></a><h3>
|
314
|
+
<a name="cairo-set-font-size"></a>cairo_set_font_size ()</h3>
|
315
|
+
<a class="indexterm" name="id2583733"></a><pre class="programlisting">void cairo_set_font_size (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
316
|
+
double size);</pre>
|
317
|
+
<p>
|
318
|
+
Sets the current font matrix to a scale by a factor of <em class="parameter"><code>size</code></em>, replacing
|
319
|
+
any font matrix previously set with <a class="link" href="cairo-Text.html#cairo-set-font-size"><code class="function">cairo_set_font_size()</code></a> or
|
320
|
+
<a class="link" href="cairo-Text.html#cairo-set-font-matrix"><code class="function">cairo_set_font_matrix()</code></a>. This results in a font size of <em class="parameter"><code>size</code></em> user space
|
321
|
+
units. (More precisely, this matrix will result in the font's
|
322
|
+
em-square being a <em class="parameter"><code>size</code></em> by <em class="parameter"><code>size</code></em> square in user space.)
|
323
|
+
</p>
|
324
|
+
<p>
|
325
|
+
If text is drawn without a call to <a class="link" href="cairo-Text.html#cairo-set-font-size"><code class="function">cairo_set_font_size()</code></a>, (nor
|
326
|
+
<a class="link" href="cairo-Text.html#cairo-set-font-matrix"><code class="function">cairo_set_font_matrix()</code></a> nor <a class="link" href="cairo-Text.html#cairo-set-scaled-font"><code class="function">cairo_set_scaled_font()</code></a>), the default
|
327
|
+
font size is 10.0.</p>
|
328
|
+
<p>
|
329
|
+
|
330
|
+
</p>
|
331
|
+
<div class="variablelist"><table border="0">
|
332
|
+
<col align="left" valign="top">
|
333
|
+
<tbody>
|
334
|
+
<tr>
|
335
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
336
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
337
|
+
</td>
|
338
|
+
</tr>
|
339
|
+
<tr>
|
340
|
+
<td><p><span class="term"><em class="parameter"><code>size</code></em> :</span></p></td>
|
341
|
+
<td> the new font size, in user space units
|
342
|
+
</td>
|
343
|
+
</tr>
|
344
|
+
</tbody>
|
345
|
+
</table></div>
|
346
|
+
</div>
|
347
|
+
<hr>
|
348
|
+
<div class="refsect2" lang="en">
|
349
|
+
<a name="id2647416"></a><h3>
|
350
|
+
<a name="cairo-set-font-matrix"></a>cairo_set_font_matrix ()</h3>
|
351
|
+
<a class="indexterm" name="id2647426"></a><pre class="programlisting">void cairo_set_font_matrix (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
352
|
+
const <a class="link" href="cairo-cairo-matrix-t.html#cairo-matrix-t">cairo_matrix_t</a> *matrix);</pre>
|
353
|
+
<p>
|
354
|
+
Sets the current font matrix to <em class="parameter"><code>matrix</code></em>. The font matrix gives a
|
355
|
+
transformation from the design space of the font (in this space,
|
356
|
+
the em-square is 1 unit by 1 unit) to user space. Normally, a
|
357
|
+
simple scale is used (see <a class="link" href="cairo-Text.html#cairo-set-font-size"><code class="function">cairo_set_font_size()</code></a>), but a more
|
358
|
+
complex font matrix can be used to shear the font
|
359
|
+
or stretch it unequally along the two axes</p>
|
360
|
+
<p>
|
361
|
+
|
362
|
+
</p>
|
363
|
+
<div class="variablelist"><table border="0">
|
364
|
+
<col align="left" valign="top">
|
365
|
+
<tbody>
|
366
|
+
<tr>
|
367
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
368
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
369
|
+
</td>
|
370
|
+
</tr>
|
371
|
+
<tr>
|
372
|
+
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
|
373
|
+
<td> a <a class="link" href="cairo-cairo-matrix-t.html#cairo-matrix-t"><span class="type">cairo_matrix_t</span></a> describing a transform to be applied to
|
374
|
+
the current font.
|
375
|
+
</td>
|
376
|
+
</tr>
|
377
|
+
</tbody>
|
378
|
+
</table></div>
|
379
|
+
</div>
|
380
|
+
<hr>
|
381
|
+
<div class="refsect2" lang="en">
|
382
|
+
<a name="id2647522"></a><h3>
|
383
|
+
<a name="cairo-get-font-matrix"></a>cairo_get_font_matrix ()</h3>
|
384
|
+
<a class="indexterm" name="id2647533"></a><pre class="programlisting">void cairo_get_font_matrix (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
385
|
+
<a class="link" href="cairo-cairo-matrix-t.html#cairo-matrix-t">cairo_matrix_t</a> *matrix);</pre>
|
386
|
+
<p>
|
387
|
+
Stores the current font matrix into <em class="parameter"><code>matrix</code></em>. See
|
388
|
+
<a class="link" href="cairo-Text.html#cairo-set-font-matrix"><code class="function">cairo_set_font_matrix()</code></a>.</p>
|
389
|
+
<p>
|
390
|
+
|
391
|
+
</p>
|
392
|
+
<div class="variablelist"><table border="0">
|
393
|
+
<col align="left" valign="top">
|
394
|
+
<tbody>
|
395
|
+
<tr>
|
396
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
397
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
398
|
+
</td>
|
399
|
+
</tr>
|
400
|
+
<tr>
|
401
|
+
<td><p><span class="term"><em class="parameter"><code>matrix</code></em> :</span></p></td>
|
402
|
+
<td> return value for the matrix
|
403
|
+
</td>
|
404
|
+
</tr>
|
405
|
+
</tbody>
|
406
|
+
</table></div>
|
407
|
+
</div>
|
408
|
+
<hr>
|
409
|
+
<div class="refsect2" lang="en">
|
410
|
+
<a name="id2647617"></a><h3>
|
411
|
+
<a name="cairo-set-font-options"></a>cairo_set_font_options ()</h3>
|
412
|
+
<a class="indexterm" name="id2647627"></a><pre class="programlisting">void cairo_set_font_options (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
413
|
+
const <a class="link" href="cairo-Font-Options.html#cairo-font-options-t">cairo_font_options_t</a> *options);</pre>
|
414
|
+
<p>
|
415
|
+
Sets a set of custom font rendering options for the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>.
|
416
|
+
Rendering options are derived by merging these options with the
|
417
|
+
options derived from underlying surface; if the value in <em class="parameter"><code>options</code></em>
|
418
|
+
has a default value (like <a class="link" href="cairo-cairo-t.html#CAIRO-ANTIALIAS-DEFAULT:CAPS"><code class="literal">CAIRO_ANTIALIAS_DEFAULT</code></a>), then the value
|
419
|
+
from the surface is used.</p>
|
420
|
+
<p>
|
421
|
+
|
422
|
+
</p>
|
423
|
+
<div class="variablelist"><table border="0">
|
424
|
+
<col align="left" valign="top">
|
425
|
+
<tbody>
|
426
|
+
<tr>
|
427
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
428
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
429
|
+
</td>
|
430
|
+
</tr>
|
431
|
+
<tr>
|
432
|
+
<td><p><span class="term"><em class="parameter"><code>options</code></em> :</span></p></td>
|
433
|
+
<td> font options to use
|
434
|
+
</td>
|
435
|
+
</tr>
|
436
|
+
</tbody>
|
437
|
+
</table></div>
|
438
|
+
</div>
|
439
|
+
<hr>
|
440
|
+
<div class="refsect2" lang="en">
|
441
|
+
<a name="id2647721"></a><h3>
|
442
|
+
<a name="cairo-get-font-options"></a>cairo_get_font_options ()</h3>
|
443
|
+
<a class="indexterm" name="id2647732"></a><pre class="programlisting">void cairo_get_font_options (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
444
|
+
<a class="link" href="cairo-Font-Options.html#cairo-font-options-t">cairo_font_options_t</a> *options);</pre>
|
445
|
+
<p>
|
446
|
+
Retrieves font rendering options set via <a class="link" href="cairo-Text.html#cairo-set-font-options"><span class="type">cairo_set_font_options</span></a>.
|
447
|
+
Note that the returned options do not include any options derived
|
448
|
+
from the underlying surface; they are literally the options
|
449
|
+
passed to <a class="link" href="cairo-Text.html#cairo-set-font-options"><code class="function">cairo_set_font_options()</code></a>.</p>
|
450
|
+
<p>
|
451
|
+
|
452
|
+
</p>
|
453
|
+
<div class="variablelist"><table border="0">
|
454
|
+
<col align="left" valign="top">
|
455
|
+
<tbody>
|
456
|
+
<tr>
|
457
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
458
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
459
|
+
</td>
|
460
|
+
</tr>
|
461
|
+
<tr>
|
462
|
+
<td><p><span class="term"><em class="parameter"><code>options</code></em> :</span></p></td>
|
463
|
+
<td> a <a class="link" href="cairo-Font-Options.html#cairo-font-options-t"><span class="type">cairo_font_options_t</span></a> object into which to store
|
464
|
+
the retrieved options. All existing values are overwritten
|
465
|
+
</td>
|
466
|
+
</tr>
|
467
|
+
</tbody>
|
468
|
+
</table></div>
|
469
|
+
</div>
|
470
|
+
<hr>
|
471
|
+
<div class="refsect2" lang="en">
|
472
|
+
<a name="id2647826"></a><h3>
|
473
|
+
<a name="cairo-set-font-face"></a>cairo_set_font_face ()</h3>
|
474
|
+
<a class="indexterm" name="id2647837"></a><pre class="programlisting">void cairo_set_font_face (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
475
|
+
<a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t">cairo_font_face_t</a> *font_face);</pre>
|
476
|
+
<p>
|
477
|
+
Replaces the current <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t"><span class="type">cairo_font_face_t</span></a> object in the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> with
|
478
|
+
<em class="parameter"><code>font_face</code></em>. The replaced font face in the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> will be
|
479
|
+
destroyed if there are no other references to it.</p>
|
480
|
+
<p>
|
481
|
+
|
482
|
+
</p>
|
483
|
+
<div class="variablelist"><table border="0">
|
484
|
+
<col align="left" valign="top">
|
485
|
+
<tbody>
|
486
|
+
<tr>
|
487
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
488
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
489
|
+
</td>
|
490
|
+
</tr>
|
491
|
+
<tr>
|
492
|
+
<td><p><span class="term"><em class="parameter"><code>font_face</code></em> :</span></p></td>
|
493
|
+
<td> a <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t"><span class="type">cairo_font_face_t</span></a>, or <code class="literal">NULL</code> to restore to the default font
|
494
|
+
</td>
|
495
|
+
</tr>
|
496
|
+
</tbody>
|
497
|
+
</table></div>
|
498
|
+
</div>
|
499
|
+
<hr>
|
500
|
+
<div class="refsect2" lang="en">
|
501
|
+
<a name="id2647947"></a><h3>
|
502
|
+
<a name="cairo-get-font-face"></a>cairo_get_font_face ()</h3>
|
503
|
+
<a class="indexterm" name="id2647958"></a><pre class="programlisting"><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t">cairo_font_face_t</a>* cairo_get_font_face (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr);</pre>
|
504
|
+
<p>
|
505
|
+
Gets the current font face for a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>.</p>
|
506
|
+
<p>
|
507
|
+
|
508
|
+
</p>
|
509
|
+
<div class="variablelist"><table border="0">
|
510
|
+
<col align="left" valign="top">
|
511
|
+
<tbody>
|
512
|
+
<tr>
|
513
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
514
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
515
|
+
</td>
|
516
|
+
</tr>
|
517
|
+
<tr>
|
518
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
519
|
+
<td> the current font face. This object is owned by
|
520
|
+
cairo. To keep a reference to it, you must call
|
521
|
+
cairo_font_face_reference.
|
522
|
+
|
523
|
+
This function never returns <code class="literal">NULL</code>. If memory cannot be allocated, a
|
524
|
+
special "nil" <a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t"><span class="type">cairo_font_face_t</span></a> object will be returned on which
|
525
|
+
<a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-status"><code class="function">cairo_font_face_status()</code></a> returns <a class="link" href="cairo-Error-Handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a>. Using
|
526
|
+
this nil object will cause its error state to propagate to other
|
527
|
+
objects it is passed to, (for example, calling
|
528
|
+
<a class="link" href="cairo-Text.html#cairo-set-font-face"><code class="function">cairo_set_font_face()</code></a> with a nil font will trigger an error that
|
529
|
+
will shutdown the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> object).
|
530
|
+
</td>
|
531
|
+
</tr>
|
532
|
+
</tbody>
|
533
|
+
</table></div>
|
534
|
+
</div>
|
535
|
+
<hr>
|
536
|
+
<div class="refsect2" lang="en">
|
537
|
+
<a name="id2648077"></a><h3>
|
538
|
+
<a name="cairo-set-scaled-font"></a>cairo_set_scaled_font ()</h3>
|
539
|
+
<a class="indexterm" name="id2648090"></a><pre class="programlisting">void cairo_set_scaled_font (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
540
|
+
const <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t">cairo_scaled_font_t</a> *scaled_font);</pre>
|
541
|
+
<p>
|
542
|
+
Replaces the current font face, font matrix, and font options in
|
543
|
+
the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> with those of the <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t"><span class="type">cairo_scaled_font_t</span></a>. Except for
|
544
|
+
some translation, the current CTM of the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> should be the
|
545
|
+
same as that of the <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t"><span class="type">cairo_scaled_font_t</span></a>, which can be accessed
|
546
|
+
using <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-get-ctm"><code class="function">cairo_scaled_font_get_ctm()</code></a>.</p>
|
547
|
+
<p>
|
548
|
+
|
549
|
+
</p>
|
550
|
+
<div class="variablelist"><table border="0">
|
551
|
+
<col align="left" valign="top">
|
552
|
+
<tbody>
|
553
|
+
<tr>
|
554
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
555
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
556
|
+
</td>
|
557
|
+
</tr>
|
558
|
+
<tr>
|
559
|
+
<td><p><span class="term"><em class="parameter"><code>scaled_font</code></em> :</span></p></td>
|
560
|
+
<td> a <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t"><span class="type">cairo_scaled_font_t</span></a>
|
561
|
+
</td>
|
562
|
+
</tr>
|
563
|
+
</tbody>
|
564
|
+
</table></div>
|
565
|
+
<p class="since">Since 1.2
|
566
|
+
</p>
|
567
|
+
</div>
|
568
|
+
<hr>
|
569
|
+
<div class="refsect2" lang="en">
|
570
|
+
<a name="id2648209"></a><h3>
|
571
|
+
<a name="cairo-get-scaled-font"></a>cairo_get_scaled_font ()</h3>
|
572
|
+
<a class="indexterm" name="id2648221"></a><pre class="programlisting"><a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t">cairo_scaled_font_t</a>* cairo_get_scaled_font (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr);</pre>
|
573
|
+
<p>
|
574
|
+
Gets the current scaled font for a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>.</p>
|
575
|
+
<p>
|
576
|
+
|
577
|
+
</p>
|
578
|
+
<div class="variablelist"><table border="0">
|
579
|
+
<col align="left" valign="top">
|
580
|
+
<tbody>
|
581
|
+
<tr>
|
582
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
583
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
584
|
+
</td>
|
585
|
+
</tr>
|
586
|
+
<tr>
|
587
|
+
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
|
588
|
+
<td> the current scaled font. This object is owned by
|
589
|
+
cairo. To keep a reference to it, you must call
|
590
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-reference"><code class="function">cairo_scaled_font_reference()</code></a>.
|
591
|
+
|
592
|
+
This function never returns <code class="literal">NULL</code>. If memory cannot be allocated, a
|
593
|
+
special "nil" <a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t"><span class="type">cairo_scaled_font_t</span></a> object will be returned on which
|
594
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-status"><code class="function">cairo_scaled_font_status()</code></a> returns <a class="link" href="cairo-Error-Handling.html#CAIRO-STATUS-NO-MEMORY:CAPS"><code class="literal">CAIRO_STATUS_NO_MEMORY</code></a>. Using
|
595
|
+
this nil object will cause its error state to propagate to other
|
596
|
+
objects it is passed to, (for example, calling
|
597
|
+
<a class="link" href="cairo-Text.html#cairo-set-scaled-font"><code class="function">cairo_set_scaled_font()</code></a> with a nil font will trigger an error that
|
598
|
+
will shutdown the <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a> object).
|
599
|
+
|
600
|
+
</td>
|
601
|
+
</tr>
|
602
|
+
</tbody>
|
603
|
+
</table></div>
|
604
|
+
<p class="since">Since 1.4
|
605
|
+
</p>
|
606
|
+
</div>
|
607
|
+
<hr>
|
608
|
+
<div class="refsect2" lang="en">
|
609
|
+
<a name="id2648356"></a><h3>
|
610
|
+
<a name="cairo-show-text"></a>cairo_show_text ()</h3>
|
611
|
+
<a class="indexterm" name="id2648366"></a><pre class="programlisting">void cairo_show_text (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
612
|
+
const char *utf8);</pre>
|
613
|
+
<p>
|
614
|
+
A drawing operator that generates the shape from a string of UTF-8
|
615
|
+
characters, rendered according to the current font_face, font_size
|
616
|
+
(font_matrix), and font_options.
|
617
|
+
</p>
|
618
|
+
<p>
|
619
|
+
This function first computes a set of glyphs for the string of
|
620
|
+
text. The first glyph is placed so that its origin is at the
|
621
|
+
current point. The origin of each subsequent glyph is offset from
|
622
|
+
that of the previous glyph by the advance values of the previous
|
623
|
+
glyph.
|
624
|
+
</p>
|
625
|
+
<p>
|
626
|
+
After this call the current point is moved to the origin of where
|
627
|
+
the next glyph would be placed in this same progression. That is,
|
628
|
+
the current point will be at the origin of the final glyph offset
|
629
|
+
by its advance values. This allows for easy display of a single
|
630
|
+
logical string with multiple calls to <a class="link" href="cairo-Text.html#cairo-show-text"><code class="function">cairo_show_text()</code></a>.
|
631
|
+
</p>
|
632
|
+
<p>
|
633
|
+
Note: The <a class="link" href="cairo-Text.html#cairo-show-text"><code class="function">cairo_show_text()</code></a> function call is part of what the cairo
|
634
|
+
designers call the "toy" text API. It is convenient for short demos
|
635
|
+
and simple programs, but it is not expected to be adequate for
|
636
|
+
serious text-using applications. See <a class="link" href="cairo-Text.html#cairo-show-glyphs"><code class="function">cairo_show_glyphs()</code></a> for the
|
637
|
+
"real" text display API in cairo.</p>
|
638
|
+
<p>
|
639
|
+
|
640
|
+
</p>
|
641
|
+
<div class="variablelist"><table border="0">
|
642
|
+
<col align="left" valign="top">
|
643
|
+
<tbody>
|
644
|
+
<tr>
|
645
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
646
|
+
<td> a cairo context
|
647
|
+
</td>
|
648
|
+
</tr>
|
649
|
+
<tr>
|
650
|
+
<td><p><span class="term"><em class="parameter"><code>utf8</code></em> :</span></p></td>
|
651
|
+
<td> a string of text encoded in UTF-8
|
652
|
+
</td>
|
653
|
+
</tr>
|
654
|
+
</tbody>
|
655
|
+
</table></div>
|
656
|
+
</div>
|
657
|
+
<hr>
|
658
|
+
<div class="refsect2" lang="en">
|
659
|
+
<a name="id2648481"></a><h3>
|
660
|
+
<a name="cairo-show-glyphs"></a>cairo_show_glyphs ()</h3>
|
661
|
+
<a class="indexterm" name="id2648492"></a><pre class="programlisting">void cairo_show_glyphs (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
662
|
+
const <a class="link" href="cairo-Text.html#cairo-glyph-t">cairo_glyph_t</a> *glyphs,
|
663
|
+
int num_glyphs);</pre>
|
664
|
+
<p>
|
665
|
+
A drawing operator that generates the shape from an array of glyphs,
|
666
|
+
rendered according to the current font_face, font_size
|
667
|
+
(font_matrix), and font_options.</p>
|
668
|
+
<p>
|
669
|
+
|
670
|
+
</p>
|
671
|
+
<div class="variablelist"><table border="0">
|
672
|
+
<col align="left" valign="top">
|
673
|
+
<tbody>
|
674
|
+
<tr>
|
675
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
676
|
+
<td> a cairo context
|
677
|
+
</td>
|
678
|
+
</tr>
|
679
|
+
<tr>
|
680
|
+
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
|
681
|
+
<td> array of glyphs to show
|
682
|
+
</td>
|
683
|
+
</tr>
|
684
|
+
<tr>
|
685
|
+
<td><p><span class="term"><em class="parameter"><code>num_glyphs</code></em> :</span></p></td>
|
686
|
+
<td> number of glyphs to show
|
687
|
+
</td>
|
688
|
+
</tr>
|
689
|
+
</tbody>
|
690
|
+
</table></div>
|
691
|
+
</div>
|
692
|
+
<hr>
|
693
|
+
<div class="refsect2" lang="en">
|
694
|
+
<a name="id2648577"></a><h3>
|
695
|
+
<a name="cairo-font-extents"></a>cairo_font_extents ()</h3>
|
696
|
+
<a class="indexterm" name="id2648587"></a><pre class="programlisting">void cairo_font_extents (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
697
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-font-extents-t">cairo_font_extents_t</a> *extents);</pre>
|
698
|
+
<p>
|
699
|
+
Gets the font extents for the currently selected font.</p>
|
700
|
+
<p>
|
701
|
+
|
702
|
+
</p>
|
703
|
+
<div class="variablelist"><table border="0">
|
704
|
+
<col align="left" valign="top">
|
705
|
+
<tbody>
|
706
|
+
<tr>
|
707
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
708
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
709
|
+
</td>
|
710
|
+
</tr>
|
711
|
+
<tr>
|
712
|
+
<td><p><span class="term"><em class="parameter"><code>extents</code></em> :</span></p></td>
|
713
|
+
<td> a <a class="link" href="cairo-Scaled-Fonts.html#cairo-font-extents-t"><span class="type">cairo_font_extents_t</span></a> object into which the results
|
714
|
+
will be stored.
|
715
|
+
</td>
|
716
|
+
</tr>
|
717
|
+
</tbody>
|
718
|
+
</table></div>
|
719
|
+
</div>
|
720
|
+
<hr>
|
721
|
+
<div class="refsect2" lang="en">
|
722
|
+
<a name="id2648665"></a><h3>
|
723
|
+
<a name="cairo-text-extents"></a>cairo_text_extents ()</h3>
|
724
|
+
<a class="indexterm" name="id2648675"></a><pre class="programlisting">void cairo_text_extents (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
725
|
+
const char *utf8,
|
726
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t">cairo_text_extents_t</a> *extents);</pre>
|
727
|
+
<p>
|
728
|
+
Gets the extents for a string of text. The extents describe a
|
729
|
+
user-space rectangle that encloses the "inked" portion of the text,
|
730
|
+
(as it would be drawn by <a class="link" href="cairo-Text.html#cairo-show-text"><code class="function">cairo_show_text()</code></a>). Additionally, the
|
731
|
+
x_advance and y_advance values indicate the amount by which the
|
732
|
+
current point would be advanced by <a class="link" href="cairo-Text.html#cairo-show-text"><code class="function">cairo_show_text()</code></a>.
|
733
|
+
</p>
|
734
|
+
<p>
|
735
|
+
Note that whitespace characters do not directly contribute to the
|
736
|
+
size of the rectangle (extents.width and extents.height). They do
|
737
|
+
contribute indirectly by changing the position of non-whitespace
|
738
|
+
characters. In particular, trailing whitespace characters are
|
739
|
+
likely to not affect the size of the rectangle, though they will
|
740
|
+
affect the x_advance and y_advance values.</p>
|
741
|
+
<p>
|
742
|
+
|
743
|
+
</p>
|
744
|
+
<div class="variablelist"><table border="0">
|
745
|
+
<col align="left" valign="top">
|
746
|
+
<tbody>
|
747
|
+
<tr>
|
748
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
749
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
750
|
+
</td>
|
751
|
+
</tr>
|
752
|
+
<tr>
|
753
|
+
<td><p><span class="term"><em class="parameter"><code>utf8</code></em> :</span></p></td>
|
754
|
+
<td> a string of text, encoded in UTF-8
|
755
|
+
</td>
|
756
|
+
</tr>
|
757
|
+
<tr>
|
758
|
+
<td><p><span class="term"><em class="parameter"><code>extents</code></em> :</span></p></td>
|
759
|
+
<td> a <a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t"><span class="type">cairo_text_extents_t</span></a> object into which the results
|
760
|
+
will be stored
|
761
|
+
</td>
|
762
|
+
</tr>
|
763
|
+
</tbody>
|
764
|
+
</table></div>
|
765
|
+
</div>
|
766
|
+
<hr>
|
767
|
+
<div class="refsect2" lang="en">
|
768
|
+
<a name="id2648803"></a><h3>
|
769
|
+
<a name="cairo-glyph-extents"></a>cairo_glyph_extents ()</h3>
|
770
|
+
<a class="indexterm" name="id2648813"></a><pre class="programlisting">void cairo_glyph_extents (<a class="link" href="cairo-cairo-t.html#cairo-t">cairo_t</a> *cr,
|
771
|
+
const <a class="link" href="cairo-Text.html#cairo-glyph-t">cairo_glyph_t</a> *glyphs,
|
772
|
+
int num_glyphs,
|
773
|
+
<a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t">cairo_text_extents_t</a> *extents);</pre>
|
774
|
+
<p>
|
775
|
+
Gets the extents for an array of glyphs. The extents describe a
|
776
|
+
user-space rectangle that encloses the "inked" portion of the
|
777
|
+
glyphs, (as they would be drawn by <a class="link" href="cairo-Text.html#cairo-show-glyphs"><code class="function">cairo_show_glyphs()</code></a>).
|
778
|
+
Additionally, the x_advance and y_advance values indicate the
|
779
|
+
amount by which the current point would be advanced by
|
780
|
+
cairo_show_glyphs.
|
781
|
+
</p>
|
782
|
+
<p>
|
783
|
+
Note that whitespace glyphs do not contribute to the size of the
|
784
|
+
rectangle (extents.width and extents.height).</p>
|
785
|
+
<p>
|
786
|
+
|
787
|
+
</p>
|
788
|
+
<div class="variablelist"><table border="0">
|
789
|
+
<col align="left" valign="top">
|
790
|
+
<tbody>
|
791
|
+
<tr>
|
792
|
+
<td><p><span class="term"><em class="parameter"><code>cr</code></em> :</span></p></td>
|
793
|
+
<td> a <a class="link" href="cairo-cairo-t.html#cairo-t"><span class="type">cairo_t</span></a>
|
794
|
+
</td>
|
795
|
+
</tr>
|
796
|
+
<tr>
|
797
|
+
<td><p><span class="term"><em class="parameter"><code>glyphs</code></em> :</span></p></td>
|
798
|
+
<td> an array of <a class="link" href="cairo-Text.html#cairo-glyph-t"><span class="type">cairo_glyph_t</span></a> objects
|
799
|
+
</td>
|
800
|
+
</tr>
|
801
|
+
<tr>
|
802
|
+
<td><p><span class="term"><em class="parameter"><code>num_glyphs</code></em> :</span></p></td>
|
803
|
+
<td> the number of elements in <em class="parameter"><code>glyphs</code></em>
|
804
|
+
</td>
|
805
|
+
</tr>
|
806
|
+
<tr>
|
807
|
+
<td><p><span class="term"><em class="parameter"><code>extents</code></em> :</span></p></td>
|
808
|
+
<td> a <a class="link" href="cairo-Scaled-Fonts.html#cairo-text-extents-t"><span class="type">cairo_text_extents_t</span></a> object into which the results
|
809
|
+
will be stored
|
810
|
+
</td>
|
811
|
+
</tr>
|
812
|
+
</tbody>
|
813
|
+
</table></div>
|
814
|
+
</div>
|
815
|
+
</div>
|
816
|
+
<div class="refsect1" lang="en">
|
817
|
+
<a name="id2648959"></a><h2>See Also</h2>
|
818
|
+
<p>
|
819
|
+
</p>
|
820
|
+
<div class="itemizedlist"><ul type="disc">
|
821
|
+
<li><a class="link" href="cairo-cairo-font-face-t.html#cairo-font-face-t"><span class="type">cairo_font_face_t</span></a></li>
|
822
|
+
<li><a class="link" href="cairo-Scaled-Fonts.html#cairo-scaled-font-t"><span class="type">cairo_scaled_font_t</span></a></li>
|
823
|
+
<li><a class="link" href="cairo-Paths.html#cairo-text-path"><code class="function">cairo_text_path()</code></a></li>
|
824
|
+
<li><a class="link" href="cairo-Paths.html#cairo-glyph-path"><code class="function">cairo_glyph_path()</code></a></li>
|
825
|
+
</ul></div>
|
826
|
+
<p>
|
827
|
+
</p>
|
828
|
+
</div>
|
829
|
+
<div class="refsect1" lang="en">
|
830
|
+
<a name="id2649005"></a><div class="refsect2" lang="en"><a name="id2649006"></a></div>
|
831
|
+
<hr>
|
832
|
+
<div class="refsect2" lang="en"><a name="id2649008"></a></div>
|
833
|
+
</div>
|
834
|
+
</div>
|
835
|
+
</body>
|
836
|
+
</html>
|