Diffusion Krita 4450d6539b9d

Fixed Flatten Layer and Merge Down actions for layer with layer styles

Authored by dkazakov on Jul 13 2015, 5:43 PM.

Description

Fixed Flatten Layer and Merge Down actions for layer with layer styles

Also fixed a few of other bus. Now merging strategy is the following:

For Flatten Layer:

  1. If a layer doesn't have layer styles, its blending mode and channel flags are kept untouched while the flattening process.
  2. If a layer has a style applied, then all the composition options are reset and the layer is converted into Normal-mode layer.

For Merge Down:

  1. If the two layers has the same opacity, blend mode, channel flags and have no layer styles, then the resulting layer inherits all their blend options.
  2. If the condition above isn't true, then the two layers are blended into a new layer with default blending options (Normal, 100% opacity).

Still TODO:
Implement "Merge Selected Layers" correctly.

CC:kimageshop@kde.org
BUG:349479
Ref T456

Details

Committed
dkazakovJul 13 2015, 5:45 PM
Parents
R37:dbacb2eb8a86: Remove unused includes
Branches
Unknown
Tags
Unknown
Tasks
Restricted Maniphest Task