Конструктор Rectangle const
const Rectangle(Создать прямоугольник, охватываемый (left, top) и (left+width, top+height).
Прямоугольник содержит точки с координатой x между left и left + width, и с координатой y между top и top + height, включая границы.
width и height должны быть неотрицательными. Если width или height отрицательные, они ограничены нулём.
Если width и height равны нулю, «прямоугольник» содержит только единственную точку (left, top).
Исходный код
const Rectangle(this.left, this.top, T width, T height)
: this.width = (width < 0) ? -width * 0 : width, // Inline _clampToZero.
this.height = (height < 0) ? -height * 0 : height;
© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-math/Rectangle/Rectangle.html