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

Zoom in/ out implementation #111

Closed
agporto opened this issue Mar 19, 2023 · 2 comments
Closed

Zoom in/ out implementation #111

agporto opened this issue Mar 19, 2023 · 2 comments

Comments

@agporto
Copy link

agporto commented Mar 19, 2023

@andfanilo Thanks for this great library. I was trying to implement zoom in/out of the canvas and I got it to work great on canvas objects (see file attached). For some reason, however, the background image does not respond to mouse events. Any chance you might know what is causing it?
DrawableCanvas_mod.txt

@andfanilo
Copy link
Owner

Hello @agporto ,

Are you able to make a PR, just to make it easier for me to view the code changes? We can close it afterwards if you then want to do a proper one.

Judging from https://stackoverflow.com/questions/16980273/html-5-how-to-zoom-canvas-background-image, It might be you need to redraw a scaled version of the image on the background canvas, though I didn't dig further

Anyway that looks awesome, hope it works out for you!

Have a nice day,
Fanilo

@agporto
Copy link
Author

agporto commented Mar 20, 2023

Closing for now, since I submitted the PR. #112

@agporto agporto closed this as completed Mar 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants