let GORYOKAKU_POINTS: ILatLng[] = [
{lat: 41.79883, lng: 140.75675},
{lat: 41.799240000000005, lng: 140.75875000000002},
{lat: 41.797650000000004, lng: 140.75905},
{lat: 41.79637, lng: 140.76018000000002},
{lat: 41.79567, lng: 140.75845},
{lat: 41.794470000000004, lng: 140.75714000000002},
{lat: 41.795010000000005, lng: 140.75611},
{lat: 41.79477000000001, lng: 140.75484},
{lat: 41.79576, lng: 140.75475},
{lat: 41.796150000000004, lng: 140.75364000000002},
{lat: 41.79744, lng: 140.75454000000002},
{lat: 41.79909000000001, lng: 140.75465}
];
let options: PoligonOptions = {
'points': GORYOKAKU_POINTS,
'strokeColor' : '#AA00FF',
'fillColor' : '#00FFAA',
'strokeWidth': 10
};
this.map.addPolygon(options).then((polygon: Polygon) => {
...
});
Params | Type | Details |
---|---|---|
points | ILatLng[] | Pass ILatLng[] to specify the vertixes. You need to contain two points at least. |
holes | ILatLng[][] | Pass ILatLng[][] to create holes in polygon. |
visible | boolean | (optional)Set false if you want to create invisible polyline. Invisible polyline is not clickable (default true) |
geodesic | boolean | (optional)Set true if you want to draw the curve polyline based on the earth(default: false) |
strokeColor | string | (optional)Set the stroke color(rgb, rgba, #RRGGBB, "colorname", ...etc) |
strokeWidth | number | (optional)Set the stroke width in pixel |
fillColor | string | (optional)Set the inside color of polygon(rgb, rgba, #RRGGBB, "colorname", ...etc) |
zIndex | number | (optional)Hierarchy z-index |
clickable | boolean | (optional)Set true if you want to receive the POLYLINE_CLICK event(default: false) |