Skip to content

Draft: psd clipping layers import improvement

Til Schmitter requested to merge til/krita:til-changes into master

psd clipping layers now get imported without changing the look of the document by creating clipping groups around clipping layers or folders and enabling alpha inheritance on clipping layers. this is purely regarding importing psds so far. once you save a psd clipping still gets removed.

to do:

  • set folder blending mode to the one of the base layer
  • ignore clipping layers that are already in clipping groups
  • export with inherit alpha -> clipping
  • prompt to ask user if a conversion should take place at all
  • (if clipping gets implemented, this code should set the clipping property instead)

BUG:350114

Test Plan

i created a complicated set of clipping layer and folder setups in medibang paint and opened the resulting psd in krita to verify the folder structure to be changed correctly.

source file in medibang paint before after
mdp_test_source image image

Formalities Checklist

  • I confirmed this builds.
  • I confirmed Krita ran and the relevant functions work.
  • I tested the relevant unit tests and can confirm they are not broken. (If not possible, don't hesitate to ask for help!)
  • I made sure my commits build individually and have good descriptions as per KDE guidelines.
  • I made sure my code conforms to the standards set in the HACKING file.
  • I can confirm the code is licensed and attributed appropriately, and that unattributed code is mine, as per KDE Licensing Policy.
Edited by Halla Rempt

Merge request reports

Loading