Skip to content
This repository has been archived by the owner on Jan 2, 2018. It is now read-only.

Commit

Permalink
prepared 1.3.1 release
Browse files Browse the repository at this point in the history
  • Loading branch information
mattetti committed May 9, 2008
1 parent 26465e2 commit 8690403
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 5 deletions.
3 changes: 3 additions & 0 deletions History.txt
@@ -1,3 +1,6 @@
== 1.3.1
* added width and spacing options

== 1.3.0
* added support for google-o-meter
* fixed a bug when the max value of a data set was 0
Expand Down
4 changes: 2 additions & 2 deletions googlecharts.gemspec
@@ -1,6 +1,6 @@
Gem::Specification.new do |s|
s.name = %q{googlecharts}
s.version = "1.3.0"
s.version = "1.3.1"

s.specification_version = 2 if s.respond_to? :specification_version=

Expand All @@ -16,6 +16,6 @@ Gem::Specification.new do |s|
s.rdoc_options = ["--main", "README.txt"]
s.require_paths = ["lib"]
s.rubyforge_project = %q{googlecharts}
s.rubygems_version = %q{1.3.0}
s.rubygems_version = %q{1.3.1}
s.summary = %q{Sexy Charts using Google API & Ruby}
end
2 changes: 1 addition & 1 deletion lib/gchart/version.rb
Expand Up @@ -2,7 +2,7 @@ module GchartInfo #:nodoc:
module VERSION #:nodoc:
MAJOR = 1
MINOR = 3
TINY = 0
TINY = 1

STRING = [MAJOR, MINOR, TINY].join('.')
end
Expand Down
31 changes: 29 additions & 2 deletions website/index.html
Expand Up @@ -232,6 +232,32 @@ <h2>Demonstration of usage</h2>
<p><img src="http://chart.apis.google.com/chart?cht=bvg&#38;chs=300x200&#38;chd=s:9UGo,Uo9C&#38;chco=FF0000,00FF00" title="grouped bars" alt="grouped bars" /></p>


<p><strong>bar chart width and spacing</strong></p>


<p>A bar chart can accept options to set the width of the bars, spacing between bars and spacing between bar groups. To set these, you can either provide a string, array or hash.</p>


<p>The Google <span class="caps">API</span> sets these options in the order of width, spacing, and group spacing, with both spacing values being optional. So, if you provide a string or array, provide them in that order:</p>


<p><pre class='syntax'>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="punct">'</span><span class="string">25,6</span><span class="punct">')</span> <span class="comment"># width of 25, spacing of 6</span>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="punct">'</span><span class="string">25,6,12</span><span class="punct">')</span> <span class="comment"># width of 25, spacing of 6, group spacing of 12</span>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="punct">[</span><span class="number">25</span><span class="punct">,</span><span class="number">6</span><span class="punct">])</span> <span class="comment"># width of 25, spacing of 6</span>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="number">25</span><span class="punct">)</span> <span class="comment"># width of 25</span>
</pre></p>


<p>The hash lets you set these values directly, with the Google default values set for any options you don&#8217;t include:</p>


<p><pre class='syntax'>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="punct">{</span><span class="symbol">:width</span> <span class="punct">=&gt;</span> <span class="number">19</span><span class="punct">})</span>
<span class="constant">Gchart</span><span class="punct">.</span><span class="ident">bar</span><span class="punct">(</span><span class="symbol">:data</span> <span class="punct">=&gt;</span> <span class="attribute">@data</span><span class="punct">,</span> <span class="symbol">:bar_width_and_spacing</span> <span class="punct">=&gt;</span> <span class="punct">{</span><span class="symbol">:spacing</span> <span class="punct">=&gt;</span> <span class="number">10</span><span class="punct">,</span> <span class="symbol">:group_spacing</span> <span class="punct">=&gt;</span> <span class="number">12</span><span class="punct">})</span>
</pre></p>


<p><strong>pie chart</strong></p>


Expand Down Expand Up @@ -639,9 +665,10 @@ <h2>Contact</h2>
<h3>Contributors</h3>


<p><a href="http://github.com/dbgrandi">David Grandinetti</a></p>
<p><a href="http://github.com/dbgrandi">David Grandinetti</a>
<a href="http://github.com/takeo">Toby Sterrett</a></p>
<p class="coda">
<a href="mattaimonetti@gmail.com">Matt Aimonetti</a>, 7th May 2008<br>
<a href="mattaimonetti@gmail.com">Matt Aimonetti</a>, 8th May 2008<br>
Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
</p>
</div>
Expand Down

0 comments on commit 8690403

Please sign in to comment.