-
Notifications
You must be signed in to change notification settings - Fork 388
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
Separate Zoom for X-Y axis #176
Comments
For now I would change all Having that functionality will allow to write a custom And yes, a pull request is very welcome : ) |
I'm trying to implement this, but I have some questions:
I'll keep in touch if I have other questions. Merry christmas :) Edit: I just renamed |
But I'll think more about this during the holidays and I'll let you to know it anything else comes to my mind. Merry Christmas! |
There's a work-in-progress at jeremyVignelles@60eb591 If you have time to give it a try, this would be helpful. Otherwise, I will use this feature at work in the following days so I will test a few things at that time. |
Nice work. It looks really good. I'm currently working on #98 and I do plan to add separate zooms into it. There are many changes in core but I may use pieces of your code for that. But I'm still thinking if we need an option to enable separate zooms or it should be a default thing. Currently I'm inclined towards having it as a default for v4. But in the same time it should be easy to use the library for SVGs that don't require separate zooms. I'll let you to know on my progress on this progress. |
I agree that it would be better if enabled by default, but I will need this feature pretty soon, this is why I implemented it as an option, for backward compatibility. This compatibility can be dropped in v4 since this is a major release. Do you plan to introduce this feature in v3 or wait for v4? |
If your work works well and has tests then I'll merge it into v3. |
Forgive me for digging up an old thread, but I was wondering if you had any suggestions on how to implement the panZoomToRect function, on top of this branch? I'm trying my best to backwards engineer it, but being unfamiliar with the project (and SVG g transforms in general) it's slow going. Thanks |
I would need this feature for a gantt view and angular. I was loading the library as follow and it has not worked anymore:
|
Ok, I noticed that typescript is not available in plugins branch, I will try to make it available. |
Hi,
I'd like to have separate X/Y scales when zooming.
In other words, I'd like to return
{x: true, y:false}
frombeforeZoom
, as this is done inbeforePan
.I have two use cases in my project:
Implementation details:
enableSeparateZooms
, default: false.panZoomToRect({x,y,width,height})
to pan and zoom to a specific viewbox, potentially with different x/y zoom factors. width or height may be ommited (but not both), in which case the current scale ratio is keptWhat do you think about the idea? Is there anything else to add ? I can try to make the PR if you want.
The text was updated successfully, but these errors were encountered: