pixelchart 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a1f640ed1d4efd1ddce15e9cad71409d881b573cbd7f4f5c2bcebe1a1ae9858b
4
- data.tar.gz: d1e054a27279e09afcb2ee911a952491f66a60807ee2d73a84fef80765652867
3
+ metadata.gz: 9129a6e4edfeeaeef2f80c67cdf5c7e5d35a30e425f432a4a62a68b9cdd4943d
4
+ data.tar.gz: 6f9411731b1b14fc0d55978f6903daaaa0cd74d2b897d030782c287ec73d6a28
5
5
  SHA512:
6
- metadata.gz: 0605e4ce1ea180a02c6c38214f52b73e3d365e15eaf35831171a9164bffe034f662d95890f5803087f7d76f48c4e10aae1d77a8cfb241baa16e3698be02d2791
7
- data.tar.gz: aa3ed4456b1b790aea5f2d3af44ef3421a1799865c81d35a65152ee55c780e9229ac297aafb9350551f2399a0ba63e9a1fc7e49b2bf2848fa28be427c526c519
6
+ metadata.gz: 6374a49217570f9aea5f4a6e43e91f48486c33c5398d4dc507ec5ef8921363ff70c22bb0d132e3e7c8662ca61d5582094f6f34cda889be7a1ea5add11c57082a
7
+ data.tar.gz: ef7b0d1b87451cb90b536a5c6a509bab1cade6227f8e77b296fc40a6e60402914e3bb3c5cfd5451b546747f5df52f35a93681dad79b1f592ed8b419a016713e1
data/LICENSE.txt CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2019-2020 Alexandre ZANNI
3
+ Copyright (c) 2019-2023 Alexandre ZANNI
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/bin/pixelchart CHANGED
@@ -2,7 +2,6 @@
2
2
  # frozen_string_literal: true
3
3
 
4
4
  # Ruby internal
5
- require 'pp'
6
5
  # Project internal
7
6
  require 'pixelchart'
8
7
  # External
@@ -41,7 +40,7 @@ DOCOPT
41
40
 
42
41
  begin
43
42
  args = Docopt.docopt(doc, version: PixelChart::VERSION)
44
- pp args if args['--debug']
43
+ puts args if args['--debug']
45
44
  Paint.mode = 0 if args['--no-color']
46
45
  if args['draw']
47
46
  data = PixelChart.load_file(args['<input>'])
@@ -62,11 +61,11 @@ begin
62
61
  end
63
62
  opts[:backend] = args['--backend'].to_sym if args['--backend']
64
63
  if args['--scale']
65
- opts[:scale] = if /,/.match?(args['--scale']) # dimensions
66
- args['--scale'].split(',').map(&:to_i)
67
- else # ratio
68
- args['--scale'].to_f
69
- end
64
+ opts[:scale] = if /,/.match?(args['--scale']) # dimensions
65
+ args['--scale'].split(',').map(&:to_i)
66
+ else # ratio
67
+ args['--scale'].to_f
68
+ end
70
69
  end
71
70
  pc = PixelChart.new(data, width, height, opts)
72
71
  pc.draw(filename, opts)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Version
4
- VERSION = '1.1.0'
4
+ VERSION = '1.2.0'
5
5
  end
data/lib/pixelchart.rb CHANGED
@@ -131,7 +131,7 @@ class PixelChart
131
131
  opts = { kernel: :nearest }
132
132
  im = im.resize(@scale, **opts)
133
133
  end
134
- im.write_to_file(filename, compression: 9, palette: true, colours: 2, Q: 0)
134
+ im.write_to_file(filename, compression: 9, palette: true, colours: 2, Q: 0, bitdepth: 1)
135
135
  end
136
136
 
137
137
  # Check if the argument is an integer else raise an error
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pixelchart
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexandre ZANNI
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-01-31 00:00:00.000000000 Z
11
+ date: 2023-12-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: docopt
@@ -42,16 +42,22 @@ dependencies:
42
42
  name: rmagick
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: '4.1'
48
+ - - "<"
49
+ - !ruby/object:Gem::Version
50
+ version: '6.0'
48
51
  type: :runtime
49
52
  prerelease: false
50
53
  version_requirements: !ruby/object:Gem::Requirement
51
54
  requirements:
52
- - - "~>"
55
+ - - ">="
53
56
  - !ruby/object:Gem::Version
54
57
  version: '4.1'
58
+ - - "<"
59
+ - !ruby/object:Gem::Version
60
+ version: '6.0'
55
61
  - !ruby/object:Gem::Dependency
56
62
  name: ruby-vips
57
63
  requirement: !ruby/object:Gem::Requirement
@@ -96,17 +102,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
96
102
  requirements:
97
103
  - - ">="
98
104
  - !ruby/object:Gem::Version
99
- version: 2.7.0
105
+ version: 3.0.0
100
106
  - - "<"
101
107
  - !ruby/object:Gem::Version
102
- version: '3.2'
108
+ version: '4.0'
103
109
  required_rubygems_version: !ruby/object:Gem::Requirement
104
110
  requirements:
105
111
  - - ">="
106
112
  - !ruby/object:Gem::Version
107
113
  version: '0'
108
114
  requirements: []
109
- rubygems_version: 3.3.3
115
+ rubygems_version: 3.4.10
110
116
  signing_key:
111
117
  specification_version: 4
112
118
  summary: Create a binary pixel map