geoman-io / leaflet-geoman

🍂🗺️ The most powerful leaflet plugin for drawing and editing geometry layers
https://geoman.io
MIT License
2.21k stars 433 forks source link

Mutliselect / box select for vertex / helper-markers in Edit Mode #1477

Open vanHekthor opened 6 months ago

vanHekthor commented 6 months ago

Hello, I need a mutliselect / box select for the vertex / helper-marker of the layers in the Edit Mode. This would allow you to select multiple vertices and then move them around or even delete them etc. I didn't find any feature that is currently able to provide that functionality. So, I was thinking of extending geoman myself.

Before going in too deep, did I miss anything? Is there an existing feature request or even, does this functionality already exist?

If not, I was wondering, if you could give me some guidance. Creating the selection box (similar to the leaflet box zoom feature) and checking which markers it contains should be easy. What troubles me is:

Hopefully, my questions aren't too silly.

Falke-Design commented 6 months ago

Hi @vanHekthor,

you are right, currently there is no feature like that available.

The markers are created here and over the drag events the markers are moved: https://github.com/geoman-io/leaflet-geoman/blob/b4918546acce6c374a8467f16027f578b463aa2e/src/js/Edit/L.PM.Edit.Line.js#L196-L200

All markers of the layer are in layer.pm._markers

plarner30 commented 1 month ago

@vanHekthor did you have any luck with this? Was wondering if you could share the code if so. Many thanks

plarner30 commented 1 month ago

@Falke-Design Any plans to implement something like this in the pro version? It would be good to be able to drag multiple marker nodes and also delete

Falke-Design commented 4 weeks ago

Hi @plarner30,

we are considering to implement this into pro. It looks like a nice feature but we don't have it currently on the road map