highcharts-rails 3.0.0 → 3.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v3.0.0 (2013-03-22)
2
+ * @license Highcharts JS v3.0.1 (2013-04-09)
3
3
  * MooTools adapter
4
4
  *
5
5
  * (c) 2010-2013 Torstein Hønsi
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v3.0.0 (2013-03-22)
2
+ * @license Highcharts JS v3.0.1 (2013-04-09)
3
3
  * Prototype adapter
4
4
  *
5
5
  * @author Michael Nelson, Torstein Hønsi.
@@ -1,22 +1,22 @@
1
1
  /*
2
- Highcharts JS v3.0.0 (2013-03-22)
2
+ Highcharts JS v3.0.1 (2013-04-09)
3
3
 
4
4
  (c) 2009-2013 Torstein Hønsi
5
5
 
6
6
  License: www.highcharts.com/license
7
7
  */
8
- (function(m,H){function K(a,b,c){this.init.call(this,a,b,c)}function L(a,b,c){a.call(this,b,c);if(this.chart.polar)this.closeSegment=function(a){var c=this.xAxis.center;a.push("L",c[0],c[1])},this.closedStacks=!0}function M(a,b){var c=this.chart,d=this.options.animation,e=this.group,g=this.markerGroup,f=this.xAxis.center,k=c.plotLeft,l=c.plotTop;if(c.polar){if(c.renderer.isSVG)if(d===!0&&(d={}),b){if(c={translateX:f[0]+k,translateY:f[1]+l,scaleX:0.001,scaleY:0.001},e.attr(c),g)g.attrSetters=e.attrSetters,
9
- g.attr(c)}else c={translateX:k,translateY:l,scaleX:1,scaleY:1},e.animate(c,d),g&&g.animate(c,d),this.animate=null}else a.call(this,b)}var Q=m.arrayMin,R=m.arrayMax,s=m.each,G=m.extend,p=m.merge,S=m.map,r=m.pick,u=m.pInt,n=m.getOptions().plotOptions,h=m.seriesTypes,A=m.extendClass,N=m.splat,o=m.wrap,O=m.Axis,B=m.Tick,z=m.Series,q=h.column.prototype,v=Math,I=v.round,C=v.floor,J=v.ceil,T=v.min,U=v.max,w=function(){};G(K.prototype,{init:function(a,b,c){var d=this,e=d.defaultOptions;d.chart=b;if(b.angular)e.background=
8
+ (function(m,F){function K(a,b,c){this.init.call(this,a,b,c)}function L(a,b,c){a.call(this,b,c);if(this.chart.polar)this.closeSegment=function(a){var c=this.xAxis.center;a.push("L",c[0],c[1])},this.closedStacks=!0}function M(a,b){var c=this.chart,d=this.options.animation,e=this.group,g=this.markerGroup,f=this.xAxis.center,k=c.plotLeft,l=c.plotTop;if(c.polar){if(c.renderer.isSVG)if(d===!0&&(d={}),b){if(c={translateX:f[0]+k,translateY:f[1]+l,scaleX:0.001,scaleY:0.001},e.attr(c),g)g.attrSetters=e.attrSetters,
9
+ g.attr(c)}else c={translateX:k,translateY:l,scaleX:1,scaleY:1},e.animate(c,d),g&&g.animate(c,d),this.animate=null}else a.call(this,b)}var Q=m.arrayMin,R=m.arrayMax,s=m.each,H=m.extend,p=m.merge,S=m.map,r=m.pick,u=m.pInt,n=m.getOptions().plotOptions,h=m.seriesTypes,A=m.extendClass,N=m.splat,o=m.wrap,O=m.Axis,B=m.Tick,z=m.Series,q=h.column.prototype,v=Math,I=v.round,C=v.floor,J=v.ceil,T=v.min,U=v.max,w=function(){};H(K.prototype,{init:function(a,b,c){var d=this,e=d.defaultOptions;d.chart=b;if(b.angular)e.background=
10
10
  {};d.options=a=p(e,a);(a=a.background)&&s([].concat(N(a)).reverse(),function(a){var b=a.backgroundColor,a=p(d.defaultBackgroundOptions,a);if(b)a.backgroundColor=b;a.color=a.backgroundColor;c.options.plotBands.unshift(a)})},defaultOptions:{center:["50%","50%"],size:"85%",startAngle:0},defaultBackgroundOptions:{shape:"circle",borderWidth:1,borderColor:"silver",backgroundColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,"#FFF"],[1,"#DDD"]]},from:Number.MIN_VALUE,innerRadius:0,to:Number.MAX_VALUE,
11
- outerRadius:"105%"}});var F=O.prototype,B=B.prototype,V={getOffset:w,redraw:function(){this.isDirty=!1},render:function(){this.isDirty=!1},setScale:w,setCategories:w,setTitle:w},P={isRadial:!0,defaultRadialGaugeOptions:{labels:{align:"center",x:0,y:null},minorGridLineWidth:0,minorTickInterval:"auto",minorTickLength:10,minorTickPosition:"inside",minorTickWidth:1,plotBands:[],tickLength:10,tickPosition:"inside",tickWidth:2,title:{rotation:0},zIndex:2},defaultRadialXOptions:{gridLineWidth:1,labels:{align:null,
12
- distance:15,x:0,y:null},maxPadding:0,minPadding:0,plotBands:[],showLastLabel:!1,tickLength:0},defaultRadialYOptions:{gridLineInterpolation:"circle",labels:{align:"right",x:-3,y:-2},plotBands:[],showLastLabel:!1,title:{x:4,text:null,rotation:90}},setOptions:function(a){this.options=p(this.defaultOptions,this.defaultRadialOptions,a)},getOffset:function(){F.getOffset.call(this);this.chart.axisOffset[this.side]=0;this.center=this.pane.center=h.pie.prototype.getCenter.call(this.pane)},getLinePath:function(a,
13
- b){var c=this.center,b=r(b,c[2]/2-this.offset);return this.chart.renderer.symbols.arc(this.left+c[0],this.top+c[1],b,b,{start:this.startAngleRad,end:this.endAngleRad,open:!0,innerR:0})},setAxisTranslation:function(){F.setAxisTranslation.call(this);if(this.center&&(this.transA=this.isCircular?(this.endAngleRad-this.startAngleRad)/(this.max-this.min||1):this.center[2]/2/(this.max-this.min||1),this.isXAxis))this.minPixelPadding=this.transA*this.minPointOffset+(this.reversed?(this.endAngleRad-this.startAngleRad)/
14
- 4:0)},beforeSetTickPositions:function(){this.autoConnect&&(this.max+=this.categories&&1||this.pointRange||this.closestPointRange)},setAxisSize:function(){F.setAxisSize.call(this);if(this.center)this.len=this.width=this.height=this.isCircular?this.center[2]*(this.endAngleRad-this.startAngleRad)/2:this.center[2]/2},getPosition:function(a,b){if(!this.isCircular)b=this.translate(a),a=this.min;return this.postTranslate(this.translate(a),r(b,this.center[2]/2)-this.offset)},postTranslate:function(a,b){var c=
11
+ outerRadius:"105%"}});var G=O.prototype,B=B.prototype,V={getOffset:w,redraw:function(){this.isDirty=!1},render:function(){this.isDirty=!1},setScale:w,setCategories:w,setTitle:w},P={isRadial:!0,defaultRadialGaugeOptions:{labels:{align:"center",x:0,y:null},minorGridLineWidth:0,minorTickInterval:"auto",minorTickLength:10,minorTickPosition:"inside",minorTickWidth:1,plotBands:[],tickLength:10,tickPosition:"inside",tickWidth:2,title:{rotation:0},zIndex:2},defaultRadialXOptions:{gridLineWidth:1,labels:{align:null,
12
+ distance:15,x:0,y:null},maxPadding:0,minPadding:0,plotBands:[],showLastLabel:!1,tickLength:0},defaultRadialYOptions:{gridLineInterpolation:"circle",labels:{align:"right",x:-3,y:-2},plotBands:[],showLastLabel:!1,title:{x:4,text:null,rotation:90}},setOptions:function(a){this.options=p(this.defaultOptions,this.defaultRadialOptions,a)},getOffset:function(){G.getOffset.call(this);this.chart.axisOffset[this.side]=0;this.center=this.pane.center=h.pie.prototype.getCenter.call(this.pane)},getLinePath:function(a,
13
+ b){var c=this.center,b=r(b,c[2]/2-this.offset);return this.chart.renderer.symbols.arc(this.left+c[0],this.top+c[1],b,b,{start:this.startAngleRad,end:this.endAngleRad,open:!0,innerR:0})},setAxisTranslation:function(){G.setAxisTranslation.call(this);if(this.center&&(this.transA=this.isCircular?(this.endAngleRad-this.startAngleRad)/(this.max-this.min||1):this.center[2]/2/(this.max-this.min||1),this.isXAxis))this.minPixelPadding=this.transA*this.minPointOffset+(this.reversed?(this.endAngleRad-this.startAngleRad)/
14
+ 4:0)},beforeSetTickPositions:function(){this.autoConnect&&(this.max+=this.categories&&1||this.pointRange||this.closestPointRange)},setAxisSize:function(){G.setAxisSize.call(this);if(this.center)this.len=this.width=this.height=this.isCircular?this.center[2]*(this.endAngleRad-this.startAngleRad)/2:this.center[2]/2},getPosition:function(a,b){if(!this.isCircular)b=this.translate(a),a=this.min;return this.postTranslate(this.translate(a),r(b,this.center[2]/2)-this.offset)},postTranslate:function(a,b){var c=
15
15
  this.chart,d=this.center,a=this.startAngleRad+a;return{x:c.plotLeft+d[0]+Math.cos(a)*b,y:c.plotTop+d[1]+Math.sin(a)*b}},getPlotBandPath:function(a,b,c){var d=this.center,e=this.startAngleRad,g=d[2]/2,f=[r(c.outerRadius,"100%"),c.innerRadius,r(c.thickness,10)],k=/%$/,l,j=this.isCircular;this.options.gridLineInterpolation==="polygon"?d=this.getPlotLinePath(a).concat(this.getPlotLinePath(b,!0)):(j||(f[0]=this.translate(a),f[1]=this.translate(b)),f=S(f,function(a){k.test(a)&&(a=u(a,10)*g/100);return a}),
16
16
  c.shape==="circle"||!j?(a=-Math.PI/2,b=Math.PI*1.5,l=!0):(a=e+this.translate(a),b=e+this.translate(b)),d=this.chart.renderer.symbols.arc(this.left+d[0],this.top+d[1],f[0],f[0],{start:a,end:b,innerR:r(f[1],f[0]-f[2]),open:l}));return d},getPlotLinePath:function(a,b){var c=this.center,d=this.chart,e=this.getPosition(a),g,f,k;this.isCircular?k=["M",c[0]+d.plotLeft,c[1]+d.plotTop,"L",e.x,e.y]:this.options.gridLineInterpolation==="circle"?(a=this.translate(a))&&(k=this.getLinePath(0,a)):(g=d.xAxis[0],
17
- k=[],a=this.translate(a),c=g.tickPositions,g.autoConnect&&(c=c.concat([c[0]])),b&&(c=[].concat(c).reverse()),s(c,function(c,b){f=g.getPosition(c,a);k.push(b?"L":"M",f.x,f.y)}));return k},getTitlePosition:function(){var a=this.center,b=this.chart,c=this.options.title;return{x:b.plotLeft+a[0]+(c.x||0),y:b.plotTop+a[1]-{high:0.5,middle:0.25,low:0}[c.align]*a[2]+(c.y||0)}}};o(F,"init",function(a,b,c){var i;var d=b.angular,e=b.polar,g=c.isX,f=d&&g,k,l;l=b.options;var j=c.pane||0;if(d){if(G(this,f?V:P),
18
- k=!g)this.defaultRadialOptions=this.defaultRadialGaugeOptions}else if(e)G(this,P),this.defaultRadialOptions=(k=g)?this.defaultRadialXOptions:p(this.defaultYAxisOptions,this.defaultRadialYOptions);a.call(this,b,c);if(!f&&(d||e)){a=this.options;if(!b.panes)b.panes=[];this.pane=(i=b.panes[j]=b.panes[j]||new K(N(l.pane)[j],b,this),j=i);j=j.options;b.inverted=!1;l.chart.zoomType=null;this.startAngleRad=b=(j.startAngle-90)*Math.PI/180;this.endAngleRad=l=(r(j.endAngle,j.startAngle+360)-90)*Math.PI/180;this.offset=
19
- a.offset||0;if((this.isCircular=k)&&c.max===H&&l-b===2*Math.PI)this.autoConnect=!0}});o(B,"getPosition",function(a,b,c,d,e){var g=this.axis;return g.getPosition?g.getPosition(c):a.call(this,b,c,d,e)});o(B,"getLabelPosition",function(a,b,c,d,e,g,f,k,l){var j=this.axis,i=g.y,h=g.align,y=(j.translate(this.pos)+j.startAngleRad+Math.PI/2)/Math.PI*180;j.isRadial?(a=j.getPosition(this.pos,j.center[2]/2+r(g.distance,-25)),g.rotation==="auto"?d.attr({rotation:y}):i===null&&(i=u(d.styles.lineHeight)*0.9-d.getBBox().height/
17
+ k=[],a=this.translate(a),c=g.tickPositions,g.autoConnect&&(c=c.concat([c[0]])),b&&(c=[].concat(c).reverse()),s(c,function(c,b){f=g.getPosition(c,a);k.push(b?"L":"M",f.x,f.y)}));return k},getTitlePosition:function(){var a=this.center,b=this.chart,c=this.options.title;return{x:b.plotLeft+a[0]+(c.x||0),y:b.plotTop+a[1]-{high:0.5,middle:0.25,low:0}[c.align]*a[2]+(c.y||0)}}};o(G,"init",function(a,b,c){var i;var d=b.angular,e=b.polar,g=c.isX,f=d&&g,k,l;l=b.options;var j=c.pane||0;if(d){if(H(this,f?V:P),
18
+ k=!g)this.defaultRadialOptions=this.defaultRadialGaugeOptions}else if(e)H(this,P),this.defaultRadialOptions=(k=g)?this.defaultRadialXOptions:p(this.defaultYAxisOptions,this.defaultRadialYOptions);a.call(this,b,c);if(!f&&(d||e)){a=this.options;if(!b.panes)b.panes=[];this.pane=(i=b.panes[j]=b.panes[j]||new K(N(l.pane)[j],b,this),j=i);j=j.options;b.inverted=!1;l.chart.zoomType=null;this.startAngleRad=b=(j.startAngle-90)*Math.PI/180;this.endAngleRad=l=(r(j.endAngle,j.startAngle+360)-90)*Math.PI/180;this.offset=
19
+ a.offset||0;if((this.isCircular=k)&&c.max===F&&l-b===2*Math.PI)this.autoConnect=!0}});o(B,"getPosition",function(a,b,c,d,e){var g=this.axis;return g.getPosition?g.getPosition(c):a.call(this,b,c,d,e)});o(B,"getLabelPosition",function(a,b,c,d,e,g,f,k,l){var j=this.axis,i=g.y,h=g.align,y=(j.translate(this.pos)+j.startAngleRad+Math.PI/2)/Math.PI*180;j.isRadial?(a=j.getPosition(this.pos,j.center[2]/2+r(g.distance,-25)),g.rotation==="auto"?d.attr({rotation:y}):i===null&&(i=u(d.styles.lineHeight)*0.9-d.getBBox().height/
20
20
  2),h===null&&(h=j.isCircular?y>20&&y<160?"left":y>200&&y<340?"right":"center":"center",d.attr({align:h})),a.x+=g.x,a.y+=i):a=a.call(this,b,c,d,e,g,f,k,l);return a});o(B,"getMarkPath",function(a,b,c,d,e,g,f){var k=this.axis;k.isRadial?(a=k.getPosition(this.pos,k.center[2]/2+d),b=["M",b,c,"L",a.x,a.y]):b=a.call(this,b,c,d,e,g,f);return b});n.arearange=p(n.area,{lineWidth:1,marker:null,threshold:null,tooltip:{pointFormat:'<span style="color:{series.color}">{series.name}</span>: <b>{point.low}</b> - <b>{point.high}</b><br/>'},
21
21
  trackByArea:!0,dataLabels:{verticalAlign:null,xLow:0,xHigh:0,yLow:0,yHigh:0}});h.arearange=m.extendClass(h.area,{type:"arearange",pointArrayMap:["low","high"],toYData:function(a){return[a.low,a.high]},pointValKey:"low",translate:function(){var a=this.yAxis;h.area.prototype.translate.apply(this);s(this.points,function(b){if(b.y!==null)b.plotLow=b.plotY,b.plotHigh=a.translate(b.high,0,1,0,1)})},getSegmentPath:function(a){var b=[],c=a.length,d=z.prototype.getSegmentPath,e,g;g=this.options;for(var f=
22
22
  g.step;c--;)e=a[c],b.push({plotX:e.plotX,plotY:e.plotHigh});a=d.call(this,a);if(f)f===!0&&(f="left"),g.step={left:"right",center:"center",right:"left"}[f];b=d.call(this,b);g.step=f;g=[].concat(a,b);b[0]="L";this.areaPath=this.areaPath.concat(a,b);return g},drawDataLabels:function(){var a=this.data,b=a.length,c,d=[],e=z.prototype,g=this.options.dataLabels,f,k=this.chart.inverted;if(g.enabled||this._hasPointLabels){for(c=b;c--;)f=a[c],f.y=f.high,f.plotY=f.plotHigh,d[c]=f.dataLabel,f.dataLabel=f.dataLabelUpper,
@@ -27,24 +27,24 @@ n.gauge=p(n.line,{dataLabels:{enabled:!0,y:15,borderWidth:1,borderColor:"silver"
27
27
  s(a.points,function(c){var b=c.graphic,e=c.shapeArgs,j=e.d,i=p(d.dial,c.dial);b?(b.animate(e),e.d=j):c.graphic=g[c.shapeType](e).attr({stroke:i.borderColor||"none","stroke-width":i.borderWidth||0,fill:i.backgroundColor||"black",rotation:e.rotation}).add(a.group)});c?c.animate({translateX:b[0],translateY:b[1]}):a.pivot=g.circle(0,0,r(e.radius,5)).attr({"stroke-width":e.borderWidth||0,stroke:e.borderColor||"silver",fill:e.backgroundColor||"black"}).translate(b[0],b[1]).add(a.group)},animate:function(a){var b=
28
28
  this;if(!a)s(b.points,function(a){var d=a.graphic;d&&(d.attr({rotation:b.yAxis.startAngleRad*180/Math.PI}),d.animate({rotation:a.shapeArgs.rotation},b.options.animation))}),b.animate=null},render:function(){this.group=this.plotGroup("group","series",this.visible?"visible":"hidden",this.options.zIndex,this.chart.seriesGroup);h.pie.prototype.render.call(this);this.group.clip(this.chart.clipRect)},setData:h.pie.prototype.setData,drawTracker:h.column.prototype.drawTracker};h.gauge=m.extendClass(h.line,
29
29
  B);n.boxplot=p(n.column,{fillColor:"#FFFFFF",lineWidth:1,medianWidth:2,states:{hover:{brightness:-0.3}},threshold:null,tooltip:{pointFormat:'<span style="color:{series.color};font-weight:bold">{series.name}</span><br/>Minimum: {point.low}<br/>Lower quartile: {point.q1}<br/>Median: {point.median}<br/>Higher quartile: {point.q3}<br/>Maximum: {point.high}<br/>'},whiskerLength:"50%",whiskerWidth:2});h.boxplot=A(h.column,{type:"boxplot",pointArrayMap:["low","q1","median","q3","high"],toYData:function(a){return[a.low,
30
- a.q1,a.median,a.q3,a.high]},pointValKey:"high",pointAttrToOptions:{fill:"fillColor",stroke:"color","stroke-width":"lineWidth"},drawDataLabels:w,translate:function(){var a=this.yAxis,b=this.pointArrayMap;h.column.prototype.translate.apply(this);s(this.points,function(c){s(b,function(b){c[b]!==null&&(c[b+"Plot"]=a.translate(c[b],0,1,0,1))})})},drawPoints:function(){var a=this,b=a.points,c=a.options,d=a.chart.renderer,e,g,f,k,l,j,i,h,y,m,t,n,o,x,r,p,v,q,w,u,B,A,z=a.doQuartiles!==!1,D=parseInt(a.options.whiskerLength,
31
- 10)/100;s(b,function(b){y=b.graphic;B=b.shapeArgs;t={};x={};p={};A=b.color||a.color;if(b.plotY!==H)if(e=b.pointAttr[b.selected?"selected":""],v=B.width,q=C(B.x),w=q+v,u=I(v/2),g=C(z?b.q1Plot:b.lowPlot),f=C(z?b.q3Plot:b.lowPlot),k=C(b.highPlot),l=C(b.lowPlot),t.stroke=b.stemColor||c.stemColor||A,t["stroke-width"]=b.stemWidth||c.stemWidth||c.lineWidth,t.dashstyle=b.stemDashStyle||c.stemDashStyle,x.stroke=b.whiskerColor||c.whiskerColor||A,x["stroke-width"]=b.whiskerWidth||c.whiskerWidth||c.lineWidth,
32
- p.stroke=b.medianColor||c.medianColor||A,p["stroke-width"]=b.medianWidth||c.medianWidth||c.lineWidth,i=t["stroke-width"]%2/2,h=q+u+i,m=["M",h,f,"L",h,k,"M",h,g,"L",h,l,"z"],z&&(i=e["stroke-width"]%2/2,h=C(h)+i,g=C(g)+i,f=C(f)+i,q+=i,w+=i,n=["M",q,f,"L",q,g,"L",w,g,"L",w,f,"L",q,f,"z"]),D&&(i=x["stroke-width"]%2/2,k+=i,l+=i,o=["M",h-u*D,k,"L",h+u*D,k,"M",h-u*D,l,"L",h+u*D,l]),i=p["stroke-width"]%2/2,j=I(b.medianPlot)+i,r=["M",q,j,w,j,"z"],y)b.stem.animate({d:m}),D&&b.whiskers.animate({d:o}),z&&b.box.animate({d:n}),
33
- b.medianShape.animate({d:r});else{b.graphic=y=d.g().add(a.group);b.stem=d.path(m).attr(t).add(y);if(D)b.whiskers=d.path(o).attr(x).add(y);if(z)b.box=d.path(n).attr(e).add(y);b.medianShape=d.path(r).attr(p).add(y)}})}});n.errorbar=p(n.boxplot,{color:"#000000",grouping:!1,linkedTo:":previous",tooltip:{pointFormat:n.arearange.tooltip.pointFormat},whiskerWidth:null});h.errorbar=A(h.boxplot,{type:"errorbar",pointArrayMap:["low","high"],toYData:function(a){return[a.low,a.high]},pointValKey:"high",doQuartiles:!1,
34
- getColumnMetrics:function(){return this.linkedParent&&this.linkedParent.columnMetrics||h.column.prototype.getColumnMetrics.call(this)}});o(F,"getSeriesExtremes",function(a,b){a.call(this,b);if(!this.isXAxis){var c=this,d=[],e=!0;s(c.series,function(a){if(a.visible&&a.stackKey&&!(a.type!=="waterfall"||HighchartsAdapter.inArray(a.stackKey)!==-1)){if(e)c.dataMin=c.dataMax=null,e=!1;var b=a.processedYData,k=b.length,h=b[0],j=b[0],i=a.options.threshold,m=c.stacks,n=a.stackKey,p="-"+n,t,o,q,x;for(x=0;x<
35
- k;x++){q=b[x]<i?p:n;t=m[q][x].total;if(x>i)t+=o,m[q][x].setTotal(t),m[q][x]._cum=null;t<h&&(h=t);t>j&&(j=t);o=t}a.dataMin=h;a.dataMax=j;c.dataMin=T(r(c.dataMin,h),h,i);c.dataMax=U(r(c.dataMax,j),j,i);d.push(a.stackKey);if(typeof i==="number")if(c.dataMin>=i)c.dataMin=i,c.ignoreMinPadding=!0;else if(c.dataMax<i)c.dataMax=i,c.ignoreMaxPadding=!0}})}});n.waterfall=p(n.column,{lineWidth:1,lineColor:"#333",dashStyle:"dot",borderColor:"#333"});h.waterfall=A(h.column,{type:"waterfall",upColorProp:"fill",
30
+ a.q1,a.median,a.q3,a.high]},pointValKey:"high",pointAttrToOptions:{fill:"fillColor",stroke:"color","stroke-width":"lineWidth"},drawDataLabels:w,translate:function(){var a=this.yAxis,b=this.pointArrayMap;h.column.prototype.translate.apply(this);s(this.points,function(c){s(b,function(b){c[b]!==null&&(c[b+"Plot"]=a.translate(c[b],0,1,0,1))})})},drawPoints:function(){var a=this,b=a.points,c=a.options,d=a.chart.renderer,e,g,f,k,l,j,i,h,y,m,t,n,r,x,o,p,v,q,w,u,B,A,z=a.doQuartiles!==!1,D=parseInt(a.options.whiskerLength,
31
+ 10)/100;s(b,function(b){y=b.graphic;B=b.shapeArgs;t={};x={};p={};A=b.color||a.color;if(b.plotY!==F)if(e=b.pointAttr[b.selected?"selected":""],v=B.width,q=C(B.x),w=q+v,u=I(v/2),g=C(z?b.q1Plot:b.lowPlot),f=C(z?b.q3Plot:b.lowPlot),k=C(b.highPlot),l=C(b.lowPlot),t.stroke=b.stemColor||c.stemColor||A,t["stroke-width"]=b.stemWidth||c.stemWidth||c.lineWidth,t.dashstyle=b.stemDashStyle||c.stemDashStyle,x.stroke=b.whiskerColor||c.whiskerColor||A,x["stroke-width"]=b.whiskerWidth||c.whiskerWidth||c.lineWidth,
32
+ p.stroke=b.medianColor||c.medianColor||A,p["stroke-width"]=b.medianWidth||c.medianWidth||c.lineWidth,i=t["stroke-width"]%2/2,h=q+u+i,m=["M",h,f,"L",h,k,"M",h,g,"L",h,l,"z"],z&&(i=e["stroke-width"]%2/2,h=C(h)+i,g=C(g)+i,f=C(f)+i,q+=i,w+=i,n=["M",q,f,"L",q,g,"L",w,g,"L",w,f,"L",q,f,"z"]),D&&(i=x["stroke-width"]%2/2,k+=i,l+=i,r=["M",h-u*D,k,"L",h+u*D,k,"M",h-u*D,l,"L",h+u*D,l]),i=p["stroke-width"]%2/2,j=I(b.medianPlot)+i,o=["M",q,j,"L",w,j,"z"],y)b.stem.animate({d:m}),D&&b.whiskers.animate({d:r}),z&&
33
+ b.box.animate({d:n}),b.medianShape.animate({d:o});else{b.graphic=y=d.g().add(a.group);b.stem=d.path(m).attr(t).add(y);if(D)b.whiskers=d.path(r).attr(x).add(y);if(z)b.box=d.path(n).attr(e).add(y);b.medianShape=d.path(o).attr(p).add(y)}})}});n.errorbar=p(n.boxplot,{color:"#000000",grouping:!1,linkedTo:":previous",tooltip:{pointFormat:n.arearange.tooltip.pointFormat},whiskerWidth:null});h.errorbar=A(h.boxplot,{type:"errorbar",pointArrayMap:["low","high"],toYData:function(a){return[a.low,a.high]},pointValKey:"high",
34
+ doQuartiles:!1,getColumnMetrics:function(){return this.linkedParent&&this.linkedParent.columnMetrics||h.column.prototype.getColumnMetrics.call(this)}});o(G,"getSeriesExtremes",function(a,b){a.call(this,b);if(!this.isXAxis){var c=this,d=[],e=!0;s(c.series,function(a){if(a.visible&&a.stackKey&&!(a.type!=="waterfall"||HighchartsAdapter.inArray(a.stackKey)!==-1)){if(e)c.dataMin=c.dataMax=null,e=!1;var b=a.processedYData,k=b.length,h=b[0],j=b[0],i=a.options.threshold,m=c.stacks,n=a.stackKey,p="-"+n,t,
35
+ o,q,x;for(x=0;x<k;x++){q=b[x]<i?p:n;t=m[q][x].total;if(x>i)t+=o,m[q][x].setTotal(t),m[q][x]._cum=null;t<h&&(h=t);t>j&&(j=t);o=t}a.dataMin=h;a.dataMax=j;c.dataMin=T(r(c.dataMin,h),h,i);c.dataMax=U(r(c.dataMax,j),j,i);d.push(a.stackKey);if(typeof i==="number")if(c.dataMin>=i)c.dataMin=i,c.ignoreMinPadding=!0;else if(c.dataMax<i)c.dataMax=i,c.ignoreMaxPadding=!0}})}});n.waterfall=p(n.column,{lineWidth:1,lineColor:"#333",dashStyle:"dot",borderColor:"#333"});h.waterfall=A(h.column,{type:"waterfall",upColorProp:"fill",
36
36
  pointArrayMap:["y","low"],pointValKey:"y",init:function(a,b){b.stacking=!0;h.column.prototype.init.call(this,a,b)},translate:function(){var a=this.yAxis,b,c,d,e,g,f,k,l,j,i,m,n,o=this.options.borderWidth%2/2;h.column.prototype.translate.apply(this);d=this.points;j=k=d[0];f=l=d[0].y;for(c=1,b=d.length;c<b;c++)e=d[c],g=e.shapeArgs,i=this.getStack(c),m=this.getStack(c-1),n=this.getStackY(m),j===null&&(j=e,l=0),e.y&&!e.isSum&&!e.isIntermediateSum&&(f+=e.y,l+=e.y),e.isSum||e.isIntermediateSum?(e.isIntermediateSum?
37
37
  (i=this.getSumEdges(j,d[c-1]),e.y=l,j=null):(i=this.getSumEdges(k,d[c-1]),e.y=f),g.y=e.plotY=i[1],g.height=i[0]-i[1]):e.y<0?(m=i._cum===null?m.total:i._cum,i._cum=m+e.y,e=J(a.translate(m,0,1))-o,i=a.translate(i._cum,0,1),g.y=e,g.height=J(i-e)):g.height=C(n-g.y)},processData:function(a){z.prototype.processData.call(this,a);var a=this.yData,b=a.length,c,d;for(d=0;d<b;d++)c=a[d],c!==null&&typeof c!=="number"&&(a[d]=c==="sum"?null:c==="intermediateSum"?null:c[0])},toYData:function(a){if(a.isSum)return"sum";
38
38
  else if(a.isIntermediateSum)return"intermediateSum";return[a.y]},getAttribs:function(){h.column.prototype.getAttribs.apply(this,arguments);var a=this.options,b=a.states,c=a.upColor||this.color,a=m.Color(c).brighten(0.1).get(),d=p(this.pointAttr),e=this.upColorProp;d[""][e]=c;d.hover[e]=b.hover.upColor||a;d.select[e]=b.select.upColor||c;s(this.points,function(a){if(a.y>0&&!a.color)a.pointAttr=d,a.color=c})},getGraphPath:function(){var a=this.data,b=a.length,c=I(this.options.lineWidth+this.options.borderWidth)%
39
39
  2/2,d=[],e,g,f;for(f=1;f<b;f++)g=a[f].shapeArgs,e=a[f-1].shapeArgs,g=["M",e.x+e.width,e.y+c,"L",g.x,e.y+c],a[f-1].y<0&&(g[2]+=e.height,g[5]+=e.height),d=d.concat(g);return d},getStack:function(a){var b=this.yAxis.stacks,c=this.stackKey;this.processedYData[a]<this.options.threshold&&(c="-"+c);return b[c][a]},getStackY:function(a){return J(this.yAxis.translate(a.total,null,!0))},getSumEdges:function(a,b){var c,d,e;d=this.options.threshold;c=a.y>=d?a.shapeArgs.y+a.shapeArgs.height:a.shapeArgs.y;d=b.y>=
40
40
  d?b.shapeArgs.y:b.shapeArgs.y+b.shapeArgs.height;d>c&&(e=c,c=d,d=e);return[c,d]},drawGraph:z.prototype.drawGraph});n.bubble=p(n.scatter,{dataLabels:{inside:!0,style:{color:"white",textShadow:"0px 0px 3px black"},verticalAlign:"middle"},marker:{lineColor:null,lineWidth:1},minSize:8,maxSize:"20%",tooltip:{pointFormat:"({point.x}, {point.y}), Size: {point.z}"},zThreshold:0});h.bubble=A(h.scatter,{type:"bubble",pointArrayMap:["y","z"],trackerGroups:["group","dataLabelsGroup"],pointAttrToOptions:{stroke:"lineColor",
41
41
  "stroke-width":"lineWidth",fill:"fillColor"},applyOpacity:function(a){var b=this.options.marker,c=r(b.fillOpacity,0.5),a=a||b.fillColor||this.color;c!==1&&(a=m.Color(a).setOpacity(c).get("rgba"));return a},convertAttribs:function(){var a=z.prototype.convertAttribs.apply(this,arguments);a.fill=this.applyOpacity(a.fill);return a},getRadii:function(a,b,c,d){var e,g,f,k=this.zData,h=[];for(g=0,e=k.length;g<e;g++)f=b-a,f=f>0?(k[g]-a)/(b-a):0.5,h.push(v.round(c+f*(d-c))/2);this.radii=h},animate:function(a){var b=
42
- this.options.animation;if(!a)s(this.points,function(a){var d=a.graphic,a=a.shapeArgs;d&&a&&(d.attr("r",1),d.animate({r:a.r},b))}),this.animate=null},translate:function(){var a,b=this.data,c,d,e=this.radii;h.scatter.prototype.translate.call(this);for(a=b.length;a--;)c=b[a],d=e[a],c.negative=c.z<(this.options.zThreshold||0),d>=this.minPxSize/2?(c.shapeType="circle",c.shapeArgs={x:c.plotX,y:c.plotY,r:d},c.dlBox={x:c.plotX-d,y:c.plotY-d,width:2*d,height:2*d}):c.shapeArgs=c.plotY=c.dlBox=null},drawLegendSymbol:function(a,
43
- b){var c=u(a.itemStyle.fontSize)/2;b.legendSymbol=this.chart.renderer.circle(c,a.baseline-c,c).attr({zIndex:3}).add(b.legendGroup)},drawPoints:h.column.prototype.drawPoints,alignDataLabel:h.column.prototype.alignDataLabel});O.prototype.beforePadding=function(){var a=this.len,b=this.chart,c=0,d=a,e=this.isXAxis,g=e?"xData":"yData",f=this.min,k={},h=v.min(b.plotWidth,b.plotHeight),j=Number.MAX_VALUE,i=-Number.MAX_VALUE,m=this.max-f,n=a/m,o=[];this.tickPositions&&(s(this.series,function(a){var b=a.options;
44
- if(a.type==="bubble"&&a.visible&&(o.push(a),e))s(["minSize","maxSize"],function(a){var c=b[a],d=/%$/.test(c),c=u(c);k[a]=d?h*c/100:c}),a.minPxSize=k.minSize,a=a.zData,j=v.min(j,v.max(Q(a),b.displayNegative===!1?b.zThreshold:-Number.MAX_VALUE)),i=v.max(i,R(a))}),s(o,function(a){var b=a[g],h=b.length,l;e&&a.getRadii(j,i,k.minSize,k.maxSize);if(m>0)for(;h--;)l=a.radii[h],c=Math.min((b[h]-f)*n-l,c),d=Math.max((b[h]-f)*n+l,d)}),m>0&&r(this.options.min,this.userMin)===H&&(d-=a,n*=(a+c-d)/a,this.min+=c/
45
- n,this.max+=d/n))};var E=z.prototype,n=m.Pointer.prototype;E.toXY=function(a){var b,c=this.chart;b=a.plotX;var d=a.plotY;a.rectPlotX=b;a.rectPlotY=d;a.clientX=b/Math.PI*180;b=this.xAxis.postTranslate(a.plotX,this.yAxis.len-d);a.plotX=a.polarPlotX=b.x-c.plotLeft;a.plotY=a.polarPlotY=b.y-c.plotTop};o(h.area.prototype,"init",L);o(h.areaspline.prototype,"init",L);o(h.spline.prototype,"getPointSpline",function(a,b,c,d){var e,g,f,h,l,j,i;if(this.chart.polar){e=c.plotX;g=c.plotY;a=b[d-1];f=b[d+1];this.connectEnds&&
46
- (a||(a=b[b.length-2]),f||(f=b[1]));if(a&&f)h=a.plotX,l=a.plotY,b=f.plotX,j=f.plotY,h=(1.5*e+h)/2.5,l=(1.5*g+l)/2.5,f=(1.5*e+b)/2.5,i=(1.5*g+j)/2.5,b=Math.sqrt(Math.pow(h-e,2)+Math.pow(l-g,2)),j=Math.sqrt(Math.pow(f-e,2)+Math.pow(i-g,2)),h=Math.atan2(l-g,h-e),l=Math.atan2(i-g,f-e),i=Math.PI/2+(h+l)/2,Math.abs(h-i)>Math.PI/2&&(i-=Math.PI),h=e+Math.cos(i)*b,l=g+Math.sin(i)*b,f=e+Math.cos(Math.PI+i)*j,i=g+Math.sin(Math.PI+i)*j,c.rightContX=f,c.rightContY=i;d?(c=["C",a.rightContX||a.plotX,a.rightContY||
47
- a.plotY,h||e,l||g,e,g],a.rightContX=a.rightContY=null):c=["M",e,g]}else c=a.call(this,b,c,d);return c});o(E,"translate",function(a){a.call(this);if(this.chart.polar&&!this.preventPostTranslate)for(var a=this.points,b=a.length;b--;)this.toXY(a[b])});o(E,"getSegmentPath",function(a,b){var c=this.points;if(this.chart.polar&&this.options.connectEnds!==!1&&b[b.length-1]===c[c.length-1]&&c[0].y!==null)this.connectEnds=!0,b=[].concat(b,[c[0]]);return a.call(this,b)});o(E,"animate",M);o(q,"animate",M);o(E,
48
- "setTooltipPoints",function(a,b){this.chart.polar&&G(this.xAxis,{tooltipLen:360});return a.call(this,b)});o(q,"translate",function(a){var b=this.xAxis,c=this.yAxis.len,d=b.center,e=b.startAngleRad,g=this.chart.renderer,f,h;this.preventPostTranslate=!0;a.call(this);if(b.isRadial){b=this.points;for(h=b.length;h--;)f=b[h],a=f.barX+e,f.shapeType="path",f.shapeArgs={d:g.symbols.arc(d[0],d[1],c-f.plotY,null,{start:a,end:a+f.pointWidth,innerR:c-r(f.yBottom,c)})},this.toXY(f)}});o(q,"alignDataLabel",function(a,
49
- b,c,d,e,g){if(this.chart.polar){a=b.rectPlotX/Math.PI*180;if(d.align===null)d.align=a>20&&a<160?"left":a>200&&a<340?"right":"center";if(d.verticalAlign===null)d.verticalAlign=a<45||a>315?"bottom":a>135&&a<225?"top":"middle";E.alignDataLabel.call(this,b,c,d,e,g)}else a.call(this,b,c,d,e,g)});o(n,"getIndex",function(a,b){var c,d=this.chart,e;d.polar?(e=d.xAxis[0].center,c=b.chartX-e[0]-d.plotLeft,d=b.chartY-e[1]-d.plotTop,c=180-Math.round(Math.atan2(c,d)/Math.PI*180)):c=a.call(this,b);return c});o(n,
50
- "getCoordinates",function(a,b){var c=this.chart,d={xAxis:[],yAxis:[]};c.polar?s(c.axes,function(a){var g=a.isXAxis,f=a.center,h=b.chartX-f[0]-c.plotLeft,f=b.chartY-f[1]-c.plotTop;d[g?"xAxis":"yAxis"].push({axis:a,value:a.translate(g?Math.PI-Math.atan2(h,f):Math.sqrt(Math.pow(h,2)+Math.pow(f,2)),!0)})}):d=a.call(this,b);return d})})(Highcharts);
42
+ this.options.animation;if(!a)s(this.points,function(a){var d=a.graphic,a=a.shapeArgs;d&&a&&(d.attr("r",1),d.animate({r:a.r},b))}),this.animate=null},translate:function(){var a,b=this.data,c,d,e=this.radii;h.scatter.prototype.translate.call(this);for(a=b.length;a--;)c=b[a],d=e[a],c.negative=c.z<(this.options.zThreshold||0),d>=this.minPxSize/2?(c.shapeType="circle",c.shapeArgs={x:c.plotX,y:c.plotY,r:d},c.dlBox={x:c.plotX-d,y:c.plotY-d,width:2*d,height:2*d}):c.shapeArgs=c.plotY=c.dlBox=F},drawLegendSymbol:function(a,
43
+ b){var c=u(a.itemStyle.fontSize)/2;b.legendSymbol=this.chart.renderer.circle(c,a.baseline-c,c).attr({zIndex:3}).add(b.legendGroup)},drawPoints:h.column.prototype.drawPoints,alignDataLabel:h.column.prototype.alignDataLabel});O.prototype.beforePadding=function(){var a=this.len,b=this.chart,c=0,d=a,e=this.isXAxis,g=e?"xData":"yData",f=this.min,k={},h=v.min(b.plotWidth,b.plotHeight),j=Number.MAX_VALUE,i=-Number.MAX_VALUE,m=this.max-f,n=a/m,o=[];this.allowZoomOutside=!0;this.tickPositions&&(s(this.series,
44
+ function(a){var b=a.options;if(a.type==="bubble"&&a.visible&&(o.push(a),e))s(["minSize","maxSize"],function(a){var c=b[a],d=/%$/.test(c),c=u(c);k[a]=d?h*c/100:c}),a.minPxSize=k.minSize,a=a.zData,j=v.min(j,v.max(Q(a),b.displayNegative===!1?b.zThreshold:-Number.MAX_VALUE)),i=v.max(i,R(a))}),s(o,function(a){var b=a[g],h=b.length,l;e&&a.getRadii(j,i,k.minSize,k.maxSize);if(m>0)for(;h--;)l=a.radii[h],c=Math.min((b[h]-f)*n-l,c),d=Math.max((b[h]-f)*n+l,d)}),m>0&&r(this.options.min,this.userMin)===F&&r(this.options.max,
45
+ this.userMax)===F&&(d-=a,n*=(a+c-d)/a,this.min+=c/n,this.max+=d/n))};var E=z.prototype,n=m.Pointer.prototype;E.toXY=function(a){var b,c=this.chart;b=a.plotX;var d=a.plotY;a.rectPlotX=b;a.rectPlotY=d;a.clientX=b/Math.PI*180;b=this.xAxis.postTranslate(a.plotX,this.yAxis.len-d);a.plotX=a.polarPlotX=b.x-c.plotLeft;a.plotY=a.polarPlotY=b.y-c.plotTop};o(h.area.prototype,"init",L);o(h.areaspline.prototype,"init",L);o(h.spline.prototype,"getPointSpline",function(a,b,c,d){var e,g,f,h,l,j,i;if(this.chart.polar){e=
46
+ c.plotX;g=c.plotY;a=b[d-1];f=b[d+1];this.connectEnds&&(a||(a=b[b.length-2]),f||(f=b[1]));if(a&&f)h=a.plotX,l=a.plotY,b=f.plotX,j=f.plotY,h=(1.5*e+h)/2.5,l=(1.5*g+l)/2.5,f=(1.5*e+b)/2.5,i=(1.5*g+j)/2.5,b=Math.sqrt(Math.pow(h-e,2)+Math.pow(l-g,2)),j=Math.sqrt(Math.pow(f-e,2)+Math.pow(i-g,2)),h=Math.atan2(l-g,h-e),l=Math.atan2(i-g,f-e),i=Math.PI/2+(h+l)/2,Math.abs(h-i)>Math.PI/2&&(i-=Math.PI),h=e+Math.cos(i)*b,l=g+Math.sin(i)*b,f=e+Math.cos(Math.PI+i)*j,i=g+Math.sin(Math.PI+i)*j,c.rightContX=f,c.rightContY=
47
+ i;d?(c=["C",a.rightContX||a.plotX,a.rightContY||a.plotY,h||e,l||g,e,g],a.rightContX=a.rightContY=null):c=["M",e,g]}else c=a.call(this,b,c,d);return c});o(E,"translate",function(a){a.call(this);if(this.chart.polar&&!this.preventPostTranslate)for(var a=this.points,b=a.length;b--;)this.toXY(a[b])});o(E,"getSegmentPath",function(a,b){var c=this.points;if(this.chart.polar&&this.options.connectEnds!==!1&&b[b.length-1]===c[c.length-1]&&c[0].y!==null)this.connectEnds=!0,b=[].concat(b,[c[0]]);return a.call(this,
48
+ b)});o(E,"animate",M);o(q,"animate",M);o(E,"setTooltipPoints",function(a,b){this.chart.polar&&H(this.xAxis,{tooltipLen:360});return a.call(this,b)});o(q,"translate",function(a){var b=this.xAxis,c=this.yAxis.len,d=b.center,e=b.startAngleRad,g=this.chart.renderer,f,h;this.preventPostTranslate=!0;a.call(this);if(b.isRadial){b=this.points;for(h=b.length;h--;)f=b[h],a=f.barX+e,f.shapeType="path",f.shapeArgs={d:g.symbols.arc(d[0],d[1],c-f.plotY,null,{start:a,end:a+f.pointWidth,innerR:c-r(f.yBottom,c)})},
49
+ this.toXY(f)}});o(q,"alignDataLabel",function(a,b,c,d,e,g){if(this.chart.polar){a=b.rectPlotX/Math.PI*180;if(d.align===null)d.align=a>20&&a<160?"left":a>200&&a<340?"right":"center";if(d.verticalAlign===null)d.verticalAlign=a<45||a>315?"bottom":a>135&&a<225?"top":"middle";E.alignDataLabel.call(this,b,c,d,e,g)}else a.call(this,b,c,d,e,g)});o(n,"getIndex",function(a,b){var c,d=this.chart,e;d.polar?(e=d.xAxis[0].center,c=b.chartX-e[0]-d.plotLeft,d=b.chartY-e[1]-d.plotTop,c=180-Math.round(Math.atan2(c,
50
+ d)/Math.PI*180)):c=a.call(this,b);return c});o(n,"getCoordinates",function(a,b){var c=this.chart,d={xAxis:[],yAxis:[]};c.polar?s(c.axes,function(a){var g=a.isXAxis,f=a.center,h=b.chartX-f[0]-c.plotLeft,f=b.chartY-f[1]-c.plotTop;d[g?"xAxis":"yAxis"].push({axis:a,value:a.translate(g?Math.PI-Math.atan2(h,f):Math.sqrt(Math.pow(h,2)+Math.pow(f,2)),!0)})}):d=a.call(this,b);return d})})(Highcharts);
@@ -2908,7 +2908,7 @@ if (CanvasRenderingContext2D) {
2908
2908
  });
2909
2909
  }
2910
2910
  }/**
2911
- * @license Highcharts JS v3.0.0 (2013-03-22)
2911
+ * @license Highcharts JS v3.0.1 (2013-04-09)
2912
2912
  * CanVGRenderer Extension module
2913
2913
  *
2914
2914
  * (c) 2011-2012 Torstein Hønsi, Erik Olsson
@@ -49,10 +49,10 @@
49
49
  * The Google Spreadsheet worksheet. The available id's can be read from
50
50
  * https://spreadsheets.google.com/feeds/worksheets/{key}/public/basic
51
51
  *
52
- * - itemDilimiter : String
52
+ * - itemDelimiter : String
53
53
  * Item or cell delimiter for parsing CSV. Defaults to ",".
54
54
  *
55
- * - lineDilimiter : String
55
+ * - lineDelimiter : String
56
56
  * Line delimiter for parsing CSV. Defaults to "\n".
57
57
  *
58
58
  * - parsed : Function
@@ -139,14 +139,16 @@
139
139
  * Parse a CSV input string
140
140
  */
141
141
  parseCSV: function () {
142
- var options = this.options,
142
+ var self = this,
143
+ options = this.options,
143
144
  csv = options.csv,
144
145
  columns = this.columns,
145
146
  startRow = options.startRow || 0,
146
147
  endRow = options.endRow || Number.MAX_VALUE,
147
148
  startColumn = options.startColumn || 0,
148
149
  endColumn = options.endColumn || Number.MAX_VALUE,
149
- lines;
150
+ lines,
151
+ activeRowNo = 0;
150
152
 
151
153
  if (csv) {
152
154
 
@@ -156,19 +158,26 @@
156
158
  .split(options.lineDelimiter || "\n");
157
159
 
158
160
  each(lines, function (line, rowNo) {
159
- if (rowNo >= startRow && rowNo <= endRow) {
160
- var items = line.split(options.itemDelimiter || ',');
161
+ var trimmed = self.trim(line),
162
+ isComment = trimmed.indexOf('#') === 0,
163
+ isBlank = trimmed === '',
164
+ items;
165
+
166
+ if (rowNo >= startRow && rowNo <= endRow && !isComment && !isBlank) {
167
+ items = line.split(options.itemDelimiter || ',');
161
168
  each(items, function (item, colNo) {
162
169
  if (colNo >= startColumn && colNo <= endColumn) {
163
170
  if (!columns[colNo - startColumn]) {
164
171
  columns[colNo - startColumn] = [];
165
172
  }
166
173
 
167
- columns[colNo - startColumn][rowNo - startRow] = item;
174
+ columns[colNo - startColumn][activeRowNo] = item;
168
175
  }
169
176
  });
177
+ activeRowNo += 1;
170
178
  }
171
- });
179
+ });
180
+
172
181
  this.dataFound();
173
182
  }
174
183
  },
@@ -299,7 +308,6 @@
299
308
  * Trim a string from whitespace
300
309
  */
301
310
  trim: function (str) {
302
- //return typeof str === 'number' ? str : str.replace(/^\s+|\s+$/g, ''); // fails with spreadsheet
303
311
  return typeof str === 'string' ? str.replace(/^\s+|\s+$/g, '') : str;
304
312
  },
305
313
 
@@ -322,6 +330,7 @@
322
330
  val = columns[col][row];
323
331
  floatVal = parseFloat(val);
324
332
  trimVal = this.trim(val);
333
+
325
334
  /*jslint eqeq: true*/
326
335
  if (trimVal == floatVal) { // is numeric
327
336
  /*jslint eqeq: false*/
@@ -370,7 +379,7 @@
370
379
  match;
371
380
 
372
381
  if (parseDate) {
373
- ret = parseDate;
382
+ ret = parseDate(val);
374
383
  }
375
384
 
376
385
  if (typeof val === 'string') {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Highcharts JS v3.0.0 (2013-03-22)
2
+ * @license Highcharts JS v3.0.1 (2013-04-09)
3
3
  * Exporting module
4
4
  *
5
5
  * (c) 2010-2013 Torstein Hønsi
@@ -42,6 +42,7 @@ var Chart = Highcharts.Chart,
42
42
 
43
43
  // Add language
44
44
  extend(defaultOptions.lang, {
45
+ printChart: 'Print chart',
45
46
  downloadPNG: 'Download PNG image',
46
47
  downloadJPEG: 'Download JPEG image',
47
48
  downloadPDF: 'Download PDF document',
@@ -49,8 +50,6 @@ var Chart = Highcharts.Chart,
49
50
  contextButtonTitle: 'Chart context menu'
50
51
  });
51
52
 
52
- // docs: update the new defaults and explain the compatibility pack
53
-
54
53
  // Buttons and menus are collected in a separate config option set called 'navigation'.
55
54
  // This can be extended later to add control buttons like zoom and pan right click menus.
56
55
  defaultOptions.navigation = {
@@ -70,7 +69,7 @@ defaultOptions.navigation = {
70
69
  color: '#FFFFFF'
71
70
  },
72
71
 
73
- buttonOptions: { // docs
72
+ buttonOptions: {
74
73
  symbolFill: '#E0E0E0',
75
74
  symbolSize: 14,
76
75
  symbolStroke: '#666',
@@ -80,6 +79,7 @@ defaultOptions.navigation = {
80
79
  align: 'right',
81
80
  buttonSpacing: 3,
82
81
  height: 22,
82
+ // text: null,
83
83
  theme: {
84
84
  fill: 'white', // capture hover
85
85
  stroke: 'none'
@@ -97,15 +97,15 @@ defaultOptions.exporting = {
97
97
  //filename: 'chart',
98
98
  type: 'image/png',
99
99
  url: 'http://export.highcharts.com/',
100
- //width: undefined, // docs
101
- //scale: 2 // docs
100
+ //width: undefined,
101
+ //scale: 2
102
102
  buttons: {
103
- contextButton: { // docs
104
- //x: -10, // docs: x is different now
103
+ contextButton: {
104
+ //x: -10,
105
105
  symbol: 'menu',
106
106
  _titleKey: 'contextButtonTitle',
107
107
  menuItems: [{
108
- text: 'Print chart',
108
+ textKey: 'printChart',
109
109
  onclick: function () {
110
110
  this.print();
111
111
  }
@@ -233,15 +233,14 @@ extend(Chart.prototype, {
233
233
  options.chart.height ||
234
234
  (/px$/.test(cssHeight) && parseInt(cssHeight, 10)) ||
235
235
  400;
236
-
237
236
 
238
237
  // override some options
239
238
  extend(options.chart, {
240
239
  animation: false,
241
240
  renderTo: sandbox,
242
241
  forExport: true,
243
- width: sourceWidth, // docs,
244
- height: sourceHeight // docs
242
+ width: sourceWidth,
243
+ height: sourceHeight
245
244
  });
246
245
  options.exporting.enabled = false; // hide buttons in print
247
246
  options.chart.plotBackgroundImage = null; // the converter doesn't handle images
@@ -334,18 +333,18 @@ extend(Chart.prototype, {
334
333
  * @param {Object} chartOptions Additional chart options for the SVG representation of the chart
335
334
  */
336
335
  exportChart: function (options, chartOptions) {
337
-
338
336
  options = options || {};
339
337
 
340
338
  var chart = this,
339
+ chartExportingOptions = chart.options.exporting,
341
340
  svg = chart.getSVG(merge(
342
- { chart: { borderRadius: 0 } }, // docs: defaults to 0 for exported charts
343
- chart.options.exporting.chartOptions, // docs
341
+ { chart: { borderRadius: 0 } },
342
+ chartExportingOptions,
344
343
  chartOptions,
345
344
  {
346
345
  exporting: {
347
- sourceWidth: options.sourceWidth, // docs
348
- sourceHeight: options.sourceHeight // docs
346
+ sourceWidth: options.sourceWidth || chartExportingOptions.sourceWidth, // docs: option and parameter in exportChart()
347
+ sourceHeight: options.sourceHeight || chartExportingOptions.sourceHeight // docs
349
348
  }
350
349
  }
351
350
  ));
@@ -626,7 +625,7 @@ extend(Chart.prototype, {
626
625
  button.add()
627
626
  .align(extend(btnOptions, {
628
627
  width: button.width,
629
- x: buttonOffset
628
+ x: Highcharts.pick(btnOptions.x, buttonOffset) // #1654
630
629
  }), true, 'spacingBox');
631
630
 
632
631
  buttonOffset += (button.width + btnOptions.buttonSpacing) * (btnOptions.align === 'right' ? -1 : 1);
@@ -1,3 +1,3 @@
1
1
  module Highcharts
2
- VERSION = "3.0.0"
2
+ VERSION = "3.0.1"
3
3
  end
metadata CHANGED
@@ -2,14 +2,14 @@
2
2
  name: highcharts-rails
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 3.0.0
5
+ version: 3.0.1
6
6
  platform: ruby
7
7
  authors:
8
8
  - Per Christian B. Viken
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-03-26 00:00:00.000000000 Z
12
+ date: 2013-04-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: railties
@@ -73,26 +73,26 @@ files:
73
73
  - LICENSE
74
74
  - README.markdown
75
75
  - Rakefile
76
+ - app/assets/images/highcharts/skies.jpg
77
+ - app/assets/images/highcharts/snow.png
78
+ - app/assets/images/highcharts/sun.png
79
+ - app/assets/javascripts/highcharts.js
80
+ - app/assets/javascripts/highcharts/adapters/mootools.js
81
+ - app/assets/javascripts/highcharts/adapters/prototype.js
82
+ - app/assets/javascripts/highcharts/highcharts-more.js
83
+ - app/assets/javascripts/highcharts/modules/canvas-tools.js
84
+ - app/assets/javascripts/highcharts/modules/data.js
85
+ - app/assets/javascripts/highcharts/modules/exporting.js
86
+ - app/assets/javascripts/highcharts/modules/funnel.js
87
+ - app/assets/javascripts/highcharts/themes/dark-blue.js
88
+ - app/assets/javascripts/highcharts/themes/dark-green.js
89
+ - app/assets/javascripts/highcharts/themes/gray.js
90
+ - app/assets/javascripts/highcharts/themes/grid.js
91
+ - app/assets/javascripts/highcharts/themes/skies.js
76
92
  - highcharts-rails.gemspec
77
93
  - lib/highcharts-rails.rb
78
94
  - lib/highcharts/rails.rb
79
95
  - lib/highcharts/version.rb
80
- - vendor/assets/images/highcharts/skies.jpg
81
- - vendor/assets/images/highcharts/snow.png
82
- - vendor/assets/images/highcharts/sun.png
83
- - vendor/assets/javascripts/highcharts.js
84
- - vendor/assets/javascripts/highcharts/adapters/mootools.js
85
- - vendor/assets/javascripts/highcharts/adapters/prototype.js
86
- - vendor/assets/javascripts/highcharts/highcharts-more.js
87
- - vendor/assets/javascripts/highcharts/modules/canvas-tools.js
88
- - vendor/assets/javascripts/highcharts/modules/data.js
89
- - vendor/assets/javascripts/highcharts/modules/exporting.js
90
- - vendor/assets/javascripts/highcharts/modules/funnel.js
91
- - vendor/assets/javascripts/highcharts/themes/dark-blue.js
92
- - vendor/assets/javascripts/highcharts/themes/dark-green.js
93
- - vendor/assets/javascripts/highcharts/themes/gray.js
94
- - vendor/assets/javascripts/highcharts/themes/grid.js
95
- - vendor/assets/javascripts/highcharts/themes/skies.js
96
96
  homepage: http://northblue.org/
97
97
  licenses: []
98
98
  post_install_message:
metadata.gz.asc CHANGED
@@ -2,17 +2,17 @@
2
2
  Version: GnuPG/MacGPG2 v2.0.19 (Darwin)
3
3
  Comment: GPGTools - http://gpgtools.org
4
4
 
5
- iQIcBAABAgAGBQJRUZ5vAAoJEH1ncb0Txu7XM7kP/3kkvcxHdeeX8BWmhO7Ni7YB
6
- CfAmHJroRjU1jFDJuAc8uw6pS13N+F559wIDHcO7alwrBUVfeb17lm1xQ39AhI2B
7
- Sk3g7l5zH2hmMFQyUjcRMnV8YSsc/i+owmwPnkRk4mVXd6obRvDU0l7atV1icE8H
8
- UtjRPliBRROrlif9tfFkHqYnE3bDHkqxHwfW6cDC7kQswoCMDaMXlrlC2/gNwZUF
9
- CO1tuBs3hRsZZFBUuP4yjs421rWiqpK+8wghJSGrnBbNqR2HdNa/mJHWVOb4z1lF
10
- Rr5dvLv30BLAdxmBj2tw+edN/wY5+XsPL5l8v0Pt2rri72+7brF2XxSsx0y/mfQE
11
- DTrK2ti/3J6kUwBIRZ2owhYKViCuUO9Ru3fUv0k5FrD31/FpFQvl37jPP+XZvJeZ
12
- Y1OOONV5x9c8wfDueHjTAIEGbKy8FKZp0hF9xlx36K3rXX9FgbUBmghY8K8uy/IG
13
- tGQYT1yNIUaHkT5jFjBvo4E6N40UBah8ENCEdvWJTuIDTE0Fg3PGgELEug+Rf5R6
14
- Bpdf3rXliDxmYGHHPKF9ZDn9OG2tveA6nta0+IgsgoyugwgZn+RjMJ1ksKV8XLbc
15
- UXdw92MTLgq+sZNf6V/a/w7aXAh8gikmDOtSrrUOwrCV+9gvC9kQvFNQ7oqSO1xS
16
- /M7EKu07FYp27ZvjznDI
17
- =tTSd
5
+ iQIbBAABAgAGBQJRZCX4AAoJEH1ncb0Txu7X/t4P9R5ENkevewpnG4BmYF2THRJd
6
+ bws9bcN4bPeSYpceQBphAnFEVQfL+QAXzTweHHw5nk/mGg1iPl18ySyWWeWdSq+G
7
+ bbjIAqcG9IdeX/ItzzWXn47WvXhjsu7s6LZ3vP57Y7q0+AcHW45Tl90p1XYSFI3D
8
+ 1Cx1lh6ljZ7JtsNe8j3lnxHq/gL29RA+f4u+k8u+jdas69I+dpcc5EiuI+9C2AnB
9
+ usTAafb8Q7lVwsiv9Mkgufai5c3J9LkSZOjLF8GhoXSVE/xybAFpFs4SzyoGKm6K
10
+ C/xXtZV+78/sv5WUm1UK//T/9LXO0jebYiE5/WZgJZDnt/zDVJDYU5Nmsr9IF1ty
11
+ QYRHUO3iMZODpDyeRxKDEL1DMYoKrZJbvZqbJx+0FmYSfvxqcyX0cKoIFYOLhZUo
12
+ rxWKoEw3otoWiJhKJPC6A+CkYS3NxOjHjixhRs6T59Dxo5Hb5dYO9cF823feCIGU
13
+ ge/FlB4wBTJeFrSSMTjl/ABU5Vrdfx2/Ng5e/nyAwFaki8p4n8CRNnfYvsJ8SvQC
14
+ 8jAspjcyeiXzQx27ujgny45NTYNMkfrl01OLHsRjVaXnTw97z8+96QQaCV/5M0tA
15
+ ZZtWxDI2BTWXIkzBp0BzyAq1utDiS++CE/p3nEhlDGRMwj49iAg3JD3mfS0/OfmB
16
+ cHbhD6RW3WPUEGUKW4M=
17
+ =LkjG
18
18
  -----END PGP SIGNATURE-----