Using the Google Maps JavaScript v3 API’s editable polygons and/or drawing library, is it possible to somehow prevent the user from creating complex polygons where two or more of the containing polylines intersect each other? Or am I going to have to write my own polygon editing library if I want this function?
Using the Google Maps JavaScript v3 API’s editable polygons and/or drawing library, is it
Share
You can check for polyline intersection in the DrawingManager’s
polygoncompleteevent. It will pass in the polygon as an argument, then it is up to you to detect/fix polyline intersections.