# androidx.compose.foundation

Common/AllAndroid/JVM

## Interfaces

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurfaceScope` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurfaceScope` is a scoped environment provided when an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable#AndroidExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.foundation.AndroidExternalSurfaceZOrder,kotlin.Boolean,kotlin.Function1)` or `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidEmbeddedExternalSurface.composable#AndroidEmbeddedExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.ui.graphics.Matrix,kotlin.Function1)` is first initialized. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipState` | The state that is associated with an instance of a tooltip. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Indication` | Indication represents visual effects that occur when certain interactions happens. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/IndicationInstance` | **This interface is deprecated.** IndicationInstance has been deprecated along with the rememberUpdatedInstance that returns it. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/IndicationNodeFactory` | IndicationNodeFactory is an Indication that creates `https://developer.android.com/reference/kotlin/androidx/compose/ui/Modifier.Node` instances to render visual effects that occur when certain interactions happens. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MarqueeSpacing` | Defines a `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MarqueeSpacing#(androidx.compose.ui.unit.Density).calculateSpacing(kotlin.Int,kotlin.Int)` method that determines the space after the end of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/basicMarquee.modifier#(androidx.compose.ui.Modifier).basicMarquee(kotlin.Int,androidx.compose.foundation.MarqueeAnimationMode,kotlin.Int,kotlin.Int,androidx.compose.foundation.MarqueeSpacing,androidx.compose.ui.unit.Dp)` content before drawing the content again. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` | An OverscrollEffect represents a visual effect that displays when the edges of a scrolling container have been reached with a scroll or fling. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory` | A factory for creating `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect`s. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/ScrollIndicatorState` | Represents the state required to draw a scroll indicator (e.g., a scrollbar), which is typically provided by a scrollable component. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/SurfaceCoroutineScope` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/SurfaceCoroutineScope` is a scoped environment provided by `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable#AndroidExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.foundation.AndroidExternalSurfaceZOrder,kotlin.Boolean,kotlin.Function1)` and `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidEmbeddedExternalSurface.composable#AndroidEmbeddedExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.ui.graphics.Matrix,kotlin.Function1)` when a new `https://developer.android.com/reference/android/view/Surface.html` is created. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/SurfaceScope` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/SurfaceScope` is a scoped environment provided by `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable#AndroidExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.foundation.AndroidExternalSurfaceZOrder,kotlin.Boolean,kotlin.Function1)` and `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidEmbeddedExternalSurface.composable#AndroidEmbeddedExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.ui.graphics.Matrix,kotlin.Function1)` to handle `https://developer.android.com/reference/android/view/Surface.html` lifecycle events. | android |

## Classes

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurfaceZOrder` | Defines the z-order of an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable#AndroidExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.foundation.AndroidExternalSurfaceZOrder,kotlin.Boolean,kotlin.Function1)`. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BorderStroke` | Class to specify the stroke to draw border with. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MarqueeAnimationMode` | Specifies when the `https://developer.android.com/reference/kotlin/androidx/compose/foundation/basicMarquee.modifier#(androidx.compose.ui.Modifier).basicMarquee(kotlin.Int,androidx.compose.foundation.MarqueeAnimationMode,kotlin.Int,kotlin.Int,androidx.compose.foundation.MarqueeSpacing,androidx.compose.ui.unit.Dp)` animation runs. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MutatorMutex` | Mutual exclusion for UI state mutation over time. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollConfiguration` | **This class is deprecated.** Providing \`OverscrollConfiguration\` through \`LocalOverscrollConfiguration\` to disable / configure overscroll has been replaced with \`LocalOverscrollFactory\` and \`rememberPlatformOverscrollFactory\`. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/ScrollState` | State of the scroll. | Cmn |

## Objects

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidComposeFoundationFlags` | This is a collection of flags which are used to guard against regressions in some of the "riskier" refactors or new feature support that is added to this module. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipDefaults` | BasicTooltip defaults that contain default values for tooltips created. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/ComposeFoundationFlags` | This is a collection of flags which are used to guard against regressions in some of the "riskier" refactors or new feature support that is added to this module. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MarqueeDefaults` | Namespace for constants representing the default values for various `https://developer.android.com/reference/kotlin/androidx/compose/foundation/basicMarquee.modifier#(androidx.compose.ui.Modifier).basicMarquee(kotlin.Int,androidx.compose.foundation.MarqueeAnimationMode,kotlin.Int,kotlin.Int,androidx.compose.foundation.MarqueeSpacing,androidx.compose.ui.unit.Dp)` parameters. | Cmn |

## Annotations

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/ExperimentalFoundationApi` |   | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/InternalFoundationApi` |   | Cmn |

## Enums

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MutatePriority` | Priorities for performing mutation on state. | Cmn |

## Composables

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidEmbeddedExternalSurface.composable` | Provides a dedicated drawing `https://developer.android.com/reference/android/view/Surface.html` embedded directly in the UI hierarchy. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable` | Provides a dedicated drawing `https://developer.android.com/reference/android/view/Surface.html` as a separate layer positioned by default behind the window holding the `https://developer.android.com/reference/kotlin/androidx/compose/foundation/AndroidExternalSurface.composable#AndroidExternalSurface(androidx.compose.ui.Modifier,kotlin.Boolean,androidx.compose.ui.unit.IntSize,androidx.compose.foundation.AndroidExternalSurfaceZOrder,kotlin.Boolean,kotlin.Function1)` composable. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipBox.composable` | BasicTooltipBox that wraps a composable with a tooltip. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Canvas.composable` | Component that allow you to specify an area on the screen and perform canvas drawing on this area. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Image.composable` | A composable that lays out and draws a given `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/vector/ImageVector`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/isSystemInDarkTheme.composable` | Returns whether the operating system is in dark theme. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/rememberBasicTooltipState.composable` | Create and remember the default `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipState`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/rememberOverscrollEffect.composable` | Returns a remembered `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` created from the current value of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#LocalOverscrollFactory()`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/rememberPlatformOverscrollFactory.composable` | Creates and remembers an instance of the platform `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory`, with the provided `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#rememberPlatformOverscrollFactory(androidx.compose.ui.graphics.Color,androidx.compose.foundation.layout.PaddingValues)` and `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#rememberPlatformOverscrollFactory(androidx.compose.ui.graphics.Color,androidx.compose.foundation.layout.PaddingValues)` values - these values will be used on platform versions where glow overscroll is used. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/rememberScrollState.composable` | Create and `https://developer.android.com/reference/kotlin/androidx/compose/runtime/remember.composable#remember(kotlin.Function0)` the `https://developer.android.com/reference/kotlin/androidx/compose/foundation/ScrollState` based on the currently appropriate scroll configuration to allow changing scroll position or observing scroll behavior. | Cmn |

## Modifiers

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/background.modifier` | Draws `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).background(androidx.compose.ui.graphics.Color,androidx.compose.ui.graphics.Shape)` with a solid `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).background(androidx.compose.ui.graphics.Color,androidx.compose.ui.graphics.Shape)` behind the content. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/basicMarquee.modifier` | Applies an animated marquee effect to the modified content if it's too wide to fit in the available space. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/border.modifier` | Modify element to add border with appearance specified with a `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).border(androidx.compose.foundation.BorderStroke,androidx.compose.ui.graphics.Shape)` and a `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).border(androidx.compose.foundation.BorderStroke,androidx.compose.ui.graphics.Shape)` and clip it. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/clickable.modifier` | Configure component to receive clicks via input or accessibility "click" event. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/clipScrollableContainer.modifier` | Clips bounds of scrollable container on main axis while leaving space for background effects (like shadows) on cross axis. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/combinedClickable.modifier` | Configure component to receive clicks, double clicks and long clicks via input or accessibility "click" event. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/excludeFromSystemGesture.modifier` | Excludes the layout rectangle from the system gesture. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/focusGroup.modifier` | Creates a focus group or marks this component as a focus group. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/focusable.modifier` | Configure component to be focusable via focus system or accessibility "focus" event. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/horizontalScroll.modifier` | Modify element to allow to scroll horizontally when width of the content is bigger than max constraints allow. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/hoverable.modifier` | Configure component to be hoverable via pointer enter/exit events. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/indication.modifier` | Draws visual effects for this component when interactions occur. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/magnifier.modifier` | Shows a `https://developer.android.com/reference/android/widget/Magnifier.html` widget that shows an enlarged version of the content at `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).magnifier(kotlin.Function1,kotlin.Function1,kotlin.Function1,kotlin.Float,androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Boolean)` relative to the current layout node. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/onFocusedBoundsChanged.modifier` | Modifier.onFocusedBoundsChanged has been deprecated, and its implementation has been removed. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/overscroll.modifier` | Renders overscroll from the provided `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.ui.Modifier).overscroll(androidx.compose.foundation.OverscrollEffect)`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/preferKeepClear.modifier` | Mark the layout rectangle as preferring to stay clear of floating windows. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/progressSemantics.modifier` | Contains the `https://developer.android.com/reference/kotlin/androidx/compose/ui/semantics/semantics.modifier#(androidx.compose.ui.Modifier).semantics(kotlin.Boolean,kotlin.Function1)` required for an indeterminate progress indicator, that represents the fact of the in-progress operation. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/scrollableArea.modifier` | Configure a component to act as a scrollable area. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/systemGestureExclusion.modifier` | Excludes the layout rectangle from the system gesture. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/verticalScroll.modifier` | Modify element to allow to scroll vertically when height of the content is bigger than max constraints allow. | Cmn |

## Top-level functions summary

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipState` | `@https://developer.android.com/reference/kotlin/androidx/compose/foundation/ExperimentalFoundationApi https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BasicTooltipState(kotlin.Boolean,kotlin.Boolean,androidx.compose.foundation.MutatorMutex)( initialIsVisible: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, isPersistent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html, mutatorMutex: https://developer.android.com/reference/kotlin/androidx/compose/foundation/MutatorMutex )` Constructor extension function for `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BasicTooltipState(kotlin.Boolean,kotlin.Boolean,androidx.compose.foundation.MutatorMutex)` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BorderStroke` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BorderStroke(androidx.compose.ui.unit.Dp,androidx.compose.ui.graphics.Color)(width: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, color: https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/Color)` Create `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BorderStroke(androidx.compose.ui.unit.Dp,androidx.compose.ui.graphics.Color)` class with width and `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/Color` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MarqueeSpacing` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#MarqueeSpacing(androidx.compose.ui.unit.Dp)(spacing: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` A `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#MarqueeSpacing(androidx.compose.ui.unit.Dp)` with a fixed size. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#checkScrollableContainerConstraints(androidx.compose.ui.unit.Constraints,androidx.compose.foundation.gestures.Orientation)( constraints: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints, orientation: https://developer.android.com/reference/kotlin/androidx/compose/foundation/gestures/Orientation )` | Cmn |

## Extension functions summary

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect.https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutEventHandling()()` Returns a wrapped version of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` that will not handle any incoming events. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect.https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutVisualEffect()()` Returns a wrapped version of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` with an empty `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect#node()`. | Cmn |

## Top-level properties summary

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/runtime/ProvidableCompositionLocal<https://developer.android.com/reference/kotlin/androidx/compose/foundation/Indication>` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#LocalIndication()` CompositionLocal that provides an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Indication` through the hierarchy. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/runtime/ProvidableCompositionLocal<https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollConfiguration?>` | `@https://developer.android.com/reference/kotlin/androidx/compose/foundation/ExperimentalFoundationApi https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#LocalOverscrollConfiguration()` **This property is deprecated.** Providing \`OverscrollConfiguration\` through \`LocalOverscrollConfiguration\` to disable / configure overscroll has been replaced with \`LocalOverscrollFactory\` and \`rememberPlatformOverscrollFactory\`. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/runtime/ProvidableCompositionLocal<https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory?>` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#LocalOverscrollFactory()` CompositionLocal that provides an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory` through the hierarchy. | Cmn |

## Top-level functions

### BasicTooltipState

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/BasicTooltip.kt+function:BasicTooltipState) Added in [1.6.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.6.0)

```
@ExperimentalFoundationApi
fun BasicTooltipState(
    initialIsVisible: Boolean = false,
    isPersistent: Boolean = true,
    mutatorMutex: MutatorMutex = BasicTooltipDefaults.GlobalMutatorMutex
): BasicTooltipState
```

Constructor extension function for `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BasicTooltipState(kotlin.Boolean,kotlin.Boolean,androidx.compose.foundation.MutatorMutex)`

| Parameters |
|---|---|
| `initialIsVisible: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html = false` | the initial value for the tooltip's visibility when drawn. |
| `isPersistent: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html = true` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` that determines if the tooltip associated with this will be persistent or not. If isPersistent is true, then the tooltip will only be dismissed when the user clicks outside the bounds of the tooltip or if `https://developer.android.com/reference/kotlin/androidx/compose/foundation/BasicTooltipState#dismiss()` is called. When isPersistent is false, the tooltip will dismiss after a short duration. Ideally, this should be set to true when there is actionable content being displayed within a tooltip. |
| `mutatorMutex: https://developer.android.com/reference/kotlin/androidx/compose/foundation/MutatorMutex = BasicTooltipDefaults.GlobalMutatorMutex` | `https://developer.android.com/reference/kotlin/androidx/compose/foundation/MutatorMutex` used to ensure that for all of the tooltips associated with the mutator mutex, only one will be shown on the screen at any time. |

### BorderStroke

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

```
fun BorderStroke(width: Dp, color: Color): BorderStroke
```

Create `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#BorderStroke(androidx.compose.ui.unit.Dp,androidx.compose.ui.graphics.Color)` class with width and `https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/Color`

| Parameters |
|---|---|
| `width: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | width of the border in `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`. Use `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Hairline()` for one-pixel border. |
| `color: https://developer.android.com/reference/kotlin/androidx/compose/ui/graphics/Color` | color to paint the border with |

### MarqueeSpacing

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/BasicMarquee.kt+function:MarqueeSpacing) Added in [1.10.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.10.0)

```
fun MarqueeSpacing(spacing: Dp): MarqueeSpacing
```

A `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#MarqueeSpacing(androidx.compose.ui.unit.Dp)` with a fixed size.

### checkScrollableContainerConstraints

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/CheckScrollableContainerConstraints.kt+function:checkScrollableContainerConstraints) Added in [1.10.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.10.0)

```
fun checkScrollableContainerConstraints(
    constraints: Constraints,
    orientation: Orientation
): Unit
```

| Parameters |
|---|---|
| `constraints: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` used to measure the scrollable container |
| `orientation: https://developer.android.com/reference/kotlin/androidx/compose/foundation/gestures/Orientation` | orientation of the scrolling |

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-state-exception/index.html` | if the container was measured with the infinity constraints in the direction of scrolling. This usually means nesting scrollable in the same direction containers which is a performance issue and is discouraged. |

## Extension functions

### OverscrollEffect.withoutEventHandling

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/Overscroll.kt+function:withoutEventHandling) Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.8.0)

```
fun OverscrollEffect.withoutEventHandling(): OverscrollEffect
```

Returns a wrapped version of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` that will not handle any incoming events. This means that calls to `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect#applyToScroll(androidx.compose.ui.geometry.Offset,androidx.compose.ui.input.nestedscroll.NestedScrollSource,kotlin.Function1)` / `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect#applyToFling(androidx.compose.ui.unit.Velocity,kotlin.coroutines.SuspendFunction1)` will directly execute the provided performScroll / performFling lambdas, without the `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` ever seeing the incoming values. `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect#node()` will still be attached, so that overscroll can render.

This can be useful if you want to render an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` in a different component that normally provides events to overscroll, such as a `https://developer.android.com/reference/kotlin/androidx/compose/foundation/lazy/LazyColumn.composable#LazyColumn(androidx.compose.ui.Modifier,androidx.compose.foundation.lazy.LazyListState,androidx.compose.foundation.layout.PaddingValues,kotlin.Boolean,androidx.compose.foundation.layout.Arrangement.Vertical,androidx.compose.ui.Alignment.Horizontal,androidx.compose.foundation.gestures.FlingBehavior,kotlin.Boolean,androidx.compose.foundation.OverscrollEffect,androidx.compose.foundation.lazy.layout.LazyLayoutCacheWindow,kotlin.Function1)`. Use this along with `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutVisualEffect()` to create two wrapped instances: one that does not handle events, and one that does not draw, so you can ensure that the overscroll effect is only rendered once, and only receives events from one source.

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutVisualEffect()` |   |

### OverscrollEffect.withoutVisualEffect

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/Overscroll.kt+function:withoutVisualEffect) Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.8.0)

```
fun OverscrollEffect.withoutVisualEffect(): OverscrollEffect
```

Returns a wrapped version of `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` with an empty `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect#node()`. This prevents the overscroll effect from applying any visual effect, but it will still handle events.

This can be used along with `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutEventHandling()` in cases where you wish to change where overscroll is rendered for a given component. Pass this wrapped instance that doesn't render to the component that handles events (such as `https://developer.android.com/reference/kotlin/androidx/compose/foundation/lazy/LazyColumn.composable#LazyColumn(androidx.compose.ui.Modifier,androidx.compose.foundation.lazy.LazyListState,androidx.compose.foundation.layout.PaddingValues,kotlin.Boolean,androidx.compose.foundation.layout.Arrangement.Vertical,androidx.compose.ui.Alignment.Horizontal,androidx.compose.foundation.gestures.FlingBehavior,kotlin.Boolean,androidx.compose.foundation.OverscrollEffect,androidx.compose.foundation.lazy.layout.LazyLayoutCacheWindow,kotlin.Function1)`) to prevent it from drawing the overscroll effect. Then to separately render the original overscroll effect, you can directly pass it to `https://developer.android.com/reference/kotlin/androidx/compose/foundation/overscroll.modifier#(androidx.compose.ui.Modifier).overscroll(androidx.compose.foundation.OverscrollEffect)` (since that modifier only renders, and does not handle events). If instead you want to draw the overscroll in another component that handles events, such as a different lazy list, you need to first wrap the original overscroll effect with `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutEventHandling()` to prevent it from also dispatching events.

```kotlin
import androidx.compose.foundation.OverscrollEffect
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.lazy.items
import androidx.compose.foundation.lazy.rememberLazyListState
import androidx.compose.foundation.overscroll
import androidx.compose.foundation.rememberOverscrollEffect
import androidx.compose.foundation.withoutVisualEffect
import androidx.compose.material3.Text
import androidx.compose.runtime.remember
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.draw.drawBehind
import androidx.compose.ui.geometry.Offset
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.graphics.RectangleShape
import androidx.compose.ui.unit.dp

val items = remember { (1..100).toList() }
val state = rememberLazyListState()
val overscroll = rememberOverscrollEffect()
// Create a wrapped version of the above overscroll effect that does not apply a visual effect.
// This will be used inside LazyColumn to provide events to overscroll, without letting
// LazyColumn render the overscroll effect internally.
val overscrollWithoutVisualEffect = overscroll?.withoutVisualEffect()
LazyColumn(
    content = { items(items) { Text("Item $it") } },
    state = state,
    modifier =
        Modifier.size(300.dp)
            .clip(RectangleShape)
            // Manually render the overscroll on top of the lazy list _and_ the 'decorations' we
            // are
            // manually drawing, to make sure they will also be included in the overscroll
            // effect.
            .overscroll(overscroll)
            .drawBehind {
                state.layoutInfo.visibleItemsInfo.drop(1).forEach { info ->
                    val verticalOffset = info.offset.toFloat()
                    drawLine(
                        color = Color.Red,
                        start = Offset(0f, verticalOffset),
                        end = Offset(size.width, verticalOffset),
                    )
                }
            },
    // Pass the overscroll effect that does not apply a visual effect inside the LazyList to
    // receive overscroll events
    overscrollEffect = overscrollWithoutVisualEffect,
)
```

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/foundation/package-summary#(androidx.compose.foundation.OverscrollEffect).withoutEventHandling()` |   |

## Top-level properties

### LocalIndication

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/Indication.kt+symbol:LocalIndication) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.0.0)

```
val LocalIndication: ProvidableCompositionLocal<Indication>
```

CompositionLocal that provides an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Indication` through the hierarchy. This `https://developer.android.com/reference/kotlin/androidx/compose/foundation/Indication` will be used by default to draw visual effects for interactions such as press and drag in components such as `https://developer.android.com/reference/kotlin/androidx/compose/foundation/clickable.modifier#(androidx.compose.ui.Modifier).clickable(kotlin.Boolean,kotlin.String,androidx.compose.ui.semantics.Role,androidx.compose.foundation.interaction.MutableInteractionSource,kotlin.Function0)`.

By default this will provide a debug indication, this should always be replaced.

### LocalOverscrollConfiguration

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

```
@ExperimentalFoundationApi
val LocalOverscrollConfiguration: ProvidableCompositionLocal<OverscrollConfiguration?>
```

> [!CAUTION]
> **This property is deprecated.**   
> Providing \`OverscrollConfiguration\` through \`LocalOverscrollConfiguration\` to disable / configure overscroll has been replaced with \`LocalOverscrollFactory\` and \`rememberPlatformOverscrollFactory\`. To disable overscroll, instead of \`LocalOverscrollConfiguration provides null\`, use \`LocalOverscrollFactory provides null\`. To change the glow color / padding, instead of \`LocalOverscrollConfiguration provides OverscrollConfiguration(myColor, myPadding)\`, use \`LocalOverscrollFactory provides rememberPlatformOverscrollFactory(myColor, myPadding)\`, use this instead:
>
> ```kotlin
> LocalOverscrollFactory
> ```

Composition local to provide configuration for scrolling containers down the hierarchy. `null` means there will be no overscroll at all.

### LocalOverscrollFactory

Cmn Artifact: [androidx.compose.foundation:foundation](https://developer.android.com/jetpack/androidx/releases/compose-foundation) [View Source](https://cs.android.com/search?q=file:androidx/compose/foundation/Overscroll.kt+symbol:LocalOverscrollFactory) Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/compose-foundation#1.8.0)

```
val LocalOverscrollFactory: ProvidableCompositionLocal<OverscrollFactory?>
```

CompositionLocal that provides an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory` through the hierarchy. This will be used by default by scrolling components, so you can provide an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollFactory` here to override the overscroll used by components within a hierarchy.

See `https://developer.android.com/reference/kotlin/androidx/compose/foundation/rememberOverscrollEffect.composable#rememberOverscrollEffect()` to remember an `https://developer.android.com/reference/kotlin/androidx/compose/foundation/OverscrollEffect` from the current provided value.