BUGFIX: xAxisLabelHeight is set to 0 in case the option 'drawXAxis' is
authoreichsjul <julian.eichstaedt@ch.sauter-bc.com>
Wed, 20 Mar 2013 14:50:58 +0000 (15:50 +0100)
committerDavid Eberlein <david.eberlein@ch.sauter-bc.com>
Thu, 11 Apr 2013 08:51:03 +0000 (10:51 +0200)
set to false.

plugins/range-selector.js

index df8f867..d45a29a 100644 (file)
@@ -176,7 +176,11 @@ rangeSelector.prototype.resize_ = function() {
   }
 
   var plotArea = this.dygraph_.layout_.getPlotArea();
-  var xAxisLabelHeight = this.getOption_('xAxisHeight') || (this.getOption_('axisLabelFontSize') + 2 * this.getOption_('axisTickSize'));
+  
+  var xAxisLabelHeight = 0;
+  if(this.getOption_('drawXAxis')){
+    xAxisLabelHeight = this.getOption_('xAxisHeight') || (this.getOption_('axisLabelFontSize') + 2 * this.getOption_('axisTickSize'));
+  }
   this.canvasRect_ = {
     x: plotArea.x,
     y: plotArea.y + plotArea.h + xAxisLabelHeight + 4,