rect property Null safety

Rect rect

The bounding box for this node in its coordinate system.

Implementation

Rect get rect => _rect;
void rect=(Rect value)

Implementation

set rect(Rect value) {
  assert(value != null);
  assert(value.isFinite, '$this (with $owner) tried to set a non-finite rect.');
  if (_rect != value) {
    _rect = value;
    _markDirty();
  }
}