recycler-view-divider / com.fondesa.recyclerviewdivider.offset / DividerOffsetProvider / getOffsetFromSize

getOffsetFromSize

@Px abstract fun getOffsetFromSize(grid: Grid, divider: Divider, dividerSide: Side, @Px size: Int): Int

Gets the divider's offset. Useful to balance the size of the items in a grid with multiple columns/rows.

Parameters

grid - the Grid in which the divider is shown.

divider - the Divider which needs to establish its offset.

dividerSide - the side of the cell on which the divider is shown.

size - the size of the divider.

Return
the offset which should be rendered by the given divider.