androidx.compose.foundation.layout
GridScopeSince 1.11Experimental
Interface · from org.jetbrains.compose.foundation:foundation-layout:1.12.2
No hand-written docs yet.
Scope for the children of Grid.
interface GridScope
Used by
Parameters that take a GridScope.
Properties
MaxGridIndexExperimental
const val MaxGridIndex: Int
The maximum allowed index for a row or column (inclusive).
GridIndexUnspecifiedExperimental
const val GridIndexUnspecified: Int
Sentinel value indicating that a grid position (row or column) is not manually specified and should be determined automatically by the layout flow.
Functions
gridItem
fun Modifier.gridItem(
row: Int = GridIndexUnspecified,
column: Int = GridIndexUnspecified,
rowSpan: Int = 1,
columnSpan: Int = 1,
alignment: Alignment = Alignment.TopStart,
): Modifier
Configures the position, span, and alignment of an element within a Grid layout.
fun Modifier.gridItem(
rows: IntRange,
columns: IntRange,
alignment: Alignment = Alignment.TopStart,
): Modifier
Configures the position, span, and alignment of an element within a Grid layout using ranges.
fun Modifier.gridItem(
areaId: Any,
alignment: Alignment = Alignment.TopStart,
): Modifier
Configures the position and alignment of an element within a Grid layout by referencing a named area.
Library docs
Scope for the children of Grid.