Bug 514760 - kra file is imported with its layer stack reversed
Summary: kra file is imported with its layer stack reversed
Status: CONFIRMED
Alias: None
Product: krita
Classification: Applications
Component: * Unknown (other bugs)
Version First Reported In: unspecified
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2026-01-17 20:18 UTC by codl
Modified: 2026-01-17 20:24 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description codl 2026-01-17 20:18:41 UTC
SUMMARY
When importing a kra file into a document, the layers from the imported file end up stacked in reverse order.

STEPS TO REPRODUCE
1. Create or find a kra file with at least two layers.
2. Open a new document.
3. Import the file into the new document, either by dragging it onto the canvas and choosing "Insert as new layer", or with the menu entry Layer > Import/Export > Import layer.

OBSERVED RESULT
Layers are imported "upside-down": the topmost layer ends up on the bottom and so on.

EXPECTED RESULT
Layers end up in the same order as in the source file.

SOFTWARE/OS VERSIONS
Krita

 Version: 5.2.14 (git 31056c6)
 Hidpi: true

Qt

  Version (compiled): 5.15.7
  Version (loaded): 5.15.7

OS Information

  Build ABI: x86_64-little_endian-lp64
  Build CPU: x86_64
  CPU: x86_64
  Kernel Type: linux
  Kernel Version: 6.18.3-arch1-1
  Pretty Productname: Steam Runtime 2 (soldier)
  Product Type: steamrt
  Product Version: 2
  Desktop: XFCE
  Appimage build: Yes

ADDITIONAL INFORMATION
In my case I don't need separate layers from the imported file but rather a single flattened layer so my workaround is to add the file as a file layer and then convert it to a paint layer.

I'm running the steam build of krita but I've also tried krita plus 5.2.15-prealpha-c82e28995d with the same result. Couldn't try krita next, it wouldn't launch for me.
Comment 1 dra.w.p.il.e+bugskde 2026-01-17 20:24:56 UTC
Thanks, can confirm this also happens with other layered formats like ORA or PSD.