androidx.compose.ui.unit
Interfaces
Density |
A density of the screen. |
Classes
Bounds |
A four dimensional bounds using Dp for units |
Constraints |
Immutable constraints used for measuring child Layouts or LayoutModifiers. |
Dp |
Dimension value representing device-independent pixels (dp). |
DpOffset |
A two-dimensional offset using Dp for units |
Duration |
A span of time, such as 27 days, 4 hours, 12 minutes, and 3 seconds. |
IntBounds |
A four dimensional bounds holder defined by integer pixels. |
IntOffset |
A two-dimensional position using Int pixels for units |
IntSize |
A two-dimensional size class used for measuring in Int pixels. |
TextUnit |
The unit used for text related dimension value. |
Uptime |
A single point in time with a time base of the system's uptime nanoseconds. |
Velocity |
A two dimensional velocity in pixels per second. |
Type-aliases
Position |
Enums
LayoutDirection |
A class for defining layout directions. |
TextUnitType |
An enum class defining for type of TextUnit. |
Top-level constants summary
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long | |
const Long |
Top-level functions summary
Constraints |
Constraints(minWidth: Int = 0, maxWidth: Int = Constraints.Infinity, minHeight: Int = 0, maxHeight: Int = Constraints.Infinity) Create a Constraints. |
Density | |
Density |
A density of the screen. |
DpOffset | |
Duration |
Duration(days: Long = 0, hours: Long = 0, minutes: Long = 0, seconds: Long = 0, milliseconds: Long = 0, microseconds: Long = 0, nanoseconds: Long = 0) Constructs a Duration given a series of time intervals in different units. |
IntBounds | |
IntOffset | |
IntSize | |
DpOffset | |
Velocity | |
Velocity |
Constructs an Velocity from the given relative x and y velocities. |
Dp |
Linearly interpolate between two Dps. |
DpOffset |
Linearly interpolate between two DpOffsets. |
IntOffset |
Linearly interpolate between two IntOffsets. |
TextUnit | |
Dp | |
TextUnit |
Returns the smaller value from the given values. |
Dp | |
TextUnit |
Returns the smaller value from the given values. |
Extension functions summary
For kotlin.Double | |
operator Dp | |
operator TextUnit |
Multiply a TextUnit by a scalar. |
For kotlin.Float | |
operator Dp | |
operator TextUnit |
Multiply a TextUnit by a scalar. |
For kotlin.Int | |
operator Dp | |
operator IntSize |
Returns an IntSize with size's IntSize.width and IntSize.height multiplied by this. |
operator TextUnit |
Multiply a TextUnit by a scalar. |
For IntBounds | |
IntOffset | |
Rect | |
IntSize |