Commit e9596443 authored by Martin Koller's avatar Martin Koller
Browse files

convert selection to ARGB32 format so that transparency mask works

according Qt doc, image format must be set to Format_ARGB32Premultiplied
or Format_ARGB32 for the composition modes to have any effect.
This is needed for the transparency mask to work here.

BUG: 300168
FIXED-IN: 4.13.1
parent 13506638
......@@ -334,7 +334,10 @@ kpImage kpAbstractImageSelection::baseImage () const
void kpAbstractImageSelection::setBaseImage (const kpImage &baseImage)
{
Q_ASSERT (::CanSetBaseImageTo (this, baseImage));
d->baseImage = baseImage;
// qt doc: the image format must be set to Format_ARGB32Premultiplied or Format_ARGB32
// for the composition modes to have any effect
d->baseImage = baseImage.convertToFormat(QImage::Format_ARGB32_Premultiplied);
recalculateTransparencyMaskCache ();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment