Closed arjain closed 9 years ago
Hey @arjain
the relevant code is here - you could fork and update or else I'd be willing to accept a PR to support more user controlled options.
It'd look something like:
if (d3.event.altKey) {
// only Y axis on meta
scaleTo(view.kx, Math.pow(2, d3_behavior_zoomDelta() * .002));
} else if (d3.event.ctrlKey) {
// no special case for control so zoom along X-axis
scaleTo(Math.pow(2, d3_behavior_zoomDelta() * .002) * view.kx, view.ky);
} else {
// default - only X axis
scaleTo(Math.pow(2, d3_behavior_zoomDelta() * .002) * view.kx, view.ky);
}
Thanks for the reply! That's exactly what I ended up doing.
I want to disable zooming across both the axes together. So, say default behavior will be to only zoom across X axes and Meta + zoom zooms only along the Y axis. Do you how can I do this?