analytics_charts 1.4.6 → 1.4.7

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: 4da6cb9c46297810193d9decc430d9e8bbc6499c
4
- data.tar.gz: ad6dc2d47756d1547c54e6666b16c6f046a5f939
3
+ metadata.gz: 32e6cc93540ae86f1fd88ce1b3e70b05a8e337ee
4
+ data.tar.gz: f7e9b05998e318f2176cdcc56a680e4bd45f5ecf
5
5
  SHA512:
6
- metadata.gz: 446173e1ecbdc9ebd757c0f484f1d02303ffe20edc1e3cd99ca103bbe8e4091894876cf3a742b2512422e3df28eb279e0d405a3dbac75b4ea88d50b231d8be14
7
- data.tar.gz: 8747fba1ddfb4f3a2a1350810c990907d110d7320ded1eda78be32eae693b987394a06e30877a7cd8f169164773b48e9584eaa91c5dde074c91d2782ae475dcd
6
+ metadata.gz: c7a6afd4f3fe0bc02b0b12d6866ed05bae35f4b29c5952f2fe598c79c8a67cacd3a93b4439dc452cd1cac695b828b13c1f7b7a6def325f337c347b2382a51941
7
+ data.tar.gz: b65e21cbbc6a3f853df85f09d0f1a73ffc1a60311dfe3f940372522eb8d88181a45159654c989da1b9edb954af99dd04aa854ae296384903cfc36328d778b50e
@@ -23,7 +23,8 @@ class AnalyticsCharts::CustomModule
23
23
 
24
24
  num_separators = @rows_of_text.count {|row| row.empty? }
25
25
  @sep_offset = 7
26
- @height = @composite_rows + (@rows_of_text.size - num_separators) * @pointsize + num_separators * @sep_offset
26
+ starting_offset = @pointsize
27
+ @height = @composite_rows + (@rows_of_text.size - num_separators) * @pointsize + num_separators * @sep_offset + starting_offset
27
28
  @base_image = Image.new(@composite_columns, @height) {
28
29
  self.background_color = "black"
29
30
  }
@@ -32,7 +33,7 @@ class AnalyticsCharts::CustomModule
32
33
  @d.stroke_width(1)
33
34
  @d = @d.line(0, @composite_rows, @composite_columns, @composite_rows)
34
35
  @d.draw(@base_image)
35
- y_offset = @pointsize + @composite_rows + @d.get_type_metrics(@dummy_image,"a").height / 2
36
+ y_offset = starting_offset + @composite_rows
36
37
  @rows_of_text.each do |text|
37
38
  text = text.gsub(/['%]/, '%' => '%%', "'" => "\'")
38
39
  if text.include? "@$$" # No paragraph break if we insert this uncommonly used word
@@ -1,3 +1,3 @@
1
1
  module AnalyticsCharts
2
- VERSION = "1.4.6"
2
+ VERSION = "1.4.7"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: analytics_charts
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.6
4
+ version: 1.4.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - STEPHEN YU