Don't know if these masking fixes are necessary anymore now that QPixmap

is 'fixed' - but they don't do any harm, so they go in anyway.

svn path=/trunk/kdebase/kwin/; revision=114434
icc-effect-5.14.5
Rik Hemsley 2001-09-16 09:26:29 +00:00
parent 2b5294278b
commit b5c7e843fe
2 changed files with 10 additions and 2 deletions

View File

@ -127,6 +127,11 @@ Button::setPixmap(const QPixmap & p)
aPixmap_.convertFromImage(aTx);
iPixmap_.convertFromImage(iTx);
if (0 != p.mask())
{
aPixmap_.setMask(*p.mask());
iPixmap_.setMask(*p.mask());
}
}
repaint();

View File

@ -198,8 +198,9 @@ Static::_createTexture(QPixmap & px, int t, bool active)
QColor c(options->color(Options::ColorType(t), active));
QRgb light(c.light(110).rgb());
QRgb dark (c.dark(110).rgb());
QRgb mid (c.rgb());
QRgb light (c.light(110).rgb());
QRgb dark (c.dark(110).rgb());
QRgb * data(reinterpret_cast<QRgb *>(texture.bits()));
@ -208,6 +209,8 @@ Static::_createTexture(QPixmap & px, int t, bool active)
data[x] = light;
else if (data[x] == b)
data[x] = dark;
else
data[x] = mid;
px.convertFromImage(texture);
}