Object

RemoteArrangement

In remote-compose, an arrangement is a contract for how to lay out children in a container that allows for more than one child.

Source set: JvmAndAndroid
public object RemoteArrangement

In remote-compose, an arrangement is a contract for how to lay out children in a container that allows for more than one child. This is a mirror of androidx.compose.foundation.layout.Arrangement

Properties

Start

Source set: JvmAndAndroid
public val Start: RemoteArrangement.Horizontal = HorizontalArrangement(ColumnLayout.START)

Place children horizontally such that they are as close as possible to the start of the main axis.

End

Source set: JvmAndAndroid
public val End: RemoteArrangement.Horizontal = HorizontalArrangement(ColumnLayout.END)

Place children horizontally such that they are as close as possible to the end of the main axis.

Top

Source set: JvmAndAndroid
public val Top: RemoteArrangement.Vertical = VerticalArrangement(ColumnLayout.TOP)

Place children vertically such that they are as close as possible to the top of the main axis.

Bottom

Source set: JvmAndAndroid
public val Bottom: RemoteArrangement.Vertical = VerticalArrangement(ColumnLayout.BOTTOM)

Place children vertically such that they are as close as possible to the bottom of the main axis.

Center

Source set: JvmAndAndroid
public val Center: RemoteArrangement.HorizontalOrVertical =
        HorizontalOrVerticalArrangement(ColumnLayout.CENTER)

Place children vertically such that they are centered on the main axis.

SpaceEvenly

Source set: JvmAndAndroid
public val SpaceEvenly: RemoteArrangement.HorizontalOrVertical =
        HorizontalOrVerticalArrangement(ColumnLayout.SPACE_EVENLY)

Place children with equal space between them, but not on the edges.

SpaceBetween

Source set: JvmAndAndroid
public val SpaceBetween: RemoteArrangement.HorizontalOrVertical =
        HorizontalOrVerticalArrangement(ColumnLayout.SPACE_BETWEEN)

Place children with equal space between them, including the edges.

SpaceAround

Source set: JvmAndAndroid
public val SpaceAround: RemoteArrangement.HorizontalOrVertical =
        HorizontalOrVerticalArrangement(ColumnLayout.SPACE_AROUND)

Place children with equal space around them.

Functions

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(space: RemoteDp): RemoteArrangement.HorizontalOrVertical

Place children such that each two adjacent ones are spaced by a fixed space distance across the main axis. The spacing will be subtracted from the available space that the children can occupy.

Parameters

space The space between adjacent children.

Return

a RemoteArrangement.HorizontalOrVertical that spaces adjacent children by space

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(space: RemoteFloat): RemoteArrangement.HorizontalOrVertical

Place children such that each two adjacent ones are spaced by a fixed space distance across the main axis. The spacing will be subtracted from the available space that the children can occupy.

Parameters

space The space between adjacent children.

Return

a RemoteArrangement.HorizontalOrVertical that spaces adjacent children by space

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(
        space: RemoteDp,
        alignment: RemoteAlignment.Horizontal,
    ): RemoteArrangement.Horizontal

Place children horizontally such that each two adjacent ones are spaced by a fixed space distance. The spacing will be subtracted from the available width that the children can occupy. An alignment can be specified to align the spaced children horizontally inside the parent, in case there is empty width remaining.

Parameters

space The space between adjacent children.
alignment The alignment of the spaced children inside the parent.

Return

a RemoteArrangement.Horizontal that spaces adjacent children by space aligned by alignment

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(
        space: RemoteFloat,
        alignment: RemoteAlignment.Horizontal,
    ): RemoteArrangement.Horizontal

Place children horizontally such that each two adjacent ones are spaced by a fixed space distance. The spacing will be subtracted from the available width that the children can occupy. An alignment can be specified to align the spaced children horizontally inside the parent, in case there is empty width remaining.

Parameters

space The space between adjacent children.
alignment The alignment of the spaced children inside the parent.

Return

a RemoteArrangement.Horizontal that spaces adjacent children by space aligned by alignment

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(
        space: RemoteDp,
        alignment: RemoteAlignment.Vertical,
    ): RemoteArrangement.Vertical

Place children vertically such that each two adjacent ones are spaced by a fixed space distance. The spacing will be subtracted from the available height that the children can occupy. An alignment can be specified to align the spaced children vertically inside the parent, in case there is empty height remaining.

Parameters

space The space between adjacent children.
alignment The alignment of the spaced children inside the parent.

Return

a RemoteArrangement.Vertical that spaces adjacent children by space aligned by alignment

spacedBy

Source set: JvmAndAndroid
public fun spacedBy(
        space: RemoteFloat,
        alignment: RemoteAlignment.Vertical,
    ): RemoteArrangement.Vertical

Place children vertically such that each two adjacent ones are spaced by a fixed space distance. The spacing will be subtracted from the available height that the children can occupy. An alignment can be specified to align the spaced children vertically inside the parent, in case there is empty height remaining.

Parameters

space The space between adjacent children.
alignment The alignment of the spaced children inside the parent.

Return

a RemoteArrangement.Vertical that spaces adjacent children by space aligned by alignment

Members

Horizontal

Source set: JvmAndAndroid
@Stable public sealed interface Horizontal

A contract for laying out children horizontally.

Vertical

Source set: JvmAndAndroid
@Stable public sealed interface Vertical

A contract for laying out children vertically.

HorizontalOrVertical

Source set: JvmAndAndroid
@Stable public sealed interface HorizontalOrVertical : Horizontal, Vertical

A contract for laying out children horizontally or vertically.

Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: