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

Zooming/dragging plot on a single axis resets the other axis #4251

Closed
YgorSouza opened this issue Mar 27, 2024 · 0 comments · Fixed by #4252
Closed

Zooming/dragging plot on a single axis resets the other axis #4251

YgorSouza opened this issue Mar 27, 2024 · 0 comments · Fixed by #4252
Labels
bug Something is broken

Comments

@YgorSouza
Copy link
Contributor

Describe the bug

When we zoom or drag the plot on a single axis (e.g. with allow_zoom([false, true].into())) the other axis is reset to autobounds.

plot_drag_single_axis.mp4

To Reproduce
Steps to reproduce the behavior:

  1. Go to https://www.egui.rs/
  2. Open the Plot demo on the charts tab
  3. Move the plot away or zoom it
  4. Uncheck either X or Y on the "Allow zoom" and/or "Allow drag" options above
  5. Try to zoom or drag the plot again. The unchecked axis resets

Expected behavior

When zooming or dragging on only one axis, the other axis should be left alone instead of resetting.

Desktop (please complete the following information):

  • OS: Fedora 39
  • Browser Firefox
  • Version 124
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant