Commit 07c8f886 authored by Mathieu Giraud's avatar Mathieu Giraud
Browse files

js/scatterPlot.js: minimal height for bar plots

See #2304.
parent fc760c4f
......@@ -918,11 +918,16 @@ ScatterPlot.prototype = {
if ( (!this.m.clone(cloneID).isVirtual()) & this.m.clone(cloneID).isActive() ) {
height = this.m.clone(cloneID).getSize()/bar_max;
}
// Minimal height (does not affect y_pos)
var height_for_display = Math.max(height, 0.01)
var y_pos_for_display = y_pos + height_for_display ;
y_pos += height;
this.nodes[cloneID].bar_y = y_pos;
this.nodes[cloneID].bar_y = y_pos_for_display;
this.nodes[cloneID].bar_x = x_pos;
this.nodes[cloneID].bar_h = height;
this.nodes[cloneID].bar_h = height_for_display;
this.nodes[cloneID].bar_w = width;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment