Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace VertexOnlyLayer with SymbolStyle on all geometries #2553

Merged
merged 8 commits into from Mar 17, 2024

Conversation

pauldendulk
Copy link
Member

@pauldendulk pauldendulk commented Mar 17, 2024

Why?

The EditingWidgetSample does not work properly because tapping a vertex only works if you tap within the polygon area, not on the vertices that are partially outside this area. This is because a hit on the vertex is not a hit on the polygon but on the points in the VertexOnlyLayer. By handling this with a style on the polygon no extra logic is needed to make it work as it should.

How

This turned out to be simpler than I thought. Instead of adding a new style and new style renderer I changed the SymbolStyle so that it can be applied to all types. This is done by using IFeature.CoordinateVisitor.

Breaking change

This could change visualization if users have SymbolStyle on a layer that contains polygons and lines as well.

@pauldendulk pauldendulk merged commit 3998854 into main Mar 17, 2024
5 checks passed
@pauldendulk pauldendulk deleted the feature/vertex-only-style branch March 17, 2024 11:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant