chooseSize

open fun chooseSize(spec: Int, desired: Int, min: Int): Int(source)

Chooses a size from the given specs and parameters that is closest to the desired size and also complies with the spec.

Return

A size that fits to the given specs

Parameters

spec

The measureSpec

desired

The preferred measurement

min

The minimum value