# ConstraintLayoutScope

Artifact: [androidx.constraintlayout:constraintlayout-compose](https://developer.android.com/jetpack/androidx/releases/constraintlayout) [View Source](https://cs.android.com/search?q=file:androidx/constraintlayout/compose/ConstraintLayout.kt+class:androidx.constraintlayout.compose.ConstraintLayoutScope) Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)


```
@LayoutScopeMarker
class ConstraintLayoutScope : ConstraintLayoutBaseScope
```

<br />

|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html) |||
| ↳ | [androidx.constraintlayout.compose.ConstraintLayoutBaseScope](https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope) ||
|   | ↳ | [androidx.constraintlayout.compose.ConstraintLayoutScope](https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope) |

*** ** * ** ***

Scope used by the inline DSL of `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`.

## Summary

| ### Nested types |
|---|
| `inner class https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope.ConstrainedLayoutReferences` Convenience API for creating multiple `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` via `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#createRefs()`. |

| ### Public functions |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier.https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#(androidx.compose.ui.Modifier).constrainAs(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)( ref: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference, constrainBlock: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainScope.() -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html )` `https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier` that defines the constraints, as part of a `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`, of the layout element. |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#createRef()()` Creates one `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference`, which needs to be assigned to a layout within the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)` as part of `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#(androidx.compose.ui.Modifier).constrainAs(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)`. |
| `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope.ConstrainedLayoutReferences` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#createRefs()()` Convenient way to create multiple `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference`s, which need to be assigned to layouts within the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)` as part of `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#(androidx.compose.ui.Modifier).constrainAs(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)`. |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#reset()()` |

| ### Inherited functions |
|---|
| From [androidx.constraintlayout.compose.ConstraintLayoutBaseScope](https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope) |---|---| | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#applyTo(androidx.constraintlayout.compose.State)(state: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/State)` | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainScope` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)(ref: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference, constrainBlock: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainScope.() -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html)` Specifies the constraints associated to the layout identified with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalChainScope` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.HorizontalChainReference,kotlin.Function1)(ref: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalChainReference, constrainBlock: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalChainScope.() -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html)` Specifies additional constraints associated to the horizontal chain identified with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.HorizontalChainReference,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalChainScope` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.VerticalChainReference,kotlin.Function1)(ref: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalChainReference, constrainBlock: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalChainScope.() -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html)` Specifies additional constraints associated to the vertical chain identified with `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(androidx.constraintlayout.compose.VerticalChainReference,kotlin.Function1)`. | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#constrain(kotlin.Array,kotlin.Function1)( vararg refs: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference, constrainBlock: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainScope.() -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html )` Convenient way to apply the same constraints to multiple `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference`s. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createAbsoluteLeftBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns a left barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createAbsoluteRightBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns a right barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createBottomBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns a bottom barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createColumn(kotlin.Array,androidx.compose.ui.unit.Dp,kotlin.FloatArray)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, spacing: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html )` Creates a Grid based helper that lays out its elements in a single Column. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createEndBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns an end barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createFlow(kotlin.Array,kotlin.Boolean,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Int,androidx.compose.ui.unit.Dp,androidx.constraintlayout.compose.Wrap,androidx.constraintlayout.compose.VerticalAlign,androidx.constraintlayout.compose.HorizontalAlign,kotlin.Float,kotlin.Float,androidx.constraintlayout.compose.FlowStyle,androidx.constraintlayout.compose.FlowStyle)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference?, flowVertically: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, verticalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, horizontalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, maxElement: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, padding: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, wrapMode: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/Wrap, verticalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalAlign, horizontalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalAlign, horizontalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle, horizontalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle )` Flow helpers allows a long sequence of Composable widgets to wrap onto multiple rows or columns. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createFlow(kotlin.Array,kotlin.Boolean,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Int,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.constraintlayout.compose.Wrap,androidx.constraintlayout.compose.VerticalAlign,androidx.constraintlayout.compose.HorizontalAlign,kotlin.Float,kotlin.Float,androidx.constraintlayout.compose.FlowStyle,androidx.constraintlayout.compose.FlowStyle)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference?, flowVertically: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, verticalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, horizontalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, maxElement: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, paddingHorizontal: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, paddingVertical: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, wrapMode: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/Wrap, verticalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalAlign, horizontalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalAlign, horizontalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle, horizontalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle )` Flow helpers allows a long sequence of Composable widgets to wrap onto multiple rows or columns. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createFlow(kotlin.Array,kotlin.Boolean,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Int,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.constraintlayout.compose.Wrap,androidx.constraintlayout.compose.VerticalAlign,androidx.constraintlayout.compose.HorizontalAlign,kotlin.Float,kotlin.Float,androidx.constraintlayout.compose.FlowStyle,androidx.constraintlayout.compose.FlowStyle)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference?, flowVertically: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, verticalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, horizontalGap: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, maxElement: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, paddingLeft: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, paddingTop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, paddingRight: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, paddingBottom: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, wrapMode: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/Wrap, verticalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalAlign, horizontalAlign: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalAlign, horizontalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalFlowBias: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, verticalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle, horizontalStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/FlowStyle )` Flow helpers allows a long sequence of Composable widgets to wrap onto multiple rows or columns. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGrid(kotlin.Array,kotlin.Int,kotlin.Int,kotlin.Boolean,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.FloatArray,kotlin.FloatArray,kotlin.Array,kotlin.Array,androidx.constraintlayout.compose.GridFlag)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, rows: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 1) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, columns: @https://developer.android.com/reference/kotlin/androidx/annotation/IntRange(from = 1) https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, isHorizontalArrangement: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, verticalSpacing: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, horizontalSpacing: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, rowWeights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html, columnWeights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html, skips: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/Skip>, spans: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/Span>, flags: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/GridFlag )` Helper that creates a fixed Grid layout. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromAbsoluteLeft(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a width fraction from the left of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromAbsoluteLeft(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the left of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromAbsoluteRight(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a width fraction from the right of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromAbsoluteRight(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the right of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromBottom(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a height percentage from the bottom of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromBottom(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the bottom of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromEnd(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a width fraction from the end of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromEnd(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the end of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromStart(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a specific offset from the start of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromStart(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the start of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromTop(kotlin.Float)(fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Creates a guideline at a height fraction from the top of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createGuidelineFromTop(androidx.compose.ui.unit.Dp)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates a guideline at a specific offset from the top of the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/HorizontalChainReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createHorizontalChain(kotlin.Array,androidx.constraintlayout.compose.ChainStyle)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, chainStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ChainStyle )` Creates a horizontal chain including the referenced layouts. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createRow(kotlin.Array,androidx.compose.ui.unit.Dp,kotlin.FloatArray)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, spacing: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, weights: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float-array/index.html )` Creates a Grid based helper that lays out its elements in a single Row. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.VerticalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createStartBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns a start barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope.HorizontalAnchor` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createTopBarrier(kotlin.Array,androidx.compose.ui.unit.Dp)(vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, margin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Creates and returns a top barrier, containing the specified elements. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/VerticalChainReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#createVerticalChain(kotlin.Array,androidx.constraintlayout.compose.ChainStyle)( vararg elements: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference, chainStyle: https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ChainStyle )` Creates a vertical chain including the referenced layouts. | | `open operator https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#equals(kotlin.Any)(other: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html?)` | | `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#hashCode()()` | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference.https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#(androidx.constraintlayout.compose.LayoutReference).withChainParams(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)( startMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, topMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, endMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, bottomMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, startGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, topGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, endGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, bottomGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Sets the parameters that are used by chains to customize the resulting layout. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference.https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#(androidx.constraintlayout.compose.LayoutReference).withHorizontalChainParams(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)( startMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, endMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, startGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, endGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Sets the parameters that are used by horizontal chains to customize the resulting layout. | | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/LayoutReference.https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#(androidx.constraintlayout.compose.LayoutReference).withVerticalChainParams(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)( topMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, bottomMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, topGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, bottomGoneMargin: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, weight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html )` Sets the parameters that are used by vertical chains to customize the resulting layout. | |

| ### Inherited properties |
|---|
| From [androidx.constraintlayout.compose.ConstraintLayoutBaseScope](https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope) |---|---| | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html<(https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/State) -> https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html>` | `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutBaseScope#tasks()` **This property is deprecated.** Tasks is unused, it breaks the immutability promise. | |

## Public functions

### Modifier.constrainAs

Artifact: [androidx.constraintlayout:constraintlayout-compose](https://developer.android.com/jetpack/androidx/releases/constraintlayout) [View Source](https://cs.android.com/search?q=file:androidx/constraintlayout/compose/ConstraintLayout.kt+function:constrainAs) Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun Modifier.constrainAs(
    ref: ConstrainedLayoutReference,
    constrainBlock: ConstrainScope.() -> Unit
): Modifier
```

`https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier` that defines the constraints, as part of a `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)`, of the layout element.

### createRef

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun createRef(): ConstrainedLayoutReference
```

Creates one `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference`, which needs to be assigned to a layout within the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)` as part of `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#(androidx.compose.ui.Modifier).constrainAs(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)`. To create more references at the same time, see `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#createRefs()`.

### createRefs

Added in [1.1.2](https://developer.android.com/jetpack/androidx/releases/constraintlayout#1.1.2)

```
fun createRefs(): ConstraintLayoutScope.ConstrainedLayoutReferences
```

Convenient way to create multiple `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstrainedLayoutReference`s, which need to be assigned to layouts within the `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayout.composable#ConstraintLayout(androidx.compose.ui.Modifier,kotlin.Int,androidx.compose.animation.core.AnimationSpec,kotlin.Function0,kotlin.Function1)` as part of `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#(androidx.compose.ui.Modifier).constrainAs(androidx.constraintlayout.compose.ConstrainedLayoutReference,kotlin.Function1)`. To create just one reference, see `https://developer.android.com/reference/kotlin/androidx/constraintlayout/compose/ConstraintLayoutScope#createRef()`.

### reset

```
open fun reset(): Unit
```