public class PinchZoomModifier extends ScaleModifierBase
PinchZoomModifier
provides zooming of the SciChartSurface
with the pinch gesture.Constructor and Description |
---|
PinchZoomModifier() |
Modifier and Type | Method and Description |
---|---|
Direction2D |
getDirection()
Gets the
Direction2D to restrict zoom interactivity to. |
boolean |
getIsUniformZoom()
Sets the value which indicates whether uniform zoom should be used by this modifier.
|
float |
getScaleFactor()
Gets the scale factor to scale (or shrink) both axes on pinch gesture.
|
boolean |
onScale(android.view.ScaleGestureDetector detector) |
boolean |
onScaleBegin(android.view.ScaleGestureDetector detector) |
void |
onScaleEnd(android.view.ScaleGestureDetector detector) |
protected void |
performZoom(android.graphics.PointF point,
double xValue,
double yValue)
Performs a zoom around the passed in point by the specified X and Y factor
|
void |
setDirection(Direction2D direction)
Sets the
Direction2D to restrict zoom interactivity to. |
void |
setIsUniformZoom(boolean isUniformZoom)
Sets the value which indicates whether uniform zoom should be used by this modifier
|
void |
setScaleFactor(float scaleFactor)
Sets the scale factor to scale (or shrink) both axes on pinch gesture.
|
attachTo, detach, onTouch
applyThemeProvider, getContext, getEventsGroupTag, getIsEnabled, getMasterModifier, getModifierSurface, getParentSurface, getPointRelativeTo, getReceiveHandledEvents, getRenderableSeries, getRenderableSeriesArea, getServices, getXAxes, getXAxis, getXAxis, getYAxes, getYAxis, getYAxis, isAttached, isWithinSourceBounds, onAnnotationsCollectionChanged, onAnnotationsDrasticallyChanged, onGenericMotion, onIsEnabledChanged, onParentSurfaceResized, onRenderableSeriesCollectionChanged, onRenderableSeriesDrasticallyChanged, onRenderSurfaceRendered, onSelectedSeriesCollectionChanged, onXAxesCollectionChanged, onXAxesDrasticallyChanged, onYAxesCollectionChanged, onYAxesDrasticallyChanged, setEventsGroupTag, setIsEnabled, setReceiveHandledEvents
public final float getScaleFactor()
public final void setScaleFactor(float scaleFactor)
scaleFactor
- The scale factor to scale (or shrink) both axes on pinch gesture.public final Direction2D getDirection()
Direction2D
to restrict zoom interactivity to.Direction2D
to restrict zoom interactivity to.public final void setDirection(Direction2D direction)
Direction2D
to restrict zoom interactivity to.direction
- The new Direction2D
to restrict zoom interactivity to.public final void setIsUniformZoom(boolean isUniformZoom)
When uniform zoom is set to true then modifier applies same scale factor for both x and y direction, otherwise scale factor calculated separately for x and y direction based on information from touch events
isUniformZoom
- The new isUniformZoom
valuepublic final boolean getIsUniformZoom()
When uniform zoom is set to true then modifier applies same scale factor for both x and y direction, otherwise scale factor calculated separately for x and y direction based on information from touch events
isUniformZoom
valuepublic boolean onScaleBegin(android.view.ScaleGestureDetector detector)
public boolean onScale(android.view.ScaleGestureDetector detector)
public void onScaleEnd(android.view.ScaleGestureDetector detector)
protected void performZoom(android.graphics.PointF point, double xValue, double yValue)
point
- The point to perform zoom around.xValue
- The x zoom factor.yValue
- The y zoom factor.