summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSamuel Rødal <sroedal@trolltech.com>2009-03-20 12:47:28 (GMT)
committerSamuel Rødal <sroedal@trolltech.com>2009-03-27 14:26:54 (GMT)
commit4833b02f80bc5bcd7b0946453f3e6c7bc09b01f6 (patch)
tree885ebeaebfe2fa6cdaa98522258929ab8ec5b7b6
parentb3f88e8629390a49d12fd7684e711280b7b2c7c2 (diff)
downloadQt-4833b02f80bc5bcd7b0946453f3e6c7bc09b01f6.zip
Qt-4833b02f80bc5bcd7b0946453f3e6c7bc09b01f6.tar.gz
Qt-4833b02f80bc5bcd7b0946453f3e6c7bc09b01f6.tar.bz2
Fix QPixmap::fromImage() bug for monochrome images on Mac.
Monochrome images should be converted to black and white, not transparent and white. Reported on qt-interest. Task-number: 249175 Reviewed-by: Trond
-rw-r--r--src/gui/image/qpixmap_mac.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/image/qpixmap_mac.cpp b/src/gui/image/qpixmap_mac.cpp
index bfc605b..26d9618 100644
--- a/src/gui/image/qpixmap_mac.cpp
+++ b/src/gui/image/qpixmap_mac.cpp
@@ -303,7 +303,7 @@ void QMacPixmapData::fromImage(const QImage &img,
else
one_bit = one_bit >> (x % 8);
if ((one_bit & 0x01))
- *(drow+x) = 0x00000000;
+ *(drow+x) = 0xFF000000;
else
*(drow+x) = 0xFFFFFFFF;
}