I use VerticallStackedAxes of SciChart component and add 7 AxisMarkerAnnotation to each NumericAxis but AxisMarkerAnnotations not draggable except first of them.
this is the part of my UserControl code:
<s:SciChartSurface.YAxes>
</s:SciChartSurface.YAxes>
<s:SciChartSurface.ChartModifier>
<s:ModifierGroup>
<s:RubberBandXyZoomModifier IsXAxisOnly="True"/>
<s:ZoomExtentsModifier/>
<s:CursorModifier ShowAxisLabels="False" ShowTooltip="False"/>
</s:ModifierGroup>
</s:SciChartSurface.ChartModifier>
<s:SciChartSurface.Annotations>
<!-- Draws Bands behind each axis -->
<s:BoxAnnotation YAxisId="Ch0" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch0}" Y2="{Binding VisibleRange.Max, ElementName=Ch0}" Background="#11000000" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch1" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch1}" Y2="{Binding VisibleRange.Max, ElementName=Ch1}" Background="#44B0C4DE" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch2" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch2}" Y2="{Binding VisibleRange.Max, ElementName=Ch2}" Background="#11000000" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch3" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch3}" Y2="{Binding VisibleRange.Max, ElementName=Ch3}" Background="#44B0C4DE" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch4" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch4}" Y2="{Binding VisibleRange.Max, ElementName=Ch4}" Background="#11000000" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch5" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch5}" Y2="{Binding VisibleRange.Max, ElementName=Ch5}" Background="#44B0C4DE" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch6" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch6}" Y2="{Binding VisibleRange.Max, ElementName=Ch6}" Background="#11000000" AnnotationCanvas="BelowChart"/>
<s:BoxAnnotation YAxisId="Ch7" CoordinateMode="RelativeX" X1="0" X2="1" Y1="{Binding VisibleRange.Min, ElementName=Ch7}" Y2="{Binding VisibleRange.Max, ElementName=Ch7}" Background="#44B0C4DE" AnnotationCanvas="BelowChart"/>
<s:AxisMarkerAnnotation X1="0.0"
Y1="0.0"
YAxisId="Ch0"
IsEditable="True"
LabelTemplate="{StaticResource AxisMarkerTemplate}"
PointerTemplate="{StaticResource DefaultAxisPointerTemplate}"/>
<s:AxisMarkerAnnotation X1="0.0"
Y1="0.0"
YAxisId="Ch1"
IsEditable="True"
LabelTemplate="{StaticResource AxisMarkerTemplate}"
PointerTemplate="{StaticResource DefaultAxisPointerTemplate}"/>
</s:SciChartSurface.Annotations>
You can find source code Here
thanks
- jack forest asked 7 years ago
- You must login to post comments
Please login first to submit.