# ScalingLazyListItemScope

# ScalingLazyListItemScope

Artifact:[androidx.wear.compose:compose-foundation](https://developer.android.com/jetpack/androidx/releases/wear-compose)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope.kt+class:androidx.wear.compose.foundation.lazy.ScalingLazyListItemScope)  
Added in[1.2.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.2.0)

<br />

```
@ScalingLazyScopeMarker
sealed interface ScalingLazyListItemScope
```

<br />

*** ** * ** ***

Receiver scope being used by the item content parameter of ScalingLazyColumn.

## Summary

|                                  ### Public functions                                   |
|-----------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier) | [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier)`.`[fillParentMaxHeight](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxHeight(kotlin.Float))`(` ` fraction: @`[FloatRange](https://developer.android.com/reference/kotlin/androidx/annotation/FloatRange)`(from = 0.0, to = 1.0) `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html) `)` Have the content fill the[Constraints.maxHeight](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())of the incoming measurement constraints by setting the[minimum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minHeight())to be equal to the[maximum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxHeight(kotlin.Float)).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier) | [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier)`.`[fillParentMaxSize](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float))`(` ` fraction: @`[FloatRange](https://developer.android.com/reference/kotlin/androidx/annotation/FloatRange)`(from = 0.0, to = 1.0) `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html) `)` Have the content fill the[Constraints.maxWidth](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())and[Constraints.maxHeight](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())of the parent measurement constraints by setting the[minimum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minWidth())to be equal to the[maximum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float))and the[minimum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minHeight())to be equal to the[maximum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float)). |
| [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier) | [Modifier](https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier)`.`[fillParentMaxWidth](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxWidth(kotlin.Float))`(` ` fraction: @`[FloatRange](https://developer.android.com/reference/kotlin/androidx/annotation/FloatRange)`(from = 0.0, to = 1.0) `[Float](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html) `)` Have the content fill the[Constraints.maxWidth](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())of the parent measurement constraints by setting the[minimum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minWidth())to be equal to the[maximum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxWidth(kotlin.Float)).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |

## Public functions

### fillParentMaxHeight

Artifact:[androidx.wear.compose:compose-foundation](https://developer.android.com/jetpack/androidx/releases/wear-compose)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope.kt+function:fillParentMaxHeight)  
Added in[1.2.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.2.0)  

```
fun Modifier.fillParentMaxHeight(
    fraction: @FloatRange(from = 0.0, to = 1.0) Float = 1.0f
): Modifier
```

Have the content fill the[Constraints.maxHeight](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())of the incoming measurement constraints by setting the[minimum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minHeight())to be equal to the[maximum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxHeight(kotlin.Float)). Note that, by default, the[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxHeight(kotlin.Float))is 1, so the modifier will make the content fill the whole parent height.[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxHeight(kotlin.Float))must be between`0`and`1`.

Regular Modifier.fillMaxHeight can't work inside the scrolling vertically layouts as the items are measured with[Constraints.Infinity](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#Infinity())as the constraints for the main axis.  

### fillParentMaxSize

Artifact:[androidx.wear.compose:compose-foundation](https://developer.android.com/jetpack/androidx/releases/wear-compose)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope.kt+function:fillParentMaxSize)  
Added in[1.2.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.2.0)  

```
fun Modifier.fillParentMaxSize(
    fraction: @FloatRange(from = 0.0, to = 1.0) Float = 1.0f
): Modifier
```

Have the content fill the[Constraints.maxWidth](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())and[Constraints.maxHeight](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())of the parent measurement constraints by setting the[minimum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minWidth())to be equal to the[maximum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float))and the[minimum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minHeight())to be equal to the[maximum height](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxHeight())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float)). Note that, by default, the[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float))is 1, so the modifier will make the content fill the whole available space.[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxSize(kotlin.Float))must be between`0`and`1`.

Regular Modifier.fillMaxSize can't work inside the scrolling layouts as the items are measured with[Constraints.Infinity](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#Infinity())as the constraints for the main axis.  

### fillParentMaxWidth

Artifact:[androidx.wear.compose:compose-foundation](https://developer.android.com/jetpack/androidx/releases/wear-compose)  
[View Source](https://cs.android.com/search?q=file:androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope.kt+function:fillParentMaxWidth)  
Added in[1.2.0](https://developer.android.com/jetpack/androidx/releases/wear-compose#1.2.0)  

```
fun Modifier.fillParentMaxWidth(
    fraction: @FloatRange(from = 0.0, to = 1.0) Float = 1.0f
): Modifier
```

Have the content fill the[Constraints.maxWidth](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())of the parent measurement constraints by setting the[minimum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#minWidth())to be equal to the[maximum width](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#maxWidth())multiplied by[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxWidth(kotlin.Float)). Note that, by default, the[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxWidth(kotlin.Float))is 1, so the modifier will make the content fill the whole parent width.[fraction](https://developer.android.com/reference/kotlin/androidx/wear/compose/foundation/lazy/ScalingLazyListItemScope#(androidx.compose.ui.Modifier).fillParentMaxWidth(kotlin.Float))must be between`0`and`1`.

Regular Modifier.fillMaxWidth can't work inside the scrolling horizontally layouts as the items are measured with[Constraints.Infinity](https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#Infinity())as the constraints for the main axis.