| Summary: | Qt6 break shift-click selection of contiguous layers | ||
|---|---|---|---|
| Product: | [Applications] krita | Reporter: | Ming Chuan <ming> |
| Component: | * Unknown | Assignee: | Krita Bugs <krita-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | dra.w.p.il.e+bugskde, halla, info |
| Priority: | NOR | ||
| Version First Reported In: | git master (please specify the git hash!) | ||
| Target Milestone: | --- | ||
| Platform: | Other | ||
| OS: | Linux | ||
| Latest Commit: | https://invent.kde.org/graphics/krita/-/commit/d3eaaf15976380a5df6370dfa9ccd7f5b281f34f | Version Fixed/Implemented In: | |
| Sentry Crash Report: | |||
|
Description
Ming Chuan
2025-10-04 01:41:06 UTC
I cannot reproduce with either master or 5.2 on my m1 with a wacom cintiq tablet. I tested with Krita 5.3, Windows 11, Huion tablet. If layers are empty, shift click works as expected (all layers inbetween get selected). If layers contain pixels (e.g. a brush stroke), shift click does not work as expected. Instead of selecting all layers inbetween only the last clicked layer gets selected. I tried that too, but I still cannot reproduce with 5.2.13 on MacOS and a cintiq tablet. That makes it sound like it's different for different types of tablets... > If layers contain pixels (e.g. a brush stroke), shift click does not work as expected. Instead of selecting all layers inbetween only the last clicked layer gets selected. That's wild, on X11/XWayland it works regardless of whether the paint layers has any pixels > I cannot reproduce with either master or 5.2 on my m1 with a wacom cintiq tablet. Did you build master with qt5 or qt6. How about qt6 appimage? I looked into the code and find that * The multi-select bug is caused by the (ctrl drag&drop) hacks in `NodeView::selectionCommand` , which overrides the shift multiselect behavior (perhaps in a nondeterministic way). * It seems like the feature that the workaround is for (ctrl-dragging&dropping) is already not 100% working when multiple layers is selected. I attempted to fix it but I think it'll need some good understanding of the qt list.. After all, it feels krita is trying to support many kinds intricate actions in the layers docker that's perhaps beyond what the qt's list view is designed for These are all Qt5 builds: I haven't succeeded in building against Qt6 on macOS yet. (Another issue that's probably specific to wayland: when the CPU is busy, krita's keyboard event loop probably got somehow stuck, and ctrl-select randomly stops working and becomes normal select) Git commit d3eaaf15976380a5df6370dfa9ccd7f5b281f34f by Dmitry Kazakov, on behalf of Luna Lovecraft. Committed on 25/12/2025 at 14:50. Pushed by dkazakov into branch 'master'. Fix shift click selection not working in Qt6 Fixed shift click layer selection not working in Qt6, by removing a custom `selectCommand` function from `NodeView`. Those workarounds don't seem to be necessary anymore as all the related bugs have been fixed in the newer Qt versions. And now the only thing it's doing is breaking the Qt6 version. M +0 -55 plugins/dockers/layerdocker/NodeView.cpp M +0 -3 plugins/dockers/layerdocker/NodeView.h https://invent.kde.org/graphics/krita/-/commit/d3eaaf15976380a5df6370dfa9ccd7f5b281f34f The fix for this caused a regression, see BUG 514427. Might need to be partially reverted or ifdef'd between Qt versions. |