offsetDescendantRect

open fun offsetDescendantRect(@NonNull parent: ViewGroup, @NonNull descendant: View, @NonNull rect: Rect)

This is a port of the common offsetDescendantRectToMyCoords from the framework, but adapted to take transformations into account. The result will be the bounding rect of the real transformed rect.

Parameters

descendant

view defining the original coordinate system of rect

rect

(in/out) the rect to offset from descendant to this view's coordinate system