summaryrefslogtreecommitdiffstats
path: root/src/kernel/qimage.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/qimage.cpp')
-rw-r--r--src/kernel/qimage.cpp30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/kernel/qimage.cpp b/src/kernel/qimage.cpp
index 1c1d84b2c..ce95f1cb6 100644
--- a/src/kernel/qimage.cpp
+++ b/src/kernel/qimage.cpp
@@ -59,12 +59,12 @@
#include <ctype.h>
#include <stdlib.h>
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
#include "qgfx_qws.h"
#endif
// 16bpp images on supported on TQt/Embedded
-#if !defined( Q_WS_QWS ) && !defined(TQT_NO_IMAGE_16_BIT)
+#if !defined( TQ_WS_QWS ) && !defined(TQT_NO_IMAGE_16_BIT)
#define TQT_NO_IMAGE_16_BIT
#endif
@@ -510,7 +510,7 @@ TQImage::TQImage( uchar* yourdata, int w, int h, int depth,
data->bitordr = bitOrder;
}
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
/*!
Constructs an image that uses an existing memory buffer. The
@@ -559,7 +559,7 @@ TQImage::TQImage( uchar* yourdata, int w, int h, int depth,
data->bits = jt;
data->bitordr = bitOrder;
}
-#endif // Q_WS_QWS
+#endif // TQ_WS_QWS
/*!
Destroys the image and cleans up.
@@ -666,7 +666,7 @@ TQImage TQImage::copy() const
} else {
TQImage image;
image.create( width(), height(), depth(), numColors(), bitOrder() );
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
// TQt/Embedded can create images with non-default bpl
// make sure we don't crash.
if ( image.numBytes() != numBytes() )
@@ -1098,7 +1098,7 @@ TQImage::Endian TQImage::systemByteOrder()
}
-#if defined(Q_WS_X11)
+#if defined(TQ_WS_X11)
#include <X11/Xlib.h> // needed for systemBitOrder
#include <X11/Xutil.h>
#include <X11/Xos.h>
@@ -1129,7 +1129,7 @@ TQImage::Endian TQImage::systemByteOrder()
TQImage::Endian TQImage::systemBitOrder()
{
-#if defined(Q_WS_X11)
+#if defined(TQ_WS_X11)
return BitmapBitOrder(tqt_xdisplay()) == MSBFirst ? BigEndian :LittleEndian;
#else
return BigEndian;
@@ -1279,7 +1279,7 @@ bool TQImage::create( int width, int height, int depth, int numColors,
return FALSE;
}
// TQt/Embedded doesn't waste memory on unnecessary padding.
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
const int bpl = (width*depth+7)/8; // bytes per scanline
const int pad = 0;
#else
@@ -4745,7 +4745,7 @@ bool read_dib( TQDataStream& s, int offset, int startpos, TQImage& image )
d->at( startpos + offset ); // start of image data
int bpl = image.bytesPerLine();
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
//
// Guess the number of bytes-per-line if we don't know how much
// image data is in the file (bogus image ?).
@@ -4761,7 +4761,7 @@ bool read_dib( TQDataStream& s, int offset, int startpos, TQImage& image )
while ( --h >= 0 ) {
if ( d->readBlock((char*)line[h],bpl) != bpl )
break;
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
if ( pad > 0 )
d->at(d->at()+pad);
#endif
@@ -4911,7 +4911,7 @@ bool read_dib( TQDataStream& s, int offset, int startpos, TQImage& image )
while ( --h >= 0 ) {
if ( d->readBlock((char *)line[h],bpl) != bpl )
break;
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
if ( pad > 0 )
d->at(d->at()+pad);
#endif
@@ -4989,7 +4989,7 @@ bool qt_write_dib( TQDataStream& s, TQImage image )
} else if ( image.depth() == 32 ) {
bpl_bmp = ((image.width()*24+31)/32)*4;
nbits = 24;
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
} else if ( image.depth() == 1 || image.depth() == 8 ) {
// TQt/E doesn't word align.
bpl_bmp = ((image.width()*image.depth()+31)/32)*4;
@@ -5035,14 +5035,14 @@ bool qt_write_dib( TQDataStream& s, TQImage image )
int y;
if ( nbits == 1 || nbits == 8 ) { // direct output
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
// TQt/E doesn't word align.
int pad = bpl_bmp - bpl;
char padding[4];
#endif
for ( y=image.height()-1; y>=0; y-- ) {
d->writeBlock( (char*)image.scanLine(y), bpl );
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
d->writeBlock( padding, pad );
#endif
}
@@ -6500,7 +6500,7 @@ void TQImage::setText(const char* key, const char* lang, const TQString& s)
#endif // TQT_NO_IMAGE_TEXT
-#ifdef Q_WS_QWS
+#ifdef TQ_WS_QWS
/*!
\internal
*/