Knowledgebase
Changing Z-Order of RenderableSeries
Posted by Admin - on 07 February 2019 02:53 PM

The order that RenderableSeries appear in the SciChartSurface.RenderableSeries collection defines the Z Order, e.g. series defined earlier in the collection appear at the bottom, and series defined later appear at the top.

The exception to this rule is StackedRenderableSeries, where the Z Order is reversed. Also, a selected RenderableSeries (set RenderableSeries.IsSelected = True) is always pushed to the top of the Z Order.
 
<!-- Example 1: Standard RenderableSeries ZOrder -->
<s:ScichartSurface>
	<s:SciChartSurface.RenderableSeries>
       <s:FastLineRenderableSeries/> 	<!-- Lowest ZIndex -->
		<s:FastLineRenderableSeries/> 
       <s:FastLineRenderableSeries/> 	<!-- Highest ZIndex -->
	</s:SciChartSurface.RenderableSeries>
</s:SciChartSurface>

<!-- Example 2: Selected RenderableSeries ZOrder -->
<!-- The ZOrder is changed to highest for selected series -->
<s:ScichartSurface>
	<s:SciChartSurface.RenderableSeries>
       <s:FastLineRenderableSeries IsSelected="True"/>  <!-- Highest ZIndex -->
		<s:FastLineRenderableSeries/> 					<!-- Lowest ZIndex -->
       <s:FastLineRenderableSeries/> 
	</s:SciChartSurface.RenderableSeries>
</s:SciChartSurface>

<!-- Example 3: Stacked RenderableSeries ZOrder -->
<s:ScichartSurface>
	<SciChart:SciChartSurface.RenderableSeries>
		<SciChart:StackedColumnRenderableSeries/> <!-- Highest ZIndex -->
		<SciChart:StackedColumnRenderableSeries/>
		<SciChart:StackedColumnRenderableSeries/> <!-- Lowest ZIndex -->
	</SciChart:SciChartSurface.RenderableSeries>
</s:SciChartSurface>
 
To learn more about Series Selection in SciChart, please refer to the Series Selection documentation article. A demo of how Series Selection works can be found in SciChart Examples Suite at Tooltips and HitTest -> Chart Series Selection. The source code for the example can be found at this link.
(3 vote(s))
Helpful
Not helpful

CONTACT US

Not sure where to start? Contact us, we are happy to help!


CONTACT US

SciChart Ltd, 16 Beaufort Court, Admirals Way, Docklands, London, E14 9XL. Email: Legal Company Number: 07430048, VAT Number: 101957725