requestFocusForChildInRootBounds
Function
Common
fun DelegatableNode.requestFocusForChildInRootBounds(
left: Int,
top: Int,
right: Int,
bottom: Int,
): Boolean
Attempts to request focus for the most suitable focusable child node that overlaps with the given
rect area (left, top, right, bottom).
The rectangle is interpreted in the coordinate space relative to the compose root. See
androidx.compose.ui.layout.LayoutCoordinates.localToRoot for converting local coordinates to
the root coordinates.
Parameters
| left | is the left edge of the rectangle, in pixels relative to the compose root. |
| top | is the top edge of the rectangle, in pixels relative to the compose root. |
| right | is the right edge of the rectangle, in pixels relative to the compose root. |
| bottom | is the bottom edge of the rectangle, in pixels relative to the compose root. |
Returns
true if a matching child was found and focus was granted; false if no such child exists, it is already focused, or the focus request failed. |
