rmagick 2.2.2 → 2.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.

Files changed (55) hide show
  1. data/ChangeLog +17 -0
  2. data/README.html +21 -46
  3. data/README.txt +18 -40
  4. data/build_tarball.rake +11 -2
  5. data/doc/comtasks.html +5 -5
  6. data/doc/constants.html +272 -241
  7. data/doc/draw.html +5 -5
  8. data/doc/ex/mask.rb +2 -2
  9. data/doc/ilist.html +9 -9
  10. data/doc/image1.html +164 -16
  11. data/doc/image2.html +105 -8
  12. data/doc/image3.html +8 -8
  13. data/doc/imageattrs.html +4 -137
  14. data/doc/imusage.html +3 -3
  15. data/doc/index.html +9 -9
  16. data/doc/info.html +5 -5
  17. data/doc/magick.html +30 -70
  18. data/doc/optequiv.html +19 -39
  19. data/doc/rvg.html +5 -5
  20. data/doc/rvgclip.html +2 -2
  21. data/doc/rvggroup.html +2 -2
  22. data/doc/rvgimage.html +3 -3
  23. data/doc/rvgpattern.html +3 -3
  24. data/doc/rvgshape.html +2 -2
  25. data/doc/rvgstyle.html +2 -2
  26. data/doc/rvgtext.html +6 -6
  27. data/doc/rvgtspan.html +4 -4
  28. data/doc/rvgtut.html +9 -9
  29. data/doc/rvguse.html +3 -3
  30. data/doc/rvgxform.html +2 -2
  31. data/doc/struct.html +54 -19
  32. data/doc/usage.html +11 -3
  33. data/ext/RMagick/MANIFEST +1 -1
  34. data/ext/RMagick/extconf.rb +8 -23
  35. data/ext/RMagick/rmagick.h +10 -5
  36. data/ext/RMagick/rmdraw.c +7 -8
  37. data/ext/RMagick/rmimage.c +186 -20
  38. data/ext/RMagick/rmmain.c +32 -12
  39. data/ext/RMagick/rmutil.c +171 -28
  40. data/lib/RMagick.rb +7 -7
  41. data/lib/rvg/clippath.rb +2 -2
  42. data/lib/rvg/container.rb +2 -2
  43. data/lib/rvg/describable.rb +2 -2
  44. data/lib/rvg/embellishable.rb +2 -2
  45. data/lib/rvg/misc.rb +2 -2
  46. data/lib/rvg/paint.rb +7 -2
  47. data/lib/rvg/pathdata.rb +2 -2
  48. data/lib/rvg/rvg.rb +3 -3
  49. data/lib/rvg/stretchable.rb +15 -3
  50. data/lib/rvg/stylable.rb +2 -2
  51. data/lib/rvg/text.rb +2 -2
  52. data/lib/rvg/transformable.rb +2 -2
  53. data/lib/rvg/units.rb +2 -2
  54. data/rmagick.gemspec +1 -1
  55. metadata +3 -3
data/doc/draw.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <meta name="generator" content=
7
7
  "HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
8
8
 
9
- <title>RMagick 2.2.2: class Draw</title>
9
+ <title>RMagick 2.3.0: class Draw</title>
10
10
  <meta http-equiv="Content-Type" content=
11
11
  "text/html; charset=us-ascii" />
12
12
  <meta name="GENERATOR" content="Quanta Plus" />
@@ -25,7 +25,7 @@
25
25
  </head>
26
26
 
27
27
  <body>
28
- <h6 id="header">RMagick 2.2.2 User's Guide and Reference</h6>
28
+ <h6 id="header">RMagick 2.3.0 User's Guide and Reference</h6>
29
29
 
30
30
  <div class="nav">
31
31
  &laquo;&nbsp;<a href="image3.html">Prev</a> | <a href=
@@ -539,7 +539,7 @@ title.annotate(montage, 0,0,0,40, 'Named Colors') {
539
539
  <h4>Description</h4>
540
540
 
541
541
  <p>Same as <a href="#dup">dup</a> except the frozen state of
542
- the original is propogated to the copy.</p>
542
+ the original is propagated to the copy.</p>
543
543
 
544
544
  <h4>Returns</h4>
545
545
 
@@ -2210,7 +2210,7 @@ draw.decorate(LineThroughDecoration)
2210
2210
  <div class="desc">
2211
2211
  <h4>Description</h4>
2212
2212
 
2213
- <p>Define a skew tranformation along the x-axis.</p>
2213
+ <p>Define a skew transformation along the x-axis.</p>
2214
2214
 
2215
2215
  <h4>Arguments</h4>
2216
2216
 
@@ -2242,7 +2242,7 @@ draw.decorate(LineThroughDecoration)
2242
2242
  <div class="desc">
2243
2243
  <h4>Description</h4>
2244
2244
 
2245
- <p>Define a skew tranformation along the y-axis.</p>
2245
+ <p>Define a skew transformation along the y-axis.</p>
2246
2246
 
2247
2247
  <h4>Arguments</h4>
2248
2248
 
data/doc/ex/mask.rb CHANGED
@@ -23,11 +23,11 @@ gc.annotate(q, 0, 0, 0, 0, "Flower Hat") do
23
23
  end
24
24
 
25
25
  # Set the matte attribute to false, indicating the absence of an alpha channel
26
- # in the mask image. Assign the mask image to the mask= attribute of the image
26
+ # in the mask image. Assign the mask image to the mask= attribute of the image
27
27
  # being masked.
28
28
 
29
29
  q.matte = false
30
- img.mask = q
30
+ img.mask q
31
31
 
32
32
  # Use the #level method to darken the image under the black part of the mask.
33
33
 
data/doc/ilist.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <meta name="generator" content=
7
7
  "HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
8
8
 
9
- <title>RMagick 2.2.2: class ImageList</title>
9
+ <title>RMagick 2.3.0: class ImageList</title>
10
10
  <meta http-equiv="Content-Type" content=
11
11
  "text/html; charset=us-ascii" />
12
12
  <meta name="GENERATOR" content="Quanta Plus" />
@@ -20,7 +20,7 @@
20
20
  </head>
21
21
 
22
22
  <body>
23
- <h6 id="header">RMagick 2.2.2 User's Guide and Reference</h6>
23
+ <h6 id="header">RMagick 2.3.0 User's Guide and Reference</h6>
24
24
 
25
25
  <div class="nav">
26
26
  &laquo;&nbsp;<a href="magick.html">Prev</a> | <a href=
@@ -374,7 +374,7 @@ ilist.ticks_per_second = 1000
374
374
  undefined results. Most of the time RMagick will raise an
375
375
  ArgumentError exception. For example, if you call
376
376
  <code>collect!</code> on an imagelist you should make sure that
377
- the members of theimagelist remain images. If you need to
377
+ the members of the imagelist remain images. If you need to
378
378
  replace images in an imagelist with non-image objects, convert
379
379
  the imagelist to an array with the <code>to_a</code> method,
380
380
  then modify the array.</p>
@@ -563,7 +563,7 @@ ilist.animate { self.server_name = "other:0.0" }
563
563
  <h4>Description</h4>
564
564
 
565
565
  <p>Same as <a href="#dup">dup</a>, but the frozen state of the
566
- original is propogated to the copy.</p>
566
+ original is propagated to the copy.</p>
567
567
 
568
568
  <h4>Returns</h4>
569
569
 
@@ -760,7 +760,7 @@ imagelist2 = imagelist1.copy
760
760
  successor. The resulting imagelist usually produces a much
761
761
  smaller file.</p>
762
762
 
763
- <p>The <code>desconstruct</code> method starts by copying the
763
+ <p>The <code>deconstruct</code> method starts by copying the
764
764
  first image in the list to the output imagelist. Then, for each
765
765
  pair of images, <code>deconstruct</code> computes the smallest
766
766
  rectangle that encompasses all the changes between the first
@@ -1519,7 +1519,7 @@ ilist.new_image(100, 100) { self.background_color = "red" }
1519
1519
  first images virtual canvas using the current background
1520
1520
  color, and compose each image in turn onto that canvas.
1521
1521
  Images falling outside that canvas will be clipped. Final
1522
- image will have a zero virtual canvas offset. This is usally
1522
+ image will have a zero virtual canvas offset. This is usually
1523
1523
  used as one of the final 'image layering' operations
1524
1524
  overlaying all the prepared image layers into a final image.
1525
1525
  For a single image this method can also be used to fillout a
@@ -1536,7 +1536,7 @@ ilist.new_image(100, 100) { self.background_color = "red" }
1536
1536
  'locked' to the origin, by definition, image layers with a
1537
1537
  negative offsets will still be clipped by the top and left
1538
1538
  edges. This method is commonly used to layout individual
1539
- image using various offset but without knowning the final
1539
+ image using various offset but without knowing the final
1540
1540
  canvas size. The resulting image will, like FlattenLayer not
1541
1541
  have any virtual offset, so can be saved to any image file
1542
1542
  format.</span> This method corresponds to <a href=
@@ -1592,7 +1592,7 @@ ilist.new_image(100, 100) { self.background_color = "red" }
1592
1592
 
1593
1593
  <dd class="imquote">Remove (and merge time delays) of
1594
1594
  duplicate consecutive images, so as to simplify layer
1595
- overlays of coalesced animations. Usally this is a result of
1595
+ overlays of coalesced animations. Usually this is a result of
1596
1596
  using a constant time delay across the whole animation, or
1597
1597
  after a larger animation was split into smaller
1598
1598
  sub-animations. The duplicate frames could also have been
@@ -1605,7 +1605,7 @@ ilist.new_image(100, 100) { self.background_color = "red" }
1605
1605
  proper timed animation, a warning is then issued). In a GIF
1606
1606
  animation, such images are usually frames which provide
1607
1607
  partial intermediary updates between the frames that are
1608
- actually displayed to users. These frames are usally added
1608
+ actually displayed to users. These frames are usually added
1609
1609
  for improved frame optimization in GIF animations.</dd>
1610
1610
  </dl>
1611
1611
 
data/doc/image1.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <meta name="generator" content=
7
7
  "HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
8
8
 
9
- <title>RMagick 2.2.2: class Image (class methods and instance
9
+ <title>RMagick 2.3.0: class Image (class methods and instance
10
10
  methods a-d)</title>
11
11
  <meta http-equiv="Content-Type" content=
12
12
  "text/html; charset=us-ascii" />
@@ -48,7 +48,7 @@ float: left;
48
48
  </head>
49
49
 
50
50
  <body>
51
- <h6 id="header">RMagick 2.2.2 User's Guide and Reference</h6>
51
+ <h6 id="header">RMagick 2.3.0 User's Guide and Reference</h6>
52
52
 
53
53
  <div class="nav">
54
54
  &laquo;&nbsp;<a href="imageattrs.html">Prev</a> | <a href=
@@ -130,6 +130,10 @@ float: left;
130
130
 
131
131
  <li><a href="#affine_transform">affine_transform</a></li>
132
132
 
133
+ <li><a href="#alpha">alpha</a></li>
134
+
135
+ <li><a href="#alpha_q">alpha?</a></li>
136
+
133
137
  <li><a href="#annotate">annotate</a></li>
134
138
 
135
139
  <li><a href="#auto_orient">auto_orient</a></li>
@@ -145,15 +149,17 @@ float: left;
145
149
  <li><a href="#blur_channel">blur_channel</a></li>
146
150
 
147
151
  <li><a href="#blur_image">blur_image</a></li>
148
-
149
- <li><a href="#border">border</a></li>
150
152
  </ul>
151
153
  </div>
152
154
 
153
155
  <div class="toccol">
154
156
  <ul>
157
+ <li><a href="#border">border</a></li>
158
+
155
159
  <li><a href="#border_bang">border!</a></li>
156
160
 
161
+ <li><a href="#bounding_box">bounding_box</a></li>
162
+
157
163
  <li><a href="#change_geometry">change_geometry</a></li>
158
164
 
159
165
  <li><a href="#changed_q">changed?</a></li>
@@ -225,6 +231,8 @@ float: left;
225
231
 
226
232
  <li><a href="#cycle_colormap">cycle_colormap</a></li>
227
233
 
234
+ <li><a href="#decipher">decipher</a></li>
235
+
228
236
  <li><a href="#delete_profile">delete_profile</a></li>
229
237
 
230
238
  <li><a href="#despeckle">despeckle</a></li>
@@ -800,7 +808,7 @@ img = Image.read_inline(content)
800
808
 
801
809
  <p>The value of <span class=
802
810
  "arg">img</span>.<code>signature</code> &lt;=&gt; <span class=
803
- "arg">other_mage</span>.<code>signature</code>.</p>
811
+ "arg">other_image</span>.<code>signature</code>.</p>
804
812
 
805
813
  <h4>See also</h4>
806
814
 
@@ -824,7 +832,7 @@ img = Image.read_inline(content)
824
832
  <div class="desc">
825
833
  <h4>Description</h4>
826
834
 
827
- <p><span class="imquote">Adaptively blurs the image by bluring
835
+ <p><span class="imquote">Adaptively blurs the image by blurring
828
836
  more intensely near image edges and less intensely far from
829
837
  edges.</span> The adaptive_blur method blurs <span class=
830
838
  "imquote">the image with a Gaussian operator of the
@@ -1344,6 +1352,82 @@ img = Image.read_inline(content)
1344
1352
  <p>AffineTransformImage</p>
1345
1353
  </div>
1346
1354
 
1355
+ <div class="sig">
1356
+ <h3 id="alpha">alpha</h3>
1357
+
1358
+ <p><span class="arg">img</span>.alpha(<span class=
1359
+ "arg">type</span>) -&gt; <em>type</em></p>
1360
+ </div>
1361
+
1362
+ <div class="desc">
1363
+ <h4>Description</h4>
1364
+
1365
+ <p>Set a flag to indicate whether or not to use alpha channel
1366
+ data.</p>
1367
+
1368
+ <h4>Arguments</h4>
1369
+
1370
+ <p>One of the following values of the AlphaChannelType
1371
+ enumeration:</p>
1372
+
1373
+ <dl>
1374
+ <dt>ActivateAlphaChannel</dt>
1375
+
1376
+ <dd>Use alpha channel data.</dd>
1377
+
1378
+ <dt>DeactivateAlphaChannel</dt>
1379
+
1380
+ <dd>Do not use alpha channel data.</dd>
1381
+
1382
+ <dt>ResetAlphaChannel</dt>
1383
+
1384
+ <dd>Set the alpha channel to fully opaque.</dd>
1385
+
1386
+ <dt>SetAlphaChannel</dt>
1387
+
1388
+ <dd>Sets the alpha channel to the intensity of the
1389
+ image.</dd>
1390
+ </dl>
1391
+
1392
+ <h4>Returns</h4>
1393
+
1394
+ <p>The argument.</p>
1395
+
1396
+ <h4>See also</h4>
1397
+
1398
+ <p><a href="#alpha_q">alpha?</a></p>
1399
+
1400
+ <h4>Notes</h4>
1401
+
1402
+ <p>Available in ImageMagick 6.3.5 and later.</p>
1403
+
1404
+ <h4>Magick API</h4>
1405
+
1406
+ <p>SetImageAlphaChannel</p>
1407
+ </div>
1408
+
1409
+ <div class="sig">
1410
+ <h3 id="alpha_q">alpha?</h3>
1411
+
1412
+ <p><span class="arg">img</span>.alpha? -&gt; <code>true</code>
1413
+ or <code>false</code></p>
1414
+ </div>
1415
+
1416
+ <div class="desc">
1417
+ <h4>Description</h4>
1418
+
1419
+ <p>Returns <code>true</code> if the alpha channel will be used,
1420
+ <code>false</code> otherwise.</p>
1421
+
1422
+ <h4>See also</h4>
1423
+
1424
+ <p><a href="#alpha">alpha</a></p>
1425
+
1426
+ <h4>Magick API</h4>
1427
+
1428
+ <p>GetImageAlphaChannel</p>
1429
+ </div>
1430
+
1347
1431
  <div class="sig">
1348
1432
  <h3 id="annotate">annotate</h3>
1349
1433
 
@@ -1639,7 +1723,7 @@ img = Image.read_inline(content)
1639
1723
 
1640
1724
  <dd>One or more <a href=
1641
1725
  "constants.html#ChannelType">ChannelType</a> values. If none
1642
- are specified, all channels are blurred. This is the
1726
+ are specified, the red, green, and blue channels are blurred. This is the
1643
1727
  equivalent of <a href="#blur_image">blur_image</a>.</dd>
1644
1728
  </dl>
1645
1729
 
@@ -1784,6 +1868,34 @@ img = Image.read_inline(content)
1784
1868
  <p>self</p>
1785
1869
  </div>
1786
1870
 
1871
+ <div class="sig">
1872
+ <h3 id="bounding_box">bounding_box</h3>
1873
+
1874
+ <p><span class="arg">img</span>.bounding_box -&gt;
1875
+ <em>rectangle</em></p>
1876
+ </div>
1877
+
1878
+ <div class="desc">
1879
+ <h4>Description</h4>
1880
+
1881
+ <p>The image's <em>bounding box</em>. The bounding box is the
1882
+ rectangle that encloses all the pixels not in the border color.
1883
+ Uses the current <a href="#fuzz">fuzz</a> value.</p>
1884
+
1885
+ <h4>Returns</h4>A <a href="struct.html#Rectangle">Rectangle</a>
1886
+ object.
1887
+
1888
+ <h4>Example</h4>
1889
+
1890
+ <p>In this example, the bounding box is the gray square
1891
+ enclosing the blue circle. (The coordinates and red circles
1892
+ were added after the bounding box was computed.)</p>
1893
+
1894
+ <p><a href="javascript:popup('bounding_box.rb.html')"><img src=
1895
+ "ex/bounding_box.gif" alt="ex/bounding_box.rb" title=
1896
+ "Click to see the example script" /></a></p>
1897
+ </div>
1898
+
1787
1899
  <div class="sig">
1788
1900
  <h3 id="change_geometry">change_geometry</h3>
1789
1901
 
@@ -2141,7 +2253,7 @@ mona.change_geometry!('320x240') { |cols, rows, img|
2141
2253
  <h4>Description</h4>
2142
2254
 
2143
2255
  <p>Same as <a href="#dup">dup</a> except the frozen state of
2144
- the original is propogated to the new copy.</p>
2256
+ the original is propagated to the new copy.</p>
2145
2257
 
2146
2258
  <h4>Returns</h4>
2147
2259
 
@@ -2167,10 +2279,10 @@ mona.change_geometry!('320x240') { |cols, rows, img|
2167
2279
  of its replacement value in an LUT gradient image.</p>
2168
2280
 
2169
2281
  <p class="imquote">The LUT image should be either a single row
2170
- or column image of replacement colors. The lookup is controled
2282
+ or column image of replacement colors. The lookup is controlled
2171
2283
  by the -interpolate setting, especially for an LUT which is not
2172
2284
  the full length needed by the IM installed Quality (Q) level.
2173
- Good setings for this is the default 'bilinear' or 'bicubic'
2285
+ Good settings for this is the default 'bilinear' or 'bicubic'
2174
2286
  interpolation setting for a smooth color gradient, or 'integer'
2175
2287
  for a direct unsmoothed lookup of color values.</p>
2176
2288
 
@@ -2183,7 +2295,7 @@ mona.change_geometry!('320x240') { |cols, rows, img|
2183
2295
  alpha/matte value using the alpha/matte value of the original
2184
2296
  image. As such correct alpha channel lookup for a pure
2185
2297
  gray-scale original image will require a copy of that grayscale
2186
- to be transfered into its alpha channel before applying the
2298
+ to be transferred into its alpha channel before applying the
2187
2299
  -clut operator.</p>
2188
2300
 
2189
2301
  <h4>Arguments</h4>
@@ -2394,9 +2506,9 @@ mona.change_geometry!('320x240') { |cols, rows, img|
2394
2506
  <dt>red_pct, green_pct, blue_pct, matte_pct</dt>
2395
2507
 
2396
2508
  <dd>The percentage of the fill color red, green, blue and
2397
- matte (tranparency) components to blend with the image pixel.
2398
- For example, <code>.25</code> is 25%. The matte_pct argument
2399
- is optional.</dd>
2509
+ matte (transparency) components to blend with the image
2510
+ pixel. For example, <code>.25</code> is 25%. The matte_pct
2511
+ argument is optional.</dd>
2400
2512
 
2401
2513
  <dt>fill</dt>
2402
2514
 
@@ -3101,7 +3213,7 @@ f.colors &raquo; 108
3101
3213
 
3102
3214
  <div class="desc">
3103
3215
  <h4>Description</h4>Returns a copy of the image. The tainted
3104
- state of the original is propogated to the copy.
3216
+ state of the original is propagated to the copy.
3105
3217
 
3106
3218
  <h4>Example</h4>
3107
3219
  <pre>
@@ -3389,6 +3501,40 @@ cropped = img.crop(x, y, width, height, true)
3389
3501
  <p>CycleColormapImage</p>
3390
3502
  </div>
3391
3503
 
3504
+ <div class="sig">
3505
+ <h3 id="decipher">decipher</h3>
3506
+
3507
+ <p><span class="arg">img</span>.decipher(<span class=
3508
+ "arg">passphrase</span>) -&gt; <em>image</em></p>
3509
+ </div>
3510
+
3511
+ <div class="desc">
3512
+ <h4>Description</h4>
3513
+
3514
+ <p>Decipher an enciphered image.</p>
3515
+
3516
+ <h4>Arguments</h4>
3517
+
3518
+ <p>The passphrase used to encipher the image.</p>
3519
+
3520
+ <h4>Returns</h4>
3521
+
3522
+ <p>A new image</p>
3523
+
3524
+ <h4>Example</h4>
3525
+ <pre>
3526
+ deciphered_img = img.decipher("magic word")
3527
+ </pre>
3528
+
3529
+ <h4>Magick API</h4>
3530
+
3531
+ <p>DecipherImage</p>
3532
+
3533
+ <h4>See also</h4>
3534
+
3535
+ <p><a href="image2.html#encipher">encipher</a></p>
3536
+ </div>
3537
+
3392
3538
  <div class="sig">
3393
3539
  <h3 id="delete_profile">delete_profile</h3>
3394
3540
 
@@ -3506,7 +3652,7 @@ cropped = img.crop(x, y, width, height, true)
3506
3652
  about their difference.</p>
3507
3653
 
3508
3654
  <p class="imquote">A small normalized mean square
3509
- error...suggests the images are very similiar in spatial layout
3655
+ error...suggests the images are very similar in spatial layout
3510
3656
  and color.</p>
3511
3657
 
3512
3658
  <h4>Returns</h4>
@@ -3851,6 +3997,8 @@ pixels = f.dispatch(0, 0, f.columns, f.rows, "RGB")
3851
3997
 
3852
3998
  <li>PerspectiveDistortion</li>
3853
3999
 
4000
+ <li>PerspectiveProjectionDistortion</li>
4001
+
3854
4002
  <li>ScaleRotateTranslateDistortion</li>
3855
4003
  </ul>
3856
4004
 
data/doc/image2.html CHANGED
@@ -6,7 +6,7 @@
6
6
  <meta name="generator" content=
7
7
  "HTML Tidy for Linux/x86 (vers 1 September 2005), see www.w3.org" />
8
8
 
9
- <title>RMagick 2.2.2: class Image (instance methods e-o)</title>
9
+ <title>RMagick 2.3.0: class Image (instance methods e-o)</title>
10
10
  <meta http-equiv="Content-Type" content=
11
11
  "text/html; charset=us-ascii" />
12
12
  <meta name="GENERATOR" content="Quanta Plus" />
@@ -47,7 +47,7 @@ td.ds {
47
47
  </head>
48
48
 
49
49
  <body>
50
- <h6 id="header">RMagick 2.2.2 User's Guide and Reference</h6>
50
+ <h6 id="header">RMagick 2.3.0 User's Guide and Reference</h6>
51
51
 
52
52
  <div class="nav">
53
53
  &laquo;&nbsp;<a href="image1.html">Prev</a> | <a href=
@@ -78,6 +78,8 @@ td.ds {
78
78
 
79
79
  <li><a href="#emboss">emboss</a></li>
80
80
 
81
+ <li><a href="#encipher">encipher</a></li>
82
+
81
83
  <li><a href="#enhance">enhance</a></li>
82
84
 
83
85
  <li><a href="#equalize">equalize</a></li>
@@ -163,6 +165,8 @@ td.ds {
163
165
 
164
166
  <div class="toccol">
165
167
  <ul>
168
+ <li><a href="#mask">mask</a></li>
169
+
166
170
  <li><a href="#map">map</a></li>
167
171
 
168
172
  <li><a href=
@@ -383,6 +387,40 @@ td.ds {
383
387
  <p>EmbossImage</p>
384
388
  </div>
385
389
 
390
+ <div class="sig">
391
+ <h3 id="encipher">encipher</h3>
392
+
393
+ <p><span class="arg">img</span>.encipher(<span class=
394
+ "arg">passphrase</span>) -&gt; <em>image</em></p>
395
+ </div>
396
+
397
+ <div class="desc">
398
+ <h4>Description</h4>
399
+
400
+ <p>Encipher an image.</p>
401
+
402
+ <h4>Arguments</h4>
403
+
404
+ <p>The passphrase.</p>
405
+
406
+ <h4>Returns</h4>
407
+
408
+ <p>A new image</p>
409
+
410
+ <h4>Example</h4>
411
+ <pre>
412
+ enciphered_img = img.encipher("magic word")
413
+ </pre>
414
+
415
+ <h4>Magick API</h4>
416
+
417
+ <p>EncipherImage</p>
418
+
419
+ <h4>See also</h4>
420
+
421
+ <p><a href="image1.html#decipher">decipher</a></p>
422
+ </div>
423
+
386
424
  <div class="sig">
387
425
  <h3 id="enhance">enhance</h3>
388
426
 
@@ -759,7 +797,7 @@ scanline = img.export_pixels(0, r, img.columns, 1, "RGB");
759
797
 
760
798
  <dt>height</dt>
761
799
 
762
- <dd>The heigth of the new image</dd>
800
+ <dd>The height of the new image</dd>
763
801
 
764
802
  <dt>x, y</dt>
765
803
 
@@ -1245,7 +1283,7 @@ scanline = img.export_pixels(0, r, img.columns, 1, "RGB");
1245
1283
  <h4>Returns</h4>
1246
1284
 
1247
1285
  <p>The elements in the returned array are 2-element arrays in
1248
- the form [name, value]. If &times;Magick does not know the name
1286
+ the form [name, value]. If ImageMagick does not know the name
1249
1287
  for an entry it uses "unknown." There may be more than one
1250
1288
  entry for "unknown" in the returned array. If there is no entry
1251
1289
  with the specified name the value is set to
@@ -2110,7 +2148,7 @@ img.import_pixels(0, r, img.columns, 1, "RGB", scanline);
2110
2148
  the <code>pixels</code> array into a string by calling
2111
2149
  <code>pack</code>, but it does demonstrate the use of a string
2112
2150
  <span class="arg">pixels</span> argument. Note that this
2113
- example assumes that &times;Magick is configured with
2151
+ example assumes that ImageMagick is configured with
2114
2152
  QuantumDepth=8.</p>
2115
2153
  <pre>
2116
2154
  hat = Image.read("Flower_Hat.jpg").first
@@ -2272,7 +2310,7 @@ img.level(white_point, gamma, black_point) -&gt; image # wrong!
2272
2310
  </pre>
2273
2311
 
2274
2312
  <p>That is, the <code>gamma</code> and <code>white_point</code>
2275
- arguments were swapped. In an effort to maintain compatiblity
2313
+ arguments were swapped. In an effort to maintain compatibility
2276
2314
  with older scripts that expect that signature,
2277
2315
  <code>level</code> inspects its arguments and will interchange
2278
2316
  <code>white_point</code> and gamma if they "look" incorrect.
@@ -2461,7 +2499,7 @@ img.level(white_point, gamma, black_point) -&gt; image # wrong!
2461
2499
 
2462
2500
  <p><a href="#magnify_bang">magnify!</a>, <a href=
2463
2501
  "#minify">minify</a>, <a href="image3.html#resize">resize</a>,
2464
- <a href="image3.html#scale">scal</a></p>
2502
+ <a href="image3.html#scale">scale</a></p>
2465
2503
 
2466
2504
  <h4>Magick API</h4>
2467
2505
 
@@ -2536,6 +2574,65 @@ img.level(white_point, gamma, black_point) -&gt; image # wrong!
2536
2574
  <p>MapImage</p>
2537
2575
  </div>
2538
2576
 
2577
+ <div class="sig">
2578
+ <h3 id="mask">mask</h3>
2579
+
2580
+ <p><span class="arg">img</span>.mask([<span class=
2581
+ "arg">image</span> or <code>nil</code>]) -&gt;
2582
+ <em>mask_image</em></p>
2583
+ </div>
2584
+
2585
+ <div class="desc">
2586
+ <h4>Description</h4>
2587
+
2588
+ <p>Sets an image clip mask created from the specified mask
2589
+ image. <span class="imquote">The mask image must have the same
2590
+ dimensions as the image being masked.</span> If not, the mask
2591
+ image is resized to match. <span class="imquote">If the mask
2592
+ image has an alpha channel the opacity of each pixel is used to
2593
+ define the mask. Otherwise, the intensity (gray level) of each
2594
+ pixel is used.</span></p>
2595
+
2596
+ <p>In general, if the mask image does not have an alpha
2597
+ channel, a white pixel in the mask prevents changes to the
2598
+ corresponding pixel in the image being masked, while a black
2599
+ pixel allows changes. A pixel that is neither black nor white
2600
+ will allow partial changes depending on its intensity.</p>
2601
+
2602
+ <p>Use <a href="image1.html#alpha">alpha</a> to specify whether
2603
+ or not the mask image has an alpha channel.</p>
2604
+
2605
+ <h4>Arguments</h4>
2606
+
2607
+ <p>If the value is an imagelist, uses the current image as the
2608
+ mask image. To remove the mask, pass <code>nil</code> instead
2609
+ of an image.</p>
2610
+
2611
+ <p>To get a copy of the current mask, omit the argument
2612
+ entirely.</p>
2613
+
2614
+ <h4>Example</h4>
2615
+
2616
+ <p class="rollover"><a href=
2617
+ "javascript:popup('mask.rb.html')"><img src="ex/mask.jpg" alt=
2618
+ "mask example" title="Click to see the example script"
2619
+ onmouseover="this.src='ex/images/Flower_Hat.jpg'" onmouseout=
2620
+ "this.src='ex/mask.jpg'" /></a> <img src="ex/images/spin.gif"
2621
+ alt="" class="spin" title=
2622
+ "Mouse over the example to see the original image" /></p>
2623
+
2624
+ <h4>Returns</h4>
2625
+
2626
+ <p>A copy of the current mask, or <code>nil</code> if no mask
2627
+ is defined.</p>
2628
+
2629
+ <h4>Notes</h4>
2630
+
2631
+ <p>This method makes a copy of the image to use as the mask.
2632
+ This means that if you want to change the mask you must call
2633
+ this method to establish the changed image as the mask.</p>
2634
+ </div>
2635
+
2539
2636
  <div class="sig">
2540
2637
  <h3 id="matte_fill_to_border">matte_fill_to_border</h3>
2541
2638
 
@@ -3306,7 +3403,7 @@ img = img.opaque('white', 'red')
3306
3403
  <div class="desc">
3307
3404
  <h4>Description</h4>
3308
3405
 
3309
- <p>DIthers the image to a predefined pattern. The <span class=
3406
+ <p>Dithers the image to a predefined pattern. The <span class=
3310
3407
  "arg">threshold_map</span> argument defines the pattern to
3311
3408
  use.</p>
3312
3409