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

Answered
0
0

Hi,

I set up my xAxis (DateAxis) with a minimalZoomConstrain = DateInterval.fromMinutes(3.0). And here is my PinchZoomModifier:

val pinchZoomModifier = PinchZoomModifier().apply {
        direction = Direction2D.XDirection
        receiveHandledEvents = true
    }

The chart works great and restricts the zoom to three minutes, but I get this error to the console whenever I zoom in to reach the minimalZoomConstrain:

E/Axis: VisibleRange was restored to its last valid value. The range class com.scichart.data.model.DateRange (Min = Tue Jan 09 01:52:40 GMT+01:00 2020, Max = Tue Jan 09 01:55:40 GMT+01:00 2020) either is not valid or it doesn't satisfy MinimalZoomConstrain or MaximumZoomConstrain. To provide fallback value please override AxisCore#coerceVisibleRange(IRange) method

How can I get rid of this error? Is there a way to tell the PinchZoomModifier that there is a min limit?

Version
3.1.0.4322
  • You must to post comments
Best Answer
0
0

Hi Erika,

We don’t have an API to set separate constraint for zoom depth in PinchZoomModifier. I believe this is how it should work in case of MinimalZoomConstrain and you can just ignore this message for now ( I think I’m going to create a task to remove this message when VisibleRange doesn’t satisfy this constaint) . Also you can create custom axis and override coerceVisibleRange() method like message suggests and adjust VisibleRange so it will satisfy MinimalZoomConstrain.

Best regards,
Yura

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.