1
- // https://root.cern/js/ v7.0.0
1
+ // https://root.cern/js/ v7.0.1
2
2
(function (global, factory) {
3
3
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
4
4
typeof define === 'function' && define.amd ? define(['exports'], factory) :
@@ -7,11 +7,11 @@ typeof define === 'function' && define.amd ? define(['exports'], factory) :
7
7
8
8
/** @summary version id
9
9
* @desc For the JSROOT release the string in format "major.minor.patch" like "6.3.0" */
10
- let version_id = "7.0.x ";
10
+ let version_id = "7.0.1 ";
11
11
12
12
/** @summary version date
13
13
* @desc Release date in format day/month/year like "19/11/2021" */
14
- let version_date = "19 /04/2022";
14
+ let version_date = "21 /04/2022";
15
15
16
16
/** @summary version id and date
17
17
* @desc Produced by concatenation of {@link version_id} and {@link version_date}
@@ -11255,7 +11255,7 @@ class ObjectPainter extends BasePainter {
11255
11255
font_size = font.size, any_text = false, only_text = true;
11256
11256
11257
11257
if ((f > 0) && ((f < 0.9) || (f > 1)))
11258
- font.size = Math.floor(font.size / f);
11258
+ font.size = Math.max(1, Math. floor(font.size / f) );
11259
11259
11260
11260
if (max_sz && (font.size > max_sz))
11261
11261
font.size = max_sz;
@@ -45121,8 +45121,9 @@ class TAxisPainter extends ObjectPainter {
45121
45121
formatLabels(d) {
45122
45122
let indx = parseFloat(d), a = this.getObject();
45123
45123
if (!this.regular_labels)
45124
- indx = (indx - a.fXmin)/(a.fXmax - a.fXmin) * a.fNbins;
45125
- indx = Math.floor(indx);
45124
+ indx = Math.round((indx - a.fXmin)/(a.fXmax - a.fXmin) * a.fNbins);
45125
+ else
45126
+ indx = Math.floor(indx);
45126
45127
if ((indx < 0) || (indx >= a.fNbins)) return null;
45127
45128
for (let i = 0; i < a.fLabels.arr.length; ++i) {
45128
45129
let tstr = a.fLabels.arr[i];
@@ -45488,12 +45489,12 @@ class TAxisPainter extends ObjectPainter {
45488
45489
textscale = Math.min(textscale, (max_text_width - labeloffset) / textwidth);
45489
45490
}
45490
45491
45491
- if ((textscale > 0.01 ) && (textscale < 0.7) && !painter.vertical && !rotate_lbls && (maxtextlen > 5) && (label_g.length == 1))
45492
+ if ((textscale > 0.0001 ) && (textscale < 0.7) && !painter.vertical && !rotate_lbls && (maxtextlen > 5) && (label_g.length == 1))
45492
45493
lbl_tilt = true;
45493
45494
45494
45495
let scale = textscale * (lbl_tilt ? 3 : 1);
45495
45496
45496
- if ((scale > 0.01 ) && (scale < 1)) {
45497
+ if ((scale > 0.0001 ) && (scale < 1)) {
45497
45498
applied_scale = 1/scale;
45498
45499
painter.scaleTextDrawing(applied_scale, label_g[0]);
45499
45500
}
@@ -45698,7 +45699,7 @@ class TAxisPainter extends ObjectPainter {
45698
45699
labelMaxWidth = arr[1];
45699
45700
45700
45701
if (settings.Zooming && !this.disable_zooming && !isBatchMode()) {
45701
- let labelSize = arr[0],
45702
+ let labelSize = Math.max( arr[0], 5) ,
45702
45703
r = axis_g.append("svg:rect")
45703
45704
.attr("class", "axis_zoom")
45704
45705
.style("opacity", "0")
@@ -96230,11 +96231,11 @@ class RAxisPainter extends RObjectPainter {
96230
96231
textscale = Math.min(textscale, maxwidth / textwidth);
96231
96232
}
96232
96233
96233
- if ((textscale > 0.01 ) && (textscale < 0.8) && !painter.vertical && !rotate_lbls && (maxtextlen > 5) && (side > 0))
96234
+ if ((textscale > 0.0001 ) && (textscale < 0.8) && !painter.vertical && !rotate_lbls && (maxtextlen > 5) && (side > 0))
96234
96235
lbls_tilt = true;
96235
96236
96236
96237
let scale = textscale * (lbls_tilt ? 3 : 1);
96237
- if ((scale > 0.01 ) && (scale < 1))
96238
+ if ((scale > 0.0001 ) && (scale < 1))
96238
96239
painter.scaleTextDrawing(1/scale, label_g);
96239
96240
}
96240
96241
0 commit comments