Is it possible to setRotationCenter on the initialization of a shape? #1453
-
Hello, In my program, I am creating various shapes programmatically that act as visual indicators for markers. I have created my own toolbar outside of geoman that will draw these shapes for the user. They are also able to use my custom menu to do things like change the length, width, and rotation. The users do not have access to DrawMode, EditMode, or Rotate Mode, and I do not want my users to be able to interact with shapes with the leaflet controls that are still available to them ( These controls are to be used exclusively with markers only ). My issue is, I want to be able to use { pmIgnore: true } in my options when creating a shape, but it seems that I can only use shape.setRotationCenter( latLng ) after the item as been created. My questions: Please let me know if you need more information, and I appreciate all of the work you have done for this great product! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
if you creating the shape with
Just update the options of a layer I do not understand your workflow but a solution could be that you draw the layer and listening for
|
Beta Was this translation helpful? Give feedback.
if you creating the shape with
pmIgnore: true
orOptIn
then the layer will not get thepm
property. This also means that the can't be rotate too. So I don't really understand how you rotate a layer if it has not thepm
property of Geoman.Just update the options of a layer
layer.options.pmIgnore = true
I do not understand your workflow b…