Positioned.fromRect({Key key, Widget child, Rect rect })

Creates a Positioned object with the values from the given Rect.

This sets the left, top, width, and height properties from the given Rect. The right and bottom properties are set to null.

Source

Positioned.fromRect({
  Key key,
  Widget child,
  Rect rect
}) : left = rect.left,
     top = rect.top,
     width = rect.width,
     height = rect.height,
     right = null,
     bottom = null,
     super(key: key, child: child);