Skip to content

Latest commit

 

History

History
103 lines (100 loc) · 3.05 KB

File metadata and controls

103 lines (100 loc) · 3.05 KB

Polygon class

Create

map.addPolygon() Add a polygon.

Methods

setPoints() Change the polygon points.
getPoints() Return an instance of the BaseArrayClass.
You can modify the points.
setHoles() Change the polygon holes.
getHoles() Return an instance of the BaseArrayClass.
You can modify the holes.
setFillColor() Change the filling color (inner color).
getFillColor() Return the current polygon filling color (inner color).
setStrokeWidth() Changes the polygon stroke width.
getStrokeWidth() Returns the current stroke width (unit: pixel).
setStrokeColor() Change the stroke color (outter color).
getStrokeColor() Return the current polygon stroke color (outer color).
setClickable() Change clickablity of the polygon.
getClickable() Return true if the polygon is clickable.
setVisible() Change visibility of the polygon.
getVisible() Return true if the polygon is visible.
setGeodesic() When true, edges of the polygon are interpreted as geodesic and will follow the curvature of the Earth.
getGeodesic() Returns true if the polygon is geodesic.
setZIndex() Change the polygon zIndex order.
getZIndex() Return the current polygon zIndex.
remove() Remove the polygon.
getMap() Return the map reference.

Events

POLYGON_CLICK Arguments: LatLng
This event is fired when you click on a polygon.