Fix layer styles to handle FG->BG gradients correctly
Patch 1: Fix layer styles to handle FG->BG gradients correctly
All the dynamic gradients should be baked before assigning to the layer.
Patch 2: Fix Fg/Bg gradients to work in the Filter Brush
We need to properly initialize KoCanvasResourcesInterfaceSP in the filter config widget.
Still TODO (for after-5.0):
-
Deprecate and remove KisConfigWidget::setView(). We store a pointer to that in kritaimage.
-
Right now both, Halftone and Gradientmap filters bake Fg/Bg colors into the configuration. It means that it is impossible to make a brush that applies gradientmap linked to the current fg and bg colors. Ideally, the brush preset should keep this link dynamic, and the user should be able to override this behavior by "baking" the dynamic gradient in the gradient selector. But this change would need a lot of refactoring with little benefit and should be postponed till after Krita 5.0