# ScrollerCompat

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  
belongs to Maven artifact com.android.support:support-compat:28.0.0-alpha1  
Deprecated since version 26.1.0  
Summary:[Methods](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#pubmethods)\|[Inherited Methods](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#inhmethods)\|[\[Expand All\]](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#)  

# ScrollerCompat

| This package is part of the Android[support library](https://developer.android.com/topic/libraries/support-library)which is no longer maintained. The support library has been superseded by[AndroidX](https://developer.android.com/jetpack/androidx)which is part of[Jetpack](https://developer.android.com/jetpack). We recommend using the AndroidX libraries in all new projects. You should also consider[migrating](https://developer.android.com/jetpack/androidx/migrate)existing projects to AndroidX. To find the AndroidX class that maps to this deprecated class, see the AndroidX support library[class mappings](https://developer.android.com/jetpack/androidx/migrate/class-mappings).

`
public

final

class
ScrollerCompat
`  
`

extends Object


``


`

|---|------------------------------------------|
| java.lang.Object                            ||
| ↳ | android.support.v4.widget.ScrollerCompat |

<br />

*** ** * ** ***

<br />

**This class was deprecated in API level 26.1.0.**   
Use[OverScroller](https://developer.android.com/reference/android/widget/OverScroller.html)directly.

Provides access to new[Scroller](https://developer.android.com/reference/android/widget/Scroller.html)APIs when available.

This class provides a platform version-independent mechanism for obeying the current device's preferred scroll physics and fling behavior. It offers a subset of the APIs from Scroller or OverScroller.

<br />

## Summary

|                                                                                                                                                                                                                                                                                                                         ### Public methods                                                                                                                                                                                                                                                                                                                         ||
|--------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ` void`                                                                                                      | ` `[abortAnimation](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#abortAnimation())`() ` *This method was deprecated in API level 26.1.0. Use[abortAnimation()](https://developer.android.com/reference/android/widget/OverScroller.html#abortAnimation())directly.*                                                                                                                                                                                                                                              |
| ` boolean`                                                                                                   | ` `[computeScrollOffset](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#computeScrollOffset())`() ` *This method was deprecated in API level 26.1.0. Use[computeScrollOffset()](https://developer.android.com/reference/android/widget/OverScroller.html#computeScrollOffset())directly.*                                                                                                                                                                                                                          |
| ` static `[ScrollerCompat](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat) | ` `[create](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#create(android.content.Context, android.view.animation.Interpolator))`(`[Context](https://developer.android.com/reference/android/content/Context.html)` context, `[Interpolator](https://developer.android.com/reference/android/view/animation/Interpolator.html)` interpolator) ` *This method was deprecated in API level 26.1.0. Use[OverScroller](https://developer.android.com/reference/android/widget/OverScroller.html)constructor directly.* |
| ` static `[ScrollerCompat](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat) | ` `[create](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#create(android.content.Context))`(`[Context](https://developer.android.com/reference/android/content/Context.html)` context) ` *This method was deprecated in API level 26.1.0. Use[OverScroller](https://developer.android.com/reference/android/widget/OverScroller.html)constructor directly.*                                                                                                                                                       |
| ` void`                                                                                                      | ` `[fling](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#fling(int, int, int, int, int, int, int, int))`(int startX, int startY, int velocityX, int velocityY, int minX, int maxX, int minY, int maxY) ` *This method was deprecated in API level 26.1.0. Use[fling(int, int, int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#fling(int, int, int, int, int, int, int, int))directly.*                                                                    |
| ` void`                                                                                                      | ` `[fling](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#fling(int, int, int, int, int, int, int, int, int, int))`(int startX, int startY, int velocityX, int velocityY, int minX, int maxX, int minY, int maxY, int overX, int overY) ` *This method was deprecated in API level 26.1.0. Use[fling(int, int, int, int, int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#fling(int, int, int, int, int, int, int, int, int, int))directly.*                |
| ` float`                                                                                                     | ` `[getCurrVelocity](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#getCurrVelocity())`() ` *This method was deprecated in API level 26.1.0. Use[getCurrVelocity()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrVelocity())directly.*                                                                                                                                                                                                                                          |
| ` int`                                                                                                       | ` `[getCurrX](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#getCurrX())`() ` *This method was deprecated in API level 26.1.0. Use[getCurrX()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrX())directly.*                                                                                                                                                                                                                                                                      |
| ` int`                                                                                                       | ` `[getCurrY](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#getCurrY())`() ` *This method was deprecated in API level 26.1.0. Use[getCurrY()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrY())directly.*                                                                                                                                                                                                                                                                      |
| ` int`                                                                                                       | ` `[getFinalX](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#getFinalX())`() ` *This method was deprecated in API level 26.1.0. Use[getFinalX()](https://developer.android.com/reference/android/widget/OverScroller.html#getFinalX())directly.*                                                                                                                                                                                                                                                                  |
| ` int`                                                                                                       | ` `[getFinalY](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#getFinalY())`() ` *This method was deprecated in API level 26.1.0. Use[getFinalY()](https://developer.android.com/reference/android/widget/OverScroller.html#getFinalY())directly.*                                                                                                                                                                                                                                                                  |
| ` boolean`                                                                                                   | ` `[isFinished](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#isFinished())`() ` *This method was deprecated in API level 26.1.0. Use[isFinished()](https://developer.android.com/reference/android/widget/OverScroller.html#isFinished())directly.*                                                                                                                                                                                                                                                              |
| ` boolean`                                                                                                   | ` `[isOverScrolled](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#isOverScrolled())`() ` *This method was deprecated in API level 26.1.0. Use[isOverScrolled()](https://developer.android.com/reference/android/widget/OverScroller.html#isOverScrolled())directly.*                                                                                                                                                                                                                                              |
| ` void`                                                                                                      | ` `[notifyHorizontalEdgeReached](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#notifyHorizontalEdgeReached(int, int, int))`(int startX, int finalX, int overX) ` *This method was deprecated in API level 26.1.0. Use[notifyHorizontalEdgeReached(int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#notifyHorizontalEdgeReached(int, int, int))directly.*                                                                                                                  |
| ` void`                                                                                                      | ` `[notifyVerticalEdgeReached](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#notifyVerticalEdgeReached(int, int, int))`(int startY, int finalY, int overY) ` *This method was deprecated in API level 26.1.0. Use[notifyVerticalEdgeReached(int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#notifyVerticalEdgeReached(int, int, int))directly.*                                                                                                                          |
| ` boolean`                                                                                                   | ` `[springBack](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#springBack(int, int, int, int, int, int))`(int startX, int startY, int minX, int maxX, int minY, int maxY) ` *This method was deprecated in API level 26.1.0. Use[springBack(int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#springBack(int, int, int, int, int, int))directly.*                                                                                                            |
| ` void`                                                                                                      | ` `[startScroll](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#startScroll(int, int, int, int, int))`(int startX, int startY, int dx, int dy, int duration) ` *This method was deprecated in API level 26.1.0. Use[startScroll(int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#startScroll(int, int, int, int, int))directly.*                                                                                                                                 |
| ` void`                                                                                                      | ` `[startScroll](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#startScroll(int, int, int, int))`(int startX, int startY, int dx, int dy) ` *This method was deprecated in API level 26.1.0. Use[getCurrX()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrX())directly.*                                                                                                                                                                                                        |

| ### Inherited methods |
|-----------------------|---|
| [![](https://developer.android.com/static/assets/images/styles/disclosure_down.png)](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#)From class` java.lang.Object ` |-------------------|-------------------------------| | ` Object`         | ` clone() `                   | | ` boolean`        | ` equals(Object arg0) `       | | ` void`           | ` finalize() `                | | ` final Class<?>` | ` getClass() `                | | ` int`            | ` hashCode() `                | | ` final void`     | ` notify() `                  | | ` final void`     | ` notifyAll() `               | | ` String`         | ` toString() `                | | ` final void`     | ` wait(long arg0, int arg1) ` | | ` final void`     | ` wait(long arg0) `           | | ` final void`     | ` wait() `                    | ||

## Public methods

### abortAnimation

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void abortAnimation ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[abortAnimation()](https://developer.android.com/reference/android/widget/OverScroller.html#abortAnimation())directly.

Stops the animation. Aborting the animation causes the scroller to move to the final x and y position.

<br />

### computeScrollOffset

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean computeScrollOffset ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[computeScrollOffset()](https://developer.android.com/reference/android/widget/OverScroller.html#computeScrollOffset())directly.

Call this when you want to know the new location. If it returns true, the animation is not yet finished. loc will be altered to provide the new location.

<br />

|      Returns      ||
|-----------|--------|
| `boolean` | <br /> |

### create

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
ScrollerCompat create (Context context, 
                Interpolator interpolator)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[OverScroller](https://developer.android.com/reference/android/widget/OverScroller.html)constructor directly.

<br />

<br />

|              Parameters               ||
|----------------|-----------------------|
| `context`      | `Context` <br />      |
| `interpolator` | `Interpolator` <br /> |

|                                                  Returns                                                   ||
|----------------------------------------------------------------------------------------------------|--------|
| [ScrollerCompat](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat) | <br /> |

### create

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
ScrollerCompat create (Context context)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[OverScroller](https://developer.android.com/reference/android/widget/OverScroller.html)constructor directly.

<br />

<br />

|         Parameters          ||
|-----------|------------------|
| `context` | `Context` <br /> |

|                                                  Returns                                                   ||
|----------------------------------------------------------------------------------------------------|--------|
| [ScrollerCompat](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat) | <br /> |

### fling

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void fling (int startX, 
                int startY, 
                int velocityX, 
                int velocityY, 
                int minX, 
                int maxX, 
                int minY, 
                int maxY)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[fling(int, int, int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#fling(int, int, int, int, int, int, int, int))directly.

Start scrolling based on a fling gesture. The distance travelled will depend on the initial velocity of the fling.

<br />

|                                         Parameters                                          ||
|-------------|--------------------------------------------------------------------------------|
| `startX`    | `int`: Starting point of the scroll (X) <br />                                 |
| `startY`    | `int`: Starting point of the scroll (Y) <br />                                 |
| `velocityX` | `int`: Initial velocity of the fling (X) measured in pixels per second. <br /> |
| `velocityY` | `int`: Initial velocity of the fling (Y) measured in pixels per second <br />  |
| `minX`      | `int`: Minimum X value. The scroller will not scroll past this point. <br />   |
| `maxX`      | `int`: Maximum X value. The scroller will not scroll past this point. <br />   |
| `minY`      | `int`: Minimum Y value. The scroller will not scroll past this point. <br />   |
| `maxY`      | `int`: Maximum Y value. The scroller will not scroll past this point. <br />   |

### fling

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void fling (int startX, 
                int startY, 
                int velocityX, 
                int velocityY, 
                int minX, 
                int maxX, 
                int minY, 
                int maxY, 
                int overX, 
                int overY)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[fling(int, int, int, int, int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#fling(int, int, int, int, int, int, int, int, int, int))directly.

Start scrolling based on a fling gesture. The distance travelled will depend on the initial velocity of the fling.

<br />

|                                                   Parameters                                                    ||
|-------------|----------------------------------------------------------------------------------------------------|
| `startX`    | `int`: Starting point of the scroll (X) <br />                                                     |
| `startY`    | `int`: Starting point of the scroll (Y) <br />                                                     |
| `velocityX` | `int`: Initial velocity of the fling (X) measured in pixels per second. <br />                     |
| `velocityY` | `int`: Initial velocity of the fling (Y) measured in pixels per second <br />                      |
| `minX`      | `int`: Minimum X value. The scroller will not scroll past this point. <br />                       |
| `maxX`      | `int`: Maximum X value. The scroller will not scroll past this point. <br />                       |
| `minY`      | `int`: Minimum Y value. The scroller will not scroll past this point. <br />                       |
| `maxY`      | `int`: Maximum Y value. The scroller will not scroll past this point. <br />                       |
| `overX`     | `int`: Overfling range. If \> 0, horizontal overfling in either direction will be possible. <br /> |
| `overY`     | `int`: Overfling range. If \> 0, vertical overfling in either direction will be possible. <br />   |

### getCurrVelocity

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
float getCurrVelocity ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getCurrVelocity()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrVelocity())directly.

Returns the current velocity on platform versions that support it.

This method should only be used as input for nonessential visual effects such as[EdgeEffectCompat](https://developer.android.com/reference/android/support/v4/widget/EdgeEffectCompat).

<br />

<br />

|                                       Returns                                        ||
|---------|-----------------------------------------------------------------------------|
| `float` | The original velocity less the deceleration. Result may be negative. <br /> |

### getCurrX

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getCurrX ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getCurrX()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrX())directly.

Returns the current X offset in the scroll.

<br />

|                                 Returns                                 ||
|-------|------------------------------------------------------------------|
| `int` | The new X offset as an absolute distance from the origin. <br /> |

### getCurrY

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getCurrY ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getCurrY()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrY())directly.

Returns the current Y offset in the scroll.

<br />

|                                 Returns                                 ||
|-------|------------------------------------------------------------------|
| `int` | The new Y offset as an absolute distance from the origin. <br /> |

### getFinalX

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getFinalX ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getFinalX()](https://developer.android.com/reference/android/widget/OverScroller.html#getFinalX())directly.

<br />

<br />

|                                 Returns                                  ||
|-------|-------------------------------------------------------------------|
| `int` | The final X position for the scroll in progress, if known. <br /> |

### getFinalY

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
int getFinalY ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getFinalY()](https://developer.android.com/reference/android/widget/OverScroller.html#getFinalY())directly.

<br />

<br />

|                                 Returns                                  ||
|-------|-------------------------------------------------------------------|
| `int` | The final Y position for the scroll in progress, if known. <br /> |

### isFinished

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean isFinished ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[isFinished()](https://developer.android.com/reference/android/widget/OverScroller.html#isFinished())directly.

Returns whether the scroller has finished scrolling.

<br />

|                                     Returns                                     ||
|-----------|----------------------------------------------------------------------|
| `boolean` | True if the scroller has finished scrolling, false otherwise. <br /> |

### isOverScrolled

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean isOverScrolled ()
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[isOverScrolled()](https://developer.android.com/reference/android/widget/OverScroller.html#isOverScrolled())directly.

Returns whether the current Scroller is currently returning to a valid position. Valid bounds were provided by the[fling(int, int, int, int, int, int, int, int, int, int)](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#fling(int, int, int, int, int, int, int, int, int, int))method. One should check this value before calling[startScroll(int, int, int, int)](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat#startScroll(int, int, int, int))as the interpolation currently in progress to restore a valid position will then be stopped. The caller has to take into account the fact that the started scroll will start from an overscrolled position.

<br />

|                                                           Returns                                                           ||
|-----------|------------------------------------------------------------------------------------------------------------------|
| `boolean` | true when the current position is overscrolled and in the process of interpolating back to a valid value. <br /> |

### notifyHorizontalEdgeReached

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void notifyHorizontalEdgeReached (int startX, 
                int finalX, 
                int overX)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[notifyHorizontalEdgeReached(int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#notifyHorizontalEdgeReached(int, int, int))directly.

Notify the scroller that we've reached a horizontal boundary. Normally the information to handle this will already be known when the animation is started, such as in a call to one of the fling functions. However there are cases where this cannot be known in advance. This function will transition the current motion and animate from startX to finalX as appropriate.

<br />

|                                                                      Parameters                                                                      ||
|----------|--------------------------------------------------------------------------------------------------------------------------------------------|
| `startX` | `int`: Starting/current X position <br />                                                                                                  |
| `finalX` | `int`: Desired final X position <br />                                                                                                     |
| `overX`  | `int`: Magnitude of overscroll allowed. This should be the maximum desired distance from finalX. Absolute value - must be positive. <br /> |

### notifyVerticalEdgeReached

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void notifyVerticalEdgeReached (int startY, 
                int finalY, 
                int overY)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[notifyVerticalEdgeReached(int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#notifyVerticalEdgeReached(int, int, int))directly.

Notify the scroller that we've reached a vertical boundary. Normally the information to handle this will already be known when the animation is started, such as in a call to one of the fling functions. However there are cases where this cannot be known in advance. This function will animate a parabolic motion from startY to finalY.

<br />

|                                                                      Parameters                                                                      ||
|----------|--------------------------------------------------------------------------------------------------------------------------------------------|
| `startY` | `int`: Starting/current Y position <br />                                                                                                  |
| `finalY` | `int`: Desired final Y position <br />                                                                                                     |
| `overY`  | `int`: Magnitude of overscroll allowed. This should be the maximum desired distance from finalY. Absolute value - must be positive. <br /> |

### springBack

added in[version 24.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
boolean springBack (int startX, 
                int startY, 
                int minX, 
                int maxX, 
                int minY, 
                int maxY)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[springBack(int, int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#springBack(int, int, int, int, int, int))directly.

Call this when you want to 'spring back' into a valid coordinate range.

<br />

|                  Parameters                   ||
|----------|-------------------------------------|
| `startX` | `int`: Starting X coordinate <br /> |
| `startY` | `int`: Starting Y coordinate <br /> |
| `minX`   | `int`: Minimum valid X value <br /> |
| `maxX`   | `int`: Maximum valid X value <br /> |
| `minY`   | `int`: Minimum valid Y value <br /> |
| `maxY`   | `int`: Maximum valid Y value <br /> |

|                                                        Returns                                                        ||
|-----------|------------------------------------------------------------------------------------------------------------|
| `boolean` | true if a springback was initiated, false if startX and startY were already within the valid range. <br /> |

### startScroll

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void startScroll (int startX, 
                int startY, 
                int dx, 
                int dy, 
                int duration)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[startScroll(int, int, int, int, int)](https://developer.android.com/reference/android/widget/OverScroller.html#startScroll(int, int, int, int, int))directly.

Start scrolling by providing a starting point and the distance to travel.

<br />

|                                                          Parameters                                                          ||
|------------|------------------------------------------------------------------------------------------------------------------|
| `startX`   | `int`: Starting horizontal scroll offset in pixels. Positive numbers will scroll the content to the left. <br /> |
| `startY`   | `int`: Starting vertical scroll offset in pixels. Positive numbers will scroll the content up. <br />            |
| `dx`       | `int`: Horizontal distance to travel. Positive numbers will scroll the content to the left. <br />               |
| `dy`       | `int`: Vertical distance to travel. Positive numbers will scroll the content up. <br />                          |
| `duration` | `int`: Duration of the scroll in milliseconds. <br />                                                            |

### startScroll

added in[version 22.1.0](https://developer.android.com/topic/libraries/support-library/revisions)  

```
void startScroll (int startX, 
                int startY, 
                int dx, 
                int dy)
```

<br />

**This method was deprecated in API level 26.1.0.**   
Use[getCurrX()](https://developer.android.com/reference/android/widget/OverScroller.html#getCurrX())directly.

Start scrolling by providing a starting point and the distance to travel. The scroll will use the default value of 250 milliseconds for the duration.

<br />

|                                                         Parameters                                                         ||
|----------|------------------------------------------------------------------------------------------------------------------|
| `startX` | `int`: Starting horizontal scroll offset in pixels. Positive numbers will scroll the content to the left. <br /> |
| `startY` | `int`: Starting vertical scroll offset in pixels. Positive numbers will scroll the content up. <br />            |
| `dx`     | `int`: Horizontal distance to travel. Positive numbers will scroll the content to the left. <br />               |
| `dy`     | `int`: Vertical distance to travel. Positive numbers will scroll the content up. <br />                          |

-

  ## Interfaces

  - [DrawerLayout.DrawerListener](https://developer.android.com/reference/android/support/v4/widget/DrawerLayout.DrawerListener)
  - [NestedScrollView.OnScrollChangeListener](https://developer.android.com/reference/android/support/v4/widget/NestedScrollView.OnScrollChangeListener)
  - [SimpleCursorAdapter.CursorToStringConverter](https://developer.android.com/reference/android/support/v4/widget/SimpleCursorAdapter.CursorToStringConverter)
  - [SimpleCursorAdapter.ViewBinder](https://developer.android.com/reference/android/support/v4/widget/SimpleCursorAdapter.ViewBinder)
  - [SlidingPaneLayout.PanelSlideListener](https://developer.android.com/reference/android/support/v4/widget/SlidingPaneLayout.PanelSlideListener)
  - [SwipeRefreshLayout.OnChildScrollUpCallback](https://developer.android.com/reference/android/support/v4/widget/SwipeRefreshLayout.OnChildScrollUpCallback)
  - [SwipeRefreshLayout.OnRefreshListener](https://developer.android.com/reference/android/support/v4/widget/SwipeRefreshLayout.OnRefreshListener)
  - [TintableCompoundButton](https://developer.android.com/reference/android/support/v4/widget/TintableCompoundButton)
-

  ## Classes

  - [AutoScrollHelper](https://developer.android.com/reference/android/support/v4/widget/AutoScrollHelper)
  - [CircularProgressDrawable](https://developer.android.com/reference/android/support/v4/widget/CircularProgressDrawable)
  - [CompoundButtonCompat](https://developer.android.com/reference/android/support/v4/widget/CompoundButtonCompat)
  - [ContentLoadingProgressBar](https://developer.android.com/reference/android/support/v4/widget/ContentLoadingProgressBar)
  - [CursorAdapter](https://developer.android.com/reference/android/support/v4/widget/CursorAdapter)
  - [DrawerLayout](https://developer.android.com/reference/android/support/v4/widget/DrawerLayout)
  - [DrawerLayout.LayoutParams](https://developer.android.com/reference/android/support/v4/widget/DrawerLayout.LayoutParams)
  - [DrawerLayout.SavedState](https://developer.android.com/reference/android/support/v4/widget/DrawerLayout.SavedState)
  - [DrawerLayout.SimpleDrawerListener](https://developer.android.com/reference/android/support/v4/widget/DrawerLayout.SimpleDrawerListener)
  - [EdgeEffectCompat](https://developer.android.com/reference/android/support/v4/widget/EdgeEffectCompat)
  - [ExploreByTouchHelper](https://developer.android.com/reference/android/support/v4/widget/ExploreByTouchHelper)
  - [ImageViewCompat](https://developer.android.com/reference/android/support/v4/widget/ImageViewCompat)
  - [ListPopupWindowCompat](https://developer.android.com/reference/android/support/v4/widget/ListPopupWindowCompat)
  - [ListViewAutoScrollHelper](https://developer.android.com/reference/android/support/v4/widget/ListViewAutoScrollHelper)
  - [ListViewCompat](https://developer.android.com/reference/android/support/v4/widget/ListViewCompat)
  - [NestedScrollView](https://developer.android.com/reference/android/support/v4/widget/NestedScrollView)
  - [PopupMenuCompat](https://developer.android.com/reference/android/support/v4/widget/PopupMenuCompat)
  - [PopupWindowCompat](https://developer.android.com/reference/android/support/v4/widget/PopupWindowCompat)
  - [ResourceCursorAdapter](https://developer.android.com/reference/android/support/v4/widget/ResourceCursorAdapter)
  - [ScrollerCompat](https://developer.android.com/reference/android/support/v4/widget/ScrollerCompat)
  - [SimpleCursorAdapter](https://developer.android.com/reference/android/support/v4/widget/SimpleCursorAdapter)
  - [SlidingPaneLayout](https://developer.android.com/reference/android/support/v4/widget/SlidingPaneLayout)
  - [SlidingPaneLayout.LayoutParams](https://developer.android.com/reference/android/support/v4/widget/SlidingPaneLayout.LayoutParams)
  - [SlidingPaneLayout.SimplePanelSlideListener](https://developer.android.com/reference/android/support/v4/widget/SlidingPaneLayout.SimplePanelSlideListener)
  - [Space](https://developer.android.com/reference/android/support/v4/widget/Space)
  - [SwipeRefreshLayout](https://developer.android.com/reference/android/support/v4/widget/SwipeRefreshLayout)
  - [TextViewCompat](https://developer.android.com/reference/android/support/v4/widget/TextViewCompat)
  - [ViewDragHelper](https://developer.android.com/reference/android/support/v4/widget/ViewDragHelper)
  - [ViewDragHelper.Callback](https://developer.android.com/reference/android/support/v4/widget/ViewDragHelper.Callback)