-
-
Notifications
You must be signed in to change notification settings - Fork 410
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
Point selection highlights do not respect canvas size limits #6682
Comments
I can reproduce this on 0.4.19 and main. |
Possibly related to this, I noticed that click targets mismatch and make it hard to move a point without accidentially adding new point. When zoomed out, the visible point is at the lower canvas limit size (larger than data size). When dragging the point not perfectly from the center, it does not move. This would be explained by this bug if point selection highlights correspond to click targets. |
I think that's the opposite problem @aeisenbarth — the point selection is defined by the point "data" size, not the canvas size, when you are way zoomed out, selecting the point is harder. (There may of course also be a bug in the target detection, but I do think that is unrelated to this one.) This is made worse by macOS's implementation of OpenGL which has an absurdly small maximum point size (regardless of what canvas size limits says) — so sometimes napari thinks that a point is on top of another point, but there is no visual indication at all that this is the case. I don't really know how to fix this though, because I don't know how to introspect what the OpenGL maximum point size is... |
There are a couple things at play:
I've not experienced selection issues when zoomed out, but when zoomed in. Those may be due to the macOS limit, but I'm not sure -- I need to do some tests with linux size by side. |
# References and relevant issues Closes #6682 # Description The selection markers were not updated accordingly. This is still not perfect (zooming in and out beyond the limits will change the thickness of the highlight), but it's a limitation of how hilight is implemented (by just using extra markers). Ideally we want to have a single marker take care of hilight as well, but this requires rewriting the shaders and it's not trivial.
🐛 Bug Report
Setting points canvas size limits works fine. However, the point selection highlights are unchanged.
💡 Steps to Reproduce
💡 Expected Behavior
I expected the selection highlights to be the same size as the points.
🌎 Environment
napari: 0.4.18
Platform: Windows-10-10.0.19045-SP0
Python: 3.10.13 | packaged by conda-forge | (main, Oct 26 2023, 18:01:37) [MSC v.1935 64 bit (AMD64)]
Qt: 5.15.8
PyQt5: 5.15.9
NumPy: 1.26.0
SciPy: 1.11.3
Dask: 2023.11.0
VisPy: 0.12.2
magicgui: 0.8.0
superqt: 0.6.1
in-n-out: 0.1.9
app-model: 0.2.2
npe2: 0.7.3
OpenGL:
Screens:
Settings path:
💡 Additional Context
No response
The text was updated successfully, but these errors were encountered: