为选定的列高亮显示不同的颜色 [英] highcharts different colors for selected columns
问题描述
是否可以在高图中为不同的选定列设置不同的颜色?
下面是我试图做的草图: http://jsfiddle.net/jZmYW/4/
当选择一个点(列)它应该得到一个特定的颜色。我试图通过为选定点设置新数据来实现这一点。
在视觉上它导致了预期的结果,但带有一个JS错误:Uncaught TypeError:对象#的属性'setState'不是一个函数。
我也尝试将功能应用于系列(在那里设置新数据)。这在JS错误稍微不同的情况下给出了非常相似的结果:未捕获的TypeError:对象#的属性'firePointEvent'不是函数。
任何想法?
可以通过为每个系列定义特定的选择状态来解决问题,请参阅 http://jsfiddle.net/jZmYW/5/
感谢highcharts支持团队在这里提供帮助。
Is it possible to have different colors for different selected columns in highcharts?
Here's a sketch for what I'm trying to do: http://jsfiddle.net/jZmYW/4/
When selecting a point (column) it should get a specific color. I try to achieve that with setting new data for the selected point. Visually it leads to the expected result but comes with a JS-error: "Uncaught TypeError: Property 'setState' of object # is not a function".
I also tried to apply the functionality to the series (with setting new data there). That gives a quite similar result where the JS-error is slightly different: "Uncaught TypeError: Property 'firePointEvent' of object # is not a function".
Any ideas?
The problem can be solved by defining a specific select state for each series, see http://jsfiddle.net/jZmYW/5/
Thanks to the highcharts support team for helping here.
这篇关于为选定的列高亮显示不同的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!