repaint the pixmap over transparency if it doesn't have an alpha cannel
svn path=/trunk/KDE/kdelibs/; revision=1133517
This commit is contained in:
parent
bbc72390b9
commit
76ead449e5
@ -154,7 +154,7 @@ void centerPixmaps(QPixmap &from, QPixmap &to)
|
||||
fromRect.moveCenter(actualRect.center());
|
||||
toRect.moveCenter(actualRect.center());
|
||||
|
||||
if (from.size() != actualRect.size()) {
|
||||
if (from.size() != actualRect.size() || !from.hasAlphaChannel()) {
|
||||
QPixmap result(actualRect.size());
|
||||
result.fill(Qt::transparent);
|
||||
QPainter p(&result);
|
||||
@ -164,7 +164,7 @@ void centerPixmaps(QPixmap &from, QPixmap &to)
|
||||
from = result;
|
||||
}
|
||||
|
||||
if (to.size() != actualRect.size()) {
|
||||
if (to.size() != actualRect.size() || !to.hasAlphaChannel()) {
|
||||
QPixmap result(actualRect.size());
|
||||
result.fill(Qt::transparent);
|
||||
QPainter p(&result);
|
||||
|
Loading…
Reference in New Issue
Block a user