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

napari widget Image shift controls does not work properly #163

Open
ondrejstranik opened this issue May 10, 2023 · 1 comment
Open

napari widget Image shift controls does not work properly #163

ondrejstranik opened this issue May 10, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@ondrejstranik
Copy link

Bug description
error message issued when arrows buttons in the napari widget are pressed:

ERROR [ExceptionHandler] Traceback (most recent call last):
  File "C:\Users\ostranik\Documents\GitHub\ImSwitch\imswitch\imcommon\view\guitools\naparitools.py", line 265, in _on_up
    self._do_shift(0, -self._get_shift_distance())
  File "C:\Users\ostranik\Documents\GitHub\ImSwitch\imswitch\imcommon\view\guitools\naparitools.py", line 281, in _do_shift
    for layer in self.viewer.layers.selected:
AttributeError: 'LayerList' object has no attribute 'selected'

Correction

change in the source naparitools.py methods on_reset(self) and _do_shift(self):

self.viewer.layers.selected --> self.viewer.layers.selection

@ondrejstranik ondrejstranik added the bug Something isn't working label May 10, 2023
@kasasxav
Copy link
Collaborator

@ondrejstranik thank you! Would you want to open a PR with the changes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants