Function

calculateStartPadding

The padding to be applied along the start edge inside a box: along the left edge if the layout direction is LTR, or along the right edge for RTL.

RevenueCat

RevenueCat

Add subscriptions to your apps in minutes

Ad Get started for free

calculateStartPadding

Common
fun PaddingValues.calculateStartPadding(layoutDirection: LayoutDirection) =
    if (layoutDirection == LayoutDirection.Ltr) {
        calculateLeftPadding(layoutDirection)
    } else {
        calculateRightPadding(layoutDirection)
    }

The padding to be applied along the start edge inside a box: along the left edge if the layout direction is LTR, or along the right edge for RTL.