Commit 4896ec1
Add pan and zoom toolbar handling to 3D Axes (Replaces PR#22614) (matplotlib#23449)
* ENH: Add pan and zoom toolbar handling to 3D Axes
1) This moves the pan logic that was already in the mouse move handler
into the "drag_pan" method to make it available from the toolbar.
2) This expands upon the panning logic to enable a zoom-to-box feature.
The zoom-to-box is done relative to the Axes, so it shrinks/expands
the box as a fraction of each delta, from lower-left Axes to lower-left
zoom-box. Thus, it tries to handle non-centered zooms, which adds more
cases to handle versus the current right-click zoom only scaling from
the center of the projection.
* Rewrite zooming with bounding box
* Rewrite 3d panning to work with a roll angle
* Whats new for zoom and pan buttons
* Make pan button configurable
* Do not jump when zooming and mouse goes over other subplot
* Rework zooming for 3d plots
* Handle x/y lock when zooming and panning
* Update tests
* Docstrings
* Dont assume a scale_z
* Limit zoom box
* Test zoom pan key modifiers
* Save some calculation by saving view axes
* Deprecation warnings for Axes3D.eye, .vvec
* Remove Axes3D._prepare_view_from_bbox for now
* Comments and docstrings
* Switch from uvn to uvw
* Save aspect to axes
* Constrain zooming with mouse when one of the equal aspect ratios is set
* Cleanup
* Cleanup
* Consolidate finding equal aspect axis indices
* linting
* More intuitive scaling
* Box zoom keeps existing aspect ratios
* Linting
* Code review comments
* Revert parameters for view_transformation
* Fix new 3d pan/zoom view going on view stack twice
* Better clipping
* Test 3d toolbar navigation
* Privatize helper functions
* Deprecations
* Code review changes
* Deprecation note
* Undeprecate proj3d.view_transformation
* Undeprecate proj3d.view_transformation
* Update doc/api/next_api_changes/deprecations/23449-SS.rst
Co-authored-by: Greg Lucas <[email protected]>
Co-authored-by: Scott Shambaugh <[email protected]>
Co-authored-by: Oscar Gustafsson <[email protected]>1 parent 834c89c commit 4896ec1
File tree
5 files changed
+396
-85
lines changed- doc
- api/next_api_changes/deprecations
- users/next_whats_new
- lib/mpl_toolkits
- mplot3d
- tests
5 files changed
+396
-85
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
0 commit comments