Skip to content

Commit 08c9b62

Browse files
committed
Fix - properly create TScatter histogram
Set x/y range only when histogram not exists before
1 parent df99daa commit 08c9b62

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/hist2d/TScatterPainter.mjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ class TScatterPainter extends TGraphPainter {
2323
/** @summary Draw axis histogram
2424
* @private */
2525
async drawAxisHisto() {
26-
const histo = this.createHistogram();
26+
const need_histo = !this.getHistogram(),
27+
histo = this.createHistogram(need_histo, need_histo);
2728
return TH2Painter.draw(this.getDrawDom(), histo, this.options.Axis + ';IGNORE_PALETTE');
2829
}
2930

0 commit comments

Comments
 (0)