mini_magick 4.0.4 → 4.1.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of mini_magick might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/lib/mini_magick/tool.rb +32 -9
- data/lib/mini_magick/version.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8921e089d8d63d1391e76876bc63b4e3ff953706
|
4
|
+
data.tar.gz: 38930195578ded9545d86b4225718671a9cd8b6a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 39cc0fccd098a964a02be8e2cde7565d492ab9a5831df89a2f1b90d751d67368c13584c05ef3253aab51f8aecf107a52ca489a6849bd32e80a334869500f4628
|
7
|
+
data.tar.gz: 9c620a81d8b8e601a172d3b8333f4020048e2b7d385ce40fe85caff7f6df7480f1e08c8046d8fa10d66164eb264efe06d9303f111444f55c6193546ca34ab0f2
|
data/lib/mini_magick/tool.rb
CHANGED
@@ -149,10 +149,11 @@ module MiniMagick
|
|
149
149
|
# Changes the last operator to its "plus" form.
|
150
150
|
#
|
151
151
|
# @example
|
152
|
-
#
|
153
|
-
#
|
154
|
-
#
|
155
|
-
#
|
152
|
+
# MiniMagick::Tool::Mogrify.new do |mogrify|
|
153
|
+
# mogrify.antialias.+
|
154
|
+
# mogrify.distort.+("Perspective", "0,0,4,5 89,0,45,46")
|
155
|
+
# end
|
156
|
+
# # executes `mogrify +antialias +distort Perspective '0,0,4,5 89,0,45,46'`
|
156
157
|
#
|
157
158
|
# @return [self]
|
158
159
|
#
|
@@ -162,6 +163,27 @@ module MiniMagick
|
|
162
163
|
self
|
163
164
|
end
|
164
165
|
|
166
|
+
##
|
167
|
+
# Create an ImageMagick stack in the command (surround.
|
168
|
+
#
|
169
|
+
# @example
|
170
|
+
# MiniMagick::Tool::Convert.new do |convert|
|
171
|
+
# convert << "wand.gif"
|
172
|
+
# convert.stack do |stack|
|
173
|
+
# stack << "wand.gif"
|
174
|
+
# stack.rotate(30)
|
175
|
+
# end
|
176
|
+
# convert.append.+
|
177
|
+
# convert << "images.gif"
|
178
|
+
# end
|
179
|
+
# # executes `convert wand.gif \( wizard.gif -rotate 30 \) +append images.gif`
|
180
|
+
#
|
181
|
+
def stack
|
182
|
+
self << "("
|
183
|
+
yield self
|
184
|
+
self << ")"
|
185
|
+
end
|
186
|
+
|
165
187
|
private
|
166
188
|
|
167
189
|
##
|
@@ -202,11 +224,12 @@ module MiniMagick
|
|
202
224
|
##
|
203
225
|
# Creates method based on command-line option's name.
|
204
226
|
#
|
205
|
-
#
|
206
|
-
#
|
207
|
-
#
|
208
|
-
#
|
209
|
-
#
|
227
|
+
# mogrify = MiniMagick::Tool.new("mogrify")
|
228
|
+
# mogrify.antialias
|
229
|
+
# mogrify.depth(8)
|
230
|
+
# mogrify.resize("500x500")
|
231
|
+
# mogirfy.command.join(" ")
|
232
|
+
# #=> "mogrify -antialias -depth 8 -resize 500x500"
|
210
233
|
#
|
211
234
|
def option(*options)
|
212
235
|
options.each do |option|
|
data/lib/mini_magick/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mini_magick
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0
|
4
|
+
version: 4.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Corey Johnson
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2015-02-
|
15
|
+
date: 2015-02-17 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: rake
|