Closed Rdornier closed 8 months ago
Thanks for the feedback. That behaviour was a conscious decision. I thought that the particular Z-index of the existing panel would be quite particular to that Image (e.g. focus on a certain feature of that image) and not be relevant to any new image that you add. This is in contrast to the T index which is preserved, so if you have a series of Time-points for a movie, you could set a new ID for those and see the same time-points for a new Image. But I see that you want the same behaviour for Z, which is fair enough, and I'm happy to change the behaviour accordingly.
I think this would just need to remove this line: https://github.com/ome/omero-figure/blob/eb6c3ead527d79584d41d0a6f8580562522c304a/src/js/views/modal_views.js#L284
and then handle theZ
of the original image being greater than sizeZ
of the new image as we do for T-index at:
https://github.com/ome/omero-figure/blob/eb6c3ead527d79584d41d0a6f8580562522c304a/src/js/views/modal_views.js#L366
Thanks Will for your feedback !
But I see that you want the same behaviour for Z, which is fair enough, and I'm happy to change the behaviour accordingly.
It would be very nice 👍, thanks a lot !
Hello @will-moore,
I open a PR #518 with the necessary changes to make it work.
However, I couldn't remove the line setting theZ
because I always got a black image.
Instead, I keep it like this and add json.newImg['theZ'] = json.selImg['theZ']
if the number of slices matches between the two images.
Bug report
Describe the bug The displayed slices of z-stacks are set to by-default values when you copy-paste the stack and edit its id (the new image has the same number of xyczt). Related issue https://github.com/ome/omero-figure/issues/511
To Reproduce
Expected behavior For each stack with the same number of slices, the displayed slice number should be kept and the slice displayed when editing the ID with another stack ID.
Screenshots![OMERO-figure-bug-slice](https://github.com/ome/omero-figure/assets/64911638/de25efa8-f884-4239-9b63-6e837d692659)
Desktop :
ping @romainGuiet