OpenLayers JavaScript Mapping Library |
OpenLayers. Handler. RegularPolygonHandler to draw a regular polygon on the map. Polygon is displayed on mouse down, moves or is modified on mouse move, and is finished on mouse up. The handler triggers callbacks for ‘done’ and ‘cancel’. Create a new instance with the OpenLayers.Handler.RegularPolygon constructor. Inherits fromSummary
snapToggle{String} If set, snapToggle is checked on mouse events and will set the snap mode to the opposite of what it currently is. To disallow toggling between snap and non-snap mode, set freehandToggle to null. Acceptable toggle values are ‘shiftKey’, ‘ctrlKey’, and ‘altKey’. Snap mode is only possible if this.snapAngle is set to a non-zero value. OpenLayers. Handler. RegularPolygonCreate a new regular polygon handler. Parameters
|
setOptions: function ( newOptions )
Turn on the handler.
activate: function()
Turn off the handler.
deactivate: function()
Finish the geometry and call the “cancel” callback.
cancel: function()
Clear any rendered features on the temporary layer.
clear: function()