CaptureSizeModifierFieldValue
A ModifierFieldValue that captures layout size changes
This class monitors size changes of Compose components and captures size information (width, height) when changes occur. It's useful for debugging and layout adjustment, allowing real-time size information verification. Values are displayed in dp units with automatic density conversion.
// Basic usage
modifier = ModifierFieldValueList().captureSize()
// Direct creation
val captureSizeField = CaptureSizeModifierFieldValue()
// Usage in components
Box(modifier = modifier.apply { createModifier() }) {
Text("Hello World")
}Content copied to clipboard
See also
Functions
Link copied to clipboard
Renders the UI builder interface for configuring this modifier. This composable is typically displayed in the Preview Lab control panel.
Link copied to clipboard
Creates a modifier from this field value.
Link copied to clipboard
Combines this modifier field value with another to create a list.