analytics_charts 1.4.0 → 1.4.2
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f666dab595381b9af701f88f98329f02ce1714ff
|
4
|
+
data.tar.gz: a42abe86eaaf6f33fc874aed314970f2fbae0184
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c96ec1ee30c9426a67a7e6f31a75b155362bd0fecb1dab848387d5a2873df61cc2631a63816680f111d8d17c4b04e9b73598cf2bc28313c8bfeee090f35b5ffc
|
7
|
+
data.tar.gz: ee3f09010f0485a937d6589b6418663484ddbed4e4c1d0774190a95a569ba0e887d43a03bffc3c6e147b0462d6a443dfa3f5177fc764f702cff22e055ba47e0c
|
@@ -72,7 +72,7 @@ class AnalyticsCharts::CustomPie
|
|
72
72
|
@d.stroke_width(radius)
|
73
73
|
@d.stroke features["fill"] unless features["fill"].nil?
|
74
74
|
@d = @d.ellipse(circle_xpos, y_offset,
|
75
|
-
radius / 2.0, radius / 2.0, 0,
|
75
|
+
radius / 2.0, radius / 2.0, 0, 400) # Need bigger overlap for smaller circle
|
76
76
|
end
|
77
77
|
|
78
78
|
def insert_text(x_offset, y_offset, text, features = {})
|
@@ -90,7 +90,7 @@ class AnalyticsCharts::CustomPie
|
|
90
90
|
@d = @d.stroke "#FFFFFF"
|
91
91
|
@d = @d.ellipse(@pie_center_x, @pie_center_y,
|
92
92
|
@pie_radius / 2.0, @pie_radius / 2.0,
|
93
|
-
|
93
|
+
-5, 360 + 1.0) # <= +0.5 'fudge factor' gets rid of the ugly gaps
|
94
94
|
@d.draw(@base_image)
|
95
95
|
# If we don't refresh draw, future "@d.draw(@base_image)" will redraw the circle,
|
96
96
|
# overlapping on the text written below
|
@@ -124,7 +124,7 @@ class AnalyticsCharts::CustomPie
|
|
124
124
|
# half the radius for both x and y
|
125
125
|
@d = @d.ellipse(@pie_center_x, @pie_center_y,
|
126
126
|
@pie_radius / 2.0, @pie_radius / 2.0,
|
127
|
-
prev_degrees, prev_degrees + degrees[i] + 0
|
127
|
+
prev_degrees, prev_degrees + degrees[i] + 1.0) # <= +0.5 'fudge factor' gets rid of the ugly gaps
|
128
128
|
prev_degrees += degrees[i]
|
129
129
|
end
|
130
130
|
# If less than two small slices, or there are two small slices that are not adjacent
|
@@ -132,10 +132,8 @@ class AnalyticsCharts::PieAndLabels < AnalyticsCharts::CustomPie
|
|
132
132
|
def tokenize_text_by_lines(text)
|
133
133
|
# First split the text by the line carriage element
|
134
134
|
carriage_split_lines = text.split("\r\n")
|
135
|
-
puts carriage_split_lines
|
136
135
|
line_tokens = Array.new
|
137
136
|
carriage_split_lines.each do |carriage_split_line|
|
138
|
-
puts carriage_split_line
|
139
137
|
line_wrap_lines = line_wrap(carriage_split_line)
|
140
138
|
begin
|
141
139
|
line_wrap_lines.each { |line| line_tokens.push(line) }
|