inflatexy method

Rect inflatexy(
  1. double deltaX,
  2. double deltaY
)

Returns a new rectangle with edges moved outwards by the given delta.

Implementation

Rect inflatexy(double deltaX, double deltaY) {
  return Rect.fromLTRB(
    left - deltaX,
    top - deltaY,
    right + deltaX,
    bottom + deltaY,
  );
}