Polygon constructor

const Polygon({
  1. required PolygonId polygonId,
  2. bool consumeTapEvents = false,
  3. Color fillColor = Colors.black,
  4. bool geodesic = false,
  5. List<LatLng> points = const <LatLng>[],
  6. List<List<LatLng>> holes = const <List<LatLng>>[],
  7. Color strokeColor = Colors.black,
  8. int strokeWidth = 10,
  9. bool visible = true,
  10. int zIndex = 0,
  11. required bool editable,
  12. VoidCallback? onTap,
  13. required ArgumentCallback<Map>? onDragend,
  14. required ArgumentCallback<Map>? onInsertAt,
  15. required ArgumentCallback<Map>? onRemoveAt,
  16. required ArgumentCallback<Map>? onSetAt,
})

Creates an immutable representation of a polygon through geographical locations on the map.

Implementation

const Polygon({
  required this.polygonId,
  this.consumeTapEvents = false,
  this.fillColor = Colors.black,
  this.geodesic = false,
  this.points = const <LatLng>[],
  this.holes = const <List<LatLng>>[],
  this.strokeColor = Colors.black,
  this.strokeWidth = 10,
  this.visible = true,
  this.zIndex = 0,
  required this.editable,
  this.onTap,
  required this.onDragend,
  required this.onInsertAt,
  required this.onRemoveAt,
  required this.onSetAt,
});