mapedit icon indicating copy to clipboard operation
mapedit copied to clipboard

Allow editor options with editFeatures/drawFeatures

Open timelyportfolio opened this issue 5 years ago • 4 comments

@tim-salabim brings up a good point in email and https://github.com/r-spatial/mapedit/issues/90#issuecomment-459247014 that currently there is no way to provide editor options in editFeatures or drawFeatures. This likely most affects editor = "leafpm" since a user might want to change snappable, snapDistance, and allowSelfIntersection. I'd like to target this for next release.

timelyportfolio avatar Feb 02 '19 14:02 timelyportfolio

Next release sounds good. Let's draw the RConsortium project to a close first

tim-salabim avatar Feb 04 '19 15:02 tim-salabim

I think being able to tweak also the "appearance" of the editFeatures map would be good, if possibile (e.g., stroke width and color, polygon transparency, shape/size of vertexes while editing....).

lbusett avatar Feb 04 '19 21:02 lbusett

I just went ahead and modified editFeatures() to take and process additional arguments pmToolbarOpts, pmDrawOpts, pmEditOpts, and pmCutOpts, which it then passes on to the corresponding leafpm functions. Would this be welcome as a pull request, and if so, should I submit that and then link to this Issue in the pull request message?

JoshOBrien avatar Apr 12 '19 17:04 JoshOBrien

Yes, a PR would be great. You can simply put someting like " addresses #92" in your commit message to link the PR to this issue.

tim-salabim avatar Apr 12 '19 17:04 tim-salabim