如何“静态化”一行,使其不可交互?

huangapple go评论77阅读模式
英文:

How to "statify" a line so that it is not interactive?

问题

我有一个图表,其中有一条样条线。每当我接近这条线时,它就会变成“活动的”并显示其数据点。

我想要使其成为非交互式(静态),只显示线而不可选择。我查看了spline可用属性,但似乎没有一个匹配。

这样的行为是否可能?或者在Highcharts中每个元素都必须是可交互的吗?

英文:

I have a chart that has one spline. Whenever I approach this line, it becomes "active" and displays its points.

I would like to make it non-interactive (static) - so that just the line is displayed and otherwise not selectable. I had a look at the available properties for the spline but none seem to match.

Is such behaviour possible? Or does each element have to be interactive in Highcharts?

答案1

得分: 1

你需要寻找 enableMouseTracking 属性,需要在你的情况下禁用它。

series: [{
    type: 'spline',
    enableMouseTracking: false,
    ...
}]

在线演示: http://jsfiddle.net/BlackLabel/1yb3L7an/

API 参考: https://api.highcharts.com/highcharts/series.spline.enableMouseTracking

英文:

You are looking for the enableMouseTracking property, which needs to be disabled in your case.

  series: [{
    type: 'spline',
    enableMouseTracking: false,
    ...
  }]

Live demo: http://jsfiddle.net/BlackLabel/1yb3L7an/

API Reference: https://api.highcharts.com/highcharts/series.spline.enableMouseTracking

huangapple
  • 本文由 发表于 2023年5月23日 00:34:14
  • 转载请务必保留本文链接:https://go.coder-hub.com/76308250.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定