SUMMARY *** Cutting (or copying) content from an alpha inheriting layer pastes it completely elsewhere *** STEPS TO REPRODUCE 1. Have a folder and 2 layers inside 2. Have the above layer inherit alpha 3. Cut content from the alpha inheriting layer 4. Paste OBSERVED RESULT The pasted content on the new created layer spawns elsewhere, sometimes out of canvas EXPECTED RESULT Pasted content would spawn in the same location it was cut from SOFTWARE/OS VERSIONS Operating System: EndeavourOS KDE Plasma Version: 5.27.3 KDE Frameworks Version: 5.104.0 Qt Version: 5.15.8 Kernel Version: 6.2.8-arch1-1 (64-bit) Graphics Platform: X11 Processors: 16 × AMD Ryzen 7 3700X 8-Core Processor Memory: 31,3 GiB of RAM Graphics Processor: NVIDIA GeForce RTX 2070 SUPER/PCIe/SSE2 ADDITIONAL INFORMATION refer to this thread for visual examples https://krita-artists.org/t/cut-paste-suddenly-doesnt-paste-in-place/61079 where I questioned the issue, got confirmed it is a bug and was requested reporting it
I can Confirm that this bug is present in the 5.1.5 appimage and the 25 March 5.2.0-prealpha (git 87759eb0fd) appimage. It seems to have been introduced in version 5.1.2 because version 5.1.1 and previous versions do not have this bug.
Seems to have been caused by commit e41db7b6, which checks whether a paste is within image boundaries. Apparently alpha-inheriting layers have an empty exactBounds(), so they are caught in the > (!clip->exactBounds().contains(image->bounds()) && !clip->exactBounds().intersects(image->bounds())) check and get pasted at the center of the image. (libs/ui/actions/KisPasteActionFactories.cpp@234/235)
*** Bug 467861 has been marked as a duplicate of this bug. ***
*** Bug 464483 has been marked as a duplicate of this bug. ***
Okay, I can reproduce
Git commit caaa5bc5645fc547dfa2e457808c3ab94918d55e by Dmitry Kazakov. Committed on 21/07/2023 at 15:32. Pushed by dkazakov into branch 'master'. Fix cut-pasting of an alpha-inheriting layer M +1 -1 libs/ui/actions/KisPasteActionFactories.cpp M +16 -10 libs/ui/kis_clipboard.cc https://invent.kde.org/graphics/krita/-/commit/caaa5bc5645fc547dfa2e457808c3ab94918d55e