PhysicalLengthConverter

Interface for converting length between physical lengthUnit and Dp

Functions

Link copied to clipboard
abstract fun dpToLength(dp: Dp, lengthUnit: LengthUnit): Float

Converts an Int Dp value to LengthUnit.

Link copied to clipboard
abstract fun lengthToDp(length: Float, lengthUnit: LengthUnit): Dp

Converts a Float LengthUnit value to Dp.