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

Don't reset the axis limits / zoom for same Axis spec #4589

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SimonDanisch
Copy link
Member

This tries to keep zoom levels etc, if the axes match exactly when re-using, since we assume the user intention is to move that axis, without resetting it:

p1 = S.Heatmap(rand(4, 4))
p2 = S.Heatmap(rand(50, 20))
ax1 = S.Axis(plots=[p1]; title="Axis 1")
ax2 = S.Axis(plots=[p2]; title="Axis 2")
grid = S.GridLayout(ax1, ax2)
f, ax, pl = plot(grid)
# swap axes while preserving zoom etc
pl[1] = S.GridLayout(ax2, ax1);

@MakieBot
Copy link
Collaborator

Benchmark Results

SHA: b8828bd0dad8e29bcb8d4824e0710da16b3d3188

Warning

These results are subject to substantial noise because GitHub's CI runs on shared machines that are not ideally suited for benchmarking.

GLMakie
CairoMakie
WGLMakie

@SimonDanisch SimonDanisch changed the title This doesn't reset the axis limits / zoom, if the exact same spec was… Don't reset the axis limits / zoom for same Axis spec Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Work in progress
Development

Successfully merging this pull request may close these issues.

2 participants