requestScrollToPositionWithOffset

open fun requestScrollToPositionWithOffset(position: Int, offset: Int)

Send the Recycler a request to scroll the content to a specific item in the binder with the given offset from resolved layout start. Animation will not be performed.

If you are just trying to make a position visible, use requestScrollToPosition.

Note: This offset is valid for LinearLayout only!

Parameters

position

Index (starting at 0) of the reference item.

offset

The distance (in pixels) between the start edge of the item view and start edge of the RecyclerView.