DimensionBuilders.ExpandedDimensionProp


@RequiresSchemaVersion(major = 1, minor = 0)
class DimensionBuilders.ExpandedDimensionProp : DimensionBuilders.ContainerDimension, DimensionBuilders.ImageDimension, DimensionBuilders.SpacerDimension


A type for a dimension that fills all the space it can (i.e. MATCH_PARENT in Android parlance).

Summary

Public functions

TypeBuilders.FloatProp?

Gets the layout weight (a dimensionless scalar value) for this element.

String

Public functions

getLayoutWeight

Added in 1.0.0
fun getLayoutWeight(): TypeBuilders.FloatProp?

Gets the layout weight (a dimensionless scalar value) for this element. This will only affect the width of children of a or the height of children of a androidx.wear.protolayout.LayoutElementBuilders.Column. By default, all children have equal weight. Where applicable, the width or height of the element is proportional to the sum of the weights of its siblings.

Note that negative values are not supported and it can lead to unexpected behaviour.

toString

fun toString(): String