graphics 1.1.1 → 1.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7ce1c375e7fe1c41126f6ef3b87becdb997368618ab2a9bfab749edd488c8377
4
- data.tar.gz: 2e05e558f38241be80074f7f7ac0f2518efddcde1cd333d3cf772980bab825cf
3
+ metadata.gz: 77f69378932806144f098c0234730070067b715fad49389094e491824e43c009
4
+ data.tar.gz: ac579bcb9081b0ed9aa2f9dffff4659857919320360f01ba1f0d74b0a83c1248
5
5
  SHA512:
6
- metadata.gz: 4ebf2dbe2d78397410bfb00769266c797a3b5da1d14c667eefc8b3396c81142c68c20fdabdbe776c85f843f8f020374f5015faa1b72f6dee9b483ea4c3dd8610
7
- data.tar.gz: 0faaf2725fa511e98d2ee3f02b7e1d52d157ba626b6e16404dc6b872f2b4793c55ae1f965bf2779108bc3a72b25a8bc95b0081d42cd65246d11ade89dee9a9c5
6
+ metadata.gz: ed79e3761f5acd978457d54fd93225a41ff8722d635141842f2125e057b6b8d9548f18ac33e010c0bef4ea813f9eb8045fe6fde59d60f82420d939d13584fc1d
7
+ data.tar.gz: 995279ada59cd448174c44f35e97a1f3e2a2329bb2c06d4233c3e11f8afb06afd193bae7c75a9a0e9b146ed968446106cdedf18b38709dcbbc9ea8aa16f305cd
checksums.yaml.gz.sig CHANGED
@@ -1,3 +1,4 @@
1
- M��|��z�
2
- ��|6�k^W�A���N��@i9�q���ӺǪ����
3
- 8/�xx/�̀Y��^q;�� 4:�h;�2e����SH1-� mQSȔ|�GDCRI�SWD�rfX�
1
+ l�C������"���� ���Lʇ��Za�����������6���2��p�T����Xv�1}�v��4��*"�*��K(�z��TZ��~Nx*�~ x�Ă'�*����AÙj����rn��L���aݻ�
2
+ y�(�rơ8�{�n�f_�'��~��'�}���G#݃W�A�ɋ�H4t����#��u�b�>!�g�TS���
3
+ H[
4
+ ����Jn��>����
data/History.rdoc CHANGED
@@ -1,3 +1,15 @@
1
+ === 1.1.2 / 2024-12-07
2
+
3
+ * 1 minor enhancement:
4
+
5
+ * Bumped required ruby version.
6
+
7
+ * 3 bug fixes:
8
+
9
+ * Fixed bad copy/paste in setup script. (havenwood)
10
+ * Fixed color handling in polygon.
11
+ * Fixed frozen string literal in examples/editor.rb
12
+
1
13
  === 1.1.1 / 2024-08-27
2
14
 
3
15
  * 1 minor enhancement:
data/Rakefile CHANGED
@@ -16,7 +16,7 @@ Hoe.spec "graphics" do
16
16
 
17
17
  extension :sdl
18
18
 
19
- require_ruby_version ">= 2.7"
19
+ require_ruby_version ">= 3.3"
20
20
 
21
21
  license "MIT"
22
22
  end
data/examples/editor.rb CHANGED
@@ -12,7 +12,7 @@ class Editor < Graphics::Simulation
12
12
  super 850, 850
13
13
 
14
14
  self.overlay = true
15
- self.s = ""
15
+ self.s = +""
16
16
  self.lines = []
17
17
  end
18
18
 
data/graphics_setup.sh CHANGED
@@ -25,7 +25,7 @@ case "$(uname -s)" in
25
25
 
26
26
  $sudo apt-get install --no-install-recommends --no-install-suggests libsdl1.2-dev libsdl-image1.2-dev libsdl-mixer1.2-dev libsdl-ttf2.0-dev gcc g++
27
27
  else
28
- echo "Detected macOS but not apt. Install sdl2 with your package manager."
28
+ echo "Detected Linux but not apt. Install sdl2 with your package manager."
29
29
  exit 1
30
30
  fi
31
31
  ;;
@@ -117,13 +117,10 @@ class Graphics::AbstractSimulation
117
117
  #
118
118
  # This also names a bunch colors and hues for convenience.
119
119
 
120
- def initialize w=nil, h=nil, name=self.class.name, full=false
120
+ def initialize w = nil, h = nil, name = self.class.name, full = false
121
121
  w ||= SDL::Screen::W/2
122
122
  h ||= SDL::Screen::H/2
123
123
 
124
- # TODO: remove for 1.0.0 final
125
- raise "Do NOT pass bpp to Simulation anymore" if !name || Integer === name
126
-
127
124
  full = full ? SDL::FULLSCREEN : 0
128
125
 
129
126
  self._bodies = []
@@ -504,7 +501,7 @@ class Graphics::AbstractSimulation
504
501
 
505
502
  xs, ys = points.transpose
506
503
 
507
- renderer.draw_polygon xs, ys.map { |y| h-y-1 }, c, :aa
504
+ renderer.draw_polygon xs, ys.map { |y| h-y-1 }, color[c], :aa
508
505
  end
509
506
 
510
507
  ##
data/lib/graphics.rb CHANGED
@@ -2,7 +2,7 @@
2
2
  # The top-level namespace.
3
3
 
4
4
  class Graphics
5
- VERSION = "1.1.1" # :nodoc:
5
+ VERSION = "1.1.2" # :nodoc:
6
6
  end
7
7
 
8
8
  require "graphics/simulation"
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphics
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Davis
@@ -29,7 +29,7 @@ cert_chain:
29
29
  S7043fq9EbQdBr2AXdj92+CDwuTfHI6/Hj5FVBDULufrJaan4xUgL70Hvc6pTTeW
30
30
  deKfBjgVAq7EYHu1AczzlUly
31
31
  -----END CERTIFICATE-----
32
- date: 2024-08-27 00:00:00.000000000 Z
32
+ date: 2024-12-07 00:00:00.000000000 Z
33
33
  dependencies:
34
34
  - !ruby/object:Gem::Dependency
35
35
  name: rdoc
@@ -194,14 +194,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
194
194
  requirements:
195
195
  - - ">="
196
196
  - !ruby/object:Gem::Version
197
- version: '2.7'
197
+ version: '3.3'
198
198
  required_rubygems_version: !ruby/object:Gem::Requirement
199
199
  requirements:
200
200
  - - ">="
201
201
  - !ruby/object:Gem::Version
202
202
  version: '0'
203
203
  requirements: []
204
- rubygems_version: 3.5.15
204
+ rubygems_version: 3.5.23
205
205
  signing_key:
206
206
  specification_version: 4
207
207
  summary: Graphics provides a simple framework to implement games and/or simulations
metadata.gz.sig CHANGED
Binary file