summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-05-03 15:03:34 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-05-03 15:03:34 -0500
commit7446fdb128feb8d941e148f4de341a44256045ef (patch)
tree1af159f8c2088d94780c53458601f17996c6c85b
parent68f557434a089b4eecd682397cc63bcd26a259f7 (diff)
downloadtqt3-7446fdb1.tar.gz
tqt3-7446fdb1.zip
Automated update from Qt3
-rw-r--r--src/kernel/qcolor_x11.cpp8
-rw-r--r--src/kernel/qpainter_x11.cpp19
2 files changed, 21 insertions, 6 deletions
diff --git a/src/kernel/qcolor_x11.cpp b/src/kernel/qcolor_x11.cpp
index 67a3912f..8f02bcde 100644
--- a/src/kernel/qcolor_x11.cpp
+++ b/src/kernel/qcolor_x11.cpp
@@ -407,8 +407,14 @@ uint TQColor::alloc( int screen )
b = sd->blue_shift > 0 ? b << sd->blue_shift : b >> -sd->blue_shift;
pix = (b & sd->blue_mask) | (g & sd->green_mask) | (r & sd->red_mask)
| ~(sd->blue_mask | sd->green_mask | sd->red_mask);
- if ( screen == TQPaintDevice::x11AppScreen() )
+ if (TQPaintDevice::x11AppDepth(screen) == 32) {
+ int a = tqAlpha(d.argb);
+ pix = pix & 0x00ffffff;
+ pix = pix | (a << 24);
+ }
+ if ( screen == TQPaintDevice::x11AppScreen() ) {
d.d32.pix = pix;
+ }
return pix;
}
TQColorData *c = sd->colorDict->find( (long)(d.argb) );
diff --git a/src/kernel/qpainter_x11.cpp b/src/kernel/qpainter_x11.cpp
index dc3e9a4c..bcc12af1 100644
--- a/src/kernel/qpainter_x11.cpp
+++ b/src/kernel/qpainter_x11.cpp
@@ -1856,16 +1856,24 @@ void TQPainter::drawWinFocusRect( int x, int y, int w, int h,
RasterOp old_rop = (RasterOp)rop;
if ( xorPaint ) {
- if ( TQColor::numBitPlanes() <= 8 )
+ if ( TQColor::numBitPlanes() <= 8 ) {
setPen( TQPen(color1, 0, TQt::FineDotLine) );
- else
+ }
+ else if ( TQColor::numBitPlanes() <= 8 ) {
setPen( TQPen(white, 0, TQt::FineDotLine) );
+ }
+ else {
+ setPen( TQPen(TQColor(tqRgba(255,255,255,0)), 0, TQt::FineDotLine) );
+ }
setRasterOp( XorROP );
- } else {
- if ( tqGray( bgColor.rgb() ) < 128 )
+ }
+ else {
+ if ( tqGray( bgColor.rgb() ) < 128 ) {
setPen( TQPen(white, 0, TQt::FineDotLine) );
- else
+ }
+ else {
setPen( TQPen(black, 0, TQt::FineDotLine) );
+ }
}
if ( testf(ExtDev|VxF|WxF) ) {
@@ -1893,6 +1901,7 @@ void TQPainter::drawWinFocusRect( int x, int y, int w, int h,
XSetLineAttributes( dpy, gc, 1, LineOnOffDash, CapButt, JoinMiter );
XDrawRectangle( dpy, hd, gc, x, y, w-1, h-1 );
+
XSetLineAttributes( dpy, gc, 0, LineSolid, CapButt, JoinMiter );
setRasterOp( old_rop );
setPen( old_pen );