Skip to content

Commit

Permalink
0.4.1 Bug fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
DmitryBaranovskiy committed Jun 2, 2010
1 parent e9e5e35 commit 177d888
Show file tree
Hide file tree
Showing 10 changed files with 88 additions and 94 deletions.
4 changes: 2 additions & 2 deletions g.bar-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 7 additions & 6 deletions g.bar.js
@@ -1,5 +1,5 @@
/* /*!
* g.Raphael 0.4 - Charting library, based on Raphaël * g.Raphael 0.4.1 - Charting library, based on Raphaël
* *
* Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com) * Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com)
* Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license. * Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license.
Expand Down Expand Up @@ -63,7 +63,7 @@ Raphael.fn.g.barchart = function (x, y, width, height, values, opts) {
for (var j = 0; j < (multi || 1); j++) { for (var j = 0; j < (multi || 1); j++) {
var h = Math.round((multi ? values[j][i] : values[i]) * Y), var h = Math.round((multi ? values[j][i] : values[i]) * Y),
top = y + height - barvgutter - h, top = y + height - barvgutter - h,
bar = this.g.finger(Math.round(X + barwidth / 2), top + h, barwidth, h, true, type).attr({stroke: colors[multi ? j : i], fill: colors[multi ? j : i]}); bar = this.g.finger(Math.round(X + barwidth / 2), top + h, barwidth, h, true, type).attr({stroke: "none", fill: colors[multi ? j : i]});
if (multi) { if (multi) {
bars[j].push(bar); bars[j].push(bar);
} else { } else {
Expand Down Expand Up @@ -260,7 +260,7 @@ Raphael.fn.g.hbarchart = function (x, y, width, height, values, opts) {
stack = []; stack = [];
for (var j = 0; j < (multi || 1); j++) { for (var j = 0; j < (multi || 1); j++) {
var val = multi ? values[j][i] : values[i], var val = multi ? values[j][i] : values[i],
bar = this.g.finger(x, Y + barheight / 2, Math.round(val * X), barheight - 1, false, type).attr({stroke: colors[multi ? j : i], fill: colors[multi ? j : i]}); bar = this.g.finger(x, Y + barheight / 2, Math.round(val * X), barheight - 1, false, type).attr({stroke: "none", fill: colors[multi ? j : i]});
if (multi) { if (multi) {
bars[j].push(bar); bars[j].push(bar);
} else { } else {
Expand Down Expand Up @@ -306,10 +306,11 @@ Raphael.fn.g.hbarchart = function (x, y, width, height, values, opts) {
Y = y + bargutter; Y = y + bargutter;
if (!opts.stacked) { if (!opts.stacked) {
for (var i = 0; i < len; i++) { for (var i = 0; i < len; i++) {
for (var j = 0; j < multi; j++) { for (var j = 0; j < (multi || 1); j++) {
var cover = this.rect(x, Y, width, barheight).attr(this.g.shim); var cover = this.rect(x, Y, width, barheight).attr(this.g.shim);
covers.push(cover); covers.push(cover);
cover.bar = bars[j][i]; cover.bar = multi ? bars[j][i] : bars[i];
cover.value = cover.bar.value;
Y += barheight; Y += barheight;
} }
Y += bargutter; Y += bargutter;
Expand Down
2 changes: 1 addition & 1 deletion g.dot-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions g.dot.js
@@ -1,5 +1,5 @@
/* /*!
* g.Raphael 0.4 - Charting library, based on Raphaël * g.Raphael 0.4.1 - Charting library, based on Raphaël
* *
* Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com) * Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com)
* Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license. * Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license.
Expand Down
2 changes: 1 addition & 1 deletion g.line-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions g.line.js
@@ -1,5 +1,5 @@
/* /*!
* g.Raphael 0.4 - Charting library, based on Raphaël * g.Raphael 0.4.1 - Charting library, based on Raphaël
* *
* Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com) * Copyright (c) 2009 Dmitry Baranovskiy (http://g.raphaeljs.com)
* Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license. * Licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) license.
Expand Down

0 comments on commit 177d888

Please sign in to comment.