Flex 图表:仅显示特定系列的数据提示? [英] Flex Charting: Only display datatip for specific series?
问题描述
我有一个包含多个系列的 LineChart
,包括 LineSeries
和 PlotSeries
,并且我有一个自定义的 dataTipFunction
设置图表.但是,我只希望为线系列显示数据提示,而不是为绘图系列显示数据提示.我试过从我的格式函数返回 null
,但这只是显示一个空框.我还尝试在情节系列上禁用鼠标事件(通过将 mouseEnabled
和 mouseFocusEnabled
设置为 false
),但无济于事.这甚至可能吗?
I have a LineChart
that contains multiple series, both LineSeries
and PlotSeries
, and I have a custom dataTipFunction
set for the chart. However, I only want data tips displayed for line series, not the plot series. I have tried returning null
from my format function, but that just displays an empty box. I have also tried disable mouse events on the plot series (by setting both mouseEnabled
and mouseFocusEnabled
to false
), to no avail. Is this even possible?
推荐答案
您可以将 *Series 的 interactive
属性设置为 false
You can set the interactive
property of a *Series to false
<mx:series>
<mx:LineSeries yField="Profit" form="curve" displayName="Profit"/>
<mx:LineSeries yField="Expenses" form="curve" displayName="Expenses"/>
<mx:LineSeries yField="Amount" form="curve" displayName="Amount"/>
<mx:PlotSeries yField="Amount" interactive="false"/>
</mx:series>
这篇关于Flex 图表:仅显示特定系列的数据提示?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!