# androidx.compose.ui.unit

Common/AllAndroid/JVM

## Interfaces

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Density` | A density of the screen. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/FontScaling` | Converts `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` and vice-versa. | Cmn android |

## Classes

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` | Immutable constraints for measuring layouts, used by `https://developer.android.com/reference/kotlin/androidx/compose/ui/layout/Layout.composable#Layout(kotlin.Function0,androidx.compose.ui.Modifier,androidx.compose.ui.layout.MeasurePolicy)` or `https://developer.android.com/reference/kotlin/androidx/compose/ui/layout/LayoutModifier` to measure their layout children. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | Dimension value representing device-independent pixels (dp). | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` | A two-dimensional offset using `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` for units. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect` | A four dimensional bounds using `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` for units | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | A two-dimensional Size using `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` for units | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | A two-dimensional position using `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` pixels for units. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | An immutable, 2D, axis-aligned, integer bounds rectangle whose coordinates are relative to a given origin. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | A two-dimensional size class used for measuring in `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` pixels. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | The unit used for text related dimension value. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType` | An enum class defining for type of `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Velocity` | A two dimensional velocity in pixels per second. | Cmn |

## Objects

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/ComposeUiUnitFlags` | 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/ui/unit/Dp.Companion` |   | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset.Companion` |   | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset.Companion` |   | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize.Companion` |   | Cmn |

## Annotations

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/ExperimentalUnitApi` |   | Cmn |

## Enums

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/LayoutDirection` | A class for defining layout directions. | Cmn |

## Top-level functions summary

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)(minWidth: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, maxWidth: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, minHeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, maxHeight: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Density` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Density(android.content.Context)(context: https://developer.android.com/reference/android/content/Context.html)` Creates a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Density(android.content.Context)` for this `https://developer.android.com/reference/android/content/Context.html`. | android |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Density` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Density(kotlin.Float,kotlin.Float)(density: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, fontScale: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` A density of the screen. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)(x: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, y: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` position `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` values. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpSize(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)(width: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, height: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpSize(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpSize(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` values. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)(x: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, y: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` position `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` values. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntRect(androidx.compose.ui.unit.IntOffset,kotlin.Int)(center: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset, radius: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Construct a rectangle that bounds the given circle | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntRect(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntSize)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset, size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize)` Construct a rectangle from its left and top edges as well as its width and height. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntRect(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset)(topLeft: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset, bottomRight: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset)` Construct the smallest rectangle that encloses the given offsets, treating them as vectors from the origin. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntSize(kotlin.Int,kotlin.Int)(width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Constructs an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntSize(kotlin.Int,kotlin.Int)` from width and height `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` values. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#TextUnit(kotlin.Float,androidx.compose.ui.unit.TextUnitType)(value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, type: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType)` Construct a new TextUnit. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Velocity` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Velocity(kotlin.Float,kotlin.Float)(x: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html, y: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Constructs an Velocity from the given relative x and y velocities. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`s. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset`s. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize`s. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset`s. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two rectangles. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)(start: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit, stop: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit, fraction: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html)` Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`s. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#max(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)(a: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, b: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#min(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)(a: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, b: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` | Cmn |

## Extension functions summary

|---|---|---|
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtLeast(androidx.compose.ui.unit.Dp)(minimumValue: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Ensures that this value is not less than the specified `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtLeast(androidx.compose.ui.unit.Dp)`. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtMost(androidx.compose.ui.unit.Dp)(maximumValue: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Ensures that this value is not greater than the specified `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtMost(androidx.compose.ui.unit.Dp)`. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)(minimumValue: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp, maximumValue: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` Ensures that this value lies in the specified range `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)`.. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrain(androidx.compose.ui.unit.Constraints)(otherConstraints: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints)` Takes `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrain(androidx.compose.ui.unit.Constraints)` and returns the result of coercing them in the current constraints. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrain(androidx.compose.ui.unit.IntSize)(size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize)` Takes a size and returns the closest size to it that satisfies the constraints. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrainHeight(kotlin.Int)(height: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Takes a height and returns the closest size to it that satisfies the constraints. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrainWidth(kotlin.Int)(width: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Takes a width and returns the closest size to it that satisfies the constraints. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).isSatisfiedBy(androidx.compose.ui.unit.IntSize)(size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize)` Takes a size and returns whether it satisfies the current constraints. | Cmn |
| `operator https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Offset).minus(androidx.compose.ui.unit.IntOffset)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset)` | Cmn |
| `operator https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntOffset).minus(androidx.compose.ui.geometry.Offset)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset)` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).offset(kotlin.Int,kotlin.Int)(horizontal: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html, vertical: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)` Returns the Constraints obtained by offsetting the current instance with the given values. | Cmn |
| `operator https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Offset).plus(androidx.compose.ui.unit.IntOffset)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset)` | Cmn |
| `operator https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntOffset).plus(androidx.compose.ui.geometry.Offset)(offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset)` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Offset).round()()` Round a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` down to the nearest `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` coordinates. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Rect).roundToIntRect()()` Rounds a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Size).roundToIntSize()()` Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).takeOrElse(kotlin.Function0)(block: () -> https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).takeOrElse(kotlin.Function0)` is executed and its result is returned. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpOffset).takeOrElse(kotlin.Function0)(block: () -> https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset)` If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpOffset).takeOrElse(kotlin.Function0)` is executed and its result is returned. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).takeOrElse(kotlin.Function0)(block: () -> https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize)` If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).takeOrElse(kotlin.Function0)` is executed and its result is returned. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.TextUnit).takeOrElse(kotlin.Function0)(block: () -> https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit)` If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.TextUnit).takeOrElse(kotlin.Function0)` is executed and its result is returned. | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).times(androidx.compose.ui.unit.Dp)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Double).times(androidx.compose.ui.unit.Dp)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.Dp)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp)` | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).times(androidx.compose.ui.unit.TextUnit)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit)` Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar. | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Double).times(androidx.compose.ui.unit.TextUnit)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit)` Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar. | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.TextUnit)(other: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit)` Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar. | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.DpSize)(size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize)` | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).times(androidx.compose.ui.unit.DpSize)(size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize)` | Cmn |
| `inline operator https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.IntSize)(size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize)` Returns an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` with `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.IntSize)`'s `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#width()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#height()` multiplied by `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntSize).toIntRect()()` Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` to a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.geometry.Size).toIntSize()()` Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`. | Cmn |
| `inline https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntOffset).toOffset()()` Converts the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntRect).toRect()()` Converts an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` to a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntSize).toSize()()` | Cmn |

## Extension properties summary

|---|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).center()` Returns the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` of the center of the rect from the point of 0, 0 with this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.IntSize).center()` Returns the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` of the center of the rect from the point of 0, 0 with this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Double).dp()` Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html`: val left = 10.0 val x = left.dp // -- or -- val y = 10.0.dp | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).dp()` Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html`: val left = 10f val x = left.dp // -- or -- val y = 10f.dp | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).dp()` Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using an `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html`: val left = 10 val x = left.dp // -- or -- val y = 10.dp | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Double).em()` Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).em()` Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).em()` Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpRect).height()` A height of this Bounds in `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).isFinite()` Return `true` when it is finite or `false` when it is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Infinity()` | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).isSpecified()` `false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpOffset).isSpecified()` `false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).isSpecified()` `false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.TextUnit).isSpecified()` `false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).isUnspecified()` `true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpOffset).isUnspecified()` `true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).isUnspecified()` `true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize#Unspecified()`. | Cmn |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.TextUnit).isUnspecified()` `true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpRect).size()` Returns the size of the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect`. | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Double).sp()` Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Float).sp()` Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).sp()` Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` | Cmn |
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect.https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpRect).width()` A width of this Bounds in `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`. | Cmn |

## Top-level functions

### Constraints

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

```
fun Constraints(
    minWidth: Int = 0,
    maxWidth: Int = Infinity,
    minHeight: Int = 0,
    maxHeight: Int = Infinity
): Constraints
```

Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)`. `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)` must be positive and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)` must be greater than or equal to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Constraints(kotlin.Int,kotlin.Int,kotlin.Int,kotlin.Int)`, respectively, or `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Constraints#Infinity()`.

### Density

android Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/AndroidDensity.android.kt+function:Density)

```
fun Density(context: Context): Density
```

Creates a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#Density(android.content.Context)` for this `https://developer.android.com/reference/android/content/Context.html`.

| Parameters |
|---|---|
| `context: https://developer.android.com/reference/android/content/Context.html` | density values will be extracted from this `https://developer.android.com/reference/android/content/Context.html` |

### Density

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

```
fun Density(density: Float, fontScale: Float = 1.0f): Density
```

A density of the screen. Used for convert `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` to pixels.

| Parameters |
|---|---|
| `density: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | The logical density of the display. This is a scaling factor for the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` unit. |
| `fontScale: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html = 1.0f` | Current user preference for the scaling factor for fonts. |

### DpOffset

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

```
inline fun DpOffset(x: Dp, y: Dp): DpOffset
```

Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpOffset(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` position `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` values.

### DpSize

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

```
fun DpSize(width: Dp, height: Dp): DpSize
```

Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpSize(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#DpSize(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` values.

### IntOffset

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

```
inline fun IntOffset(x: Int, y: Int): IntOffset
```

Constructs a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` from `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntOffset(kotlin.Int,kotlin.Int)` position `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` values.

### IntRect

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

```
fun IntRect(center: IntOffset, radius: Int): IntRect
```

Construct a rectangle that bounds the given circle

| Parameters |
|---|---|
| `center: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | Offset that represents the center of the circle |
| `radius: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | Radius of the circle to enclose |

### IntRect

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

```
fun IntRect(offset: IntOffset, size: IntSize): IntRect
```

Construct a rectangle from its left and top edges as well as its width and height.

| Parameters |
|---|---|
| `offset: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | Offset to represent the top and left parameters of the Rect |
| `size: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` | Size to determine the width and height of this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntRect(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntSize)`. |

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` | Rect with `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect#left()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect#top()` configured to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset#x()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset#y()` as `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect#right()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect#bottom()` to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset#x()` + `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#width()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset#y()` + `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#height()` respectively |

### IntRect

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

```
fun IntRect(topLeft: IntOffset, bottomRight: IntOffset): IntRect
```

Construct the smallest rectangle that encloses the given offsets, treating them as vectors from the origin.

| Parameters |
|---|---|
| `topLeft: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | Offset representing the left and top edges of the rectangle |
| `bottomRight: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` | Offset representing the bottom and right edges of the rectangle |

### IntSize

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

```
inline fun IntSize(width: Int, height: Int): IntSize
```

Constructs an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#IntSize(kotlin.Int,kotlin.Int)` from width and height `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` values.

### TextUnit

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

```
fun TextUnit(value: Float, type: TextUnitType): TextUnit
```

Construct a new TextUnit.

| Parameters |
|---|---|
| `value: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | of the dimension |
| `type: https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType` | dimension |

### Velocity

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

```
fun Velocity(x: Float, y: Float): Velocity
```

Constructs an Velocity from the given relative x and y velocities.

| Parameters |
|---|---|
| `x: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | Horizontal component of the velocity in pixels per second |
| `y: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` | Vertical component of the velocity in pixels per second |

### lerp

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

```
fun lerp(start: Dp, stop: Dp, fraction: Float): Dp
```

Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`s.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)`), 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)`), and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid.

### lerp

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

```
fun lerp(start: DpOffset, stop: DpOffset, fraction: Float): DpOffset
```

Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset`s.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)`), 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)`), and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpOffset,androidx.compose.ui.unit.DpOffset,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid.

### lerp

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

```
fun lerp(start: DpSize, stop: DpSize, fraction: Float): DpSize
```

Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize`s.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)`, 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)`, and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.DpSize,androidx.compose.ui.unit.DpSize,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid.

### lerp

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

```
fun lerp(start: IntOffset, stop: IntOffset, fraction: Float): IntOffset
```

Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset`s.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)`), 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)`), and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntOffset,androidx.compose.ui.unit.IntOffset,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid.

### lerp

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

```
fun lerp(start: IntRect, stop: IntRect, fraction: Float): IntRect
```

Linearly interpolate between two rectangles.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)`), 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)`), and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid (and can easily be generated by curves).

Values for `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.IntRect,androidx.compose.ui.unit.IntRect,kotlin.Float)` are usually obtained from an Animation, such as an `AnimationController`.

### lerp

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

```
fun lerp(start: TextUnit, stop: TextUnit, fraction: Float): TextUnit
```

Linearly interpolate between two `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`s.

The `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` argument represents position on the timeline, with 0.0 meaning that the interpolation has not started, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)`), 1.0 meaning that the interpolation has finished, returning `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` (or something equivalent to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)`), and values in between meaning that the interpolation is at the relevant point on the timeline between `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)`. The interpolation can be extrapolated beyond 0.0 and 1.0, so negative values and values greater than 1.0 are valid.

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-argument-exception/index.html` | if `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#lerp(androidx.compose.ui.unit.TextUnit,androidx.compose.ui.unit.TextUnit,kotlin.Float)` have different `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType`s, or either of the two has its `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType` equal to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnitType#Unspecified()`. |

### max

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

```
inline fun max(a: Dp, b: Dp): Dp
```

### min

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

```
inline fun min(a: Dp, b: Dp): Dp
```

## Extension functions

### Dp.coerceAtLeast

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

```
inline fun Dp.coerceAtLeast(minimumValue: Dp): Dp
```

Ensures that this value is not less than the specified `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtLeast(androidx.compose.ui.unit.Dp)`.

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | this value if it's greater than or equal to the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtLeast(androidx.compose.ui.unit.Dp)` or the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtLeast(androidx.compose.ui.unit.Dp)` otherwise. |

### Dp.coerceAtMost

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

```
inline fun Dp.coerceAtMost(maximumValue: Dp): Dp
```

Ensures that this value is not greater than the specified `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtMost(androidx.compose.ui.unit.Dp)`.

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | this value if it's less than or equal to the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtMost(androidx.compose.ui.unit.Dp)` or the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceAtMost(androidx.compose.ui.unit.Dp)` otherwise. |

### Dp.coerceIn

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

```
inline fun Dp.coerceIn(minimumValue: Dp, maximumValue: Dp): Dp
```

Ensures that this value lies in the specified range `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)`..`https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)`.

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` | this value if it's in the range, or `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` if this value is less than `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)`, or `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)` if this value is greater than `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).coerceIn(androidx.compose.ui.unit.Dp,androidx.compose.ui.unit.Dp)`. |

### Constraints.constrain

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

```
fun Constraints.constrain(otherConstraints: Constraints): Constraints
```

Takes `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrain(androidx.compose.ui.unit.Constraints)` and returns the result of coercing them in the current constraints. Note this means that any size satisfying the resulting constraints will satisfy the current constraints, but they might not satisfy the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Constraints).constrain(androidx.compose.ui.unit.Constraints)` when the two set of constraints are disjoint. Examples (showing only width, height works the same): (minWidth=2, maxWidth=10).constrain(minWidth=7, maxWidth=12) -\> (minWidth = 7, maxWidth = 10) (minWidth=2, maxWidth=10).constrain(minWidth=11, maxWidth=12) -\> (minWidth=10, maxWidth=10) (minWidth=2, maxWidth=10).constrain(minWidth=5, maxWidth=7) -\> (minWidth=5, maxWidth=7)

### Constraints.constrain

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

```
fun Constraints.constrain(size: IntSize): IntSize
```

Takes a size and returns the closest size to it that satisfies the constraints.

### Constraints.constrainHeight

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

```
fun Constraints.constrainHeight(height: Int): Int
```

Takes a height and returns the closest size to it that satisfies the constraints.

### Constraints.constrainWidth

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

```
fun Constraints.constrainWidth(width: Int): Int
```

Takes a width and returns the closest size to it that satisfies the constraints.

### Constraints.isSatisfiedBy

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

```
fun Constraints.isSatisfiedBy(size: IntSize): Boolean
```

Takes a size and returns whether it satisfies the current constraints.

### Offset.minus

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

```
operator fun Offset.minus(offset: IntOffset): Offset
```

### IntOffset.minus

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

```
operator fun IntOffset.minus(offset: Offset): Offset
```

### Constraints.offset

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

```
fun Constraints.offset(horizontal: Int = 0, vertical: Int = 0): Constraints
```

Returns the Constraints obtained by offsetting the current instance with the given values.

### Offset.plus

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

```
operator fun Offset.plus(offset: IntOffset): Offset
```

### IntOffset.plus

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

```
operator fun IntOffset.plus(offset: Offset): Offset
```

### Offset.round

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

```
fun Offset.round(): IntOffset
```

Round a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset` down to the nearest `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` coordinates.

### Rect.roundToIntRect

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

```
fun Rect.roundToIntRect(): IntRect
```

Rounds a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect`

### Size.roundToIntSize

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

```
fun Size.roundToIntSize(): IntSize
```

Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`. This rounds `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size#width()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size#height()` to the nearest integer.

### Dp.takeOrElse

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

```
inline fun Dp.takeOrElse(block: () -> Dp): Dp
```

If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.Dp).takeOrElse(kotlin.Function0)` is executed and its result is returned.

### DpOffset.takeOrElse

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

```
inline fun DpOffset.takeOrElse(block: () -> DpOffset): DpOffset
```

If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpOffset).takeOrElse(kotlin.Function0)` is executed and its result is returned.

### DpSize.takeOrElse

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

```
inline fun DpSize.takeOrElse(block: () -> DpSize): DpSize
```

If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize` `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.DpSize).takeOrElse(kotlin.Function0)` is executed and its result is returned.

### TextUnit.takeOrElse

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

```
inline fun TextUnit.takeOrElse(block: () -> TextUnit): TextUnit
```

If this `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/package-summary#(androidx.compose.ui.geometry.Offset).isSpecified()` then this is returned, otherwise `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(androidx.compose.ui.unit.TextUnit).takeOrElse(kotlin.Function0)` is executed and its result is returned.

### Float.times

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

```
inline operator fun Float.times(other: Dp): Dp
```

### Double.times

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

```
inline operator fun Double.times(other: Dp): Dp
```

### Int.times

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

```
inline operator fun Int.times(other: Dp): Dp
```

### Float.times

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

```
inline operator fun Float.times(other: TextUnit): TextUnit
```

Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar.

This operation works only if the right operand is not equal to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`. The result of this operation is the same unit type of the given one.

### Double.times

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

```
inline operator fun Double.times(other: TextUnit): TextUnit
```

Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar.

This operation works only if the right operand is not equal to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`. The result of this operation is the same unit type of the given one.

### Int.times

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

```
inline operator fun Int.times(other: TextUnit): TextUnit
```

Multiply a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit` by a scalar.

This operation works only if the right operand is not equal to `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`. The result of this operation is the same unit type of the given one.

### Int.times

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

```
inline operator fun Int.times(size: DpSize): DpSize
```

### Float.times

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

```
inline operator fun Float.times(size: DpSize): DpSize
```

### Int.times

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

```
inline operator fun Int.times(size: IntSize): IntSize
```

Returns an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` with `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/package-summary#(kotlin.Int).times(androidx.compose.ui.unit.IntSize)`'s `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#width()` and `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize#height()` multiplied by `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html`.

### IntSize.toIntRect

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

```
fun IntSize.toIntRect(): IntRect
```

Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize` to a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect`.

### Size.toIntSize

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

```
fun Size.toIntSize(): IntSize
```

Convert a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Size` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`. This rounds the width and height values down to the nearest integer.

### IntOffset.toOffset

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

```
inline fun IntOffset.toOffset(): Offset
```

Converts the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` to an `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Offset`.

### IntRect.toRect

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

```
fun IntRect.toRect(): Rect
```

Converts an `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntRect` to a `https://developer.android.com/reference/kotlin/androidx/compose/ui/geometry/Rect`

### IntSize.toSize

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

```
fun IntSize.toSize(): Size
```

## Extension properties

### DpSize.center

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:center)

```
val DpSize.center: DpOffset
```

Returns the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset` of the center of the rect from the point of 0, 0 with this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize`.

### IntSize.center

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/IntSize.kt+symbol:center)

```
val IntSize.center: IntOffset
```

Returns the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntOffset` of the center of the rect from the point of 0, 0 with this `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/IntSize`.

### Double.dp

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

```
val Double.dp: Dp
```

Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-double/index.html`: val left = 10.0 val x = left.dp // -- or -- val y = 10.0.dp

### Float.dp

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

```
val Float.dp: Dp
```

Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html`: val left = 10f val x = left.dp // -- or -- val y = 10f.dp

### Int.dp

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

```
val Int.dp: Dp
```

Create a `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp` using an `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html`: val left = 10 val x = left.dp // -- or -- val y = 10.dp

### Double.em

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

```
val Double.em: TextUnit
```

Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### Float.em

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

```
val Float.em: TextUnit
```

Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### Int.em

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

```
val Int.em: TextUnit
```

Creates an EM unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### DpRect.height

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

```
val DpRect.height: Dp
```

A height of this Bounds in `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`.

### Dp.isFinite

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isFinite)

```
val Dp.isFinite: Boolean
```

Return `true` when it is finite or `false` when it is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Infinity()`

### Dp.isSpecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isSpecified)

```
val Dp.isSpecified: Boolean
```

`false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Unspecified()`.

### DpOffset.isSpecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isSpecified)

```
val DpOffset.isSpecified: Boolean
```

`false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset#Unspecified()`.

### DpSize.isSpecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isSpecified)

```
val DpSize.isSpecified: Boolean
```

`false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize#Unspecified()`.

### TextUnit.isSpecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/TextUnit.kt+symbol:isSpecified)

```
val TextUnit.isSpecified: Boolean
```

`false` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`.

### Dp.isUnspecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isUnspecified)

```
val Dp.isUnspecified: Boolean
```

`true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp#Unspecified()`.

### DpOffset.isUnspecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isUnspecified)

```
val DpOffset.isUnspecified: Boolean
```

`true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpOffset#Unspecified()`.

### DpSize.isUnspecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:isUnspecified)

```
val DpSize.isUnspecified: Boolean
```

`true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpSize#Unspecified()`.

### TextUnit.isUnspecified

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/TextUnit.kt+symbol:isUnspecified)

```
val TextUnit.isUnspecified: Boolean
```

`true` when this is `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit#Unspecified()`.

### DpRect.size

Cmn Artifact: [androidx.compose.ui:ui-unit](https://developer.android.com/jetpack/androidx/releases/compose-ui) [View Source](https://cs.android.com/search?q=file:androidx/compose/ui/unit/Dp.kt+symbol:size) Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/compose-ui#1.1.0)

```
val DpRect.size: DpSize
```

Returns the size of the `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/DpRect`.

### Double.sp

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

```
val Double.sp: TextUnit
```

Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### Float.sp

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

```
val Float.sp: TextUnit
```

Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### Int.sp

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

```
val Int.sp: TextUnit
```

Creates a SP unit `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/TextUnit`

### DpRect.width

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

```
val DpRect.width: Dp
```

A width of this Bounds in `https://developer.android.com/reference/kotlin/androidx/compose/ui/unit/Dp`.