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

Activating the context menu on plots is difficult. #132

Open
tshead2 opened this issue Jan 23, 2016 · 1 comment
Open

Activating the context menu on plots is difficult. #132

tshead2 opened this issue Jan 23, 2016 · 1 comment

Comments

@tshead2
Copy link
Member

tshead2 commented Jan 23, 2016

It's hard to hit the line. We should probably be highlighting / selecting whatever is closest to the cursor.

@tshead2 tshead2 added this to the Toyplot 0.11.0 milestone Jan 23, 2016
@tshead2
Copy link
Member Author

tshead2 commented Jan 23, 2016

Broadly speaking, there are a couple of options:

  • Add invisible geometry that can receive mouseover events.
    • Pro: just works for arbitrary complexity shapes, Bezier paths, etc.
    • Con: where there's overlap, the order in which a region is chosen is fixed.
      • In theory, getIntersectionList() could be used, but it's missing on Firefox and buggy elsewhere.
  • Add spatial indexing such as kd trees.
    • Pro: Can be used to search for nearest neighbors, no matter the scene complexity.
    • Con: search for shapes other than points is trickier - at a minimum we would need nearest line segment for plots and spines, plus nearest rect for bars, plus fills.
      • Looks like maybe a quad tree is what we want.

@tshead2 tshead2 modified the milestone: Toyplot 0.12.0 May 12, 2016
@tshead2 tshead2 modified the milestone: Toyplot 0.13.0 Jun 7, 2016
@tshead2 tshead2 modified the milestone: Toyplot 0.13.0 Jun 25, 2016
@tshead2 tshead2 modified the milestone: Toyplot 0.14.0 Jul 22, 2016
@tshead2 tshead2 modified the milestone: Toyplot 0.15.0 Apr 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant