VIAMICHELIN JAVASCRIPT API


Polygon

Circle is responsible for graphic object of circle type. Launched via new and extends Layer.

Constructor

PropertyTypeDescriptionDefault
center GeoPoint Geographical coordinates of the centre. N/A
radius int Circle radius in metres. 10 000
strokeColor string Colour of the circle stroke path in HTML hex style. '#000'
strokeOpacity float Opacity of the circle stroke path between 0.0 (fully transparent) and 1.0 (fully opaque). 1.0
strokeWeight int Pixel width of the circle stroke path. 2
fillColor string Fill colour in HTML hex style. '#0F0'
fillOpacity float The fill opacity between 0.0 (fully transparent) and 1.0 (fully opaque). 0.0
htm string HTML content to be displayed in the Info-bubble. ''

 

Methods

MethodsReturn valueDescription
getGeoBoundaries() [GeoPoint,GeoPoint] Returns the geographical coordinates of the circle boundaries as north-west and south-east corners.
getStrokeColor() string Retrieves current circle stroke colour.
setStrokeColor(newColor: string) - Sets new circle stroke colour.
getStrokeOpacity() float Retrieves current circle stroke opacity.
setStrokeOpacity(newOpacity: float) - Sets new circle stroke opacity.
getStrokeWeight() int Retrieves current circle stroke width.
setStrokeWeight(newWeight: int) - Sets new circle stroke width.
getFillColor() string Retrieves current circle fill color.
setFillColor(newColor: string) - Sets new circle fill color.
getFillOpacity() float Retrieves current circle fill opacity.
setFillOpacity(newOpacity: float) - Sets new circle fill opacity.
setBubbleContent(htm: string) - HTML content to be displayed in the Info-bubble.

 

Events

EventsArgumentsDescription
onClick GeoPoint Fired when a mouse click takes place on the circle.
onExpandOpen - Fired when circle info-bubble is opened.
onExpandClose - Fired when circle info-bubble is closed.

Back to top