我想为每种样式设置标记设置。我想为“style1”显示标记,我不想为“style2”显示它们。
这是我当前的 XML 示例数据:
<?xml version = "1.0" encoding="utf-8" standalone = "yes"?>
<anychart>
<settings>
<animation enabled="false"/>
<no_data show_waiting_animation="False">
<label>
<text></text>
<font family="Verdana" bold="yes" size="10"/>
</label>
</no_data>
</settings>
<margin left="0" top="" right="0" bottom="0" />
<charts>
<chart plot_type="CategorizedVertical" name="chart_1295609758644867">
<styles>
<line_style name="style1">
<line enabled="true" thickness="5" opacity="1" />
</line_style>
<line_style name="style2">
<line dashed="True" dash_length="2" space_length="5" color="red"/>
</line_style>
</styles>
<chart_settings>
<title enabled="False" />
<chart_background>
<fill type="Solid" color="0xffffff" opacity="0" />
<border enabled="false"/>
<corners type="Square"/>
</chart_background>
<data_plot_background>
</data_plot_background>
<axes>
<y_axis >
</y_axis>
<x_axis>
</x_axis>
</axes>
<legend enabled="true" position="Right" align="Near" elements_layout="Vertical"
</legend>
</chart_settings>
<data_plot_settings enable_3d_mode="false" default_series_type="Line">
<line_series style="style1">
<tooltip_settings enabled="true">
<format><![CDATA[{%Name}{enabled:False} - {%Value}{numDecimals:1,decimalSeparator:\,,thousandsSeparator:.}]]></format>
<font family="Tahoma" size="10" color="0x000000" />
<position anchor="Float" valign="Top" padding="10" />
</tooltip_settings>
<label_settings enabled="false" mode="Outside" multi_line_align="Center">
<format><![CDATA[{%Value}{numDecimals:1,decimalSeparator:\,,thousandsSeparator:.}]]></format>
<background enabled="false"/>
<font family="Arial" size="10" color="0x000000" />
</label_settings>
<line_style>
<line enabled="true" thickness="5" opacity="1" />
</line_style>
<marker_settings enabled="True" >
<marker type="Circle" />
</marker_settings>
</line_series>
<line_series style="style2">
<marker_settings enabled="False" />
</line_series>
</data_plot_settings>
<data>
<series name="A" style="style1">
<point name="01.01.2014" y="1"/>
<point name="02.01.2014" y="1"/>
<point name="03.01.2014" y="1"/>
</series>
<series name="B" style="style2">
<point name="01.01.2014" y="2"/>
<point name="02.01.2014" y="2"/>
<point name="03.01.2014" y="2"/>
</series>
</data>
</chart>
</charts>
</anychart>
(注意:我删除了“axes”和“legend”标签之间的一些细节,以使代码部分更小)
这是一个为样式设置标记的示例:http: //anychart.com/products/anychart/ docs/users-guide/Samples/sample-simple-style-for-line-chart.html#xml-code
在我的图表中,它显示每个系列的标记,无论是什么风格。(或者如果我将这个“marker_settings enabled="False"”放在“line_series style="style1"”-tag 中,则根本没有标记)。
有人能帮忙吗?
在此先感谢,
托马斯