Rect constructor

Rect({
  1. required double x,
  2. required double y,
  3. required double width,
  4. required double height,
  5. String? id,
  6. Color? fill,
  7. Color? stroke,
  8. StrokeWidth? strokeWidth,
  9. StrokeDasharray? strokeDasharray,
  10. String? style,
  11. String? transform,
  12. Unit? unit,
  13. Visibility? visibility = Visibility.inherit,
})

Rect constructor x left top x coordinate of the rectangle y left top y coordinate of the rectangle width width of rectangle height height of rectangle id widget id to made some reference in the SVG file fill fill color stroke stroke line color strokeWidth stroke line width strokeDasharray stroke line dash style style custom css style transform custom css transformation unit unit used in the parameters, default is px (pixel) visibility visibility of the element, default is inherit

Implementation

Rect(
    {required this.x,
    required this.y,
    required this.width,
    required this.height,
    this.id,
    this.fill,
    this.stroke,
    this.strokeWidth,
    this.strokeDasharray,
    this.style,
    this.transform,
    this.unit,
    this.visibility = Visibility.inherit});