Rect.fromCoordinates constructor
Implementation
Rect.fromCoordinates(this.x1, this.y1, this.x2, this.y2) {
if (x1 != null && x2 != null) {
width = (x2 as double) - (x1 as double);
}
if (y1 != null && y2 != null) {
height = (y2 as double) - (y1 as double);
}
}