ImageMapRegion.fromCircle constructor

ImageMapRegion.fromCircle({
  1. required Offset center,
  2. required double radius,
  3. Color? color,
  4. String? title,
  5. String? link,
})

Implementation

factory ImageMapRegion.fromCircle({
  required Offset center,
  required double radius,
  Color? color,
  String? title,
  String? link,
}) {
  return ImageMapRegion(
    shape: ImageMapShape.circle,
    path: Path()
      ..addOval(
        Rect.fromCircle(
          center: center,
          radius: radius,
        ),
      ),
    color: color ?? Colors.transparent,
    title: title,
    link: link,
  );
}