Google is committed to advancing racial equity for Black communities. See how.

Arrangement

@Immutable interface Arrangement
androidx.ui.layout.Arrangement

Used to specify the arrangement of the layout's children in Row or Column in the main axis direction (horizontal and vertical, respectively).

Summary

Nested classes

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

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

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

abstract

Used to specify the horizontal arrangement of the layout's children in a Row.

Place children such that they are spaced evenly across the main axis, including free space before the first child and after the last child, but half the amount of space existing otherwise between two consecutive children.

Place children such that they are spaced evenly across the main axis, without free space before the first child or after the last child.

Place children such that they are spaced evenly across the main axis, including free space before the first child and after the last child.

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

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

abstract

Used to specify the vertical arrangement of the layout's children in a Column.

Public methods
abstract List<Int>
arrange(totalSize: Int, size: List<Int>, layoutDirection: LayoutDirection)

Places the layout children inside the parent layout along the main axis.

Public methods

arrange

abstract fun arrange(
    totalSize: Int,
    size: List<Int>,
    layoutDirection: LayoutDirection
): List<Int>

Places the layout children inside the parent layout along the main axis.

Parameters
totalSize: Int Available space that can be occupied by the children.
size: List<Int> A list of sizes of all children.
layoutDirection: LayoutDirection A layout direction, left-to-right or right-to-left, of the parent layout that should be taken into account when determining positions of the children in horizontal direction.