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

Already on GitHub? Sign in to your account

show vertices only for selected way #1075

merged 5 commits into from Apr 24, 2013


None yet
2 participants

jfirebaugh commented Mar 18, 2013

Reopening from #1022.

I think we should strongly consider this again. It has several advantages:

  • Reduced visual clutter, less overwhelming for new mappers.
  • Improved performance. From what I've seen lately, vertex rendering is the rendering hotspot.
  • Significantly reduces the chances of accidentally dragging a vertex when you were trying to pan.
  • Fixes #569.
  • Provides an elegant solution to #750 -- we can copy what P2 does.
  • Makes it easier to implement simplification for ways when rendering, a potential performance improvement -- we can simplify non-selected ways without having to worry about them not matching up with their vertices.

Started looking at this. First off, rendering all vertices and hiding them in CSS by default is a no go -- performance is terrible. So we need to add/remove them dynamically.

Second, some interaction minutia:

  • Tagged vertices are always visible.
  • When a vertex is selected, all vertices in parent ways should be visible (so you can move from vertex to vertex easily).
  • Need to think about multi-select. Maybe have the proximity behavior whenever Shift key is down. But that introduces a way to select a vertex without selecting a way first, the absence of which provided the solution for #750.

jfirebaugh commented Mar 18, 2013

Ok, this is tricky. Proximity based show/hide is pretty performance-intensive and not that great of an effect, so I switched to hover. Current issue is that when you hover over a vertex, the parent way gets a mouseout event, which causes the vertex to hide, leading to weird flickering. Not sure the best way to address this.

I added midpoints to this as well. One problem with this is it makes it difficult to do midpoint drags. You click to select the way, and half the time the midpoint you want to move is covered up by the radial menu.


jfirebaugh commented Mar 18, 2013

Ok, this is working better now, except for the usability problem with midpoints. Try it out.


ansis commented Mar 18, 2013

Nice, looks a lot cleaner

The main issue I'm seeing is that its impossible to identify connectivity issues for roads, railways. What about rendering all line vertices, or if its not too tricky, rendering all line vertices with more than one parent way. Since there are a lot less line vertices than area vertices, the clutter, performance and dragging should be less of a problem.

Is it too distracting to have it show on mouseover for the select mode too?


jfirebaugh commented Mar 18, 2013

I tried out always rendering all shared vertices. It looked a little odd where buildings are connected, I think we'd want to limit it to line vertices.

If the use case is 'flag connectivity issues', maybe we can accomplish that another way, like with a "Crossing way" validation.

Is it too distracting to have it show on mouseover for the select mode too?

It's not too distracting, but I like not having them show because then I never accidentally drag a vertex when I'm trying to pan.


ansis commented Mar 18, 2013

Not showing road intersections could also make it less clear to new users that roads need to connect. This could be an imagined issue though.

Two bugs:

Tagged vertices disappear when hovering over a parent way

I'm sometimes seeing vertices rendered in the wrong place while dragging.

@tmcw tmcw referenced this pull request Mar 27, 2013


split ways at intersection #750

@jfirebaugh jfirebaugh merged commit d31fa9a into master Apr 24, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment