From c4dc91f5f2a7e04926070bbaabcd58ce85bb516d Mon Sep 17 00:00:00 2001 From: "Philipp Lohmann [pl]" Date: Tue, 5 Oct 2010 15:16:38 +0200 Subject: ooo33gsl10: #i112076# fix MetaFloatTransparentAction --- vcl/source/gdi/metaact.cxx | 2 -- 1 file changed, 2 deletions(-) (limited to 'vcl/source') diff --git a/vcl/source/gdi/metaact.cxx b/vcl/source/gdi/metaact.cxx index 94f07b8f17d1..8c1545758c3b 100644 --- a/vcl/source/gdi/metaact.cxx +++ b/vcl/source/gdi/metaact.cxx @@ -3793,7 +3793,6 @@ MetaAction* MetaFloatTransparentAction::Clone() void MetaFloatTransparentAction::Move( long nHorzMove, long nVertMove ) { maPoint.Move( nHorzMove, nVertMove ); - maMtf.Move(nHorzMove, nVertMove); } // ------------------------------------------------------------------------ @@ -3804,7 +3803,6 @@ void MetaFloatTransparentAction::Scale( double fScaleX, double fScaleY ) ImplScaleRect( aRectangle, fScaleX, fScaleY ); maPoint = aRectangle.TopLeft(); maSize = aRectangle.GetSize(); - maMtf.Scale(fScaleX, fScaleY); } // ------------------------------------------------------------------------ -- cgit From 967df99b1d91bbc884dfada36df16eead61f2d95 Mon Sep 17 00:00:00 2001 From: "Philipp Lohmann [pl]" Date: Wed, 6 Oct 2010 11:30:10 +0200 Subject: ooo33gsl10: #i97556# fix ImplDrawAlpha in RTL case --- vcl/source/gdi/outdev2.cxx | 11 +++++++++-- vcl/source/window/window.cxx | 0 2 files changed, 9 insertions(+), 2 deletions(-) mode change 100644 => 100755 vcl/source/gdi/outdev2.cxx mode change 100644 => 100755 vcl/source/window/window.cxx (limited to 'vcl/source') diff --git a/vcl/source/gdi/outdev2.cxx b/vcl/source/gdi/outdev2.cxx old mode 100644 new mode 100755 index bea307a4c38d..06dcd73cc3d4 --- a/vcl/source/gdi/outdev2.cxx +++ b/vcl/source/gdi/outdev2.cxx @@ -1988,7 +1988,15 @@ void OutputDevice::ImplDrawAlpha( const Bitmap& rBmp, const AlphaMask& rAlpha, const long nSrcWidth = aBmpRect.GetWidth(), nSrcHeight = aBmpRect.GetHeight(); const long nDstWidth = aDstRect.GetWidth(), nDstHeight = aDstRect.GetHeight(); const long nOutWidth = aOutSz.Width(), nOutHeight = aOutSz.Height(); - const long nOffX = aDstRect.Left() - aOutPt.X(), nOffY = aDstRect.Top() - aOutPt.Y(); + // calculate offset in original bitmap + // in RTL case this is a little more complicated since the contents of the + // bitmap is not mirrored (it never is), however the paint region and bmp region + // are in mirrored coordinates, so the intersection of (aOutPt,aOutSz) with these + // is content wise somewhere else and needs to take mirroring into account + const long nOffX = IsRTLEnabled() + ? aOutSz.Width() - aDstRect.GetWidth() - (aDstRect.Left() - aOutPt.X()) + : aDstRect.Left() - aOutPt.X(), + nOffY = aDstRect.Top() - aOutPt.Y(); long nX, nOutX, nY, nOutY; long nMirrOffX = 0; long nMirrOffY = 0; @@ -2002,7 +2010,6 @@ void OutputDevice::ImplDrawAlpha( const Bitmap& rBmp, const AlphaMask& rAlpha, for( nX = 0L, nOutX = nOffX; nX < nDstWidth; nX++, nOutX++ ) { pMapX[ nX ] = aBmpRect.Left() + nOutX * nSrcWidth / nOutWidth; - if( bHMirr ) pMapX[ nX ] = nMirrOffX - pMapX[ nX ]; } diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx old mode 100644 new mode 100755 -- cgit