From 560378aaca1784ba19806a0414a32b20c744de39 Mon Sep 17 00:00:00 2001 From: tpearson Date: Mon, 3 Jan 2011 04:12:51 +0000 Subject: Automated conversion for enhanced compatibility with TQt for Qt4 3.4.0 TP1 NOTE: This will not compile with Qt4 (yet), however it does compile with Qt3 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1211081 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kdeui/kpixmapio.cpp | 98 ++++++++++++++++++++++++++--------------------------- 1 file changed, 49 insertions(+), 49 deletions(-) (limited to 'kdeui/kpixmapio.cpp') diff --git a/kdeui/kpixmapio.cpp b/kdeui/kpixmapio.cpp index 74c68b82e..3946c58ad 100644 --- a/kdeui/kpixmapio.cpp +++ b/kdeui/kpixmapio.cpp @@ -468,7 +468,7 @@ TQImage KPixmapIO::convertFromXImage() cmap, ncells); image.setNumColors(ncells); for (i=0; i> 8)); + image.setColor(i, tqRgb(cmap[i].red, cmap[i].green, cmap[i].blue >> 8)); } else image.create(width, height, 32); @@ -485,11 +485,11 @@ TQImage KPixmapIO::convertFromXImage() case bo16_RGB_565: case bo16_BGR_565: { - Q_INT32 pixel, *src; + TQ_INT32 pixel, *src; QRgb *dst, val; for (y=0; y> 24) | (d2 << 8); @@ -581,16 +581,16 @@ TQImage KPixmapIO::convertFromXImage() char *src; QRgb *dst; int w1 = width/4; - Q_INT32 d1, d2, d3; + TQ_INT32 d1, d2, d3; for (y=0; y> 24) | (d2 << 8); @@ -638,11 +638,11 @@ void KPixmapIO::convertToXImage(const TQImage &img) if (img.depth() == 32) { QRgb *src, pixel; - Q_INT32 *dst, val; + TQ_INT32 *dst, val; for (y=0; y> 9) | + *((TQ_INT16 *)dst) = ((pixel & 0xf80000) >> 9) | ((pixel & 0xf800) >> 6) | ((pixel & 0xff) >> 3); } } } else { uchar *src; - Q_INT32 val, *dst; + TQ_INT32 val, *dst; QRgb pixel, *clut = img.colorTable(); for (y=0; y> 9) | + *((TQ_INT16 *)dst) = ((pixel & 0xf80000) >> 9) | ((pixel & 0xf800) >> 6) | ((pixel & 0xff) >> 3); } } @@ -695,11 +695,11 @@ void KPixmapIO::convertToXImage(const TQImage &img) if (img.depth() == 32) { QRgb *src, pixel; - Q_INT32 *dst, val; + TQ_INT32 *dst, val; for (y=0; y> 8) | + *((TQ_INT16 *)dst) = ((pixel & 0xf80000) >> 8) | ((pixel & 0xfc00) >> 5) | ((pixel & 0xff) >> 3); } } } else { uchar *src; - Q_INT32 val, *dst; + TQ_INT32 val, *dst; QRgb pixel, *clut = img.colorTable(); for (y=0; y> 8) | + *((TQ_INT16 *)dst) = ((pixel & 0xf80000) >> 8) | ((pixel & 0xfc00) >> 5) | ((pixel & 0xff) >> 3); } } @@ -763,17 +763,17 @@ void KPixmapIO::convertToXImage(const TQImage &img) d2 = (*src++ & 0xffffff); d3 = (*src++ & 0xffffff); d4 = (*src++ & 0xffffff); - *((Q_INT32 *)dst) = d1 | (d2 << 24); - *((Q_INT32 *)dst+1) = (d2 >> 8) | (d3 << 16); - *((Q_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); + *((TQ_INT32 *)dst) = d1 | (d2 << 24); + *((TQ_INT32 *)dst+1) = (d2 >> 8) | (d3 << 16); + *((TQ_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); dst += 12; } for (x=w1*4; x> 8) | (d3 << 16); - *((Q_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); + *((TQ_INT32 *)dst) = d1 | (d2 << 24); + *((TQ_INT32 *)dst+1) = (d2 >> 8) | (d3 << 16); + *((TQ_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); dst += 12; } for (x=w1*4; x> 8) | (d3 << 16); - *((Q_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); + *((TQ_INT32 *)dst) = d1 | (d2 << 24); + *((TQ_INT32 *)dst+1) = (d2 >> 8) | (d3 << 16); + *((TQ_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); dst += 12; } for (x=w1*4; x> 8) | (d3 << 16); - *((Q_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); + *((TQ_INT32 *)dst) = d1 | (d2 << 24); + *((TQ_INT32 *)dst+1) = (d2 >> 8) | (d3 << 16); + *((TQ_INT32 *)dst+2) = (d4 << 8) | (d3 >> 16); dst += 12; } for (x=w1*4; x