rmagick 3.2.0 → 4.3.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of rmagick might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/.codeclimate.yml +63 -0
- data/.devcontainer/Dockerfile +14 -0
- data/.devcontainer/ImageMagick6/devcontainer.json +11 -0
- data/.devcontainer/devcontainer.json +11 -0
- data/.devcontainer/setup-repo.sh +10 -0
- data/.devcontainer/setup-user.sh +45 -0
- data/.editorconfig +3 -0
- data/.github/ISSUE_TEMPLATE.md +17 -0
- data/.github/workflows/ci.yml +79 -0
- data/.gitignore +3 -1
- data/.rspec +1 -0
- data/.rubocop.yml +24 -0
- data/.rubocop_todo.yml +151 -297
- data/.yardopts +5 -0
- data/CHANGELOG.md +233 -0
- data/CODE_OF_CONDUCT.md +122 -7
- data/CONTRIBUTING.md +14 -10
- data/README.md +326 -0
- data/Rakefile +16 -22
- data/before_install_linux.sh +22 -28
- data/before_install_osx.sh +57 -2
- data/ext/RMagick/extconf.rb +149 -105
- data/ext/RMagick/rmagick.c +77 -104
- data/ext/RMagick/rmagick.h +121 -103
- data/ext/RMagick/rmdraw.c +364 -436
- data/ext/RMagick/rmenum.c +106 -114
- data/ext/RMagick/rmfill.c +149 -70
- data/ext/RMagick/rmilist.c +225 -367
- data/ext/RMagick/rmimage.c +4751 -4405
- data/ext/RMagick/rminfo.c +574 -787
- data/ext/RMagick/rmkinfo.c +51 -121
- data/ext/RMagick/rmmain.c +454 -286
- data/ext/RMagick/rmmontage.c +64 -130
- data/ext/RMagick/rmpixel.c +488 -437
- data/ext/RMagick/rmstruct.c +83 -96
- data/ext/RMagick/rmutil.c +302 -214
- data/lib/rmagick/version.rb +1 -1
- data/lib/rmagick_internal.rb +138 -93
- data/lib/rvg/clippath.rb +2 -1
- data/lib/rvg/container.rb +10 -5
- data/lib/rvg/describable.rb +1 -1
- data/lib/rvg/embellishable.rb +5 -4
- data/lib/rvg/misc.rb +15 -12
- data/lib/rvg/paint.rb +2 -1
- data/lib/rvg/pathdata.rb +12 -11
- data/lib/rvg/rvg.rb +12 -8
- data/lib/rvg/stylable.rb +9 -7
- data/lib/rvg/text.rb +11 -6
- data/lib/rvg/transformable.rb +3 -2
- data/lib/rvg/units.rb +1 -1
- data/rmagick.gemspec +10 -11
- metadata +52 -423
- data/.appveyor.yml +0 -45
- data/.circleci/config.yml +0 -56
- data/.ruby-version +0 -1
- data/.simplecov +0 -27
- data/.travis.yml +0 -62
- data/Doxyfile +0 -1514
- data/README.textile +0 -259
- data/benchmarks/memory/README.md +0 -50
- data/benchmarks/memory/image_new.rb +0 -8
- data/benchmarks/memory/rmagick.gnuplot +0 -16
- data/doc/.cvsignore +0 -1
- data/doc/comtasks.html +0 -287
- data/doc/constants.html +0 -1581
- data/doc/css/doc.css +0 -299
- data/doc/css/popup.css +0 -34
- data/doc/css/ref.css +0 -67
- data/doc/draw.html +0 -3272
- data/doc/ex/InitialCoords.rb +0 -22
- data/doc/ex/NewCoordSys.rb +0 -30
- data/doc/ex/OrigCoordSys.rb +0 -16
- data/doc/ex/PreserveAspectRatio.rb +0 -204
- data/doc/ex/RotateScale.rb +0 -36
- data/doc/ex/Skew.rb +0 -38
- data/doc/ex/Use01.rb +0 -15
- data/doc/ex/Use02.rb +0 -20
- data/doc/ex/Use03.rb +0 -16
- data/doc/ex/ViewBox.rb +0 -31
- data/doc/ex/adaptive_threshold.rb +0 -9
- data/doc/ex/add_noise.rb +0 -16
- data/doc/ex/affine.rb +0 -48
- data/doc/ex/affine_transform.rb +0 -20
- data/doc/ex/arc.rb +0 -49
- data/doc/ex/arcpath.rb +0 -32
- data/doc/ex/arcs01.rb +0 -28
- data/doc/ex/arcs02.rb +0 -59
- data/doc/ex/average.rb +0 -15
- data/doc/ex/axes.rb +0 -64
- data/doc/ex/baseline_shift01.rb +0 -17
- data/doc/ex/bilevel_channel.rb +0 -8
- data/doc/ex/blur_image.rb +0 -12
- data/doc/ex/border.rb +0 -10
- data/doc/ex/bounding_box.rb +0 -42
- data/doc/ex/cbezier1.rb +0 -41
- data/doc/ex/cbezier2.rb +0 -41
- data/doc/ex/cbezier3.rb +0 -41
- data/doc/ex/cbezier4.rb +0 -42
- data/doc/ex/cbezier5.rb +0 -42
- data/doc/ex/cbezier6.rb +0 -53
- data/doc/ex/channel.rb +0 -25
- data/doc/ex/charcoal.rb +0 -12
- data/doc/ex/chop.rb +0 -29
- data/doc/ex/circle.rb +0 -33
- data/doc/ex/circle01.rb +0 -16
- data/doc/ex/clip_path.rb +0 -60
- data/doc/ex/coalesce.rb +0 -57
- data/doc/ex/color_fill_to_border.rb +0 -29
- data/doc/ex/color_floodfill.rb +0 -28
- data/doc/ex/color_histogram.rb +0 -47
- data/doc/ex/color_reset.rb +0 -11
- data/doc/ex/colorize.rb +0 -16
- data/doc/ex/colors.rb +0 -64
- data/doc/ex/compose_mask.rb +0 -22
- data/doc/ex/composite.rb +0 -133
- data/doc/ex/composite_layers.rb +0 -52
- data/doc/ex/composite_tiled.rb +0 -21
- data/doc/ex/contrast.rb +0 -36
- data/doc/ex/crop.rb +0 -31
- data/doc/ex/crop_with_gravity.rb +0 -42
- data/doc/ex/cubic01.rb +0 -43
- data/doc/ex/cubic02.rb +0 -91
- data/doc/ex/cycle_colormap.rb +0 -21
- data/doc/ex/dissolve.rb +0 -12
- data/doc/ex/drawcomp.rb +0 -41
- data/doc/ex/drop_shadow.rb +0 -60
- data/doc/ex/edge.rb +0 -11
- data/doc/ex/ellipse.rb +0 -45
- data/doc/ex/ellipse01.rb +0 -21
- data/doc/ex/emboss.rb +0 -11
- data/doc/ex/enhance.rb +0 -28
- data/doc/ex/equalize.rb +0 -11
- data/doc/ex/evenodd.rb +0 -42
- data/doc/ex/fill_pattern.rb +0 -23
- data/doc/ex/flatten_images.rb +0 -36
- data/doc/ex/flip.rb +0 -11
- data/doc/ex/flop.rb +0 -11
- data/doc/ex/font_styles.rb +0 -32
- data/doc/ex/fonts.rb +0 -16
- data/doc/ex/frame.rb +0 -12
- data/doc/ex/gaussian_blur.rb +0 -11
- data/doc/ex/get_multiline_type_metrics.rb +0 -41
- data/doc/ex/get_pixels.rb +0 -45
- data/doc/ex/get_type_metrics.rb +0 -142
- data/doc/ex/gradientfill.rb +0 -27
- data/doc/ex/grav.rb +0 -45
- data/doc/ex/gravity.rb +0 -78
- data/doc/ex/group.rb +0 -26
- data/doc/ex/hatchfill.rb +0 -27
- data/doc/ex/image.rb +0 -44
- data/doc/ex/images/Apple.miff +0 -0
- data/doc/ex/images/Ballerina.jpg +0 -0
- data/doc/ex/images/Ballerina3.jpg +0 -0
- data/doc/ex/images/Button_0.gif +0 -0
- data/doc/ex/images/Button_1.gif +0 -0
- data/doc/ex/images/Button_2.gif +0 -0
- data/doc/ex/images/Button_3.gif +0 -0
- data/doc/ex/images/Button_4.gif +0 -0
- data/doc/ex/images/Button_5.gif +0 -0
- data/doc/ex/images/Button_6.gif +0 -0
- data/doc/ex/images/Button_7.gif +0 -0
- data/doc/ex/images/Button_8.gif +0 -0
- data/doc/ex/images/Button_9.gif +0 -0
- data/doc/ex/images/Button_A.gif +0 -0
- data/doc/ex/images/Button_B.gif +0 -0
- data/doc/ex/images/Button_C.gif +0 -0
- data/doc/ex/images/Button_D.gif +0 -0
- data/doc/ex/images/Button_E.gif +0 -0
- data/doc/ex/images/Button_F.gif +0 -0
- data/doc/ex/images/Button_G.gif +0 -0
- data/doc/ex/images/Button_H.gif +0 -0
- data/doc/ex/images/Button_I.gif +0 -0
- data/doc/ex/images/Button_J.gif +0 -0
- data/doc/ex/images/Button_K.gif +0 -0
- data/doc/ex/images/Button_L.gif +0 -0
- data/doc/ex/images/Button_M.gif +0 -0
- data/doc/ex/images/Button_N.gif +0 -0
- data/doc/ex/images/Button_O.gif +0 -0
- data/doc/ex/images/Button_P.gif +0 -0
- data/doc/ex/images/Button_Q.gif +0 -0
- data/doc/ex/images/Button_R.gif +0 -0
- data/doc/ex/images/Button_S.gif +0 -0
- data/doc/ex/images/Button_T.gif +0 -0
- data/doc/ex/images/Button_U.gif +0 -0
- data/doc/ex/images/Button_V.gif +0 -0
- data/doc/ex/images/Button_W.gif +0 -0
- data/doc/ex/images/Button_X.gif +0 -0
- data/doc/ex/images/Button_Y.gif +0 -0
- data/doc/ex/images/Button_Z.gif +0 -0
- data/doc/ex/images/Cheetah.jpg +0 -0
- data/doc/ex/images/Coffee.png +0 -0
- data/doc/ex/images/Flower_Hat.jpg +0 -0
- data/doc/ex/images/Gold_Statue.jpg +0 -0
- data/doc/ex/images/Hot_Air_Balloons.jpg +0 -0
- data/doc/ex/images/Hot_Air_Balloons_H.jpg +0 -0
- data/doc/ex/images/Leaf.miff +0 -0
- data/doc/ex/images/No.png +0 -0
- data/doc/ex/images/Polynesia.jpg +0 -0
- data/doc/ex/images/Red_Rocks.jpg +0 -0
- data/doc/ex/images/Rocks_On_Beach.miff +0 -0
- data/doc/ex/images/Shorts.jpg +0 -0
- data/doc/ex/images/Snake.png +0 -0
- data/doc/ex/images/Violin.jpg +0 -0
- data/doc/ex/images/Yellow_Rose.miff +0 -0
- data/doc/ex/images/big-duck.gif +0 -0
- data/doc/ex/images/duck.gif +0 -0
- data/doc/ex/images/duck0.gif +0 -0
- data/doc/ex/images/duck1.gif +0 -0
- data/doc/ex/images/duck10.gif +0 -0
- data/doc/ex/images/duck11.gif +0 -0
- data/doc/ex/images/duck12.gif +0 -0
- data/doc/ex/images/duck13.gif +0 -0
- data/doc/ex/images/duck14.gif +0 -0
- data/doc/ex/images/duck15.gif +0 -0
- data/doc/ex/images/duck2.gif +0 -0
- data/doc/ex/images/duck3.gif +0 -0
- data/doc/ex/images/duck4.gif +0 -0
- data/doc/ex/images/duck5.gif +0 -0
- data/doc/ex/images/duck6.gif +0 -0
- data/doc/ex/images/duck7.gif +0 -0
- data/doc/ex/images/duck8.gif +0 -0
- data/doc/ex/images/duck9.gif +0 -0
- data/doc/ex/images/graydient230x6.gif +0 -0
- data/doc/ex/images/image_with_profile.jpg +0 -0
- data/doc/ex/images/logo400x83.gif +0 -0
- data/doc/ex/images/model.miff +0 -0
- data/doc/ex/images/notimplemented.gif +0 -0
- data/doc/ex/images/smile.miff +0 -0
- data/doc/ex/images/spin.gif +0 -0
- data/doc/ex/implode.rb +0 -34
- data/doc/ex/level.rb +0 -11
- data/doc/ex/level_colors.rb +0 -11
- data/doc/ex/line.rb +0 -41
- data/doc/ex/line01.rb +0 -21
- data/doc/ex/mask.rb +0 -35
- data/doc/ex/matte_fill_to_border.rb +0 -39
- data/doc/ex/matte_floodfill.rb +0 -32
- data/doc/ex/matte_replace.rb +0 -39
- data/doc/ex/median_filter.rb +0 -28
- data/doc/ex/modulate.rb +0 -11
- data/doc/ex/mono.rb +0 -23
- data/doc/ex/morph.rb +0 -25
- data/doc/ex/mosaic.rb +0 -37
- data/doc/ex/motion_blur.rb +0 -11
- data/doc/ex/negate.rb +0 -11
- data/doc/ex/negate_channel.rb +0 -9
- data/doc/ex/nested_rvg.rb +0 -21
- data/doc/ex/nonzero.rb +0 -42
- data/doc/ex/normalize.rb +0 -11
- data/doc/ex/oil_paint.rb +0 -11
- data/doc/ex/opacity.rb +0 -37
- data/doc/ex/ordered_dither.rb +0 -11
- data/doc/ex/path.rb +0 -63
- data/doc/ex/pattern1.rb +0 -25
- data/doc/ex/pattern2.rb +0 -26
- data/doc/ex/polaroid.rb +0 -26
- data/doc/ex/polygon.rb +0 -23
- data/doc/ex/polygon01.rb +0 -21
- data/doc/ex/polyline.rb +0 -22
- data/doc/ex/polyline01.rb +0 -21
- data/doc/ex/posterize.rb +0 -8
- data/doc/ex/preview.rb +0 -8
- data/doc/ex/qbezierpath.rb +0 -52
- data/doc/ex/quad01.rb +0 -34
- data/doc/ex/quantize-m.rb +0 -25
- data/doc/ex/radial_blur.rb +0 -9
- data/doc/ex/raise.rb +0 -8
- data/doc/ex/random_threshold_channel.rb +0 -13
- data/doc/ex/rect01.rb +0 -14
- data/doc/ex/rect02.rb +0 -20
- data/doc/ex/rectangle.rb +0 -34
- data/doc/ex/reduce_noise.rb +0 -28
- data/doc/ex/remap.rb +0 -11
- data/doc/ex/remap_images.rb +0 -19
- data/doc/ex/resize_to_fill.rb +0 -8
- data/doc/ex/resize_to_fit.rb +0 -8
- data/doc/ex/roll.rb +0 -9
- data/doc/ex/rotate.rb +0 -44
- data/doc/ex/rotate_f.rb +0 -14
- data/doc/ex/roundrect.rb +0 -33
- data/doc/ex/rubyname.rb +0 -30
- data/doc/ex/rvg_clippath.rb +0 -12
- data/doc/ex/rvg_linecap.rb +0 -42
- data/doc/ex/rvg_linejoin.rb +0 -40
- data/doc/ex/rvg_opacity.rb +0 -18
- data/doc/ex/rvg_pattern.rb +0 -26
- data/doc/ex/rvg_stroke_dasharray.rb +0 -11
- data/doc/ex/segment.rb +0 -11
- data/doc/ex/sepiatone.rb +0 -7
- data/doc/ex/shade.rb +0 -11
- data/doc/ex/shadow.rb +0 -30
- data/doc/ex/shave.rb +0 -15
- data/doc/ex/shear.rb +0 -10
- data/doc/ex/sketch.rb +0 -17
- data/doc/ex/skewx.rb +0 -51
- data/doc/ex/skewy.rb +0 -47
- data/doc/ex/smile.rb +0 -126
- data/doc/ex/solarize.rb +0 -11
- data/doc/ex/sparse_color.rb +0 -55
- data/doc/ex/splice.rb +0 -8
- data/doc/ex/spread.rb +0 -11
- data/doc/ex/stegano.rb +0 -54
- data/doc/ex/stroke_dasharray.rb +0 -42
- data/doc/ex/stroke_fill.rb +0 -10
- data/doc/ex/stroke_linecap.rb +0 -44
- data/doc/ex/stroke_linejoin.rb +0 -48
- data/doc/ex/stroke_width.rb +0 -49
- data/doc/ex/swirl.rb +0 -17
- data/doc/ex/text.rb +0 -37
- data/doc/ex/text01.rb +0 -16
- data/doc/ex/text_align.rb +0 -36
- data/doc/ex/text_antialias.rb +0 -37
- data/doc/ex/text_styles.rb +0 -19
- data/doc/ex/text_undercolor.rb +0 -28
- data/doc/ex/texture_fill_to_border.rb +0 -34
- data/doc/ex/texture_floodfill.rb +0 -32
- data/doc/ex/texturefill.rb +0 -24
- data/doc/ex/threshold.rb +0 -13
- data/doc/ex/to_blob.rb +0 -13
- data/doc/ex/translate.rb +0 -39
- data/doc/ex/transparent.rb +0 -38
- data/doc/ex/transpose.rb +0 -9
- data/doc/ex/transverse.rb +0 -9
- data/doc/ex/tref01.rb +0 -24
- data/doc/ex/triangle01.rb +0 -15
- data/doc/ex/trim.rb +0 -23
- data/doc/ex/tspan01.rb +0 -17
- data/doc/ex/tspan02.rb +0 -17
- data/doc/ex/tspan03.rb +0 -19
- data/doc/ex/unsharp_mask.rb +0 -28
- data/doc/ex/viewex.rb +0 -33
- data/doc/ex/vignette.rb +0 -12
- data/doc/ex/watermark.rb +0 -27
- data/doc/ex/wave.rb +0 -9
- data/doc/ex/wet_floor.rb +0 -58
- data/doc/ex/writing_mode01.rb +0 -26
- data/doc/ex/writing_mode02.rb +0 -26
- data/doc/ilist.html +0 -2056
- data/doc/image1.html +0 -4680
- data/doc/image2.html +0 -3665
- data/doc/image3.html +0 -4522
- data/doc/imageattrs.html +0 -1638
- data/doc/imusage.html +0 -514
- data/doc/index.html +0 -416
- data/doc/info.html +0 -1499
- data/doc/magick.html +0 -570
- data/doc/optequiv.html +0 -2435
- data/doc/rvg.html +0 -975
- data/doc/rvgclip.html +0 -248
- data/doc/rvggroup.html +0 -305
- data/doc/rvgimage.html +0 -289
- data/doc/rvgpattern.html +0 -475
- data/doc/rvgshape.html +0 -406
- data/doc/rvgstyle.html +0 -270
- data/doc/rvgtext.html +0 -465
- data/doc/rvgtspan.html +0 -238
- data/doc/rvgtut.html +0 -530
- data/doc/rvguse.html +0 -145
- data/doc/rvgxform.html +0 -294
- data/doc/scripts/doc.js +0 -22
- data/doc/scripts/stripeTables.js +0 -23
- data/doc/struct.html +0 -1339
- data/doc/usage.html +0 -1621
- data/examples/constitute.rb +0 -7
- data/examples/crop_with_gravity.rb +0 -42
- data/examples/demo.rb +0 -323
- data/examples/describe.rb +0 -41
- data/examples/find_similar_region.rb +0 -34
- data/examples/histogram.rb +0 -312
- data/examples/identify.rb +0 -174
- data/examples/image_opacity.rb +0 -28
- data/examples/import_export.rb +0 -31
- data/examples/pattern_fill.rb +0 -37
- data/examples/rotating_text.rb +0 -45
- data/examples/spinner.rb +0 -49
- data/examples/thumbnail.rb +0 -64
- data/examples/vignette.rb +0 -78
- data/lib/obsolete.rb +0 -66
- data/spec/rmagick/ImageList1_spec.rb +0 -24
- data/spec/rmagick/draw_spec.rb +0 -155
- data/spec/rmagick/image/blue_shift_spec.rb +0 -14
- data/spec/rmagick/image/channel_entropy_spec.rb +0 -9
- data/spec/rmagick/image/composite_spec.rb +0 -72
- data/spec/rmagick/image/constitute_spec.rb +0 -13
- data/spec/rmagick/image/dispatch_spec.rb +0 -16
- data/spec/rmagick/image/from_blob_spec.rb +0 -12
- data/spec/rmagick/image/ping_spec.rb +0 -12
- data/spec/rmagick/image/properties_spec.rb +0 -27
- data/spec/rmagick/image/read_spec.rb +0 -28
- data/spec/spec_helper.rb +0 -10
- data/spec/support/issue_200/app.rb +0 -8
- data/test/Draw.rb +0 -351
- data/test/Enum.rb +0 -228
- data/test/Fill.rb +0 -93
- data/test/Image1.rb +0 -627
- data/test/Image2.rb +0 -1426
- data/test/Image3.rb +0 -1091
- data/test/ImageList1.rb +0 -858
- data/test/ImageList2.rb +0 -406
- data/test/Image_attributes.rb +0 -666
- data/test/Import_Export.rb +0 -115
- data/test/Info.rb +0 -444
- data/test/KernelInfo.rb +0 -67
- data/test/Magick.rb +0 -311
- data/test/Pixel.rb +0 -285
- data/test/PolaroidOptions.rb +0 -23
- data/test/Preview.rb +0 -26
- data/test/Struct.rb +0 -45
- data/test/appearance/Montage.rb +0 -26
- data/test/appearance/appearance_assertion.rb +0 -13
- data/test/appearance/expected/montage_border_color.jpg +0 -0
- data/test/cmyk.icm +0 -0
- data/test/lib/Obsolete.rb +0 -30
- data/test/lib/internal/Draw.rb +0 -823
- data/test/lib/internal/Geometry.rb +0 -98
- data/test/lib/internal/Magick.rb +0 -40
- data/test/srgb.icm +0 -0
- data/test/test_all_basic.rb +0 -49
- data/test/tmpnam_test.rb +0 -50
data/doc/rvgshape.html
DELETED
@@ -1,406 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
3
|
-
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
5
|
-
<head>
|
6
|
-
<meta name="generator" content=
|
7
|
-
"HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
|
8
|
-
|
9
|
-
<title>RMagick 0.0.0: RVG Reference: Shapes</title>
|
10
|
-
<meta http-equiv="Content-Type" content=
|
11
|
-
"text/html; charset=us-ascii" />
|
12
|
-
<meta name="GENERATOR" content="Quanta Plus" />
|
13
|
-
<meta name="Copyright" content=
|
14
|
-
"Copyright (C) 2006 by Timothy P. Hunter" />
|
15
|
-
<link rel="stylesheet" type="text/css" href="css/doc.css" />
|
16
|
-
<link rel="stylesheet" type="text/css" href="css/ref.css" />
|
17
|
-
<script type="text/javascript" src="scripts/doc.js">
|
18
|
-
</script>
|
19
|
-
<script type="text/javascript">
|
20
|
-
//<![CDATA[
|
21
|
-
//]]>
|
22
|
-
</script>
|
23
|
-
<style type="text/css">
|
24
|
-
/*<![CDATA[*/
|
25
|
-
}
|
26
|
-
/*]]>*/
|
27
|
-
</style>
|
28
|
-
</head>
|
29
|
-
|
30
|
-
<body>
|
31
|
-
<h6 id="header">RMagick 0.0.0 User's Guide and Reference</h6>
|
32
|
-
|
33
|
-
<div class="nav">
|
34
|
-
« <a href="rvgstyle.html">Prev</a> | <a href=
|
35
|
-
"index.html">Contents</a> | <a href=
|
36
|
-
"rvgxform.html">Next</a> »
|
37
|
-
</div>
|
38
|
-
|
39
|
-
<h1>The shape methods</h1>
|
40
|
-
|
41
|
-
<div id="toc">
|
42
|
-
<h2>Table of Contents</h2>
|
43
|
-
|
44
|
-
<h3>About the shape methods</h3>
|
45
|
-
|
46
|
-
<h3>Shape methods</h3>
|
47
|
-
|
48
|
-
<div class="toccol">
|
49
|
-
<ul>
|
50
|
-
<li><a href="#circle">circle</a></li>
|
51
|
-
|
52
|
-
<li><a href="#ellipse">ellipse</a></li>
|
53
|
-
|
54
|
-
<li><a href="#line">line</a></li>
|
55
|
-
|
56
|
-
<li><a href="#path">path</a></li>
|
57
|
-
|
58
|
-
<li><a href="#polygon">polygon</a></li>
|
59
|
-
|
60
|
-
<li><a href="#polyline">polyline</a></li>
|
61
|
-
|
62
|
-
<li><a href="#rect">rect</a></li>
|
63
|
-
</ul>
|
64
|
-
</div>
|
65
|
-
</div>
|
66
|
-
|
67
|
-
<div class="subhd">
|
68
|
-
<h2>About the shape methods</h2>
|
69
|
-
</div>
|
70
|
-
|
71
|
-
<div class="intro">
|
72
|
-
<p>The shape methods listed below are defined in the <a href=
|
73
|
-
"rvg.html">RVG</a>, <a href="rvgclip.html">RVG::ClipPath</a>,
|
74
|
-
<a href="rvggroup.html">RVG::Group</a>, and <a href=
|
75
|
-
"rvgpattern.html">RVG::Pattern</a> classes. You can chain the
|
76
|
-
<a href="rvgstyle.html">styles</a> method and the <a href=
|
77
|
-
"rvgxform.html">transform methods</a> to the shape methods.</p>
|
78
|
-
</div>
|
79
|
-
|
80
|
-
<div class="subhd">
|
81
|
-
<h2>shape</h2>
|
82
|
-
</div>
|
83
|
-
|
84
|
-
<div class="sig">
|
85
|
-
<h4 id='circle'>circle</h4>
|
86
|
-
|
87
|
-
<p><span class="arg">obj</span>.circle(<span class=
|
88
|
-
"arg">radius</span>, <span class="arg">cx</span>=0,
|
89
|
-
<span class="arg">cy</span>=0) -> <em>circle</em></p>
|
90
|
-
</div>
|
91
|
-
|
92
|
-
<div class='desc'>
|
93
|
-
<h5>Description</h5>
|
94
|
-
|
95
|
-
<p>Adds a circle to the target object. The arc of a circle
|
96
|
-
begins at the "3 o'clock" point on the radius and progresses
|
97
|
-
towards the "9 o'clock" point. The starting point and direction
|
98
|
-
of the arc are affected by the user space transform in the same
|
99
|
-
manner as the geometry of the object.</p>
|
100
|
-
|
101
|
-
<h5>Arguments</h5>
|
102
|
-
|
103
|
-
<dl>
|
104
|
-
<dt>radius</dt>
|
105
|
-
|
106
|
-
<dd>The radius of the circle</dd>
|
107
|
-
|
108
|
-
<dt>cx, cy</dt>
|
109
|
-
|
110
|
-
<dd>The center of the circle</dd>
|
111
|
-
</dl>
|
112
|
-
|
113
|
-
<h5>Example</h5>
|
114
|
-
|
115
|
-
<p><a href="javascript:popup('circle01.rb.html')"><img src=
|
116
|
-
"ex/circle01.gif" title="Click to see the example script" alt=
|
117
|
-
"circle example" /></a></p>
|
118
|
-
</div>
|
119
|
-
|
120
|
-
<div class="sig">
|
121
|
-
<h4 id='ellipse'>ellipse</h4>
|
122
|
-
|
123
|
-
<p><span class="arg">obj</span>.ellipse(<span class=
|
124
|
-
"arg">rx</span>, <span class="arg">ry</span>, <span class=
|
125
|
-
"arg">cx</span>=0, <span class="arg">cy</span>=0) ->
|
126
|
-
<em>ellipse</em></p>
|
127
|
-
</div>
|
128
|
-
|
129
|
-
<div class='desc'>
|
130
|
-
<h5>Description</h5>
|
131
|
-
|
132
|
-
<p>Adds an ellipse to the target object. The arc of an ellipse
|
133
|
-
begins at the "3 o'clock" point on the radius and progresses
|
134
|
-
towards the "9 o'clock" point. The starting point and direction
|
135
|
-
of the arc are affected by the user space transform in the same
|
136
|
-
manner as the geometry of the object.</p>
|
137
|
-
|
138
|
-
<h5>Arguments</h5>
|
139
|
-
|
140
|
-
<dl>
|
141
|
-
<dt>rx, ry</dt>
|
142
|
-
|
143
|
-
<dd>The <em>x</em>- and <em>y</em>-radii of the ellipse</dd>
|
144
|
-
|
145
|
-
<dt>cx, cy</dt>
|
146
|
-
|
147
|
-
<dd>The center of the ellipse</dd>
|
148
|
-
</dl>
|
149
|
-
|
150
|
-
<h5>Example</h5>
|
151
|
-
|
152
|
-
<p><a href="javascript:popup('ellipse01.rb.html')"><img src=
|
153
|
-
"ex/ellipse01.gif" title="Click to see the example script" alt=
|
154
|
-
"ellipse example" /></a></p>
|
155
|
-
</div>
|
156
|
-
|
157
|
-
<div class="sig">
|
158
|
-
<h4 id='line'>line</h4>
|
159
|
-
|
160
|
-
<p><span class="arg">obj</span>.line(<span class=
|
161
|
-
"arg">x1</span>=0, y1=0, <span class="arg">x2</span>=0,
|
162
|
-
<span class="arg">y2</span>=0) -> <em>line</em></p>
|
163
|
-
</div>
|
164
|
-
|
165
|
-
<div class='desc'>
|
166
|
-
<h5>Description</h5>
|
167
|
-
|
168
|
-
<p>Adds a line to the target object. Lines are never
|
169
|
-
filled.</p>
|
170
|
-
|
171
|
-
<h5>Arguments</h5>
|
172
|
-
|
173
|
-
<dl>
|
174
|
-
<dt>x1, y1</dt>
|
175
|
-
|
176
|
-
<dd>The starting point of the line</dd>
|
177
|
-
|
178
|
-
<dt>x2, y2</dt>
|
179
|
-
|
180
|
-
<dd>The ending point of the line</dd>
|
181
|
-
</dl>
|
182
|
-
|
183
|
-
<h5>Example</h5>
|
184
|
-
|
185
|
-
<p><a href="javascript:popup('line01.rb.html')"><img src=
|
186
|
-
"ex/line01.gif" title="Click to see the example script" alt=
|
187
|
-
"line example" /></a></p>
|
188
|
-
</div>
|
189
|
-
|
190
|
-
<div class="sig">
|
191
|
-
<h4 id='path'>path</h4>
|
192
|
-
|
193
|
-
<p><span class="arg">obj</span>.path(<span class=
|
194
|
-
"arg">path_data</span>) -> <em>path</em></p>
|
195
|
-
</div>
|
196
|
-
|
197
|
-
<div class="desc">
|
198
|
-
<h5>Description</h5>
|
199
|
-
|
200
|
-
<p>Adds a path to the target object.</p>
|
201
|
-
|
202
|
-
<h5>Arguments</h5>
|
203
|
-
|
204
|
-
<p>A path string. The path string has the same syntax as the
|
205
|
-
<strong>d=</strong> attribute on SVG's path element. See the
|
206
|
-
<a href="http://www.w3.org/TR/SVG11/paths.html">SVG
|
207
|
-
standard</a> for a complete description of the syntax.</p>
|
208
|
-
|
209
|
-
<h5>Examples</h5>
|
210
|
-
|
211
|
-
<p>moveto, lineto, and closepath commands<a href=
|
212
|
-
"javascript:popup('triangle01.rb.html')"><img src=
|
213
|
-
"ex/triangle01.gif" title="Click to see the example script"
|
214
|
-
alt="triangle example" /></a></p>
|
215
|
-
|
216
|
-
<p>simple uses of cubic Bézier commands within a
|
217
|
-
path<a href="javascript:popup('cubic01.rb.html')"><img src=
|
218
|
-
"ex/cubic01.gif" title="Click to see the example script" alt=
|
219
|
-
"cubic Bezier commands example" /></a></p>
|
220
|
-
|
221
|
-
<p>cubic Bézier commands change their shape according to
|
222
|
-
the position of the control points<a href=
|
223
|
-
"javascript:popup('cubic02.rb.html')"><img src="ex/cubic02.gif"
|
224
|
-
title="Click to see the example script" alt=
|
225
|
-
"cubic Bezier commands example" /></a></p>
|
226
|
-
|
227
|
-
<p>simple uses of quadratic Bézier commands within a
|
228
|
-
path <a href="javascript:popup('quad01.rb.html')"><img src=
|
229
|
-
"ex/quad01.gif" title="Click to see the example script" alt=
|
230
|
-
"quadratic Bezier commands example" /></a></p>
|
231
|
-
|
232
|
-
<p>simple uses of arc commands within a path<a href=
|
233
|
-
"javascript:popup('arcs01.rb.html')"><img src="ex/arcs01.gif"
|
234
|
-
title="Click to see the example script" alt=
|
235
|
-
"arc commands example" /></a></p>
|
236
|
-
|
237
|
-
<p>Elliptical arcs: The following illustrates the four
|
238
|
-
combinations of large-arc-flag and sweep-flag and the four
|
239
|
-
different arcs that will be drawn based on the values of these
|
240
|
-
flags. <a href="javascript:popup('arcs02.rb.html')"><img src=
|
241
|
-
"ex/arcs02.gif" title="Click to see the example script" alt=
|
242
|
-
"elliptical arc example" /></a></p>
|
243
|
-
</div>
|
244
|
-
|
245
|
-
<div class="sig">
|
246
|
-
<h4 id='polygon'>polygon</h4>
|
247
|
-
|
248
|
-
<p><span class="arg">obj</span>.polygon(<span class=
|
249
|
-
"arg">x1</span>, y1, <span class="arg">x2</span>, <span class=
|
250
|
-
"arg">y2</span>...) -> <em>polygon</em><br />
|
251
|
-
<span class="arg">obj</span>.polygon(<span class=
|
252
|
-
"arg">array</span>) -> <em>polygon</em><br />
|
253
|
-
<span class="arg">obj</span>.polygon(<span class=
|
254
|
-
"arg">array1</span>, <span class="arg">array2</span>) ->
|
255
|
-
<em>polygon</em></p>
|
256
|
-
</div>
|
257
|
-
|
258
|
-
<div class="desc">
|
259
|
-
<h5>Description</h5>
|
260
|
-
|
261
|
-
<p>Adds a closed shape consisting of a series of connected line
|
262
|
-
segments to the target object.</p>
|
263
|
-
|
264
|
-
<h5>Arguments</h5>
|
265
|
-
|
266
|
-
<p>The arguments to <code>polygon</code> and <a href=
|
267
|
-
"#polyline">polyline</a> can be</p>
|
268
|
-
|
269
|
-
<ol>
|
270
|
-
<li>At least 4 numbers that describe the [x, y] coordinates
|
271
|
-
of the points of the polygon/polyline.</li>
|
272
|
-
|
273
|
-
<li>One array containing at least 4 numbers.</li>
|
274
|
-
|
275
|
-
<li>Two arrays. The first array is a list of x-coordinates.
|
276
|
-
The second array is a list of y-coordinates. Both arrays must
|
277
|
-
have at least one element. If one array is shorter than the
|
278
|
-
other, the shorter array is extended by duplicating its
|
279
|
-
elements as necessary. The combined arrays must describe at
|
280
|
-
least 2 pairs of [x,y] coordinates. For example
|
281
|
-
<pre>
|
282
|
-
x = [1, 3, 5, 7, 9]
|
283
|
-
y = [2,4]
|
284
|
-
canvas.polygon(x, y)
|
285
|
-
# is equivalent to canvas.polygon(1,2, 3,4, 5,2, 7,4, 9,2)
|
286
|
-
</pre>
|
287
|
-
</li>
|
288
|
-
</ol>
|
289
|
-
|
290
|
-
<p>It is an error to specify an odd number of coordinates.
|
291
|
-
Array arguments can be any objects that can be converted to
|
292
|
-
arrays by the Kernel#Array method.</p>
|
293
|
-
|
294
|
-
<h5>Example</h5>
|
295
|
-
|
296
|
-
<p><a href="javascript:popup('polygon01.rb.html')"><img src=
|
297
|
-
"ex/polygon01.gif" title="Click to see the example script" alt=
|
298
|
-
"polygon example" /></a></p>
|
299
|
-
</div>
|
300
|
-
|
301
|
-
<div class="sig">
|
302
|
-
<h4 id='polyline'>polyline</h4>
|
303
|
-
|
304
|
-
<p><span class="arg">obj</span>.polyline(<span class=
|
305
|
-
"arg">x1</span>, y1, <span class="arg">x2</span>, <span class=
|
306
|
-
"arg">y2</span>...) -> <em>polyline</em><br />
|
307
|
-
<span class="arg">obj</span>.polyline(<span class=
|
308
|
-
"arg">array</span>) -> <em>polyline</em><br />
|
309
|
-
<span class="arg">obj</span>.polyline(<span class=
|
310
|
-
"arg">array1</span>, <span class="arg">array2</span>) ->
|
311
|
-
<em>polyline</em></p>
|
312
|
-
</div>
|
313
|
-
|
314
|
-
<div class="desc">
|
315
|
-
<h5>Description</h5>
|
316
|
-
|
317
|
-
<p>Adds a set of connected lines segments to the target object.
|
318
|
-
Typically a polyline defines an open shape.</p>
|
319
|
-
|
320
|
-
<h5>Arguments</h5>
|
321
|
-
|
322
|
-
<p>See <a href="#polygon">polygon</a></p>
|
323
|
-
|
324
|
-
<h5>Example</h5>
|
325
|
-
|
326
|
-
<p><a href="javascript:popup('polyline01.rb.html')"><img src=
|
327
|
-
"ex/polyline01.gif" title="Click to see the example script"
|
328
|
-
alt="polyline example" /></a></p>
|
329
|
-
</div>
|
330
|
-
|
331
|
-
<div class="sig">
|
332
|
-
<h4 id='rect'>rect</h4>
|
333
|
-
|
334
|
-
<p><span class="arg">obj</span>.rect(<span class=
|
335
|
-
"arg">width</span>, <span class="arg">height</span>,
|
336
|
-
<span class="arg">x</span>=0, <span class="arg">y</span>=0)
|
337
|
-
-> <em>rect</em></p>
|
338
|
-
</div>
|
339
|
-
|
340
|
-
<div class="desc">
|
341
|
-
<h5>Description</h5>
|
342
|
-
|
343
|
-
<p>Adds a rectangle to the target object.</p>
|
344
|
-
|
345
|
-
<h5>Arguments</h5>
|
346
|
-
|
347
|
-
<dl>
|
348
|
-
<dt>width, height</dt>
|
349
|
-
|
350
|
-
<dd>The width and height of the rectangle</dd>
|
351
|
-
|
352
|
-
<dt>x, y</dt>
|
353
|
-
|
354
|
-
<dd>The <em>x</em>- and <em>y</em>-axis coordinates of the
|
355
|
-
upper-left corner</dd>
|
356
|
-
</dl>
|
357
|
-
|
358
|
-
<h5>Example</h5>
|
359
|
-
|
360
|
-
<p><a href="javascript:popup('rect01.rb.html')"><img src=
|
361
|
-
"ex/rect01.gif" title="Click to see the example script" alt=
|
362
|
-
"rect example" /></a></p>
|
363
|
-
|
364
|
-
<h5>Rounded rectangles</h5>
|
365
|
-
|
366
|
-
<p>You can define a rounded rectangle by chaining the
|
367
|
-
<code>round</code> method to <code>rect</code>:</p>
|
368
|
-
|
369
|
-
<p><span class="arg">obj</span>.rect(<span class=
|
370
|
-
"arg">width</span>, <span class="arg">height</span>,
|
371
|
-
<span class="arg">x</span>=0, <span class=
|
372
|
-
"arg">y</span>=0).round(<code>rx</code>[, <code>ry</code>])</p>
|
373
|
-
|
374
|
-
<p>The round method accepts two arguments.</p>
|
375
|
-
|
376
|
-
<dl>
|
377
|
-
<dt>rx</dt>
|
378
|
-
|
379
|
-
<dd>The x-axis radius of the ellipse used to round off the
|
380
|
-
corners of the rectangle</dd>
|
381
|
-
|
382
|
-
<dt>ry</dt>
|
383
|
-
|
384
|
-
<dd>The y-axis radius of the ellipse used to round off the
|
385
|
-
corners of the rectangle</dd>
|
386
|
-
</dl>
|
387
|
-
|
388
|
-
<p>If the second argument is omitted it defaults to the value
|
389
|
-
of the first argument.</p>
|
390
|
-
|
391
|
-
<h5>Example</h5>
|
392
|
-
|
393
|
-
<p><a href="javascript:popup('rect02.rb.html')"><img src=
|
394
|
-
"ex/rect02.gif" title="Click to see the example script" alt=
|
395
|
-
"rect example" /></a></p>
|
396
|
-
</div>
|
397
|
-
|
398
|
-
<p class="spacer"> </p>
|
399
|
-
|
400
|
-
<div class="nav">
|
401
|
-
« <a href="rvgstyle.html">Prev</a> | <a href=
|
402
|
-
"index.html">Contents</a> | <a href="rvgxform.html">Next</a>
|
403
|
-
»
|
404
|
-
</div>
|
405
|
-
</body>
|
406
|
-
</html>
|
data/doc/rvgstyle.html
DELETED
@@ -1,270 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
2
|
-
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
3
|
-
|
4
|
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
5
|
-
<head>
|
6
|
-
<meta name="generator" content=
|
7
|
-
"HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
|
8
|
-
|
9
|
-
<title>RMagick 0.0.0: RVG Reference: Styles</title>
|
10
|
-
<meta http-equiv="Content-Type" content=
|
11
|
-
"text/html; charset=us-ascii" />
|
12
|
-
<meta name="GENERATOR" content="Quanta Plus" />
|
13
|
-
<meta name="Copyright" content=
|
14
|
-
"Copyright (C) 2006 by Timothy P. Hunter" />
|
15
|
-
<link rel="stylesheet" type="text/css" href="css/doc.css" />
|
16
|
-
<script type="text/javascript" src="scripts/doc.js">
|
17
|
-
</script>
|
18
|
-
<script type="text/javascript">
|
19
|
-
//<![CDATA[
|
20
|
-
//]]>
|
21
|
-
</script>
|
22
|
-
<style type="text/css">
|
23
|
-
/*<![CDATA[*/
|
24
|
-
}
|
25
|
-
/*]]>*/
|
26
|
-
</style>
|
27
|
-
</head>
|
28
|
-
|
29
|
-
<body>
|
30
|
-
<h6 id="header">RMagick 0.0.0 User's Guide and Reference</h6>
|
31
|
-
|
32
|
-
<div class="nav">
|
33
|
-
« <a href="rvguse.html">Prev</a> | <a href=
|
34
|
-
"index.html">Contents</a> | <a href=
|
35
|
-
"rvgshape.html">Next</a> »
|
36
|
-
</div>
|
37
|
-
|
38
|
-
<h1>The styles method</h1>
|
39
|
-
|
40
|
-
<div id="toc">
|
41
|
-
<h2>Table of Contents</h2>
|
42
|
-
|
43
|
-
<h3>instance methods</h3>
|
44
|
-
|
45
|
-
<div>
|
46
|
-
<ul>
|
47
|
-
<li><a href="#styles">styles</a></li>
|
48
|
-
</ul>
|
49
|
-
</div>
|
50
|
-
</div>
|
51
|
-
|
52
|
-
<h2 class="methods">styles</h2>
|
53
|
-
|
54
|
-
<div class="sig">
|
55
|
-
<h3 id='styles'>styles</h3>
|
56
|
-
|
57
|
-
<p><span class="arg">obj.</span>styles(<span class=
|
58
|
-
"arg">:style=>value</span>[, <span class=
|
59
|
-
"arg">:style=>value</span>...]) [{|obj| }] ->
|
60
|
-
<em>obj</em></p>
|
61
|
-
</div>
|
62
|
-
|
63
|
-
<div class="desc">
|
64
|
-
<h4>Description</h4>
|
65
|
-
|
66
|
-
<p>Assigns <em>styles</em> to the target object, which may be a
|
67
|
-
container, shape, text, raster image, or pattern. Styles are
|
68
|
-
presentational attributes that define how the object is
|
69
|
-
rendered.</p>
|
70
|
-
|
71
|
-
<p><code>Styles</code> yields to a block if a block is present,
|
72
|
-
passing the target object as an argument. This is useful when
|
73
|
-
<code>styles</code> is chained to a container constructor
|
74
|
-
method such as <a href="rvg.html#RVG_g">g</a> or <a href=
|
75
|
-
"rvg.html#RVG_rvg">rvg</a>. By default, objects within a
|
76
|
-
container get the styles defined on the container.</p>
|
77
|
-
|
78
|
-
<p><code>Styles</code> returns the target object, so other
|
79
|
-
methods can be chained to it.</p>
|
80
|
-
|
81
|
-
<h4>Arguments</h4>
|
82
|
-
|
83
|
-
<p>The argument is a hash. The hash keys are style name
|
84
|
-
symbols. The hash values are the style values. RVG supports the
|
85
|
-
following style names.</p>
|
86
|
-
|
87
|
-
<dl>
|
88
|
-
<dt>:clip_path</dt>
|
89
|
-
|
90
|
-
<dd>An outline used to clip a shape or collection of shapes.
|
91
|
-
The value is an <a href="rvgclip.html#new">clipping
|
92
|
-
path</a>.</dd>
|
93
|
-
|
94
|
-
<dt>:clip_rule</dt>
|
95
|
-
|
96
|
-
<dd>If the <code>clip_path</code> style is used, how to
|
97
|
-
determine if a point is inside or outside a the clip path.
|
98
|
-
The value is a string, either 'nonzero' or 'evenodd'. The
|
99
|
-
default is 'nonzero'. See the <code>fill_rule</code> example
|
100
|
-
below.</dd>
|
101
|
-
|
102
|
-
<dt>:fill</dt>
|
103
|
-
|
104
|
-
<dd>The fill color. The value must be a <a href=
|
105
|
-
"imusage.html#color_names">color name</a> or a <a href=
|
106
|
-
"rvgpattern.html#new">pattern</a>. The default is
|
107
|
-
'black'.</dd>
|
108
|
-
|
109
|
-
<dt>:fill_opacity</dt>
|
110
|
-
|
111
|
-
<dd>The opacity of the fill color. A number between 0.0
|
112
|
-
(fully transparent) and 1.0 (fully opaque). The default is
|
113
|
-
1.0</dd>
|
114
|
-
|
115
|
-
<dt>:fill_rule</dt>
|
116
|
-
|
117
|
-
<dd>How to determine if a point is inside or outside a shape.
|
118
|
-
The value is a string, either 'nonzero' or 'evenodd'. The
|
119
|
-
default is 'nonzero'.</dd>
|
120
|
-
|
121
|
-
<dd>
|
122
|
-
The following descriptions of 'nonzero' and 'evenodd' are
|
123
|
-
from the <a href=
|
124
|
-
"http://www.w3.org/TR/SVG11/painting.html#FillProperties">SVG
|
125
|
-
1.1 standard</a>.
|
126
|
-
|
127
|
-
<dl>
|
128
|
-
<dt>nonzero</dt>
|
129
|
-
|
130
|
-
<dd>This rule determines the "insideness" of a point on
|
131
|
-
the canvas by drawing a ray from that point to infinity
|
132
|
-
in any direction and then examining the places where a
|
133
|
-
segment of the shape crosses the ray. Starting with a
|
134
|
-
count of zero, add one each time a path segment crosses
|
135
|
-
the ray from left to right and subtract one each time a
|
136
|
-
path segment crosses the ray from right to left. After
|
137
|
-
counting the crossings, if the result is zero then the
|
138
|
-
point is outside the path. Otherwise, it is inside.</dd>
|
139
|
-
|
140
|
-
<dt>evenodd</dt>
|
141
|
-
|
142
|
-
<dd>This rule determines the "insideness" of a point on
|
143
|
-
the canvas by drawing a ray from that point to infinity
|
144
|
-
in any direction and counting the number of path segments
|
145
|
-
from the given shape that the ray crosses. If this number
|
146
|
-
is odd, the point is inside; if even, the point is
|
147
|
-
outside.</dd>
|
148
|
-
</dl>
|
149
|
-
</dd>
|
150
|
-
|
151
|
-
<dd>See the examples below.</dd>
|
152
|
-
|
153
|
-
<dt>:opacity</dt>
|
154
|
-
|
155
|
-
<dd>Both the stroke and the fill opacity. A number between
|
156
|
-
0.0 (fully transparent) and 1.0 (fully opaque). The default
|
157
|
-
is 1.0. See below for an example.</dd>
|
158
|
-
|
159
|
-
<dt>:stroke</dt>
|
160
|
-
|
161
|
-
<dd>The stroke color. The value must be a <a href=
|
162
|
-
"imusage.html#color_names">color name</a> or a <a href=
|
163
|
-
"rvgpattern.html#new">pattern</a>. The default is 'none',
|
164
|
-
that is, transparent black ("#000000ff").</dd>
|
165
|
-
|
166
|
-
<dt>:stroke_dasharray</dt>
|
167
|
-
|
168
|
-
<dd>An array of numbers that specify the length of the dashes
|
169
|
-
and gaps with which to draw a dashed line. If the array
|
170
|
-
contains an odd number of values, the values are repeated to
|
171
|
-
produce an even number of dashes and gaps. The numbers are in
|
172
|
-
user coordinates. By default all lines are drawn as solid
|
173
|
-
lines. See below for an example.</dd>
|
174
|
-
|
175
|
-
<dt>:stroke_dashoffset</dt>
|
176
|
-
|
177
|
-
<dd>Normally a dashed line is drawn using the first number in
|
178
|
-
the stroke_dasharray as the length of the first dash. This
|
179
|
-
style can be used to specify a different starting point in
|
180
|
-
the array.</dd>
|
181
|
-
|
182
|
-
<dt>:stroke_linecap</dt>
|
183
|
-
|
184
|
-
<dd>The shape of the end of a line. The value may be one of
|
185
|
-
the strings 'butt', 'round', or 'square'. The default is
|
186
|
-
'butt'. See below for an example.</dd>
|
187
|
-
|
188
|
-
<dt>:stroke_linejoin</dt>
|
189
|
-
|
190
|
-
<dd>The shape of the corner where two lines are joined. The
|
191
|
-
value may be one of the strings 'miter', 'round', or 'bevel'.
|
192
|
-
The default is 'miter'. See below for an example.</dd>
|
193
|
-
|
194
|
-
<dt>:stroke_miterlimit</dt>
|
195
|
-
|
196
|
-
<dd>If the <code>stroke_linejoin</code> value is 'miter', a
|
197
|
-
number specifying the ratio of the miter to the thickness of
|
198
|
-
the lines being joined. When the limit is exceeded the join
|
199
|
-
is converted from a miter to a bevel. The value must be a
|
200
|
-
number greater than or equal to 1.0. The default is 4.0.</dd>
|
201
|
-
|
202
|
-
<dt>:stroke_opacity</dt>
|
203
|
-
|
204
|
-
<dd>The opacity of the stroke color. A number between 0.0
|
205
|
-
(fully transparent) and 1.0 (fully opaque). The default is
|
206
|
-
1.0 unless <code>stroke</code> has the default value
|
207
|
-
'none'.</dd>
|
208
|
-
|
209
|
-
<dt>:stroke_width</dt>
|
210
|
-
|
211
|
-
<dd>The thickness of the stroke. The default is 1 user
|
212
|
-
coordinate.</dd>
|
213
|
-
</dl>
|
214
|
-
|
215
|
-
<p>(Text styles are described with the <a href=
|
216
|
-
"rvgtext.html#new">Text</a> class.)</p>
|
217
|
-
|
218
|
-
<h4>Examples</h4>
|
219
|
-
|
220
|
-
<p><strong>:fill=>'#00ff00', :stroke=>'blue',
|
221
|
-
:stroke_width=>8</strong><a href=
|
222
|
-
"javascript:popup('stroke_fill.rb.html')"><img src=
|
223
|
-
"ex/stroke_fill.gif" title="Click to see the example script"
|
224
|
-
alt="stroke and fill example" /></a></p>
|
225
|
-
|
226
|
-
<p><strong>:fill_rule=>'nonzero'</strong><a href=
|
227
|
-
"javascript:popup('nonzero.rb.html')"><img src="ex/nonzero.gif"
|
228
|
-
title="Click to see the example script" alt=
|
229
|
-
"nonzero example" /></a></p>
|
230
|
-
|
231
|
-
<p><strong>:fill_rule=>'evenodd'</strong><a href=
|
232
|
-
"javascript:popup('evenodd.rb.html')"><img src="ex/evenodd.gif"
|
233
|
-
title="Click to see the example script" alt=
|
234
|
-
"evenodd example" /></a></p>
|
235
|
-
|
236
|
-
<p><strong>Three values of :opacity</strong><a href=
|
237
|
-
"javascript:popup('rvg_opacity.rb.html')"><img src=
|
238
|
-
"ex/rvg_opacity.gif" title="Click to see the example script"
|
239
|
-
alt="opacity example" /></a></p>
|
240
|
-
|
241
|
-
<p><strong>:stroke_dasharray=>[10,5]</strong><a href=
|
242
|
-
"javascript:popup('rvg_stroke_dasharray.rb.html')"><img src=
|
243
|
-
"ex/rvg_stroke_dasharray.gif" title=
|
244
|
-
"Click to see the example script" alt=
|
245
|
-
"stroke_dasharray example" /></a></p>
|
246
|
-
|
247
|
-
<p><strong>Three values of :stroke_linecap</strong><a href=
|
248
|
-
"javascript:popup('rvg_linecap.rb.html')"><img src=
|
249
|
-
"ex/rvg_linecap.gif" title="Click to see the example script"
|
250
|
-
alt="stroke_linecap example" /></a></p>
|
251
|
-
|
252
|
-
<p><strong>Three values of :stroke_linejoin</strong><a href=
|
253
|
-
"javascript:popup('rvg_linejoin.rb.html')"><img src=
|
254
|
-
"ex/rvg_linejoin.gif" title="Click to see the example script"
|
255
|
-
alt="stroke_linejoin example" /></a></p>
|
256
|
-
|
257
|
-
<h4>Returns</h4>
|
258
|
-
|
259
|
-
<p><span class="arg">obj</span></p>
|
260
|
-
</div>
|
261
|
-
|
262
|
-
<p class="spacer"> </p>
|
263
|
-
|
264
|
-
<div class="nav">
|
265
|
-
« <a href="rvguse.html">Prev</a> | <a href=
|
266
|
-
"index.html">Contents</a> | <a href="rvgshape.html">Next</a>
|
267
|
-
»
|
268
|
-
</div>
|
269
|
-
</body>
|
270
|
-
</html>
|