Compose Unstyled 2.0 is out! Check the official announcement blog ->
Class

SubspacePlaceable

A SubspacePlaceable corresponds to a child layout that can be positioned by its parent layout.

Source set: Android
public abstract class SubspacePlaceable

A SubspacePlaceable corresponds to a child layout that can be positioned by its parent layout. Most SubspacePlaceable are the result of a SubspaceMeasurable.measure call.

Based on androidx.compose.ui.layout.Placeable.

Properties

width

Source set: Android
public var width: Int

The width, in pixels, of the measured layout, as seen by the parent. This will usually coincide with the measured width of the layout (aka the width value passed into SubspaceMeasureScope.layout), but can be different if the layout does not respect its incoming constraints: in these cases the width will be coerced inside the min and max width constraints - to access the actual width that the layout measured itself to, use measuredWidth.

height

Source set: Android
public var height: Int

The height, in pixels, of the measured layout, as seen by the parent. This will usually coincide with the measured height of the layout (aka the height value passed into SubspaceMeasureScope.layout), but can be different if the layout does not respect its incoming constraints: in these cases the height will be coerced inside the min and max height constraints - to access the actual height that the layout measured itself to, use measuredHeight.

depth

Source set: Android
public var depth: Int

The depth, in pixels, of the measured layout, as seen by the parent. This will usually coincide with the measured depth of the layout (aka the depth value passed into SubspaceMeasureScope.layout), but can be different if the layout does not respect its incoming constraints: in these cases the depth will be coerced inside the min and max depth constraints - to access the actual depth that the layout measured itself to, use measuredDepth.

measuredWidth

Source set: Android
public var measuredWidth: Int

The measured width of the layout. This might not respect measurementConstraints.

measuredHeight

Source set: Android
public var measuredHeight: Int

The measured height of the layout. This might not respect measurementConstraints.

measuredDepth

Source set: Android
public var measuredDepth: Int

The measured depth of the layout. This might not respect measurementConstraints.

Last updated: