Hi,
in a MVVM scenario, I bind the AnimatedVisibleRange to a property in the view model.
<s:SciChartSurface SeriesSource="{Binding ChartSeries}">
<s:SciChartSurface.XAxis>
<s:NumericAxis AxisTitle="x" AnimatedVisibleRange="{Binding XVisibleRange, Mode=TwoWay}" AutoRange="Never" />
</s:SciChartSurface.XAxis>
<s:SciChartSurface.YAxis>
<s:NumericAxis AxisTitle="y" AnimatedVisibleRange="{Binding YVisibleRange, Mode=TwoWay}" AutoRange="Never" />
</s:SciChartSurface.YAxis>
<s:SciChartSurface.ChartModifier>
<s:ModifierGroup>
<s:MouseWheelZoomModifier IsEnabled="True" XyDirection="XDirection"/>
</s:ModifierGroup>
</s:SciChartSurface.ChartModifier>
</s:SciChartSurface>
Setting the XVisibleRange property in the view model smoothly animates the view. However, when I zoom in the chart with the mouse wheel, the view model property receives no updates (so the XVisibleRange property in the view model always stays on the value initially set by the view model).
The same thing works when I bind he VisibleRange instead of the AnimatedVisibleRange, i.e. in that case I get an update of the view model property on every mouse wheel zoom.
Is this intendend, or a bug? Building a workaround would require additional bindings, which I would like to avoid.
Best regards,
Andree
- Andree Grosse asked 9 years ago
- last active 9 years ago
Hello,
Currently I am using ViewportManager.AnimateZoomExtents to animate the data to fit the size of the graph. However, the animation causes the data to reach the very edge (X-Axis Max and Y-Axis Max). Is there a way that I can use AnimateZoomExtents to animate the data out but leave a 10% gap between the edge and X-Axis/Y-Axis Max?
I was able to do this using the following code, but I lose complete animation (which is what I’m looking for).
AxisYVisibleRange = new DoubleRange(AxisYVisibleRange.Min, AxisYVisibleRange.Max + (AxisYVisibleRange.Max * .10))
ViewportManager.AnimateZoomExtents(AnimateZoomTimeSpan);
- Daniel Moncada asked 7 years ago
- last active 7 years ago
Hi,
I’m working on the iOS and android version. I’m trying to implemented an animated visible range change on Y axis when zooming/panning X axis.
On iOS, I just have to do:
yAxis.autoRange = .always
yAxis.animateVisibleRangeChanges = true
yAxis.animatedChangeDuration = 0.5
But I can’t find a way to do that on Android, is it hidden somewhere else?
Kind Regards,
Alexis
- Alexis Durand asked 6 years ago
- last active 6 years ago
Hello
I have animated line renderable series – when new point added, whole x-axes moves to the right a little.
Everything is smooth until pinch zoom appears.
I think it’s conflict with animated viewport move and zooming.
Is there a way to know, when zooming appears?
E.g. if i know, when zoom started and finished – i can solve this.
Thanks
- Kirey Vadim asked 5 years ago
- last active 5 years ago