Brush size keybinding
See original GitHub issue🚀 Feature
Keybinding to change label paint brush size.
Motivation
During labeling, I usually completely label each object (cell, cell colony, etc) before moving to another. To do so I label the coarse structure of the object first, using little zoom (“overview mode”). Then, I zoom in to label the finer details of the object (rim areas, branches, string-like features), before I switch to the next object. This involves quite a bit of paint brush size changing. Changing the size in the layer controls is inconvenient, as I have to move the cursor out of the image to be labeled, change the size, move back to the image to check if the new size is correct, (optionally move back to the layer controls to re-adjust), and then continue labeling. This disrupts the workflow.
Pitch
I suggest a simple key binding (e.g. q
and e
to have them close to the 1
-5
mode switches) to adjust the brush size.
Alternatives
Alternatively, one could change the brush size using the mouse wheel (not used at the moment as far as I know).
Additional context
This is my first request. I searched the issue list for potential duplicates of this request, but didn’t find any, so I hope this request makes sense.
There already is a menu Preferences -> Shortcuts -> Group: Labels layer
to adjust keybinding, so I think it should be quite easy to add an option for brush size adjustment.
If anybody has pointers towards where this behavior is controlled, we (MBPhys and me) are happy to implement this ourselves and merge it if you’ll allow it.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:10
- Comments:20 (20 by maintainers)
It is life changing indeed! Let’s keep your PR open, as it already describes the issue perfectly and presents a minimum working solution for people to experience the pure bliss of auto-repeating brush size key bindings ❤️ I’ll quote my above-mentioned idea for a general solution of press-and-hold keybindings in the PR so that the information is found in one place.
This scroll wheel binding from @ianhi is pretty sweet too: https://github.com/napari/napari/issues/4837#issuecomment-1189342980 https://github.com/Hekstra-Lab/napari-labeller/blob/74913dce72c773df2ec94e1cb3798dd40fedf219/src/napari_labeller/_keybinds.py#L59-L66
Though personally I might prefer the scroll wheel just did zoom independent of PAN on the Labels layer…