rmagick 6.0.1 → 6.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.devcontainer/ImageMagick6/devcontainer.json +2 -2
- data/.devcontainer/devcontainer.json +2 -2
- data/.editorconfig +2 -2
- data/.github/workflows/ci.yml +46 -13
- data/.rubocop.yml +4 -0
- data/.rubocop_todo.yml +53 -56
- data/CHANGELOG.md +15 -0
- data/Gemfile +4 -0
- data/README.md +11 -6
- data/Rakefile +10 -2
- data/before_install_linux.sh +3 -1
- data/before_install_osx.sh +1 -1
- data/ext/RMagick/extconf.rb +12 -97
- data/ext/RMagick/rmagick.h +1 -1
- data/ext/RMagick/rmilist.cpp +1 -1
- data/ext/RMagick/rmimage.cpp +2 -0
- data/lib/rmagick/version.rb +1 -1
- data/lib/rmagick_internal.rb +2 -2
- data/lib/rvg/clippath.rb +2 -0
- data/lib/rvg/container.rb +2 -0
- data/lib/rvg/deep_equal.rb +2 -0
- data/lib/rvg/describable.rb +2 -0
- data/lib/rvg/embellishable.rb +2 -0
- data/lib/rvg/misc.rb +2 -0
- data/lib/rvg/paint.rb +2 -0
- data/lib/rvg/pathdata.rb +2 -0
- data/lib/rvg/rvg.rb +2 -0
- data/lib/rvg/stretchable.rb +2 -0
- data/lib/rvg/stylable.rb +2 -0
- data/lib/rvg/text.rb +2 -0
- data/lib/rvg/transformable.rb +2 -0
- data/lib/rvg/units.rb +2 -0
- data/rmagick.gemspec +5 -3
- data/sig/rmagick/_draw_common_methods.rbs +2 -0
- data/sig/rmagick/_image_common_methods.rbs +4 -2
- data/sig/rmagick/draw.rbs +2 -0
- data/sig/rmagick/draw_attribute.rbs +2 -0
- data/sig/rmagick/enum.rbs +6 -4
- data/sig/rmagick/error.rbs +2 -0
- data/sig/rmagick/fill.rbs +2 -0
- data/sig/rmagick/geometry.rbs +3 -1
- data/sig/rmagick/image.rbs +5 -3
- data/sig/rmagick/image_list.rbs +23 -21
- data/sig/rmagick/iptc.rbs +2 -0
- data/sig/rmagick/kernel_info.rbs +2 -0
- data/sig/rmagick/optional_method_arguments.rbs +2 -0
- data/sig/rmagick/pixel.rbs +2 -0
- data/sig/rmagick/struct.rbs +2 -0
- data/sig/rvg/embellishable.rbs +1 -1
- data/sig/rvg/pathdata.rbs +1 -1
- data/sig/rvg/rvg.rbs +1 -1
- data/sig/rvg/stylable.rbs +1 -1
- data/sig/rvg/text.rbs +1 -1
- data/sig/rvg/transformable.rbs +1 -1
- metadata +4 -6
data/ext/RMagick/extconf.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
lib_dir = File.expand_path('../../lib', File.dirname(__FILE__))
|
2
4
|
$LOAD_PATH.unshift(lib_dir) unless $LOAD_PATH.include?(lib_dir)
|
3
|
-
require 'rubygems'
|
4
5
|
require 'mkmf'
|
5
6
|
require 'pkg-config'
|
6
7
|
|
@@ -108,9 +109,6 @@ module RMagick
|
|
108
109
|
|
109
110
|
else
|
110
111
|
|
111
|
-
check_multiple_imagemagick_versions
|
112
|
-
check_partial_imagemagick_versions
|
113
|
-
|
114
112
|
original_ldflags = $LDFLAGS.dup
|
115
113
|
|
116
114
|
libdir = PKGConfig.libs_only_L($magick_package).chomp.sub('-L', '')
|
@@ -127,10 +125,8 @@ module RMagick
|
|
127
125
|
# if linker does not recognizes '-Wl,-rpath,somewhere' option, it revert to original option
|
128
126
|
$LDFLAGS = "#{original_ldflags} #{ldflags}"
|
129
127
|
end
|
130
|
-
|
131
|
-
configure_archflags_for_osx($magick_package) if RUBY_PLATFORM.include?('darwin') # osx
|
132
|
-
|
133
128
|
end
|
129
|
+
|
134
130
|
$CPPFLAGS += ' $(optflags) $(debugflags) -fomit-frame-pointer'
|
135
131
|
end
|
136
132
|
|
@@ -167,10 +163,14 @@ module RMagick
|
|
167
163
|
|
168
164
|
def determine_imagemagick_package
|
169
165
|
packages = [installed_im7_packages, installed_im6_packages].flatten
|
166
|
+
return if packages.empty?
|
170
167
|
|
171
|
-
|
172
|
-
|
173
|
-
|
168
|
+
msg = "\nDetected ImageMagick packages:\n"
|
169
|
+
Logging.message msg
|
170
|
+
message msg
|
171
|
+
package_paths = packages.map { |package| "- #{PKGConfig.package_config(package).pc_path}" }.join("\n")
|
172
|
+
Logging.message package_paths + "\n\n"
|
173
|
+
message package_paths + "\n\n"
|
174
174
|
|
175
175
|
if installed_im6_packages.any? && installed_im7_packages.any?
|
176
176
|
checking_for('forced use of ImageMagick 6') do
|
@@ -185,8 +185,7 @@ module RMagick
|
|
185
185
|
end
|
186
186
|
|
187
187
|
if packages.length > 1
|
188
|
-
|
189
|
-
msg = "\nWarning: Found more than one ImageMagick installation. This could cause problems at runtime.\n#{package_lines}\n\n"
|
188
|
+
msg = "\nWarning: Found more than one ImageMagick installation. This could cause problems at runtime.\n\n"
|
190
189
|
Logging.message msg
|
191
190
|
message msg
|
192
191
|
end
|
@@ -194,80 +193,6 @@ module RMagick
|
|
194
193
|
packages.first
|
195
194
|
end
|
196
195
|
|
197
|
-
# Seems like lots of people have multiple versions of ImageMagick installed.
|
198
|
-
def check_multiple_imagemagick_versions
|
199
|
-
versions = []
|
200
|
-
path = ENV['PATH'].split(File::PATH_SEPARATOR)
|
201
|
-
path.each do |dir|
|
202
|
-
file = File.join(dir, 'Magick-config')
|
203
|
-
next unless File.executable? file
|
204
|
-
|
205
|
-
vers = `#{file} --version`.chomp.strip
|
206
|
-
prefix = `#{file} --prefix`.chomp.strip
|
207
|
-
versions << [vers, prefix, dir]
|
208
|
-
end
|
209
|
-
versions.uniq!
|
210
|
-
return unless versions.size > 1
|
211
|
-
|
212
|
-
msg = "\nWarning: Found more than one ImageMagick installation. This could cause problems at runtime.\n"
|
213
|
-
versions.each do |vers, prefix, dir|
|
214
|
-
msg << " #{dir}/Magick-config reports version #{vers} is installed in #{prefix}\n"
|
215
|
-
end
|
216
|
-
msg << "Using #{versions[0][0]} from #{versions[0][1]}.\n\n"
|
217
|
-
Logging.message msg
|
218
|
-
message msg
|
219
|
-
end
|
220
|
-
|
221
|
-
# Ubuntu (maybe other systems) comes with a partial installation of
|
222
|
-
# ImageMagick in the prefix /usr (some libraries, no includes, and no
|
223
|
-
# binaries). This causes problems when /usr/lib is in the path (e.g., using
|
224
|
-
# the default Ruby installation).
|
225
|
-
def check_partial_imagemagick_versions
|
226
|
-
prefix = config_string('prefix') || ''
|
227
|
-
matches = [
|
228
|
-
prefix + '/lib/lib?agick*',
|
229
|
-
prefix + '/include/ImageMagick',
|
230
|
-
prefix + '/bin/Magick-config'
|
231
|
-
].map do |file_glob|
|
232
|
-
Dir.glob(file_glob)
|
233
|
-
end
|
234
|
-
matches.delete_if(&:empty?)
|
235
|
-
return unless !matches.empty? && matches.length < 3
|
236
|
-
|
237
|
-
msg = <<~MESSAGE
|
238
|
-
|
239
|
-
Warning: Found a partial ImageMagick installation. Your operating
|
240
|
-
system likely has some built-in ImageMagick libraries but not all of
|
241
|
-
ImageMagick. This will most likely cause problems at both compile and
|
242
|
-
runtime.
|
243
|
-
Found partial installation at: #{prefix}
|
244
|
-
|
245
|
-
MESSAGE
|
246
|
-
|
247
|
-
Logging.message msg
|
248
|
-
message msg
|
249
|
-
end
|
250
|
-
|
251
|
-
# issue #169
|
252
|
-
# set ARCHFLAGS appropriately for OSX
|
253
|
-
def configure_archflags_for_osx(magick_package)
|
254
|
-
return unless PKGConfig.libs_only_L(magick_package) =~ %r{-L(.+)/lib}
|
255
|
-
|
256
|
-
imagemagick_dir = Regexp.last_match(1)
|
257
|
-
command = Dir.glob(File.join(imagemagick_dir, "bin/*")).find { |file| File.executable? file }
|
258
|
-
fileinfo = `file #{command}`
|
259
|
-
|
260
|
-
# default ARCHFLAGS
|
261
|
-
archs = $ARCH_FLAG.scan(/-arch\s+(\S+)/).flatten
|
262
|
-
|
263
|
-
archflags = []
|
264
|
-
archs.each do |arch|
|
265
|
-
archflags << "-arch #{arch}" if fileinfo.include?(arch)
|
266
|
-
end
|
267
|
-
|
268
|
-
$ARCH_FLAG = archflags.join(' ') unless archflags.empty?
|
269
|
-
end
|
270
|
-
|
271
196
|
def search_paths_for_windows
|
272
197
|
msg = 'searching PATH for the ImageMagick library...'
|
273
198
|
Logging.message msg
|
@@ -299,7 +224,6 @@ module RMagick
|
|
299
224
|
end
|
300
225
|
|
301
226
|
def assert_can_compile!
|
302
|
-
assert_minimum_ruby_version!
|
303
227
|
assert_has_dev_libs!
|
304
228
|
|
305
229
|
# Check for compiler. Extract first word so ENV['CXX'] can be a program name with arguments.
|
@@ -307,14 +231,6 @@ module RMagick
|
|
307
231
|
exit_failure "No C++ compiler found in ${ENV['PATH']}. See mkmf.log for details." unless find_executable(cxx)
|
308
232
|
end
|
309
233
|
|
310
|
-
def assert_minimum_ruby_version!
|
311
|
-
supported = checking_for("Ruby version >= #{MIN_RUBY_VERS}") do
|
312
|
-
Gem::Version.new(RUBY_VERSION) >= Gem::Version.new(MIN_RUBY_VERS)
|
313
|
-
end
|
314
|
-
|
315
|
-
exit_failure "Can't install RMagick #{RMAGICK_VERS}. Ruby #{MIN_RUBY_VERS} or later required.\n" unless supported
|
316
|
-
end
|
317
|
-
|
318
234
|
def assert_has_dev_libs!
|
319
235
|
failure_message = <<~END_FAILURE
|
320
236
|
Can't install RMagick #{RMAGICK_VERS}.
|
@@ -327,11 +243,10 @@ module RMagick
|
|
327
243
|
$magick_version = Regexp.last_match(1)
|
328
244
|
exit_failure failure_message unless $magick_version
|
329
245
|
else
|
330
|
-
unless
|
246
|
+
unless ($magick_package = determine_imagemagick_package)
|
331
247
|
exit_failure failure_message
|
332
248
|
end
|
333
249
|
|
334
|
-
$magick_package = determine_imagemagick_package
|
335
250
|
$magick_version = PKGConfig.modversion($magick_package)[/^(\d+\.\d+\.\d+)/]
|
336
251
|
end
|
337
252
|
|
data/ext/RMagick/rmagick.h
CHANGED
@@ -349,7 +349,7 @@ EXTERN VALUE Class_Chromaticity;
|
|
349
349
|
EXTERN VALUE Class_Color;
|
350
350
|
EXTERN VALUE Class_Font;
|
351
351
|
EXTERN VALUE Class_Geometry;
|
352
|
-
EXTERN VALUE Class_GeometryValue; // Defined in
|
352
|
+
EXTERN VALUE Class_GeometryValue; // Defined in rmagick_internal.rb
|
353
353
|
EXTERN VALUE Class_Pixel;
|
354
354
|
EXTERN VALUE Class_Point;
|
355
355
|
EXTERN VALUE Class_PolaroidOptions;
|
data/ext/RMagick/rmilist.cpp
CHANGED
@@ -744,7 +744,7 @@ ImageList_optimize_layers(VALUE self, VALUE method)
|
|
744
744
|
* No Ruby usage (internal function)
|
745
745
|
*
|
746
746
|
* Notes:
|
747
|
-
* - this simply calls ImageList.new() in
|
747
|
+
* - this simply calls ImageList.new() in rmagick_internal.rb
|
748
748
|
*
|
749
749
|
* @return a new imagelist
|
750
750
|
*/
|
data/ext/RMagick/rmimage.cpp
CHANGED
@@ -11600,6 +11600,8 @@ rd_image(VALUE klass ATTRIBUTE_UNUSED, VALUE file, gvl_function_t fp)
|
|
11600
11600
|
rm_check_exception(exception, images, DestroyOnError);
|
11601
11601
|
DestroyExceptionInfo(exception);
|
11602
11602
|
|
11603
|
+
rm_ensure_result(images);
|
11604
|
+
|
11603
11605
|
rm_set_user_artifact(images, info);
|
11604
11606
|
rm_sync_image_options(images, info);
|
11605
11607
|
|
data/lib/rmagick/version.rb
CHANGED
data/lib/rmagick_internal.rb
CHANGED
@@ -1,9 +1,9 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
# $Id:
|
3
|
+
# $Id: rmagick_internal.rb,v 1.84 2009/09/15 22:08:41 rmagick Exp $
|
4
4
|
#==============================================================================
|
5
5
|
# Copyright (C) 2009 by Timothy P. Hunter
|
6
|
-
# Name:
|
6
|
+
# Name: rmagick_internal.rb
|
7
7
|
# Author: Tim Hunter
|
8
8
|
# Purpose: Extend Ruby to interface with ImageMagick.
|
9
9
|
# Notes: RMagick2.so defines the classes. The code below adds methods
|
data/lib/rvg/clippath.rb
CHANGED
data/lib/rvg/container.rb
CHANGED
data/lib/rvg/deep_equal.rb
CHANGED
data/lib/rvg/describable.rb
CHANGED
data/lib/rvg/embellishable.rb
CHANGED
data/lib/rvg/misc.rb
CHANGED
data/lib/rvg/paint.rb
CHANGED
data/lib/rvg/pathdata.rb
CHANGED
data/lib/rvg/rvg.rb
CHANGED
data/lib/rvg/stretchable.rb
CHANGED
data/lib/rvg/stylable.rb
CHANGED
data/lib/rvg/text.rb
CHANGED
data/lib/rvg/transformable.rb
CHANGED
data/lib/rvg/units.rb
CHANGED
data/rmagick.gemspec
CHANGED
@@ -1,4 +1,5 @@
|
|
1
|
-
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require 'English'
|
3
4
|
require './lib/rmagick/version'
|
4
5
|
|
@@ -15,6 +16,7 @@ Gem::Specification.new do |s|
|
|
15
16
|
s.metadata['bug_tracker_uri'] = 'https://github.com/rmagick/rmagick/issues'
|
16
17
|
s.metadata['documentation_uri'] = 'https://rmagick.github.io/'
|
17
18
|
s.metadata['changelog_uri'] = 'https://github.com/rmagick/rmagick/blob/main/CHANGELOG.md'
|
19
|
+
s.metadata['rubygems_mfa_required'] = 'true'
|
18
20
|
|
19
21
|
tracked_files = `git ls-files`.split($OUTPUT_RECORD_SEPARATOR)
|
20
22
|
file_exclusion_regex = /\A(doc|benchmarks|examples|spec|Steepfile)/
|
@@ -27,6 +29,6 @@ Gem::Specification.new do |s|
|
|
27
29
|
s.required_ruby_version = ">= #{Magick::MIN_RUBY_VERSION}"
|
28
30
|
s.requirements << "ImageMagick #{Magick::MIN_IM_VERSION} or later"
|
29
31
|
|
30
|
-
s.
|
31
|
-
s.
|
32
|
+
s.add_dependency 'observer', '~> 0.1'
|
33
|
+
s.add_dependency 'pkg-config', '~> 1.4'
|
32
34
|
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Magick
|
2
4
|
interface _ImageCommonMethods
|
3
5
|
# Magick::Image / Magick::ImageList common methods
|
@@ -20,7 +22,7 @@ module Magick
|
|
20
22
|
def matte_replace: (int x, int y) -> Image
|
21
23
|
def matte_floodfill: (int x, int y) -> Image
|
22
24
|
def matte_fill_to_border: (int x, int y) -> Image
|
23
|
-
def matte_reset!: -> Image
|
25
|
+
def matte_reset!: () -> Image
|
24
26
|
def resize_to_fill: (real ncols, ?real nrows, ?GravityType gravity) -> Image
|
25
27
|
def resize_to_fill!: (real ncols, ?real nrows, ?GravityType gravity) -> Image
|
26
28
|
alias crop_resized resize_to_fill
|
@@ -304,7 +306,7 @@ module Magick
|
|
304
306
|
def raise: (?int width, ?int height, ?bool raised) -> Image
|
305
307
|
def random_threshold_channel: (Geometry | string geometry, *ChannelType channel) -> Image
|
306
308
|
def recolor: (Array[magick_real] color_matrix) -> Image
|
307
|
-
def reduce_noise: (int radius)
|
309
|
+
def reduce_noise: (int radius) -> Image
|
308
310
|
def resample: (?magick_real x_resolution, ?magick_real y_resolution, ?FilterType filter, ?magick_real blur) -> Image
|
309
311
|
def resample!: (?magick_real x_resolution, ?magick_real y_resolution, ?FilterType filter, ?magick_real blur) -> self
|
310
312
|
def resize: (magick_real scale) -> Image
|
data/sig/rmagick/draw.rbs
CHANGED
data/sig/rmagick/enum.rbs
CHANGED
@@ -1,8 +1,10 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Magick
|
2
4
|
class Enum
|
3
5
|
def initialize: (interned sym, int val) -> void
|
4
|
-
def to_s: -> String
|
5
|
-
def to_i: -> Integer
|
6
|
+
def to_s: () -> String
|
7
|
+
def to_i: () -> Integer
|
6
8
|
def <=>: (Enum other) -> (-1 | 0 | 1 | nil)
|
7
9
|
def ===: (Enum other) -> bool
|
8
10
|
def |: (Enum other) -> Enum
|
@@ -10,11 +12,11 @@ module Magick
|
|
10
12
|
|
11
13
|
interface _EnumInstanceMethod
|
12
14
|
def initialize: (interned sym, int val) -> void
|
13
|
-
def inspect: -> String
|
15
|
+
def inspect: () -> String
|
14
16
|
end
|
15
17
|
|
16
18
|
interface _EnumClassMethod[T]
|
17
|
-
def values: -> Array[T]
|
19
|
+
def values: () -> Array[T]
|
18
20
|
end
|
19
21
|
|
20
22
|
class GeometryValue < Enum
|
data/sig/rmagick/error.rbs
CHANGED
data/sig/rmagick/fill.rbs
CHANGED
data/sig/rmagick/geometry.rbs
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Magick
|
2
4
|
class Geometry
|
3
5
|
attr_accessor width: Integer | Float
|
@@ -8,7 +10,7 @@ module Magick
|
|
8
10
|
|
9
11
|
def initialize: (?magick_real? width, ?magick_real? height, ?real? x, ?real? y, ?GeometryValue? flag) -> void
|
10
12
|
def self.from_s: (String str) -> Geometry
|
11
|
-
def to_s: -> String
|
13
|
+
def to_s: () -> String
|
12
14
|
end
|
13
15
|
end
|
14
16
|
|
data/sig/rmagick/image.rbs
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Magick
|
2
4
|
class Image
|
3
5
|
include Comparable
|
@@ -29,7 +31,7 @@ module Magick
|
|
29
31
|
def []=: (interned key_arg, String attr_arg) -> self
|
30
32
|
def delay=: (int val) -> int
|
31
33
|
def display: () -> self
|
32
|
-
| () { (Image::Info) -> void} -> self
|
34
|
+
| () { (Image::Info) -> void } -> self
|
33
35
|
def marshal_dump: () -> [String, String]
|
34
36
|
def marshal_load: ([string, string] ary) -> self
|
35
37
|
def montage: () -> String?
|
@@ -37,9 +39,9 @@ module Magick
|
|
37
39
|
def scene: () -> Integer
|
38
40
|
def ticks_per_second=: (int tps) -> int
|
39
41
|
def to_blob: () -> String?
|
40
|
-
| () { (Image::Info) -> void} -> String?
|
42
|
+
| () { (Image::Info) -> void } -> String?
|
41
43
|
def write: (File | string file) -> self
|
42
|
-
| (File | string file) { (Image::Info) -> void} -> self
|
44
|
+
| (File | string file) { (Image::Info) -> void } -> self
|
43
45
|
def destroy!: () -> self
|
44
46
|
def destroyed?: () -> bool
|
45
47
|
|
data/sig/rmagick/image_list.rbs
CHANGED
@@ -1,9 +1,11 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Magick
|
2
4
|
class ImageList
|
3
5
|
include Enumerable[Image]
|
4
6
|
include Comparable
|
5
|
-
|
6
|
-
|
7
|
+
# The methods of Magick::Image class can be called via method_missing
|
8
|
+
include _ImageCommonMethods
|
7
9
|
|
8
10
|
private
|
9
11
|
|
@@ -37,7 +39,7 @@ module Magick
|
|
37
39
|
| (int start, int length, magick_image | Array[Image] image) -> void
|
38
40
|
def at: () -> Image
|
39
41
|
def each: () -> Enumerator[Image, self]
|
40
|
-
| () { (Image) -> void} -> void
|
42
|
+
| () { (Image) -> void } -> void
|
41
43
|
def each_index: () -> Enumerator[Integer, self]
|
42
44
|
| () { (Integer) -> void } -> void
|
43
45
|
def empty?: () -> bool
|
@@ -49,11 +51,11 @@ module Magick
|
|
49
51
|
def hash: () -> Integer
|
50
52
|
def include?: (untyped obj) -> bool
|
51
53
|
def index: (Image | ImageList | Array[Image] obj) -> ::Integer?
|
52
|
-
| () { (Image) ->
|
54
|
+
| () { (Image) -> boolish } -> Integer?
|
53
55
|
| () -> ::Enumerator[Image, Integer?]
|
54
56
|
def length: () -> Integer
|
55
|
-
def rindex: (Image | ImageList | Array[Image]
|
56
|
-
| () { (Image) ->
|
57
|
+
def rindex: (Image | ImageList | Array[Image] obj) -> ::Integer?
|
58
|
+
| () { (Image) -> boolish } -> Integer?
|
57
59
|
| () -> ::Enumerator[Image, Integer?]
|
58
60
|
def sort!: () -> self
|
59
61
|
| () { (Image a, Image b) -> Integer } -> self
|
@@ -62,31 +64,31 @@ module Magick
|
|
62
64
|
| ...
|
63
65
|
def collect: () { (Image) -> Image } -> ImageList
|
64
66
|
def collect!: () { (Image) -> Image } -> self
|
65
|
-
def copy: -> ImageList
|
67
|
+
def copy: () -> ImageList
|
66
68
|
| ...
|
67
|
-
def cur_image: -> Image
|
69
|
+
def cur_image: () -> Image
|
68
70
|
| ...
|
69
71
|
alias map collect
|
70
72
|
alias __map__ collect
|
71
73
|
alias map! collect!
|
72
74
|
alias __map__! collect!
|
73
|
-
def compact: -> ImageList
|
74
|
-
def compact!: -> self?
|
75
|
+
def compact: () -> ImageList
|
76
|
+
def compact!: () -> self?
|
75
77
|
def concat: (ImageList | Array[Image] other) -> self
|
76
78
|
def delay=: (int d) -> void
|
77
79
|
def delete: (Image obj) -> Image?
|
78
80
|
| [T] (Image obj) { (Image) -> T } -> (Image | T)
|
79
81
|
def delete_at: (int ndx) -> Image?
|
80
|
-
def delete_if: () { (Image) ->
|
82
|
+
def delete_if: () { (Image) -> boolish } -> self
|
81
83
|
| () -> self
|
82
|
-
def dup: -> ImageList
|
84
|
+
def dup: () -> ImageList
|
83
85
|
| ...
|
84
86
|
def eql?: (ImageList | Array[Image] other) -> bool
|
85
87
|
def fill: (Image image, ?int start, ?int length) -> ImageList
|
86
88
|
| (Image image, Range[Integer] range) -> ImageList
|
87
89
|
| (?int start, ?int length) { (Integer index) -> Image } -> ImageList
|
88
90
|
| (Range[Integer] range) { (Integer index) -> Image } -> ImageList
|
89
|
-
def find_all: () { (Image) ->
|
91
|
+
def find_all: () { (Image) -> boolish } -> ImageList
|
90
92
|
| () -> ImageList
|
91
93
|
alias select find_all
|
92
94
|
def from_blob: (string blob) -> self
|
@@ -97,24 +99,24 @@ module Magick
|
|
97
99
|
def iterations=: (int n) -> void
|
98
100
|
def last: () -> Image?
|
99
101
|
| (int n) -> ImageList
|
100
|
-
def marshal_dump: () ->
|
102
|
+
def marshal_dump: () -> Array[(Integer | String)?]
|
101
103
|
def marshal_load: (Array[(Integer | String)?] ary) -> void
|
102
104
|
def method_missing: (untyped meth_id, *untyped args) ?{ (*untyped, **untyped) -> untyped } -> untyped
|
103
105
|
def new_image: (int cols, int rows, ?magick_fill fill) -> self
|
104
106
|
| (int cols, int rows, ?magick_fill fill) { (Image::Info) -> void } -> self
|
105
|
-
def partition: () { (Image) ->
|
107
|
+
def partition: () { (Image) -> boolish } -> [ImageList, ImageList]
|
106
108
|
def ping: (*(File | string) files) -> self
|
107
109
|
| (*(File | string) files) { (Image::Info) -> void } -> self
|
108
110
|
def pop: () -> Image?
|
109
111
|
def push: (*Image objs) -> self
|
110
112
|
def read: (*(File | string) files) -> self
|
111
113
|
| (*(File | string) files) { (Image::Info) -> void } -> self
|
112
|
-
def reject: () { (Image) ->
|
113
|
-
def reject!: () { (Image) ->
|
114
|
+
def reject: () { (Image) -> boolish } -> ImageList
|
115
|
+
def reject!: () { (Image) -> boolish } -> self?
|
114
116
|
def replace: (ImageList | Array[Image] other) -> ImageList
|
115
117
|
def respond_to?: (interned meth_id, ?bool priv) -> bool
|
116
|
-
def reverse: -> ImageList
|
117
|
-
def reverse!: -> self
|
118
|
+
def reverse: () -> ImageList
|
119
|
+
def reverse!: () -> self
|
118
120
|
def reverse_each: () { (Image) -> void } -> self
|
119
121
|
def shift: () -> Image?
|
120
122
|
def slice: (int index) -> ImageList?
|
@@ -125,7 +127,7 @@ module Magick
|
|
125
127
|
| (Range[Integer] range) -> Image?
|
126
128
|
def ticks_per_second=: (int t) -> void
|
127
129
|
def to_a: () -> Array[Image]
|
128
|
-
def uniq: -> ImageList
|
130
|
+
def uniq: () -> ImageList
|
129
131
|
def uniq!: () -> self?
|
130
132
|
def unshift: (Image obj) -> self
|
131
133
|
def values_at: (*int index) -> ImageList
|
@@ -152,7 +154,7 @@ module Magick
|
|
152
154
|
def optimize_layers: (LayerMethod method) -> ImageList
|
153
155
|
def quantize: (?int number_colors, ?ColorspaceType colorspace, ?(DitherMethod | bool) dither, ?int tree_depth, ?bool measure_error) -> ImageList
|
154
156
|
def to_blob: () -> String?
|
155
|
-
| () { (Image::Info) -> void} -> String?
|
157
|
+
| () { (Image::Info) -> void } -> String?
|
156
158
|
def write: (File | string file) -> self
|
157
159
|
| (File | string file) { (Image::Info) -> void } -> self
|
158
160
|
def destroy!: () -> self
|
data/sig/rmagick/iptc.rbs
CHANGED
data/sig/rmagick/kernel_info.rbs
CHANGED
data/sig/rmagick/pixel.rbs
CHANGED
data/sig/rmagick/struct.rbs
CHANGED
data/sig/rvg/embellishable.rbs
CHANGED
@@ -197,7 +197,7 @@ module Magick
|
|
197
197
|
# Define grouped elements by calling RVG::Embellishable
|
198
198
|
# methods within the associated block.
|
199
199
|
def g: () -> Group
|
200
|
-
| { (Group) -> void } -> Group
|
200
|
+
| () { (Group) -> void } -> Group
|
201
201
|
end
|
202
202
|
|
203
203
|
# Methods that construct raster image objects within a container
|
data/sig/rvg/pathdata.rbs
CHANGED