SpatialArrangement.Absolute

object SpatialArrangement.Absolute


Used to specify arrangement which doesn't change with layout direction.

Summary

Public functions

SpatialArrangement.Horizontal

Children placed next to each other horizontally and align them according to the spatialAlignment given.

SpatialArrangement.Horizontal
spacedBy(space: Dp, spatialAlignment: SpatialAlignment.Horizontal)

Children are placed next to each other with fixed space between them horizontally and align them according to the spatialAlignment given.

Public properties

SpatialArrangement.Horizontal

All children should be arranged at the center of the androidx.xr.compose.subspace.SpatialRow.

SpatialArrangement.Horizontal

All children should be arranged at the left of the androidx.xr.compose.subspace.SpatialRow.

SpatialArrangement.Horizontal

All children should be arranged at the right of the androidx.xr.compose.subspace.SpatialRow.

SpatialArrangement.Horizontal

There should be equal space around each child.

SpatialArrangement.Horizontal

There should be equal space between the children and no space before the first child or after the last child.

SpatialArrangement.Horizontal

There should be equal space between the children and before the first child and after the last child.

Public functions

aligned

Added in 1.0.0-alpha13
fun aligned(spatialAlignment: SpatialAlignment.Horizontal): SpatialArrangement.Horizontal

Children placed next to each other horizontally and align them according to the spatialAlignment given. Unlike SpatialArrangement.spacedBy, when layout direction is RTL, children will not be mirrored.

Parameters
spatialAlignment: SpatialAlignment.Horizontal

SpatialAlignment.Horizontal to align the children with.

spacedBy

Added in 1.0.0-alpha13
fun spacedBy(space: Dp, spatialAlignment: SpatialAlignment.Horizontal): SpatialArrangement.Horizontal

Children are placed next to each other with fixed space between them horizontally and align them according to the spatialAlignment given. Unlike SpatialArrangement.spacedBy, when layout direction is RTL, children will not be mirrored.

Parameters
space: Dp

fixed space Dp to place between adjacent children.

spatialAlignment: SpatialAlignment.Horizontal

SpatialAlignment.Horizontal to align the children with.

Public properties

Center

Added in 1.0.0-alpha13
val CenterSpatialArrangement.Horizontal

All children should be arranged at the center of the androidx.xr.compose.subspace.SpatialRow. Unlike SpatialArrangement.Center, when layout direction is RTL, children will not be mirrored. Visually: ##123##

Left

Added in 1.0.0-alpha13
val LeftSpatialArrangement.Horizontal

All children should be arranged at the left of the androidx.xr.compose.subspace.SpatialRow. Unlike SpatialArrangement.Start, when layout direction is RTL, children will not be mirrored. Visually: 123####

Right

Added in 1.0.0-alpha13
val RightSpatialArrangement.Horizontal

All children should be arranged at the right of the androidx.xr.compose.subspace.SpatialRow. Unlike SpatialArrangement.End, when layout direction is RTL, children will not be mirrored. Visually: ####123

SpaceAround

Added in 1.0.0-alpha13
val SpaceAroundSpatialArrangement.Horizontal

There should be equal space around each child. Unlike SpatialArrangement.SpaceAround, when layout direction is RTL, children will not be mirrored. Visually: #1##2##3##4#

SpaceBetween

Added in 1.0.0-alpha13
val SpaceBetweenSpatialArrangement.Horizontal

There should be equal space between the children and no space before the first child or after the last child. Unlike SpatialArrangement.SpaceBetween, when layout direction is RTL, children will not be mirrored. Visually: 1##2##3

SpaceEvenly

Added in 1.0.0-alpha13
val SpaceEvenlySpatialArrangement.Horizontal

There should be equal space between the children and before the first child and after the last child. Unlike SpatialArrangement.SpaceEvenly, when layout direction is RTL, children will not be mirrored. Visually: #1#2#3#