SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and iOS Chart & Android Chart Components

1
0

If you set limit on range of axis, the pinch gesture will not work correctly.
Pinch the chart and hold for a while (about less than 1 sec), the chart will resize to the limit value you set on the axis.

You can change code of OscilloscopeFragment.java#106 in Examples to below to reproduce this problem.

final IAxis xBottomAxis = sciChartBuilder.newNumericAxis()
                    .withAutoRangeMode(AutoRange.Never)
                    .withAxisTitle("Time (ms)")
                    .withVisibleRange(new DoubleRange(2.5, 4.5))
                    .withVisibleRangeLimit(0,20)   // this will help reproduce the problem
                    .build();
Version
2.2.2.2424
  • Yura Khariton
    Hi Zhengyang. I’m sorry I don’t understand how to reproduce this issue. I tried to add code you provided and use pinch zoom in Oscilloscope example and I didn’t see anything. Can you provide more detailed steps how to reproduce this issue? Thanks in advance.
  • zhengyang qu
    Use pinch gesture to zoom the chart and don’t let your finger leave, after about 1 second, the chart will resize to its limited range. Sorry for my broken English.
  • You must to post comments
0
0
  • You must to post comments
0
0

How can I apply this to the default modifier group? I tried using builder to build a modifier group with code below:

SciChartBuilder.instance().newModifierGroup()
            .withZoomPanModifier().build()
            .withPinchZoomModifier().withIsUniformZoom(true).build()
            .withZoomExtentsModifier().build()
            .build()

Bug of PinchZoom modifier seems gone, but the ZoomPan modifier is not working now.

  • You must to post comments
0
0

Default modifier group is created using next code:

 public ModifierGroupBuilder newModifierGroupWithDefaultModifiers() {
    return newModifierGroup()
            .withPinchZoomModifier().build()
            .withZoomPanModifier().withReceiveHandledEvents(true).build()
            .withZoomExtentsModifier().build();
}

I tried to use this code as base and added uniform zoom for PinchZoomModifier and it worked for me – all 3 modifiers work as expected.

 Collections.addAll(surface.getChartModifiers(), sciChartBuilder.newModifierGroup()
                    .withPinchZoomModifier().withIsUniformZoom(true).build()
                    .withZoomPanModifier().withReceiveHandledEvents(true).build()
                    .withZoomExtentsModifier().build()
                    .build());

Best regards,
Yura

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.