JustinPierce
Posts: 1
Joined: Thu Nov 10, 2011 6:24 pm

Highcharts 2.1.7 and hideTooltipOnMouseMove

Today I had to chase down a tooltip issue that cropped up after upgrading to Highcharts 2.1.7. The problem was that our calls to tooltip.refresh() to manually display a tooltip were no longer working correctly. My adventure eventually led me to the hideTooltipOnMouseMove() function in the bowels of Highcharts, which was introduced in 2.1.7. This function, as its name hints, hides the tooltip when you move the mouse outside the plot area.

The problem is that we are showing the tooltip using events generated by HTML elements that are in a table outside the plot. The refresh() function still works to show the tooltip (I can see it in the script debugger), but the hideTooltipOnMouseMove() immediately hides it. Obviously, when interacting with the chart via HTML elements, the mouse will always be outside the plot.

I was able to solve the problem in the short term by modifying hideTooltipOnMouseMove() to allow me to disable it with a tooltip option. However, I don't think it's unreasonable to have Highcharts support this behavior by default in the future.

Return to “Highcharts Usage”