gruff 0.20.0 → 0.21.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -1
- data/lib/gruff/base.rb +7 -3
- data/lib/gruff/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d83fb72593318497b0fe0ff48a98f9f30f7f6c2795b30d1695757ae5d2b808df
|
4
|
+
data.tar.gz: 77bf7f31d3339c4a4065dbd47a9ed586f486781641fd59c9fc01b1ff9779e605
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4bc158cc912fdc90f795c280e2ae3fab90ffb7d7513b9a6ed3432b4d732b0acbaf8ff52dfd674c2cd30758e0423744002e6bc2fd96bd8db98f2222bfb2224f78
|
7
|
+
data.tar.gz: 7a2bcddc07f2225eaac48304de583235818ead0d1664b90818913953b0baff25e410c90bf899ba8866d26605886dbba6e352a8ce6e8e71df615f1d56e7c8c99a
|
data/CHANGELOG.md
CHANGED
@@ -1,8 +1,11 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
+
## 0.21.0
|
4
|
+
- Fix legend color with empty label (#615)
|
5
|
+
|
3
6
|
## 0.20.0
|
4
7
|
- Fix legend position when blank labels present (#614)
|
5
|
-
- Fixed NoMethodError (undefined method `format
|
8
|
+
- Fixed NoMethodError (undefined method `format=` for Gruff::Line (#612)
|
6
9
|
- Drop Ruby 2.5 support (#611)
|
7
10
|
- Fix deprecation warning for Base#to_blob (#610)
|
8
11
|
|
data/lib/gruff/base.rb
CHANGED
@@ -1035,9 +1035,13 @@ module Gruff
|
|
1035
1035
|
def calculate_legend_label_widths_for_each_line(legend_labels, legend_square_width)
|
1036
1036
|
label_widths = [[]]
|
1037
1037
|
label_lines = [[]]
|
1038
|
-
legend_labels.
|
1039
|
-
|
1040
|
-
|
1038
|
+
legend_labels.each do |label|
|
1039
|
+
if label.empty?
|
1040
|
+
label_width = 0.0
|
1041
|
+
else
|
1042
|
+
width = calculate_width(@legend_font, label)
|
1043
|
+
label_width = width + (legend_square_width * 2.7)
|
1044
|
+
end
|
1041
1045
|
label_widths.last.push label_width
|
1042
1046
|
label_lines.last.push label
|
1043
1047
|
|
data/lib/gruff/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gruff
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.21.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Geoffrey Grosenbach
|
@@ -246,7 +246,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
246
246
|
- !ruby/object:Gem::Version
|
247
247
|
version: '0'
|
248
248
|
requirements: []
|
249
|
-
rubygems_version: 3.
|
249
|
+
rubygems_version: 3.4.10
|
250
250
|
signing_key:
|
251
251
|
specification_version: 4
|
252
252
|
summary: Beautiful graphs for one or multiple datasets.
|