5dc51439a861d1cf4e7f6946c7b6317be3ef03b5 hiram Wed Nov 11 22:41:17 2020 -0800 replace word mean with greek letter mu, much less space used refs #21980 diff --git src/hg/js/hgTracks.js src/hg/js/hgTracks.js index d0e7511..f13a7fb 100644 --- src/hg/js/hgTracks.js +++ src/hg/js/hgTracks.js @@ -4615,31 +4615,31 @@ // LEFTADD. var graphOffset = Math.max(0, clientX - tdLeft - 3); if (hgTracks.revCmplDisp) { graphOffset = Math.max(0, rightSide - clientX); } var windowUp = false; // see if window is supposed to become visible var foundIdx = -1; if (mouseOver.spans[trackName]) { foundIdx = mouseOver.findRange(graphOffset, mouseOver.spans[trackName]); } // can show 'no data' when not found var mouseOverValue = "no data"; if (foundIdx > -1) { // value to display if (mouseOver.spans[trackName][foundIdx].c > 1) { - mouseOverValue = " mean: " + mouseOver.spans[trackName][foundIdx].v + " "; + mouseOverValue = " μ " + mouseOver.spans[trackName][foundIdx].v + " "; } else { mouseOverValue = " " + mouseOver.spans[trackName][foundIdx].v + " "; } } $('#mouseOverText').html(mouseOverValue); var msgWidth = mouseOver.maximumWidth[trackName]; $('#mouseOverText').width(msgWidth); var msgHeight = Math.ceil($('#mouseOverText').height()); var lineHeight = Math.max(0, tdHeight - msgHeight); var lineTop = Math.max(0, tdTop + msgHeight); var msgLeft = Math.max(0, clientX - (msgWidth/2) - 3); // with magic 3 var lineLeft = Math.max(0, clientX - 3); // with magic 3 $('#mouseOverText').css('fontSize',mouseOver.browserTextSize); $('#mouseOverText').css('left',msgLeft + "px"); $('#mouseOverText').css('top',tdTop + "px"); @@ -4730,31 +4730,31 @@ var longestNumber = 0; var hasMean = false; for (var span in arr[trackName]) { if (arr[trackName][span].c > 1) { hasMean = true; } var lenV = arr[trackName][span].v.toString().length; if (lenV > lengthLongestNumberString) { lengthLongestNumberString = lenV; longestNumber = arr[trackName][span].v; } mouseOver.spans[trackName].push(arr[trackName][span]); ++itemCount; } mouseOver.tracks[trackName] = itemCount; // merely for debugging watch var mouseOverValue = ""; if (hasMean) { - mouseOverValue = " mean: " + longestNumber + " "; + mouseOverValue = " μ " + longestNumber + " "; } else { mouseOverValue = " " + longestNumber + " "; } $('#mouseOverText').html(mouseOverValue); // see how big as rendered $('#mouseOverText').css('fontSize',mouseOver.browserTextSize); var maximumWidth = Math.ceil($('#mouseOverText').width()); $('#mouseOverText').html("no data"); // might be bigger if (Math.ceil($('#mouseOverText').width() > maximumWidth)) { maximumWidth = Math.ceil($('#mouseOverText').width()); } mouseOver.maximumWidth[trackName] = maximumWidth; } }, // receiveData: function (arr) failedRequest: function(trackName)