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

Shape scaling #55

Open
brian428 opened this issue May 12, 2016 · 2 comments
Open

Shape scaling #55

brian428 opened this issue May 12, 2016 · 2 comments

Comments

@brian428
Copy link

It would be very useful to have an option to scale the shapes drawn via the annotation tools when the zoom level changes. If someone is marking a section of the chart with an annotation, and then they zoom, the shape is now covering an incorrect area on the chart.

@aadrian
Copy link

aadrian commented Jul 18, 2016

not respecting the zoom it's a bug IMHO. The coordinates should be in the Axis domain, not in the pixel one.

@pawelfus
Copy link
Collaborator

Hi, thank you for your feedback!

I think you are right, however I am very cautious with changing behaviour in a minor/patch release. Currently, buttons use only x-y coordinates to render on the chart (any annotation, not only rect-type). Solution for now is to create your own buttons and use shape.units = "value".

I think this change in the buttons logic can be made when we split logic for buttons and annotations core (two separate js-files). I hope that annotations 2.0 will get this.

@pawelfus pawelfus added this to the Annotations 2.0 milestone Jul 18, 2016
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

3 participants