getDescendantOffset method

Offset getDescendantOffset({
  1. required RenderBox descendant,
  2. Offset offset = Offset.zero,
})

Returns an Offset of the provided RenderBox descendent, along with any additional passed offset, within this parent Roll.

Implementation

Offset getDescendantOffset({
  required RenderBox descendant,
  Offset offset = Offset.zero,
}) =>
    descendant.localToGlobal(offset,
        ancestor: context.findRenderObject() as RenderBox);