summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2011-07-31 23:49:35 +0100
committerCaolán McNamara <caolanm@redhat.com>2011-07-31 23:49:35 +0100
commitef6add9a7e0bcba1fb039afb75d62e753fa37949 (patch)
tree2f4bcee1cbcb97e6015995b7edd0d9087289a54e /vcl
parentd4d26018402aaa75fcb6524f5c7d99fcd9c5be45 (diff)
callcatcher: remove unused code
Diffstat (limited to 'vcl')
-rw-r--r--vcl/inc/vcl/outdev.hxx8
-rw-r--r--vcl/source/gdi/print2.cxx69
2 files changed, 0 insertions, 77 deletions
diff --git a/vcl/inc/vcl/outdev.hxx b/vcl/inc/vcl/outdev.hxx
index 78c7ad938d1a..135cdfe59a83 100644
--- a/vcl/inc/vcl/outdev.hxx
+++ b/vcl/inc/vcl/outdev.hxx
@@ -1193,14 +1193,6 @@ public:
Bitmap GetDownsampledBitmap( const Size& rDstSz,
const Point& rSrcPt, const Size& rSrcSz,
const Bitmap& rBmp, long nMaxBmpDPIX, long nMaxBmpDPIY );
- /** Retrieve downsampled and cropped bitmapEx
-
- @attention This method ignores negative rDstSz values, thus
- mirroring must happen outside this method (e.g. in DrawBitmapEx)
- */
- BitmapEx GetDownsampledBitmapEx( const Size& rDstSz,
- const Point& rSrcPt, const Size& rSrcSz,
- const BitmapEx& rBmpEx, long nMaxBmpDPIX, long nMaxBmpDPIY );
//-------------------------------------
// Native Widget Rendering functions
diff --git a/vcl/source/gdi/print2.cxx b/vcl/source/gdi/print2.cxx
index 2001968c60e8..0ce7d92e3f29 100644
--- a/vcl/source/gdi/print2.cxx
+++ b/vcl/source/gdi/print2.cxx
@@ -1470,75 +1470,6 @@ Bitmap OutputDevice::GetDownsampledBitmap( const Size& rDstSz,
// -----------------------------------------------------------------------------
-BitmapEx OutputDevice::GetDownsampledBitmapEx( const Size& rDstSz,
- const Point& rSrcPt, const Size& rSrcSz,
- const BitmapEx& rBmpEx, long nMaxBmpDPIX, long nMaxBmpDPIY )
-{
- BitmapEx aBmpEx( rBmpEx );
-
- if( !aBmpEx.IsEmpty() )
- {
- Point aPoint;
- const Rectangle aBmpRect( aPoint, aBmpEx.GetSizePixel() );
- Rectangle aSrcRect( rSrcPt, rSrcSz );
-
- // do cropping if neccessary
- if( aSrcRect.Intersection( aBmpRect ) != aBmpRect )
- {
- if( !aSrcRect.IsEmpty() )
- aBmpEx.Crop( aSrcRect );
- else
- aBmpEx.SetEmpty();
- }
-
- if( !aBmpEx.IsEmpty() )
- {
- // do downsampling if neccessary
- Size aDstSizeTwip( PixelToLogic( LogicToPixel( rDstSz ), MAP_TWIP ) );
-
- // #103209# Normalize size (mirroring has to happen outside of this method)
- aDstSizeTwip = Size( labs(aDstSizeTwip.Width()), labs(aDstSizeTwip.Height()) );
-
- const Size aBmpSize( aBmpEx.GetSizePixel() );
- const double fBmpPixelX = aBmpSize.Width();
- const double fBmpPixelY = aBmpSize.Height();
- const double fMaxPixelX = aDstSizeTwip.Width() * nMaxBmpDPIX / 1440.0;
- const double fMaxPixelY = aDstSizeTwip.Height() * nMaxBmpDPIY / 1440.0;
-
- // check, if the bitmap DPI exceeds the maximum DPI (allow 4 pixel rounding tolerance)
- if( ( ( fBmpPixelX > ( fMaxPixelX + 4 ) ) ||
- ( fBmpPixelY > ( fMaxPixelY + 4 ) ) ) &&
- ( fBmpPixelY > 0.0 ) && ( fMaxPixelY > 0.0 ) )
- {
- // do scaling
- Size aNewBmpSize;
- const double fBmpWH = fBmpPixelX / fBmpPixelY;
- const double fMaxWH = fMaxPixelX / fMaxPixelY;
-
- if( fBmpWH < fMaxWH )
- {
- aNewBmpSize.Width() = FRound( fMaxPixelY * fBmpWH );
- aNewBmpSize.Height() = FRound( fMaxPixelY );
- }
- else if( fBmpWH > 0.0 )
- {
- aNewBmpSize.Width() = FRound( fMaxPixelX );
- aNewBmpSize.Height() = FRound( fMaxPixelX / fBmpWH);
- }
-
- if( aNewBmpSize.Width() && aNewBmpSize.Height() )
- aBmpEx.Scale( aNewBmpSize );
- else
- aBmpEx.SetEmpty();
- }
- }
- }
-
- return aBmpEx;
-}
-
-// -----------------------------------------------------------------------------
-
void Printer::DrawGradientEx( OutputDevice* pOut, const Rectangle& rRect, const Gradient& rGradient )
{
const PrinterOptions& rPrinterOptions = GetPrinterOptions();