ibrierley / flutter_map_line_editor

A basic line/poly editor that works with flutter_map and dragmarkers.
MIT License
44 stars 25 forks source link

Feature request: option to make start/end of polyline non-editable #44

Open leiflinse-trivector opened 3 months ago

leiflinse-trivector commented 3 months ago

I tried to take all but first and last marker, but it appears that they are ordered not along the line, but grouped by point type, so one would have to take that into account when deciding which points to remove, at which point this feels like I am getting too deep into implementation specific details of this library.

polyEditor.edit().sublist(1, polyEditor.edit().length - 2)

So I think it would be better if there is an option to disable the first and last marker. Perhaps two independent flags, as there may also be use cases where you only want to fixate one of the ends.