-
Notifications
You must be signed in to change notification settings - Fork 74
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
image viewer zoom-level/center #2649
Merged
Merged
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
cdbc668
move zoom-level and center logic to image viewer state
kecnry 1e1a63a
expose zoom-level in plot options plugin
kecnry 0227f10
split state into center_x/y and expose in plot options
kecnry 8b28ce2
consolidate and expose to user API
kecnry 73e0fdd
add to existing changelog entry
kecnry 2265137
use original center logic
kecnry 283c996
set callbacks before initializing state
kecnry 6f51176
fix initializing zoom-level/center
kecnry 6caa8d6
Revert "use original center logic"
kecnry 94dd032
fix astrowidgets center_on
kecnry 689e5a6
consolidate code logic
kecnry 6c7e2fe
do not use custom reset_limits for non-imviz image viewers
kecnry 36c4003
do not allow zoom_level <= 0
kecnry ea78dd5
Revert "consolidate code logic"
kecnry 48fa6b4
enable for mosviz
kecnry fc900b2
remove unused import introduced during rebase
kecnry 86de264
small styling tweak to reset limits button in plot options
kecnry 5468fb1
expose zoom-radius instead of zoom-level in state/plot options
kecnry 89d3bc0
dynamic zoom step-size and units
kecnry dcaa2e4
gracefully handle negative zoom radius
kecnry 903a12a
smarter viewer logic when setting zoom step
kecnry ddf3c0d
revert center_on logic
kecnry e380a96
optimize world_to_pixel_values calls
kecnry File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this
iswas the reason for the cubeviz test failure - this forces cubeviz to use Imviz'sreset_limits
which behaves differently, even after accounting for different pixel components. We may eventually want to updatereset_limits
and/or the tests so that the image viewers in cubeviz and Imviz behave consistently when resetting limits, but that is out of scope here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By Imviz's reset limits, do you mean this?
jdaviz/jdaviz/core/astrowidgets_api.py
Lines 195 to 198 in 00954e1
I farmed it back out to glue-jupyter. Nothing fancy there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, I meant
FreezableBqplotImageViewerState.reset_limits()
which overrides glue'sBqplotImageViewerState.reset_limits()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like you implemented this 2 years ago in #1897
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know, and that so far has not been enabled in cubeviz.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And then that particular line was changed from a different logic by me later in #1928
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think there is any point to make Imviz and Cubeviz consistent. Imviz has WCS linking to worry about, Cubeviz does not.