PolygonAnnotation

fun PolygonAnnotation(points: List<List<Point>>, fillColorInt: Int? = null, fillColorString: String? = null, fillOpacity: Double? = null, fillOutlineColorInt: Int? = null, fillOutlineColorString: String? = null, fillPattern: String? = null, onClick: (PolygonAnnotation) -> Boolean = { false })

Composable function to add a PolygonAnnotation to the Map.

Parameters

points

A list of lists of Point for the fill, which represents the locations of the fill on the map.

fillColorInt

The color of the filled part of this layer. This color can be specified as rgba with an alpha component and the color's opacity will not affect the opacity of the 1px stroke, if it is used. The property is set as Color Int.

fillColorString

The color of the filled part of this layer. This color can be specified as rgba with an alpha component and the color's opacity will not affect the opacity of the 1px stroke, if it is used. The property is set as Color String.

fillOpacity

The opacity of the entire fill layer. In contrast to the {@link PropertyFactory#fillColor}, this value will also affect the 1px stroke around the fill, if the stroke is used.

fillOutlineColorInt

The outline color of the fill. Matches the value of {@link PropertyFactory#fillColor} if unspecified. The property is set as Color Int.

fillOutlineColorString

The outline color of the fill. Matches the value of {@link PropertyFactory#fillColor} if unspecified. The property is set as Color String.

fillPattern

Name of image in sprite to use for drawing image fills. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

onClick

Callback to be invoked when the PolygonAnnotation is clicked. The clicked PolygonAnnotation will be passed as parameter.