Skip to main content

GmapDrawingManager

Drawing Library removal

Google deprecated the Maps JavaScript API Drawing Library and removed google.maps.drawing.DrawingManager in Maps JavaScript API v3.65+. GmapDrawingManager is kept only for legacy API versions where Google still serves the Drawing Library. For current Maps API versions, build drawing workflows with editable shapes, the Data layer/GeoJSON, or a third-party drawing library such as Terra Draw.

DrawingManager component

See source code ,[See](Official documentation) ,[See](Official reference)

Props​

Prop nameDescriptionTypeValuesDefault
circleOptionsThe circle options
@see circleOptions interface
object-undefined
markerOptionsThe marker options
@see markerOptions interface
object-undefined
polygonOptionsThe polygon options
@see polygonOptions interface
object-undefined
polylineOptionsThe polyline options
@see polylineOptions interface
object-undefined
rectangleOptionsThe rectangle options
@see rectangleOptions interface
object-undefined
positionThe position of the toolbar
Possible values: 'TOP_CENTER', 'TOP_LEFT', 'TOP_RIGHT', 'LEFT_TOP', 'RIGHT_TOP', 'LEFT_CENTER',<br/>'RIGHT_CENTER', 'LEFT_BOTTOM', 'RIGHT_BOTTOM', 'BOTTOM_CENTER', 'BOTTOM_LEFT', 'BOTTOM_RIGHT'
string-''
shapesAn array of shapes that you can set to render in the map and saves on it the new shapes that you add.array-

Methods​

setDrawingMode​

The setDrawingMode method is binded into the default component slot

Params​

Param nameTypeDescription
modestringmode - Possible values 'marker', 'circle', 'polygon', 'polyline', 'rectangle', null

Return​

TypeDescription
void

deleteSelection​

The deleteSelection method is binded into the default component slot

Params​

Param nameTypeDescription
mixedIt doesn't requires any parameter

Return​

TypeDescription
void

Events​

Event namePropertiesDescription
update:shapesplace array - this.finalShapesupdate:shapes event

Slots​

NameDescriptionBindings
defaultUsed to set your drawing manager