summaryrefslogtreecommitdiff
path: root/vcl/source/gdi
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source/gdi')
-rw-r--r--vcl/source/gdi/animate.cxx67
-rw-r--r--vcl/source/gdi/bitmap.cxx85
-rw-r--r--vcl/source/gdi/bitmap2.cxx46
-rw-r--r--vcl/source/gdi/bitmap3.cxx16
-rw-r--r--vcl/source/gdi/bitmap4.cxx28
-rw-r--r--vcl/source/gdi/gdimtf.cxx134
-rw-r--r--vcl/source/gdi/impgraph.cxx131
-rw-r--r--vcl/source/gdi/impimage.cxx46
-rw-r--r--vcl/source/gdi/impvect.cxx97
-rw-r--r--vcl/source/gdi/outdev.cxx119
-rw-r--r--vcl/source/gdi/outdev2.cxx16
-rw-r--r--vcl/source/gdi/outdev3.cxx324
-rw-r--r--vcl/source/gdi/outdev4.cxx36
-rw-r--r--vcl/source/gdi/pngread.cxx70
-rw-r--r--vcl/source/gdi/pngwrite.cxx43
-rw-r--r--vcl/source/gdi/print2.cxx17
-rw-r--r--vcl/source/gdi/salmisc.cxx28
17 files changed, 1 insertions, 1302 deletions
diff --git a/vcl/source/gdi/animate.cxx b/vcl/source/gdi/animate.cxx
index fe7de29f3bd4..9665f832040e 100644
--- a/vcl/source/gdi/animate.cxx
+++ b/vcl/source/gdi/animate.cxx
@@ -27,23 +27,11 @@
#include <impanmvw.hxx>
DBG_NAME( Animation )
-// -----------
-// - Defines -
-// -----------
-
#define MIN_TIMEOUT 2L
#define INC_TIMEOUT 0L
-// -----------
-// - statics -
-// -----------
-
sal_uLong Animation::mnAnimCount = 0UL;
-// -------------------
-// - AnimationBitmap -
-// -------------------
-
sal_uLong AnimationBitmap::GetChecksum() const
{
sal_uInt32 nCrc = aBmpEx.GetChecksum();
@@ -73,10 +61,6 @@ sal_uLong AnimationBitmap::GetChecksum() const
return nCrc;
}
-// -------------
-// - Animation -
-// -------------
-
Animation::Animation() :
mnLoopCount ( 0 ),
mnLoops ( 0 ),
@@ -90,8 +74,6 @@ Animation::Animation() :
maTimer.SetTimeoutHdl( LINK( this, Animation, ImplTimeoutHdl ) );
}
-// -----------------------------------------------------------------------
-
Animation::Animation( const Animation& rAnimation ) :
maBitmapEx ( rAnimation.maBitmapEx ),
maGlobalSize ( rAnimation.maGlobalSize ),
@@ -111,8 +93,6 @@ Animation::Animation( const Animation& rAnimation ) :
mnLoops = mbLoopTerminated ? 0 : mnLoopCount;
}
-// -----------------------------------------------------------------------
-
Animation::~Animation()
{
DBG_DTOR( Animation, NULL );
@@ -127,8 +107,6 @@ Animation::~Animation()
delete maViewList[ i ];
}
-// -----------------------------------------------------------------------
-
Animation& Animation::operator=( const Animation& rAnimation )
{
Clear();
@@ -148,8 +126,6 @@ Animation& Animation::operator=( const Animation& rAnimation )
return *this;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::operator==( const Animation& rAnimation ) const
{
const size_t nCount = maList.size();
@@ -192,8 +168,6 @@ void Animation::Clear()
maViewList.clear();
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::IsTransparent() const
{
Point aPoint;
@@ -223,8 +197,6 @@ sal_Bool Animation::IsTransparent() const
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_uLong Animation::GetSizeBytes() const
{
sal_uLong nSizeBytes = GetBitmapEx().GetSizeBytes();
@@ -238,8 +210,6 @@ sal_uLong Animation::GetSizeBytes() const
return nSizeBytes;
}
-// -----------------------------------------------------------------------
-
sal_uLong Animation::GetChecksum() const
{
SVBT32 aBT32;
@@ -266,8 +236,6 @@ sal_uLong Animation::GetChecksum() const
return nCrc;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Start( OutputDevice* pOut, const Point& rDestPt, const Size& rDestSz, long nExtraData,
OutputDevice* pFirstFrameOutDev )
{
@@ -330,8 +298,6 @@ sal_Bool Animation::Start( OutputDevice* pOut, const Point& rDestPt, const Size&
return bRet;
}
-// -----------------------------------------------------------------------
-
void Animation::Stop( OutputDevice* pOut, long nExtraData )
{
for( size_t i = 0; i < maViewList.size(); )
@@ -355,15 +321,11 @@ void Animation::Stop( OutputDevice* pOut, long nExtraData )
}
}
-// -----------------------------------------------------------------------
-
void Animation::Draw( OutputDevice* pOut, const Point& rDestPt ) const
{
Draw( pOut, rDestPt, pOut->PixelToLogic( maGlobalSize ) );
}
-// -----------------------------------------------------------------------
-
void Animation::Draw( OutputDevice* pOut, const Point& rDestPt, const Size& rDestSz ) const
{
const size_t nCount = maList.size();
@@ -388,15 +350,12 @@ void Animation::Draw( OutputDevice* pOut, const Point& rDestPt, const Size& rDes
}
}
-// -----------------------------------------------------------------------
-
void Animation::ImplRestartTimer( sal_uLong nTimeout )
{
maTimer.SetTimeout( Max( nTimeout, (sal_uLong)(MIN_TIMEOUT + ( mnAnimCount - 1 ) * INC_TIMEOUT) ) * 10L );
maTimer.Start();
}
-// -----------------------------------------------------------------------
typedef ::std::vector< AInfo* > AInfoList_impl;
IMPL_LINK_NOARG(Animation, ImplTimeoutHdl)
@@ -523,8 +482,6 @@ IMPL_LINK_NOARG(Animation, ImplTimeoutHdl)
return 0L;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Insert( const AnimationBitmap& rStepBmp )
{
sal_Bool bRet = sal_False;
@@ -547,16 +504,12 @@ sal_Bool Animation::Insert( const AnimationBitmap& rStepBmp )
return bRet;
}
-// -----------------------------------------------------------------------
-
const AnimationBitmap& Animation::Get( sal_uInt16 nAnimation ) const
{
DBG_ASSERT( ( nAnimation < maList.size() ), "No object at this position" );
return *maList[ nAnimation ];
}
-// -----------------------------------------------------------------------
-
void Animation::Replace( const AnimationBitmap& rNewAnimationBitmap, sal_uInt16 nAnimation )
{
DBG_ASSERT( ( nAnimation < maList.size() ), "No object at this position" );
@@ -583,24 +536,18 @@ void Animation::Replace( const AnimationBitmap& rNewAnimationBitmap, sal_uInt16
}
}
-// -----------------------------------------------------------------------
-
void Animation::SetLoopCount( const sal_uLong nLoopCount )
{
mnLoopCount = nLoopCount;
ResetLoopCount();
}
-// -----------------------------------------------------------------------
-
void Animation::ResetLoopCount()
{
mnLoops = mnLoopCount;
mbLoopTerminated = sal_False;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Convert( BmpConversion eConversion )
{
DBG_ASSERT( !IsInAnimation(), "Animation modified while it is animated" );
@@ -622,8 +569,6 @@ sal_Bool Animation::Convert( BmpConversion eConversion )
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::ReduceColors( sal_uInt16 nNewColorCount, BmpReduce eReduce )
{
DBG_ASSERT( !IsInAnimation(), "Animation modified while it is animated" );
@@ -645,8 +590,6 @@ sal_Bool Animation::ReduceColors( sal_uInt16 nNewColorCount, BmpReduce eReduce )
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Invert()
{
DBG_ASSERT( !IsInAnimation(), "Animation modified while it is animated" );
@@ -668,8 +611,6 @@ sal_Bool Animation::Invert()
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Mirror( sal_uLong nMirrorFlags )
{
DBG_ASSERT( !IsInAnimation(), "Animation modified while it is animated" );
@@ -704,8 +645,6 @@ sal_Bool Animation::Mirror( sal_uLong nMirrorFlags )
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Adjust( short nLuminancePercent, short nContrastPercent,
short nChannelRPercent, short nChannelGPercent, short nChannelBPercent,
double fGamma, sal_Bool bInvert )
@@ -739,8 +678,6 @@ sal_Bool Animation::Adjust( short nLuminancePercent, short nContrastPercent,
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool Animation::Filter( BmpFilter eFilter, const BmpFilterParam* pFilterParam, const Link* pProgress )
{
DBG_ASSERT( !IsInAnimation(), "Animation modified while it is animated" );
@@ -762,8 +699,6 @@ sal_Bool Animation::Filter( BmpFilter eFilter, const BmpFilterParam* pFilterPara
return bRet;
}
-// -----------------------------------------------------------------------
-
SvStream& operator<<( SvStream& rOStm, const Animation& rAnimation )
{
const sal_uInt16 nCount = rAnimation.Count();
@@ -807,8 +742,6 @@ SvStream& operator<<( SvStream& rOStm, const Animation& rAnimation )
return rOStm;
}
-// -----------------------------------------------------------------------
-
SvStream& operator>>( SvStream& rIStm, Animation& rAnimation )
{
Bitmap aBmp;
diff --git a/vcl/source/gdi/bitmap.cxx b/vcl/source/gdi/bitmap.cxx
index 98de0a4e2f84..64d8f4e64bec 100644
--- a/vcl/source/gdi/bitmap.cxx
+++ b/vcl/source/gdi/bitmap.cxx
@@ -33,17 +33,11 @@
#include <impbmp.hxx>
#include <salbmp.hxx>
-// ----------
-// - Bitmap -
-// ----------
-
Bitmap::Bitmap() :
mpImpBmp( NULL )
{
}
-// ------------------------------------------------------------------
-
Bitmap::Bitmap( const ResId& rResId ) :
mpImpBmp( NULL )
{
@@ -53,8 +47,6 @@ Bitmap::Bitmap( const ResId& rResId ) :
*this = aBmpEx.GetBitmap();
}
-// ------------------------------------------------------------------
-
Bitmap::Bitmap( const Bitmap& rBitmap ) :
maPrefMapMode ( rBitmap.maPrefMapMode ),
maPrefSize ( rBitmap.maPrefSize )
@@ -65,8 +57,6 @@ Bitmap::Bitmap( const Bitmap& rBitmap ) :
mpImpBmp->ImplIncRefCount();
}
-// ------------------------------------------------------------------
-
Bitmap::Bitmap( SalBitmap* pSalBitmap )
{
mpImpBmp = new ImpBitmap();
@@ -75,8 +65,6 @@ Bitmap::Bitmap( SalBitmap* pSalBitmap )
maPrefSize = mpImpBmp->ImplGetSize();
}
-// ------------------------------------------------------------------
-
Bitmap::Bitmap( const Size& rSizePixel, sal_uInt16 nBitCount, const BitmapPalette* pPal )
{
if( rSizePixel.Width() && rSizePixel.Height() )
@@ -140,15 +128,11 @@ Bitmap::Bitmap( const Size& rSizePixel, sal_uInt16 nBitCount, const BitmapPalett
mpImpBmp = NULL;
}
-// ------------------------------------------------------------------
-
Bitmap::~Bitmap()
{
ImplReleaseRef();
}
-// ------------------------------------------------------------------
-
const BitmapPalette& Bitmap::GetGreyPalette( int nEntries )
{
static BitmapPalette aGreyPalette2;
@@ -217,8 +201,6 @@ const BitmapPalette& Bitmap::GetGreyPalette( int nEntries )
}
}
-// ------------------------------------------------------------------
-
bool BitmapPalette::IsGreyPalette() const
{
const int nEntryCount = GetEntryCount();
@@ -244,8 +226,6 @@ bool BitmapPalette::IsGreyPalette() const
return bRet;
}
-// ------------------------------------------------------------------
-
Bitmap& Bitmap::operator=( const Bitmap& rBitmap )
{
maPrefSize = rBitmap.maPrefSize;
@@ -260,8 +240,6 @@ Bitmap& Bitmap::operator=( const Bitmap& rBitmap )
return *this;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::IsEqual( const Bitmap& rBmp ) const
{
return( IsSameInstance( rBmp ) ||
@@ -270,8 +248,6 @@ sal_Bool Bitmap::IsEqual( const Bitmap& rBmp ) const
rBmp.GetChecksum() == GetChecksum() ) );
}
-// ------------------------------------------------------------------
-
void Bitmap::SetEmpty()
{
maPrefMapMode = MapMode();
@@ -281,13 +257,10 @@ void Bitmap::SetEmpty()
mpImpBmp = NULL;
}
-// ------------------------------------------------------------------
-
Size Bitmap::GetSizePixel() const
{
return( mpImpBmp ? mpImpBmp->ImplGetSize() : Size() );
}
-// ------------------------------------------------------------------
void Bitmap::SetSourceSizePixel( const Size& rSize)
{
@@ -295,15 +268,11 @@ void Bitmap::SetSourceSizePixel( const Size& rSize)
mpImpBmp->ImplSetSourceSize( rSize);
}
-// ------------------------------------------------------------------
-
sal_uInt16 Bitmap::GetBitCount() const
{
return( mpImpBmp ? mpImpBmp->ImplGetBitCount() : 0 );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::HasGreyPalette() const
{
const sal_uInt16 nBitCount = GetBitCount();
@@ -320,8 +289,6 @@ sal_Bool Bitmap::HasGreyPalette() const
return bRet;
}
-// ------------------------------------------------------------------
-
sal_uLong Bitmap::GetChecksum() const
{
sal_uLong nRet = 0UL;
@@ -377,8 +344,6 @@ sal_uLong Bitmap::GetChecksum() const
return nRet;
}
-// ------------------------------------------------------------------
-
void Bitmap::ImplReleaseRef()
{
if( mpImpBmp )
@@ -393,8 +358,6 @@ void Bitmap::ImplReleaseRef()
}
}
-// ------------------------------------------------------------------
-
void Bitmap::ImplMakeUnique()
{
if( mpImpBmp && mpImpBmp->ImplGetRefCount() > 1UL )
@@ -408,8 +371,6 @@ void Bitmap::ImplMakeUnique()
}
}
-// ------------------------------------------------------------------
-
void Bitmap::ImplAssignWithSize( const Bitmap& rBitmap )
{
const Size aOldSizePix( GetSizePixel() );
@@ -431,15 +392,11 @@ void Bitmap::ImplAssignWithSize( const Bitmap& rBitmap )
maPrefMapMode = aOldMapMode;
}
-// ------------------------------------------------------------------
-
ImpBitmap* Bitmap::ImplGetImpBitmap() const
{
return mpImpBmp;
}
-// ------------------------------------------------------------------
-
void Bitmap::ImplSetImpBitmap( ImpBitmap* pImpBmp )
{
if( pImpBmp != mpImpBmp )
@@ -449,8 +406,6 @@ void Bitmap::ImplSetImpBitmap( ImpBitmap* pImpBmp )
}
}
-// ------------------------------------------------------------------
-
BitmapReadAccess* Bitmap::AcquireReadAccess()
{
BitmapReadAccess* pReadAccess = new BitmapReadAccess( *this );
@@ -464,8 +419,6 @@ BitmapReadAccess* Bitmap::AcquireReadAccess()
return pReadAccess;
}
-// ------------------------------------------------------------------
-
BitmapWriteAccess* Bitmap::AcquireWriteAccess()
{
BitmapWriteAccess* pWriteAccess = new BitmapWriteAccess( *this );
@@ -479,15 +432,11 @@ BitmapWriteAccess* Bitmap::AcquireWriteAccess()
return pWriteAccess;
}
-// ------------------------------------------------------------------
-
void Bitmap::ReleaseAccess( BitmapReadAccess* pBitmapAccess )
{
delete pBitmapAccess;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Erase( const Color& rFillColor )
{
if( !(*this) )
@@ -568,8 +517,6 @@ sal_Bool Bitmap::Erase( const Color& rFillColor )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Invert()
{
BitmapWriteAccess* pAcc = AcquireWriteAccess();
@@ -604,8 +551,6 @@ sal_Bool Bitmap::Invert()
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Mirror( sal_uLong nMirrorFlags )
{
sal_Bool bHorz = ( ( nMirrorFlags & BMP_MIRROR_HORZ ) == BMP_MIRROR_HORZ );
@@ -705,8 +650,6 @@ sal_Bool Bitmap::Mirror( sal_uLong nMirrorFlags )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Rotate( long nAngle10, const Color& rFillColor )
{
sal_Bool bRet = sal_False;
@@ -848,8 +791,6 @@ sal_Bool Bitmap::Rotate( long nAngle10, const Color& rFillColor )
return bRet;
};
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Crop( const Rectangle& rRectPixel )
{
const Size aSizePix( GetSizePixel() );
@@ -894,8 +835,6 @@ sal_Bool Bitmap::Crop( const Rectangle& rRectPixel )
return bRet;
};
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::CopyPixel( const Rectangle& rRectDst,
const Rectangle& rRectSrc, const Bitmap* pBmpSrc )
{
@@ -1083,8 +1022,6 @@ sal_Bool Bitmap::CopyPixel( const Rectangle& rRectDst,
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Expand( sal_uLong nDX, sal_uLong nDY, const Color* pInitColor )
{
sal_Bool bRet = sal_False;
@@ -1144,8 +1081,6 @@ sal_Bool Bitmap::Expand( sal_uLong nDX, sal_uLong nDY, const Color* pInitColor )
return bRet;
}
-// ------------------------------------------------------------------
-
Bitmap Bitmap::CreateMask( const Color& rTransColor, sal_uLong nTol ) const
{
Bitmap aNewBmp( GetSizePixel(), 1 );
@@ -1336,8 +1271,6 @@ Bitmap Bitmap::CreateMask( const Color& rTransColor, sal_uLong nTol ) const
return aNewBmp;
}
-// ------------------------------------------------------------------
-
Region Bitmap::CreateRegion( const Color& rColor, const Rectangle& rRect ) const
{
Region aRegion;
@@ -1389,8 +1322,6 @@ Region Bitmap::CreateRegion( const Color& rColor, const Rectangle& rRect ) const
return aRegion;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Replace( const Bitmap& rMask, const Color& rReplaceColor )
{
BitmapReadAccess* pMaskAcc = ( (Bitmap&) rMask ).AcquireReadAccess();
@@ -1467,8 +1398,6 @@ sal_Bool Bitmap::Replace( const Bitmap& rMask, const Color& rReplaceColor )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Replace( const AlphaMask& rAlpha, const Color& rMergeColor )
{
Bitmap aNewBmp( GetSizePixel(), 24 );
@@ -1513,8 +1442,6 @@ sal_Bool Bitmap::Replace( const AlphaMask& rAlpha, const Color& rMergeColor )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Replace( const Color& rSearchColor, const Color& rReplaceColor, sal_uLong nTol )
{
// Bitmaps with 1 bit color depth can cause problems
@@ -1576,8 +1503,6 @@ sal_Bool Bitmap::Replace( const Color& rSearchColor, const Color& rReplaceColor,
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Replace( const Color* pSearchColors, const Color* pReplaceColors,
sal_uLong nColorCount, sal_uLong* _pTols )
{
@@ -1685,8 +1610,6 @@ sal_Bool Bitmap::Replace( const Color* pSearchColors, const Color* pReplaceColor
return bRet;
}
-// ------------------------------------------------------------------
-
Bitmap Bitmap::CreateDisplayBitmap( OutputDevice* pDisplay )
{
Bitmap aDispBmp( *this );
@@ -1704,8 +1627,6 @@ Bitmap Bitmap::CreateDisplayBitmap( OutputDevice* pDisplay )
return aDispBmp;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::CombineSimple( const Bitmap& rMask, BmpCombine eCombine )
{
BitmapReadAccess* pMaskAcc = ( (Bitmap&) rMask ).AcquireReadAccess();
@@ -1843,8 +1764,6 @@ sal_Bool Bitmap::CombineSimple( const Bitmap& rMask, BmpCombine eCombine )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Blend( const AlphaMask& rAlpha, const Color& rBackgroundColor )
{
// TODO: Have a look at OutputDevice::ImplDrawAlpha() for some
@@ -1879,15 +1798,11 @@ sal_Bool Bitmap::Blend( const AlphaMask& rAlpha, const Color& rBackgroundColor )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::MakeMono( sal_uInt8 cThreshold )
{
return ImplMakeMono( cThreshold );
}
-// ------------------------------------------------------------------
-
bool Bitmap::GetSystemData( BitmapSystemData& rData ) const
{
bool bRet = false;
diff --git a/vcl/source/gdi/bitmap2.cxx b/vcl/source/gdi/bitmap2.cxx
index 43a0d405669b..ab259bfb37c6 100644
--- a/vcl/source/gdi/bitmap2.cxx
+++ b/vcl/source/gdi/bitmap2.cxx
@@ -31,19 +31,11 @@
#include <valgrind/memcheck.h>
#endif
-
-// -----------
-// - Defines -
-// -----------
-
#define DIBCOREHEADERSIZE ( 12UL )
#define DIBINFOHEADERSIZE ( sizeof( DIBInfoHeader ) )
#define BITMAPINFOHEADER 0x28
-// ----------------------
-// - Compression defines
-// ----------------------
-
+// Compression defines
#define COMPRESS_OWN ('S'|('D'<<8UL))
#define COMPRESS_NONE ( 0UL )
#define RLE_8 ( 1UL )
@@ -51,10 +43,6 @@
#define BITFIELDS ( 3UL )
#define ZCOMPRESS ( COMPRESS_OWN | 0x01000000UL ) /* == 'SD01' (binary) */
-// -----------------
-// - DIBInfoHeader -
-// -----------------
-
struct DIBInfoHeader
{
sal_uInt32 nSize;
@@ -101,26 +89,18 @@ namespace
}
}
-// ----------
-// - Bitmap -
-// ----------
-
SvStream& operator>>( SvStream& rIStm, Bitmap& rBitmap )
{
rBitmap.Read( rIStm, sal_True );
return rIStm;
}
-// ------------------------------------------------------------------
-
SvStream& operator<<( SvStream& rOStm, const Bitmap& rBitmap )
{
rBitmap.Write( rOStm, sal_False, sal_True );
return rOStm;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Read( SvStream& rIStm, sal_Bool bFileHeader, sal_Bool bIsMSOFormat )
{
const sal_uInt16 nOldFormat = rIStm.GetNumberFormatInt();
@@ -151,8 +131,6 @@ sal_Bool Bitmap::Read( SvStream& rIStm, sal_Bool bFileHeader, sal_Bool bIsMSOFor
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplReadDIB( SvStream& rIStm, Bitmap& rBmp, sal_uLong nOffset, sal_Bool bIsMSOFormat )
{
DIBInfoHeader aHeader;
@@ -255,8 +233,6 @@ sal_Bool Bitmap::ImplReadDIB( SvStream& rIStm, Bitmap& rBmp, sal_uLong nOffset,
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplReadDIBFileHeader( SvStream& rIStm, sal_uLong& rOffset )
{
sal_uInt32 nTmp32;
@@ -290,8 +266,6 @@ sal_Bool Bitmap::ImplReadDIBFileHeader( SvStream& rIStm, sal_uLong& rOffset )
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplReadDIBInfoHeader( SvStream& rIStm, DIBInfoHeader& rHeader, sal_Bool& bTopDown, sal_Bool bIsMSOFormat )
{
// BITMAPINFOHEADER or BITMAPCOREHEADER
@@ -407,8 +381,6 @@ sal_Bool Bitmap::ImplReadDIBInfoHeader( SvStream& rIStm, DIBInfoHeader& rHeader,
return( ( rHeader.nPlanes == 1 ) && ( rIStm.GetError() == 0UL ) );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplReadDIBPalette( SvStream& rIStm, BitmapWriteAccess& rAcc, sal_Bool bQuad )
{
const sal_uInt16 nColors = rAcc.GetPaletteEntryCount();
@@ -436,8 +408,6 @@ sal_Bool Bitmap::ImplReadDIBPalette( SvStream& rIStm, BitmapWriteAccess& rAcc, s
return( rIStm.GetError() == 0UL );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplReadDIBBits( SvStream& rIStm, DIBInfoHeader& rHeader, BitmapWriteAccess& rAcc, sal_Bool bTopDown )
{
const sal_uLong nAlignedWidth = AlignedWidth4Bytes( rHeader.nWidth * rHeader.nBitCount );
@@ -659,8 +629,6 @@ sal_Bool Bitmap::ImplReadDIBBits( SvStream& rIStm, DIBInfoHeader& rHeader, Bitma
return( rIStm.GetError() == 0UL );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::Write( SvStream& rOStm, sal_Bool bCompressed, sal_Bool bFileHeader ) const
{
DBG_ASSERT( mpImpBmp, "Empty Bitmaps can't be saved" );
@@ -701,8 +669,6 @@ sal_Bool Bitmap::Write( SvStream& rOStm, sal_Bool bCompressed, sal_Bool bFileHea
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplWriteDIB( SvStream& rOStm, BitmapReadAccess& rAcc, sal_Bool bCompressed ) const
{
const MapMode aMapPixel( MAP_PIXEL );
@@ -851,8 +817,6 @@ sal_Bool Bitmap::ImplWriteDIB( SvStream& rOStm, BitmapReadAccess& rAcc, sal_Bool
return bRet;
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplWriteDIBFileHeader( SvStream& rOStm, BitmapReadAccess& rAcc )
{
sal_uInt32 nPalCount = ( rAcc.HasPalette() ? rAcc.GetPaletteEntryCount() :
@@ -868,8 +832,6 @@ sal_Bool Bitmap::ImplWriteDIBFileHeader( SvStream& rOStm, BitmapReadAccess& rAcc
return( rOStm.GetError() == 0UL );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplWriteDIBPalette( SvStream& rOStm, BitmapReadAccess& rAcc )
{
const sal_uInt16 nColors = rAcc.GetPaletteEntryCount();
@@ -894,8 +856,6 @@ sal_Bool Bitmap::ImplWriteDIBPalette( SvStream& rOStm, BitmapReadAccess& rAcc )
return( rOStm.GetError() == 0UL );
}
-// ------------------------------------------------------------------
-
#if defined HAVE_VALGRIND_HEADERS
namespace
{
@@ -1086,8 +1046,6 @@ sal_Bool Bitmap::ImplWriteDIBBits( SvStream& rOStm, BitmapReadAccess& rAcc,
return( rOStm.GetError() == 0UL );
}
-// ------------------------------------------------------------------
-
void Bitmap::ImplDecodeRLE( sal_uInt8* pBuffer, DIBInfoHeader& rHeader,
BitmapWriteAccess& rAcc, sal_Bool bRLE4 )
{
@@ -1191,8 +1149,6 @@ void Bitmap::ImplDecodeRLE( sal_uInt8* pBuffer, DIBInfoHeader& rHeader,
while ( !bEndDecoding && ( nY >= 0L ) );
}
-// ------------------------------------------------------------------
-
sal_Bool Bitmap::ImplWriteRLE( SvStream& rOStm, BitmapReadAccess& rAcc, sal_Bool bRLE4 )
{
const sal_uLong nWidth = rAcc.Width();
diff --git a/vcl/source/gdi/bitmap3.cxx b/vcl/source/gdi/bitmap3.cxx
index 10b1160f471d..2855ca6b7ad6 100644
--- a/vcl/source/gdi/bitmap3.cxx
+++ b/vcl/source/gdi/bitmap3.cxx
@@ -29,10 +29,6 @@
#include <impvect.hxx>
#include <math.h>
-// -----------
-// - Defines -
-// -----------
-
#define RGB15( _def_cR, _def_cG, _def_cB ) (((sal_uLong)(_def_cR)<<10UL)|((sal_uLong)(_def_cG)<<5UL)|(sal_uLong)(_def_cB))
#define GAMMA( _def_cVal, _def_InvGamma ) ((sal_uInt8)MinMax(FRound(pow( _def_cVal/255.0,_def_InvGamma)*255.0),0L,255L))
@@ -65,10 +61,6 @@
p1T[nX] += FloydError7[nRErr]; \
p2T[nX] += FloydError1[nRErr];
-// -----------
-// - Statics -
-// -----------
-
const extern sal_uLong nVCLRLut[ 6 ] = { 16, 17, 18, 19, 20, 21 };
const extern sal_uLong nVCLGLut[ 6 ] = { 0, 6, 12, 18, 24, 30 };
const extern sal_uLong nVCLBLut[ 6 ] = { 0, 36, 72, 108, 144, 180 };
@@ -215,10 +207,6 @@ const long FloydIndexMap[6] =
-30, 21, 72, 123, 174, 225
};
-// --------------------------
-// - ImplCreateDitherMatrix -
-// --------------------------
-
void ImplCreateDitherMatrix( sal_uInt8 (*pDitherMatrix)[16][16] )
{
double fVal = 3.125;
@@ -245,10 +233,6 @@ void ImplCreateDitherMatrix( sal_uInt8 (*pDitherMatrix)[16][16] )
(*pDitherMatrix)[i][j] = (sal_uInt8) ( fVal * pMtx[i][j] );
}
-// ----------
-// - Bitmap -
-// ----------
-
sal_Bool Bitmap::Convert( BmpConversion eConversion )
{
const sal_uInt16 nBitCount = GetBitCount();
diff --git a/vcl/source/gdi/bitmap4.cxx b/vcl/source/gdi/bitmap4.cxx
index 882ae050669f..45c99c822149 100644
--- a/vcl/source/gdi/bitmap4.cxx
+++ b/vcl/source/gdi/bitmap4.cxx
@@ -22,10 +22,6 @@
#include <vcl/bmpacc.hxx>
#include <vcl/bitmap.hxx>
-// -----------
-// - Defines -
-// -----------
-
#define S2(a,b) { register long t; if( ( t = b - a ) < 0 ) { a += t; b -= t; } }
#define MN3(a,b,c) S2(a,b); S2(a,c);
#define MX3(a,b,c) S2(b,c); S2(a,c);
@@ -34,10 +30,6 @@
#define MNMX5(a,b,c,d,e) S2(a,b); S2(c,d); MN3(a,c,e); MX3(b,d,e);
#define MNMX6(a,b,c,d,e,f) S2(a,d); S2(b,e); S2(c,f); MN3(a,b,c); MX3(d,e,f);
-// ----------
-// - Bitmap -
-// ----------
-
sal_Bool Bitmap::Filter( BmpFilter eFilter, const BmpFilterParam* pFilterParam, const Link* pProgress )
{
sal_Bool bRet = sal_False;
@@ -106,8 +98,6 @@ sal_Bool Bitmap::Filter( BmpFilter eFilter, const BmpFilterParam* pFilterParam,
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplConvolute3( const long* pMatrix, long nDivisor,
const BmpFilterParam* /*pFilterParam*/, const Link* /*pProgress*/ )
{
@@ -254,8 +244,6 @@ sal_Bool Bitmap::ImplConvolute3( const long* pMatrix, long nDivisor,
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplMedianFilter( const BmpFilterParam* /*pFilterParam*/, const Link* /*pProgress*/ )
{
BitmapReadAccess* pReadAcc = AcquireReadAccess();
@@ -385,8 +373,6 @@ sal_Bool Bitmap::ImplMedianFilter( const BmpFilterParam* /*pFilterParam*/, const
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplSobelGrey( const BmpFilterParam* /*pFilterParam*/, const Link* /*pProgress*/ )
{
sal_Bool bRet = ImplMakeGreyscales( 256 );
@@ -513,8 +499,6 @@ sal_Bool Bitmap::ImplSobelGrey( const BmpFilterParam* /*pFilterParam*/, const Li
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplEmbossGrey( const BmpFilterParam* pFilterParam, const Link* /*pProgress*/ )
{
sal_Bool bRet = ImplMakeGreyscales( 256 );
@@ -627,8 +611,6 @@ sal_Bool Bitmap::ImplEmbossGrey( const BmpFilterParam* pFilterParam, const Link*
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplSolarize( const BmpFilterParam* pFilterParam, const Link* /*pProgress*/ )
{
sal_Bool bRet = sal_False;
@@ -677,8 +659,6 @@ sal_Bool Bitmap::ImplSolarize( const BmpFilterParam* pFilterParam, const Link* /
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplSepia( const BmpFilterParam* pFilterParam, const Link* /*pProgress*/ )
{
BitmapReadAccess* pReadAcc = AcquireReadAccess();
@@ -764,8 +744,6 @@ sal_Bool Bitmap::ImplSepia( const BmpFilterParam* pFilterParam, const Link* /*pP
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplMosaic( const BmpFilterParam* pFilterParam, const Link* /*pProgress*/ )
{
sal_uLong nTileWidth = ( pFilterParam && pFilterParam->meFilter == BMP_FILTER_MOSAIC ) ?
@@ -923,16 +901,12 @@ sal_Bool Bitmap::ImplMosaic( const BmpFilterParam* pFilterParam, const Link* /*p
return bRet;
}
-// -----------------------------------------------------------------------------
-
struct PopArtEntry
{
sal_uInt32 mnIndex;
sal_uInt32 mnCount;
};
-// ------------------------------------------------------------------------
-
extern "C" int SAL_CALL ImplPopArtCmpFnc( const void* p1, const void* p2 )
{
int nRet;
@@ -947,8 +921,6 @@ extern "C" int SAL_CALL ImplPopArtCmpFnc( const void* p1, const void* p2 )
return nRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool Bitmap::ImplPopArt( const BmpFilterParam* /*pFilterParam*/, const Link* /*pProgress*/ )
{
sal_Bool bRet = ( GetBitCount() > 8 ) ? Convert( BMP_CONVERSION_8BIT_COLORS ) : sal_True;
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index e2d4c1d7c1f6..798d4d830a5b 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -49,16 +49,8 @@
using namespace com::sun::star;
-// -----------
-// - Defines -
-// -----------
-
#define GAMMA( _def_cVal, _def_InvGamma ) ((sal_uInt8)MinMax(FRound(pow( _def_cVal/255.0,_def_InvGamma)*255.0),0L,255L))
-// --------------------------
-// - Color exchange structs -
-// --------------------------
-
struct ImplColAdjustParam
{
sal_uInt8* pMapR;
@@ -77,8 +69,6 @@ struct ImplBmpAdjustParam
sal_Bool bInvert;
};
-// -----------------------------------------------------------------------------
-
struct ImplColConvertParam
{
MtfConversion eConversion;
@@ -89,8 +79,6 @@ struct ImplBmpConvertParam
BmpConversion eConversion;
};
-// -----------------------------------------------------------------------------
-
struct ImplColMonoParam
{
Color aColor;
@@ -101,8 +89,6 @@ struct ImplBmpMonoParam
Color aColor;
};
-// -----------------------------------------------------------------------------
-
struct ImplColReplaceParam
{
sal_uLong* pMinR;
@@ -123,10 +109,6 @@ struct ImplBmpReplaceParam
const sal_uLong* pTols;
};
-// ---------------
-// - GDIMetaFile -
-// ---------------
-
GDIMetaFile::GDIMetaFile() :
nCurrentActionElement( 0 ),
aPrefSize ( 1, 1 ),
@@ -139,8 +121,6 @@ GDIMetaFile::GDIMetaFile() :
{
}
-// ------------------------------------------------------------------------
-
GDIMetaFile::GDIMetaFile( const GDIMetaFile& rMtf ) :
aPrefMapMode ( rMtf.aPrefMapMode ),
aPrefSize ( rMtf.aPrefSize ),
@@ -168,44 +148,32 @@ GDIMetaFile::GDIMetaFile( const GDIMetaFile& rMtf ) :
}
}
-// ------------------------------------------------------------------------
-
GDIMetaFile::~GDIMetaFile()
{
Clear();
}
-// ------------------------------------------------------------------------
-
size_t GDIMetaFile::GetActionSize() const
{
return aList.size();
}
-// ------------------------------------------------------------------------
-
MetaAction* GDIMetaFile::GetAction( size_t nAction ) const
{
return (nAction < aList.size()) ? aList[ nAction ] : NULL;
}
-// ------------------------------------------------------------------------
-
MetaAction* GDIMetaFile::FirstAction()
{
nCurrentActionElement = 0;
return aList.empty() ? NULL : aList[ 0 ];
}
-// ------------------------------------------------------------------------
-
MetaAction* GDIMetaFile::NextAction()
{
return ( nCurrentActionElement + 1 < aList.size() ) ? aList[ ++nCurrentActionElement ] : NULL;
}
-// ------------------------------------------------------------------------
-
MetaAction* GDIMetaFile::ReplaceAction( MetaAction* pAction, size_t nAction )
{
if ( nAction >= aList.size() )
@@ -221,8 +189,6 @@ MetaAction* GDIMetaFile::ReplaceAction( MetaAction* pAction, size_t nAction )
return pAction;
}
-// ------------------------------------------------------------------------
-
GDIMetaFile& GDIMetaFile::operator=( const GDIMetaFile& rMtf )
{
if( this != &rMtf )
@@ -258,8 +224,6 @@ GDIMetaFile& GDIMetaFile::operator=( const GDIMetaFile& rMtf )
return *this;
}
-// ------------------------------------------------------------------------
-
sal_Bool GDIMetaFile::operator==( const GDIMetaFile& rMtf ) const
{
const size_t nObjCount = aList.size();
@@ -286,8 +250,6 @@ sal_Bool GDIMetaFile::operator==( const GDIMetaFile& rMtf ) const
return bRet;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Clear()
{
if( bRecord )
@@ -298,8 +260,6 @@ void GDIMetaFile::Clear()
aList.clear();
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Linker( OutputDevice* pOut, sal_Bool bLink )
{
if( bLink )
@@ -333,15 +293,11 @@ void GDIMetaFile::Linker( OutputDevice* pOut, sal_Bool bLink )
}
}
-// ------------------------------------------------------------------------
-
long GDIMetaFile::Hook()
{
return aHookHdlLink.Call( this );
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Record( OutputDevice* pOut )
{
if( bRecord )
@@ -353,8 +309,6 @@ void GDIMetaFile::Record( OutputDevice* pOut )
Linker( pOut, sal_True );
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Play( GDIMetaFile& rMtf, size_t nPos )
{
if ( !bRecord && !rMtf.bRecord )
@@ -380,8 +334,6 @@ void GDIMetaFile::Play( GDIMetaFile& rMtf, size_t nPos )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Play( OutputDevice* pOut, size_t nPos )
{
if( !bRecord )
@@ -432,8 +384,6 @@ void GDIMetaFile::Play( OutputDevice* pOut, size_t nPos )
}
}
-// ------------------------------------------------------------------------
-
bool GDIMetaFile::ImplPlayWithRenderer( OutputDevice* pOut, const Point& rPos, Size rDestSize )
{
if (!bUseCanvas)
@@ -524,8 +474,6 @@ bool GDIMetaFile::ImplPlayWithRenderer( OutputDevice* pOut, const Point& rPos, S
return false;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::ImplDelegate2PluggableRenderer( const MetaCommentAction* pAct, OutputDevice* pOut )
{
OSL_ASSERT( pAct->GetComment() == "DELEGATE_PLUGGABLE_RENDERER" );
@@ -597,8 +545,6 @@ void GDIMetaFile::ImplDelegate2PluggableRenderer( const MetaCommentAction* pAct,
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Play( OutputDevice* pOut, const Point& rPos,
const Size& rSize, size_t nPos )
{
@@ -663,8 +609,6 @@ void GDIMetaFile::Play( OutputDevice* pOut, const Point& rPos,
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Pause( sal_Bool _bPause )
{
if( bRecord )
@@ -684,8 +628,6 @@ void GDIMetaFile::Pause( sal_Bool _bPause )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Stop()
{
if( bRecord )
@@ -699,16 +641,12 @@ void GDIMetaFile::Stop()
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::WindStart()
{
if( !bRecord )
nCurrentActionElement = 0;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::WindPrev()
{
if( !bRecord )
@@ -716,8 +654,6 @@ void GDIMetaFile::WindPrev()
--nCurrentActionElement;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::AddAction( MetaAction* pAction )
{
aList.push_back( pAction );
@@ -729,8 +665,6 @@ void GDIMetaFile::AddAction( MetaAction* pAction )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::AddAction( MetaAction* pAction, size_t nPos )
{
if ( nPos < aList.size() )
@@ -751,15 +685,11 @@ void GDIMetaFile::AddAction( MetaAction* pAction, size_t nPos )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::push_back( MetaAction* pAction )
{
aList.push_back( pAction );
}
-// ------------------------------------------------------------------------
-
// @since #110496#
void GDIMetaFile::RemoveAction( size_t nPos )
{
@@ -776,8 +706,6 @@ void GDIMetaFile::RemoveAction( size_t nPos )
pPrev->RemoveAction( nPos );
}
-// ------------------------------------------------------------------------
-
sal_Bool GDIMetaFile::Mirror( sal_uLong nMirrorFlags )
{
const Size aOldPrefSize( GetPrefSize() );
@@ -808,8 +736,6 @@ sal_Bool GDIMetaFile::Mirror( sal_uLong nMirrorFlags )
return bRet;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Move( long nX, long nY )
{
const Size aBaseOffset( nX, nY );
@@ -887,8 +813,6 @@ void GDIMetaFile::Move( long nX, long nY, long nDPIX, long nDPIY )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Scale( double fScaleX, double fScaleY )
{
for( MetaAction* pAct = FirstAction(); pAct; pAct = NextAction() )
@@ -910,15 +834,11 @@ void GDIMetaFile::Scale( double fScaleX, double fScaleY )
aPrefSize.Height() = FRound( aPrefSize.Height() * fScaleY );
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Scale( const Fraction& rScaleX, const Fraction& rScaleY )
{
Scale( (double) rScaleX, (double) rScaleY );
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Clip( const Rectangle& i_rClipRect )
{
Rectangle aCurRect( i_rClipRect );
@@ -951,8 +871,6 @@ void GDIMetaFile::Clip( const Rectangle& i_rClipRect )
}
}
-// ------------------------------------------------------------------------
-
Point GDIMetaFile::ImplGetRotatedPoint( const Point& rPt, const Point& rRotatePt,
const Size& rOffset, double fSin, double fCos )
{
@@ -963,8 +881,6 @@ Point GDIMetaFile::ImplGetRotatedPoint( const Point& rPt, const Point& rRotatePt
-FRound( fSin * nX - fCos * nY ) + rRotatePt.Y() + rOffset.Height() );
}
-// ------------------------------------------------------------------------
-
Polygon GDIMetaFile::ImplGetRotatedPolygon( const Polygon& rPoly, const Point& rRotatePt,
const Size& rOffset, double fSin, double fCos )
{
@@ -976,8 +892,6 @@ Polygon GDIMetaFile::ImplGetRotatedPolygon( const Polygon& rPoly, const Point& r
return aRet;
}
-// ------------------------------------------------------------------------
-
PolyPolygon GDIMetaFile::ImplGetRotatedPolyPolygon( const PolyPolygon& rPolyPoly, const Point& rRotatePt,
const Size& rOffset, double fSin, double fCos )
{
@@ -989,8 +903,6 @@ PolyPolygon GDIMetaFile::ImplGetRotatedPolyPolygon( const PolyPolygon& rPolyPoly
return aRet;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::ImplAddGradientEx( GDIMetaFile& rMtf,
const OutputDevice& rMapDev,
const PolyPolygon& rPolyPoly,
@@ -1015,8 +927,6 @@ void GDIMetaFile::ImplAddGradientEx( GDIMetaFile& rMtf,
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Rotate( long nAngle10 )
{
nAngle10 %= 3600L;
@@ -1480,8 +1390,6 @@ void GDIMetaFile::Rotate( long nAngle10 )
}
}
-// ------------------------------------------------------------------------
-
static void ImplActionBounds( Rectangle& o_rOutBounds,
const Rectangle& i_rInBounds,
const std::vector<Rectangle>& i_rClipStack,
@@ -1929,8 +1837,6 @@ Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, Rectangle* pHai
return aBound;
}
-// ------------------------------------------------------------------------
-
Color GDIMetaFile::ImplColAdjustFnc( const Color& rColor, const void* pColParam )
{
return Color( rColor.GetTransparency(),
@@ -1940,8 +1846,6 @@ Color GDIMetaFile::ImplColAdjustFnc( const Color& rColor, const void* pColParam
}
-// ------------------------------------------------------------------------
-
BitmapEx GDIMetaFile::ImplBmpAdjustFnc( const BitmapEx& rBmpEx, const void* pBmpParam )
{
const ImplBmpAdjustParam* p = (const ImplBmpAdjustParam*) pBmpParam;
@@ -1954,8 +1858,6 @@ BitmapEx GDIMetaFile::ImplBmpAdjustFnc( const BitmapEx& rBmpEx, const void* pBmp
return aRet;
}
-// ------------------------------------------------------------------------
-
Color GDIMetaFile::ImplColConvertFnc( const Color& rColor, const void* pColParam )
{
sal_uInt8 cLum = rColor.GetLuminance();
@@ -1966,8 +1868,6 @@ Color GDIMetaFile::ImplColConvertFnc( const Color& rColor, const void* pColParam
return Color( rColor.GetTransparency(), cLum, cLum, cLum );
}
-// ------------------------------------------------------------------------
-
BitmapEx GDIMetaFile::ImplBmpConvertFnc( const BitmapEx& rBmpEx, const void* pBmpParam )
{
BitmapEx aRet( rBmpEx );
@@ -1977,15 +1877,11 @@ BitmapEx GDIMetaFile::ImplBmpConvertFnc( const BitmapEx& rBmpEx, const void* pBm
return aRet;
}
-// ------------------------------------------------------------------------
-
Color GDIMetaFile::ImplColMonoFnc( const Color&, const void* pColParam )
{
return( ( (const ImplColMonoParam*) pColParam )->aColor );
}
-// ------------------------------------------------------------------------
-
BitmapEx GDIMetaFile::ImplBmpMonoFnc( const BitmapEx& rBmpEx, const void* pBmpParam )
{
BitmapPalette aPal( 3 );
@@ -2005,8 +1901,6 @@ BitmapEx GDIMetaFile::ImplBmpMonoFnc( const BitmapEx& rBmpEx, const void* pBmpPa
return aBmp;
}
-// ------------------------------------------------------------------------
-
Color GDIMetaFile::ImplColReplaceFnc( const Color& rColor, const void* pColParam )
{
const sal_uLong nR = rColor.GetRed(), nG = rColor.GetGreen(), nB = rColor.GetBlue();
@@ -2027,8 +1921,6 @@ Color GDIMetaFile::ImplColReplaceFnc( const Color& rColor, const void* pColParam
return rColor;
}
-// ------------------------------------------------------------------------
-
BitmapEx GDIMetaFile::ImplBmpReplaceFnc( const BitmapEx& rBmpEx, const void* pBmpParam )
{
const ImplBmpReplaceParam* p = (const ImplBmpReplaceParam*) pBmpParam;
@@ -2039,8 +1931,6 @@ BitmapEx GDIMetaFile::ImplBmpReplaceFnc( const BitmapEx& rBmpEx, const void* pBm
return aRet;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pColParam,
BmpExchangeFnc pFncBmp, const void* pBmpParam )
{
@@ -2305,8 +2195,6 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol
*this = aMtf;
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Adjust( short nLuminancePercent, short nContrastPercent,
short nChannelRPercent, short nChannelGPercent,
short nChannelBPercent, double fGamma, sal_Bool bInvert )
@@ -2381,8 +2269,6 @@ void GDIMetaFile::Adjust( short nLuminancePercent, short nContrastPercent,
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::Convert( MtfConversion eConversion )
{
// nothing to do? => return quickly
@@ -2398,8 +2284,6 @@ void GDIMetaFile::Convert( MtfConversion eConversion )
}
}
-// ------------------------------------------------------------------------
-
void GDIMetaFile::ReplaceColors( const Color* pSearchColors, const Color* pReplaceColors, sal_uLong nColorCount, sal_uLong* pTols )
{
ImplColReplaceParam aColParam;
@@ -2448,8 +2332,6 @@ void GDIMetaFile::ReplaceColors( const Color* pSearchColors, const Color* pRepla
delete[] aColParam.pMaxB;
};
-// ------------------------------------------------------------------------
-
GDIMetaFile GDIMetaFile::GetMonochromeMtf( const Color& rColor ) const
{
GDIMetaFile aRet( *this );
@@ -2465,8 +2347,6 @@ GDIMetaFile GDIMetaFile::GetMonochromeMtf( const Color& rColor ) const
return aRet;
}
-// ------------------------------------------------------------------------
-
sal_uLong GDIMetaFile::GetChecksum() const
{
GDIMetaFile aMtf;
@@ -2813,8 +2693,6 @@ sal_uLong GDIMetaFile::GetChecksum() const
return nCrc;
}
-// ------------------------------------------------------------------------
-
sal_uLong GDIMetaFile::GetSizeBytes() const
{
sal_uLong nSizeBytes = 0;
@@ -2871,8 +2749,6 @@ sal_uLong GDIMetaFile::GetSizeBytes() const
return( nSizeBytes );
}
-// ------------------------------------------------------------------------
-
SvStream& operator>>( SvStream& rIStm, GDIMetaFile& rGDIMetaFile )
{
if( !rIStm.GetError() )
@@ -2935,8 +2811,6 @@ SvStream& operator>>( SvStream& rIStm, GDIMetaFile& rGDIMetaFile )
return rIStm;
}
-// ------------------------------------------------------------------------
-
SvStream& operator<<( SvStream& rOStm, const GDIMetaFile& rGDIMetaFile )
{
if( !rOStm.GetError() )
@@ -2967,8 +2841,6 @@ Please set environment variable SAL_ENABLE_SVM1 to '1' to reenable old behavior"
return rOStm;
}
-// ------------------------------------------------------------------------
-
SvStream& GDIMetaFile::Read( SvStream& rIStm )
{
Clear();
@@ -2977,8 +2849,6 @@ SvStream& GDIMetaFile::Read( SvStream& rIStm )
return rIStm;
}
-// ------------------------------------------------------------------------
-
SvStream& GDIMetaFile::Write( SvStream& rOStm )
{
VersionCompat* pCompat;
@@ -3013,8 +2883,6 @@ SvStream& GDIMetaFile::Write( SvStream& rOStm )
return rOStm;
}
-// ------------------------------------------------------------------------
-
sal_Bool GDIMetaFile::CreateThumbnail( sal_uInt32 nMaximumExtent,
BitmapEx& rBmpEx,
const BitmapEx* pOverlay,
@@ -3136,8 +3004,6 @@ void GDIMetaFile::UseCanvas( sal_Bool _bUseCanvas )
bUseCanvas = _bUseCanvas;
}
-// ------------------------------------------------------------------------
-
MetaCommentAction* makePluggableRendererAction( const rtl::OUString& rRendererServiceName,
const rtl::OUString& rGraphicServiceName,
const void* _pData,
diff --git a/vcl/source/gdi/impgraph.cxx b/vcl/source/gdi/impgraph.cxx
index fc161a2cfed6..2e90cf7d29a2 100644
--- a/vcl/source/gdi/impgraph.cxx
+++ b/vcl/source/gdi/impgraph.cxx
@@ -37,10 +37,6 @@
#include <impgraph.hxx>
#include <com/sun/star/ucb/CommandAbortedException.hpp>
-// -----------
-// - Defines -
-// -----------
-
#define GRAPHIC_MAXPARTLEN 256000L
#define GRAPHIC_MTFTOBMP_MAXEXT 2048
#define GRAPHIC_STREAMBUFSIZE 8192UL
@@ -53,20 +49,12 @@
#define GRAPHIC_FORMAT_50 static_cast<sal_uInt32>(COMPAT_FORMAT( 'G', 'R', 'F', '5' ))
#define NATIVE_FORMAT_50 static_cast<sal_uInt32>(COMPAT_FORMAT( 'N', 'A', 'T', '5' ))
-// ---------------
-// - ImpSwapFile -
-// ---------------
-
struct ImpSwapFile
{
INetURLObject aSwapURL;
sal_uLong nRefCount;
};
-// -----------------
-// - Graphicreader -
-// -----------------
-
class ReaderData
{
public:
@@ -78,16 +66,12 @@ GraphicReader::~GraphicReader()
delete mpReaderData;
}
-// ------------------------------------------------------------------------
-
void GraphicReader::DisablePreviewMode()
{
if( mpReaderData )
mpReaderData->maPreviewSize = Size( 0, 0 );
}
-// ------------------------------------------------------------------------
-
void GraphicReader::SetPreviewSize( const Size& rSize )
{
if( !mpReaderData )
@@ -95,8 +79,6 @@ void GraphicReader::SetPreviewSize( const Size& rSize )
mpReaderData->maPreviewSize = rSize;
}
-// ------------------------------------------------------------------------
-
Size GraphicReader::GetPreviewSize() const
{
Size aSize( 0, 0 );
@@ -105,10 +87,6 @@ Size GraphicReader::GetPreviewSize() const
return aSize;
}
-// --------------
-// - ImpGraphic -
-// --------------
-
ImpGraphic::ImpGraphic() :
mpAnimation ( NULL ),
mpContext ( NULL ),
@@ -123,8 +101,6 @@ ImpGraphic::ImpGraphic() :
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic( const ImpGraphic& rImpGraphic ) :
maMetaFile ( rImpGraphic.maMetaFile ),
maEx ( rImpGraphic.maEx ),
@@ -157,8 +133,6 @@ ImpGraphic::ImpGraphic( const ImpGraphic& rImpGraphic ) :
maSvgData = rImpGraphic.maSvgData;
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic( const Bitmap& rBitmap ) :
maEx ( rBitmap ),
mpAnimation ( NULL ),
@@ -174,8 +148,6 @@ ImpGraphic::ImpGraphic( const Bitmap& rBitmap ) :
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic( const BitmapEx& rBitmapEx ) :
maEx ( rBitmapEx ),
mpAnimation ( NULL ),
@@ -191,8 +163,6 @@ ImpGraphic::ImpGraphic( const BitmapEx& rBitmapEx ) :
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic(const SvgDataPtr& rSvgDataPtr)
: mpAnimation( NULL ),
mpContext( NULL ),
@@ -208,8 +178,6 @@ ImpGraphic::ImpGraphic(const SvgDataPtr& rSvgDataPtr)
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic( const Animation& rAnimation ) :
maEx ( rAnimation.GetBitmapEx() ),
mpAnimation ( new Animation( rAnimation ) ),
@@ -225,8 +193,6 @@ ImpGraphic::ImpGraphic( const Animation& rAnimation ) :
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::ImpGraphic( const GDIMetaFile& rMtf ) :
maMetaFile ( rMtf ),
mpAnimation ( NULL ),
@@ -242,8 +208,6 @@ ImpGraphic::ImpGraphic( const GDIMetaFile& rMtf ) :
{
}
-// ------------------------------------------------------------------------
-
ImpGraphic::~ImpGraphic()
{
ImplClear();
@@ -252,8 +216,6 @@ ImpGraphic::~ImpGraphic()
delete mpContext;
}
-// ------------------------------------------------------------------------
-
ImpGraphic& ImpGraphic::operator=( const ImpGraphic& rImpGraphic )
{
if( &rImpGraphic != this )
@@ -302,8 +264,6 @@ ImpGraphic& ImpGraphic::operator=( const ImpGraphic& rImpGraphic )
return *this;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::operator==( const ImpGraphic& rImpGraphic ) const
{
sal_Bool bRet = sal_False;
@@ -367,8 +327,6 @@ sal_Bool ImpGraphic::operator==( const ImpGraphic& rImpGraphic ) const
return bRet;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplClearGraphics( sal_Bool bCreateSwapInfo )
{
if( bCreateSwapInfo && !ImplIsSwapOut() )
@@ -396,8 +354,6 @@ void ImpGraphic::ImplClearGraphics( sal_Bool bCreateSwapInfo )
maSvgData.reset();
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplClear()
{
if( mpSwapFile )
@@ -444,30 +400,22 @@ void ImpGraphic::ImplClear()
mnSizeBytes = 0;
}
-// ------------------------------------------------------------------------
-
GraphicType ImpGraphic::ImplGetType() const
{
return meType;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetDefaultType()
{
ImplClear();
meType = GRAPHIC_DEFAULT;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsSupportedGraphic() const
{
return( meType != GRAPHIC_NONE );
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsTransparent() const
{
sal_Bool bRet(sal_True);
@@ -480,8 +428,6 @@ sal_Bool ImpGraphic::ImplIsTransparent() const
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsAlpha() const
{
sal_Bool bRet(sal_False);
@@ -498,15 +444,11 @@ sal_Bool ImpGraphic::ImplIsAlpha() const
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsAnimated() const
{
return( mpAnimation != NULL );
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsEPS() const
{
return( ( meType == GRAPHIC_GDIMETAFILE ) &&
@@ -514,9 +456,6 @@ sal_Bool ImpGraphic::ImplIsEPS() const
( maMetaFile.GetAction( 0 )->GetType() == META_EPS_ACTION ) );
}
-
-// ------------------------------------------------------------------------
-
Bitmap ImpGraphic::ImplGetBitmap(const GraphicConversionParameters& rParameters) const
{
Bitmap aRetBmp;
@@ -618,8 +557,6 @@ Bitmap ImpGraphic::ImplGetBitmap(const GraphicConversionParameters& rParameters)
return aRetBmp;
}
-// ------------------------------------------------------------------------
-
BitmapEx ImpGraphic::ImplGetBitmapEx(const GraphicConversionParameters& rParameters) const
{
BitmapEx aRetBmpEx;
@@ -646,8 +583,6 @@ BitmapEx ImpGraphic::ImplGetBitmapEx(const GraphicConversionParameters& rParamet
return aRetBmpEx;
}
-// ------------------------------------------------------------------------
-
Animation ImpGraphic::ImplGetAnimation() const
{
Animation aAnimation;
@@ -658,15 +593,11 @@ Animation ImpGraphic::ImplGetAnimation() const
return aAnimation;
}
-// ------------------------------------------------------------------------
-
const GDIMetaFile& ImpGraphic::ImplGetGDIMetaFile() const
{
return maMetaFile;
}
-// ------------------------------------------------------------------------
-
Size ImpGraphic::ImplGetPrefSize() const
{
Size aSize;
@@ -714,8 +645,6 @@ Size ImpGraphic::ImplGetPrefSize() const
return aSize;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetPrefSize( const Size& rPrefSize )
{
switch( meType )
@@ -754,8 +683,6 @@ void ImpGraphic::ImplSetPrefSize( const Size& rPrefSize )
}
}
-// ------------------------------------------------------------------------
-
MapMode ImpGraphic::ImplGetPrefMapMode() const
{
MapMode aMapMode;
@@ -799,8 +726,6 @@ MapMode ImpGraphic::ImplGetPrefMapMode() const
return aMapMode;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetPrefMapMode( const MapMode& rPrefMapMode )
{
switch( meType )
@@ -839,8 +764,6 @@ void ImpGraphic::ImplSetPrefMapMode( const MapMode& rPrefMapMode )
}
}
-// ------------------------------------------------------------------------
-
sal_uLong ImpGraphic::ImplGetSizeBytes() const
{
if( 0 == mnSizeBytes )
@@ -865,8 +788,6 @@ sal_uLong ImpGraphic::ImplGetSizeBytes() const
return( mnSizeBytes );
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplDraw( OutputDevice* pOutDev, const Point& rDestPt ) const
{
if( ImplIsSupportedGraphic() && !ImplIsSwapOut() )
@@ -902,8 +823,6 @@ void ImpGraphic::ImplDraw( OutputDevice* pOutDev, const Point& rDestPt ) const
}
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplDraw( OutputDevice* pOutDev,
const Point& rDestPt, const Size& rDestSize ) const
{
@@ -944,8 +863,6 @@ void ImpGraphic::ImplDraw( OutputDevice* pOutDev,
}
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplStartAnimation( OutputDevice* pOutDev, const Point& rDestPt,
const Size& rDestSize, long nExtraData,
OutputDevice* pFirstFrameOutDev )
@@ -954,24 +871,18 @@ void ImpGraphic::ImplStartAnimation( OutputDevice* pOutDev, const Point& rDestPt
mpAnimation->Start( pOutDev, rDestPt, rDestSize, nExtraData, pFirstFrameOutDev );
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplStopAnimation( OutputDevice* pOutDev, long nExtraData )
{
if( ImplIsSupportedGraphic() && !ImplIsSwapOut() && mpAnimation )
mpAnimation->Stop( pOutDev, nExtraData );
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetAnimationNotifyHdl( const Link& rLink )
{
if( mpAnimation )
mpAnimation->SetNotifyHdl( rLink );
}
-// ------------------------------------------------------------------------
-
Link ImpGraphic::ImplGetAnimationNotifyHdl() const
{
Link aLink;
@@ -982,29 +893,21 @@ Link ImpGraphic::ImplGetAnimationNotifyHdl() const
return aLink;
}
-// ------------------------------------------------------------------------
-
sal_uLong ImpGraphic::ImplGetAnimationLoopCount() const
{
return( mpAnimation ? mpAnimation->GetLoopCount() : 0UL );
}
-// ------------------------------------------------------------------------
-
GraphicReader* ImpGraphic::ImplGetContext()
{
return mpContext;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetContext( GraphicReader* pReader )
{
mpContext = pReader;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetDocFileName( const String& rName, sal_uLong nFilePos )
{
const INetURLObject aURL( rName );
@@ -1015,22 +918,16 @@ void ImpGraphic::ImplSetDocFileName( const String& rName, sal_uLong nFilePos )
mnDocFilePos = nFilePos;
}
-// ------------------------------------------------------------------------
-
const String& ImpGraphic::ImplGetDocFileName() const
{
return maDocFileURLStr;
}
-// ------------------------------------------------------------------------
-
sal_uLong ImpGraphic::ImplGetDocFilePos() const
{
return mnDocFilePos;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplReadEmbedded( SvStream& rIStm, sal_Bool bSwap )
{
MapMode aMapMode;
@@ -1268,8 +1165,6 @@ sal_Bool ImpGraphic::ImplReadEmbedded( SvStream& rIStm, sal_Bool bSwap )
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplWriteEmbedded( SvStream& rOStm )
{
sal_Bool bRet = sal_False;
@@ -1349,8 +1244,6 @@ sal_Bool ImpGraphic::ImplWriteEmbedded( SvStream& rOStm )
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplSwapOut()
{
sal_Bool bRet = sal_False;
@@ -1424,8 +1317,6 @@ sal_Bool ImpGraphic::ImplSwapOut()
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplSwapOut( SvStream* pOStm )
{
sal_Bool bRet = sal_False;
@@ -1454,8 +1345,6 @@ sal_Bool ImpGraphic::ImplSwapOut( SvStream* pOStm )
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplSwapIn()
{
sal_Bool bRet = sal_False;
@@ -1531,8 +1420,6 @@ sal_Bool ImpGraphic::ImplSwapIn()
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplSwapIn( SvStream* pIStm )
{
sal_Bool bRet = sal_False;
@@ -1557,15 +1444,11 @@ sal_Bool ImpGraphic::ImplSwapIn( SvStream* pIStm )
return bRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsSwapOut() const
{
return mbSwapOut;
}
-// ------------------------------------------------------------------------
-
void ImpGraphic::ImplSetLink( const GfxLink& rGfxLink )
{
delete mpGfxLink;
@@ -1575,22 +1458,16 @@ void ImpGraphic::ImplSetLink( const GfxLink& rGfxLink )
mpGfxLink->SwapOut();
}
-// ------------------------------------------------------------------------
-
GfxLink ImpGraphic::ImplGetLink()
{
return( mpGfxLink ? *mpGfxLink : GfxLink() );
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplIsLink() const
{
return ( mpGfxLink != NULL ) ? sal_True : sal_False;
}
-// ------------------------------------------------------------------------
-
sal_uLong ImpGraphic::ImplGetChecksum() const
{
sal_uLong nRet = 0;
@@ -1630,8 +1507,6 @@ sal_uLong ImpGraphic::ImplGetChecksum() const
return nRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool ImpGraphic::ImplExportNative( SvStream& rOStm ) const
{
sal_Bool bResult = sal_False;
@@ -1655,15 +1530,11 @@ sal_Bool ImpGraphic::ImplExportNative( SvStream& rOStm ) const
return bResult;
}
-// ------------------------------------------------------------------------
-
const SvgDataPtr& ImpGraphic::getSvgData() const
{
return maSvgData;
}
-// ------------------------------------------------------------------------
-
SvStream& operator>>( SvStream& rIStm, ImpGraphic& rImpGraphic )
{
if( !rIStm.GetError() )
@@ -1814,8 +1685,6 @@ SvStream& operator>>( SvStream& rIStm, ImpGraphic& rImpGraphic )
return rIStm;
}
-// ------------------------------------------------------------------------
-
SvStream& operator<<( SvStream& rOStm, const ImpGraphic& rImpGraphic )
{
if( !rOStm.GetError() )
diff --git a/vcl/source/gdi/impimage.cxx b/vcl/source/gdi/impimage.cxx
index 50e32b6e5638..7bb76da3f510 100644
--- a/vcl/source/gdi/impimage.cxx
+++ b/vcl/source/gdi/impimage.cxx
@@ -28,15 +28,9 @@
#include <image.h>
-// -----------
-// - Defines -
-// -----------
-
#define IMPSYSIMAGEITEM_MASK ( 0x01 )
#define IMPSYSIMAGEITEM_ALPHA ( 0x02 )
-// -----------------------------------------------------------------------
-
ImageAryData::ImageAryData( const ImageAryData& rData ) :
maName( rData.maName ),
mnId( rData.mnId ),
@@ -50,14 +44,10 @@ ImageAryData::ImageAryData( const rtl::OUString &aName,
{
}
-// -----------------------------------------------------------------------
-
ImageAryData::~ImageAryData()
{
}
-// -----------------------------------------------------------------------
-
ImageAryData& ImageAryData::operator=( const ImageAryData& rData )
{
maName = rData.maName;
@@ -67,10 +57,6 @@ ImageAryData& ImageAryData::operator=( const ImageAryData& rData )
return *this;
}
-// -----------------
-// - ImplImageList -
-// -----------------
-
ImplImageList::ImplImageList()
{
}
@@ -113,42 +99,26 @@ void ImplImageList::RemoveImage( sal_uInt16 nPos )
maImages.erase( maImages.begin() + nPos );
}
-// -----------------
-// - ImplImageData -
-// -----------------
-
ImplImageData::ImplImageData( const BitmapEx& rBmpEx ) :
mpImageBitmap( NULL ),
maBmpEx( rBmpEx )
{
}
-// -----------------------------------------------------------------------
-
ImplImageData::~ImplImageData()
{
delete mpImageBitmap;
}
-// -----------------
-// - ImplImageData -
-// -----------------
-
sal_Bool ImplImageData::IsEqual( const ImplImageData& rData )
{
return( maBmpEx == rData.maBmpEx );
}
-// -------------
-// - ImplImage -
-// -------------
-
ImplImage::ImplImage()
{
}
-// ------------------------------------------------------------------------------
-
ImplImage::~ImplImage()
{
switch( meType )
@@ -163,10 +133,6 @@ ImplImage::~ImplImage()
}
}
-// ----------------
-// - ImplImageBmp -
-// ----------------
-
ImplImageBmp::ImplImageBmp() :
mpDisplayBmp( NULL ),
mpInfoAry( NULL ),
@@ -174,18 +140,12 @@ ImplImageBmp::ImplImageBmp() :
{
}
-// -------------
-// - ImplImage -
-// -------------
-
ImplImageBmp::~ImplImageBmp()
{
delete[] mpInfoAry;
delete mpDisplayBmp;
}
-// -----------------------------------------------------------------------
-
void ImplImageBmp::Create( const BitmapEx& rBmpEx, long nItemWidth, long nItemHeight, sal_uInt16 nInitSize )
{
maBmpEx = rBmpEx;
@@ -204,8 +164,6 @@ void ImplImageBmp::Create( const BitmapEx& rBmpEx, long nItemWidth, long nItemHe
mnSize );
}
-// -----------------------------------------------------------------------
-
void ImplImageBmp::Draw( sal_uInt16 nPos, OutputDevice* pOutDev,
const Point& rPos, sal_uInt16 nStyle,
const Size* pSize )
@@ -362,8 +320,6 @@ void ImplImageBmp::Draw( sal_uInt16 nPos, OutputDevice* pOutDev,
}
}
-// -----------------------------------------------------------------------
-
void ImplImageBmp::ImplUpdateDisplayBmp( OutputDevice*
#if defined WNT
pOutDev
@@ -390,8 +346,6 @@ pOutDev
}
}
-// -----------------------------------------------------------------------
-
void ImplImageBmp::ImplUpdateDisabledBmpEx( int nPos )
{
const Size aTotalSize( maBmpEx.GetSizePixel() );
diff --git a/vcl/source/gdi/impvect.cxx b/vcl/source/gdi/impvect.cxx
index 26c12f8f4be1..093d94fdbcf7 100644
--- a/vcl/source/gdi/impvect.cxx
+++ b/vcl/source/gdi/impvect.cxx
@@ -28,35 +28,21 @@
#include <vcl/virdev.hxx>
#include <impvect.hxx>
-// -----------
-// - Defines -
-// -----------
-
#define VECT_POLY_MAX 8192
-// -----------------------------------------------------------------------------
-
#define VECT_FREE_INDEX 0
#define VECT_CONT_INDEX 1
#define VECT_DONE_INDEX 2
-// -----------------------------------------------------------------------------
-
#define VECT_POLY_INLINE_INNER 1UL
#define VECT_POLY_INLINE_OUTER 2UL
#define VECT_POLY_OUTLINE_INNER 4UL
#define VECT_POLY_OUTLINE_OUTER 8UL
-// -----------------------------------------------------------------------------
-
#define VECT_MAP( _def_pIn, _def_pOut, _def_nVal ) _def_pOut[_def_nVal]=(_def_pIn[_def_nVal]=((_def_nVal)*4L)+1L)+5L;
#define BACK_MAP( _def_nVal ) ((((_def_nVal)+2)>>2)-1)
#define VECT_PROGRESS( _def_pProgress, _def_nVal ) if(_def_pProgress&&_def_pProgress->IsSet())(_def_pProgress->Call((void*)_def_nVal));
-// -----------
-// - statics -
-// -----------
-
struct ChainMove { long nDX; long nDY; };
static ChainMove aImplMove[ 8 ] = {
@@ -92,10 +78,6 @@ static ChainMove aImplMoveOuter[ 8 ] = {
{ 0L, -1L }
};
-// ----------------
-// - ImplColorSet -
-// ----------------
-
struct ImplColorSet
{
BitmapColor maColor;
@@ -106,22 +88,16 @@ struct ImplColorSet
sal_Bool operator>( const ImplColorSet& rSet ) const;
};
-// ----------------------------------------------------------------------------
-
inline sal_Bool ImplColorSet::operator<( const ImplColorSet& rSet ) const
{
return( mbSet && ( !rSet.mbSet || ( maColor.GetLuminance() > rSet.maColor.GetLuminance() ) ) );
}
-// ----------------------------------------------------------------------------
-
inline sal_Bool ImplColorSet::operator>( const ImplColorSet& rSet ) const
{
return( !mbSet || ( rSet.mbSet && maColor.GetLuminance() < rSet.maColor.GetLuminance() ) );
}
-// ----------------------------------------------------------------------------
-
extern "C" int SAL_CALL ImplColorSetCmpFnc( const void* p1, const void* p2 )
{
ImplColorSet* pSet1 = (ImplColorSet*) p1;
@@ -144,10 +120,6 @@ extern "C" int SAL_CALL ImplColorSetCmpFnc( const void* p1, const void* p2 )
return nRet;
}
-// ------------------
-// - ImplPointArray -
-// ------------------
-
class ImplPointArray
{
Point* mpArray;
@@ -170,8 +142,6 @@ public:
void ImplCreatePoly( Polygon& rPoly ) const;
};
-// -----------------------------------------------------------------------------
-
ImplPointArray::ImplPointArray() :
mpArray ( NULL ),
mnSize ( 0UL ),
@@ -180,16 +150,12 @@ ImplPointArray::ImplPointArray() :
{
}
-// -----------------------------------------------------------------------------
-
ImplPointArray::~ImplPointArray()
{
if( mpArray )
rtl_freeMemory( mpArray );
}
-// -----------------------------------------------------------------------------
-
void ImplPointArray::ImplSetSize( sal_uLong nSize )
{
const sal_uLong nTotal = nSize * sizeof( Point );
@@ -204,33 +170,23 @@ void ImplPointArray::ImplSetSize( sal_uLong nSize )
memset( (HPBYTE) mpArray, 0, nTotal );
}
-// -----------------------------------------------------------------------------
-
inline Point& ImplPointArray::operator[]( sal_uLong nPos )
{
DBG_ASSERT( nPos < mnSize, "ImplPointArray::operator[]: nPos out of range!" );
return mpArray[ nPos ];
}
-// -----------------------------------------------------------------------------
-
inline const Point& ImplPointArray::operator[]( sal_uLong nPos ) const
{
DBG_ASSERT( nPos < mnSize, "ImplPointArray::operator[]: nPos out of range!" );
return mpArray[ nPos ];
}
-// -----------------------------------------------------------------------------
-
void ImplPointArray::ImplCreatePoly( Polygon& rPoly ) const
{
rPoly = Polygon( sal::static_int_cast<sal_uInt16>(mnRealSize), mpArray );
}
-// ---------------
-// - ImplVectMap -
-// ---------------
-
class ImplVectMap
{
private:
@@ -259,8 +215,6 @@ public:
};
-// -----------------------------------------------------------------------------
-
ImplVectMap::ImplVectMap( long nWidth, long nHeight ) :
mnWidth ( nWidth ),
mnHeight( nHeight )
@@ -276,55 +230,38 @@ ImplVectMap::ImplVectMap( long nWidth, long nHeight ) :
mpScan[ nY++ ] = pTmp;
}
-// -----------------------------------------------------------------------------
-
-
ImplVectMap::~ImplVectMap()
{
rtl_freeMemory( mpBuf );
rtl_freeMemory( mpScan );
}
-// -----------------------------------------------------------------------------
-
inline void ImplVectMap::Set( long nY, long nX, sal_uInt8 cVal )
{
const sal_uInt8 cShift = sal::static_int_cast<sal_uInt8>(6 - ( ( nX & 3 ) << 1 ));
( ( mpScan[ nY ][ nX >> 2 ] ) &= ~( 3 << cShift ) ) |= ( cVal << cShift );
}
-// -----------------------------------------------------------------------------
-
inline sal_uInt8 ImplVectMap::Get( long nY, long nX ) const
{
return sal::static_int_cast<sal_uInt8>( ( ( mpScan[ nY ][ nX >> 2 ] ) >> ( 6 - ( ( nX & 3 ) << 1 ) ) ) & 3 );
}
-// -----------------------------------------------------------------------------
-
inline sal_Bool ImplVectMap::IsFree( long nY, long nX ) const
{
return( VECT_FREE_INDEX == Get( nY, nX ) );
}
-// -----------------------------------------------------------------------------
-
inline sal_Bool ImplVectMap::IsCont( long nY, long nX ) const
{
return( VECT_CONT_INDEX == Get( nY, nX ) );
}
-// -----------------------------------------------------------------------------
-
inline sal_Bool ImplVectMap::IsDone( long nY, long nX ) const
{
return( VECT_DONE_INDEX == Get( nY, nX ) );
}
-// -------------
-// - ImplChain -
-// -------------
-
class ImplChain
{
private:
@@ -355,8 +292,6 @@ public:
const Polygon& ImplGetPoly() const { return maPoly; }
};
-// -----------------------------------------------------------------------------
-
ImplChain::ImplChain( sal_uLong nInitCount, long nResize ) :
mnArraySize ( nInitCount ),
mnCount ( 0UL ),
@@ -366,15 +301,11 @@ ImplChain::ImplChain( sal_uLong nInitCount, long nResize ) :
mpCodes = new sal_uInt8[ mnArraySize ];
}
-// -----------------------------------------------------------------------------
-
ImplChain::~ImplChain()
{
delete[] mpCodes;
}
-// -----------------------------------------------------------------------------
-
void ImplChain::ImplGetSpace()
{
const sal_uLong nOldArraySize = mnArraySize;
@@ -387,8 +318,6 @@ void ImplChain::ImplGetSpace()
mpCodes = pNewCodes;
}
-// -----------------------------------------------------------------------------
-
void ImplChain::ImplBeginAdd( const Point& rStartPt )
{
maPoly = Polygon();
@@ -396,8 +325,6 @@ void ImplChain::ImplBeginAdd( const Point& rStartPt )
mnCount = 0UL;
}
-// -----------------------------------------------------------------------------
-
inline void ImplChain::ImplAdd( sal_uInt8 nCode )
{
if( mnCount == mnArraySize )
@@ -406,8 +333,6 @@ inline void ImplChain::ImplAdd( sal_uInt8 nCode )
mpCodes[ mnCount++ ] = nCode;
}
-// -----------------------------------------------------------------------------
-
void ImplChain::ImplEndAdd( sal_uLong nFlag )
{
if( mnCount )
@@ -650,8 +575,6 @@ void ImplChain::ImplEndAdd( sal_uLong nFlag )
maPoly.SetSize( 0 );
}
-// -----------------------------------------------------------------------------
-
void ImplChain::ImplPostProcess( const ImplPointArray& rArr )
{
ImplPointArray aNewArr1;
@@ -711,22 +634,14 @@ void ImplChain::ImplPostProcess( const ImplPointArray& rArr )
aNewArr2.ImplCreatePoly( maPoly );
}
-// ------------------
-// - ImplVectorizer -
-// ------------------
-
ImplVectorizer::ImplVectorizer()
{
}
-// -----------------------------------------------------------------------------
-
ImplVectorizer::~ImplVectorizer()
{
}
-// -----------------------------------------------------------------------------
-
sal_Bool ImplVectorizer::ImplVectorize( const Bitmap& rColorBmp, GDIMetaFile& rMtf,
sal_uInt8 cReduce, sal_uLong nFlags, const Link* pProgress )
{
@@ -830,8 +745,6 @@ sal_Bool ImplVectorizer::ImplVectorize( const Bitmap& rColorBmp, GDIMetaFile& rM
return bRet;
}
-// -----------------------------------------------------------------------------
-
sal_Bool ImplVectorizer::ImplVectorize( const Bitmap& rMonoBmp,
PolyPolygon& rPolyPoly,
sal_uLong nFlags, const Link* pProgress )
@@ -927,8 +840,6 @@ sal_Bool ImplVectorizer::ImplVectorize( const Bitmap& rMonoBmp,
return bRet;
}
-// -----------------------------------------------------------------------------
-
void ImplVectorizer::ImplLimitPolyPoly( PolyPolygon& rPolyPoly )
{
if( rPolyPoly.Count() > VECT_POLY_MAX )
@@ -961,8 +872,6 @@ void ImplVectorizer::ImplLimitPolyPoly( PolyPolygon& rPolyPoly )
}
}
-// -----------------------------------------------------------------------------
-
ImplVectMap* ImplVectorizer::ImplExpand( BitmapReadAccess* pRAcc, const Color& rColor )
{
ImplVectMap* pMap = NULL;
@@ -1054,8 +963,6 @@ ImplVectMap* ImplVectorizer::ImplExpand( BitmapReadAccess* pRAcc, const Color& r
return pMap;
}
-// -----------------------------------------------------------------------------
-
void ImplVectorizer::ImplCalculate( ImplVectMap* pMap, PolyPolygon& rPolyPoly, sal_uInt8 cReduce, sal_uLong nFlags )
{
const long nWidth = pMap->Width(), nHeight= pMap->Height();
@@ -1123,8 +1030,6 @@ void ImplVectorizer::ImplCalculate( ImplVectMap* pMap, PolyPolygon& rPolyPoly, s
}
}
-// -----------------------------------------------------------------------------
-
sal_Bool ImplVectorizer::ImplGetChain( ImplVectMap* pMap, const Point& rStartPt, ImplChain& rChain )
{
long nActX = rStartPt.X();
@@ -1177,8 +1082,6 @@ sal_Bool ImplVectorizer::ImplGetChain( ImplVectMap* pMap, const Point& rStartPt
return sal_True;
}
-// -----------------------------------------------------------------------------
-
sal_Bool ImplVectorizer::ImplIsUp( ImplVectMap* pMap, long nY, long nX ) const
{
if( pMap->IsDone( nY - 1L, nX ) )
diff --git a/vcl/source/gdi/outdev.cxx b/vcl/source/gdi/outdev.cxx
index cb014ec4bfa8..2872262ddb10 100644
--- a/vcl/source/gdi/outdev.cxx
+++ b/vcl/source/gdi/outdev.cxx
@@ -30,7 +30,6 @@
#include <vcl/print.hxx>
#include <vcl/outdev.hxx>
#include <vcl/unowrap.hxx>
-// declare system types in sysdata.hxx
#include <svsys.h>
#include <vcl/sysdata.hxx>
@@ -78,8 +77,6 @@ DBG_NAME( PolyPolygon )
#endif
DBG_NAMEEX( Region )
-// -----------------------------------------------------------------------
-
#ifdef DBG_UTIL
const char* ImplDbgCheckOutputDevice( const void* pObj )
{
@@ -123,8 +120,6 @@ struct ImplObjStack
sal_uInt16 mnFlags;
};
-// -----------------------------------------------------------------------
-
static void ImplDeleteObjStack( ImplObjStack* pObjStack )
{
if ( pObjStack->mnFlags & PUSH_LINECOLOR )
@@ -175,8 +170,6 @@ static void ImplDeleteObjStack( ImplObjStack* pObjStack )
delete pObjStack;
}
-// -----------------------------------------------------------------------
-
bool OutputDevice::ImplIsAntiparallel() const
{
bool bRet = false;
@@ -191,9 +184,6 @@ bool OutputDevice::ImplIsAntiparallel() const
return bRet;
}
-// -----------------------------------------------------------------------
-
-
bool OutputDevice::ImplSelectClipRegion( const Region& rRegion, SalGraphics* pGraphics )
{
DBG_TESTSOLARMUTEX();
@@ -414,8 +404,6 @@ OutputDevice::OutputDevice() :
maThresRes.mnThresPixToLogY = 0;
}
-// -----------------------------------------------------------------------
-
OutputDevice::~OutputDevice()
{
DBG_DTOR( OutputDevice, ImplDbgCheckOutputDevice );
@@ -487,8 +475,6 @@ bool OutputDevice::supportsOperation( OutDevSupportType eType ) const
return bHasSupport;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::EnableRTL( sal_Bool bEnable )
{
mbEnableRTL = (bEnable != 0);
@@ -561,9 +547,6 @@ void OutputDevice::ImplReMirror( Region &rRegion ) const
rRegion = aMirroredRegion;
}
-
-// -----------------------------------------------------------------------
-
SalGraphics* OutputDevice::ImplGetGraphics() const
{
DBG_TESTSOLARMUTEX();
@@ -714,8 +697,6 @@ SalGraphics* OutputDevice::ImplGetGraphics() const
return mpGraphics;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplReleaseGraphics( sal_Bool bRelease )
{
DBG_TESTSOLARMUTEX();
@@ -833,8 +814,6 @@ void OutputDevice::ImplReleaseGraphics( sal_Bool bRelease )
mpNextGraphics = NULL;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitOutDevData()
{
if ( !mpOutDevData )
@@ -849,8 +828,6 @@ void OutputDevice::ImplInitOutDevData()
}
}
-// -----------------------------------------------------------------------
-
// #i75163#
void OutputDevice::ImplInvalidateViewTransform()
{
@@ -870,15 +847,11 @@ void OutputDevice::ImplInvalidateViewTransform()
}
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::ImplIsRecordLayout() const
{
return mpOutDevData && mpOutDevData->mpRecordLayout;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDeInitOutDevData()
{
if ( mpOutDevData )
@@ -893,8 +866,6 @@ void OutputDevice::ImplDeInitOutDevData()
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitLineColor()
{
DBG_TESTSOLARMUTEX();
@@ -916,8 +887,6 @@ void OutputDevice::ImplInitLineColor()
mbInitLineColor = sal_False;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitFillColor()
{
DBG_TESTSOLARMUTEX();
@@ -939,8 +908,6 @@ void OutputDevice::ImplInitFillColor()
mbInitFillColor = sal_False;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitClipRegion()
{
DBG_TESTSOLARMUTEX();
@@ -1027,8 +994,6 @@ void OutputDevice::ImplInitClipRegion()
mbInitClipRegion = sal_False;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplSetClipRegion( const Region* pRegion )
{
DBG_TESTSOLARMUTEX();
@@ -1050,8 +1015,6 @@ void OutputDevice::ImplSetClipRegion( const Region* pRegion )
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetClipRegion()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1065,8 +1028,6 @@ void OutputDevice::SetClipRegion()
mpAlphaVDev->SetClipRegion();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetClipRegion( const Region& rRegion )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1087,8 +1048,6 @@ void OutputDevice::SetClipRegion( const Region& rRegion )
mpAlphaVDev->SetClipRegion( rRegion );
}
-// -----------------------------------------------------------------------
-
Region OutputDevice::GetClipRegion() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1096,8 +1055,6 @@ Region OutputDevice::GetClipRegion() const
return PixelToLogic( maRegion );
}
-// -----------------------------------------------------------------------
-
Region OutputDevice::GetActiveClipRegion() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1119,8 +1076,6 @@ Region OutputDevice::GetActiveClipRegion() const
return GetClipRegion();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::MoveClipRegion( long nHorzMove, long nVertMove )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1139,8 +1094,6 @@ void OutputDevice::MoveClipRegion( long nHorzMove, long nVertMove )
mpAlphaVDev->MoveClipRegion( nHorzMove, nVertMove );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::IntersectClipRegion( const Rectangle& rRect )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1157,8 +1110,6 @@ void OutputDevice::IntersectClipRegion( const Rectangle& rRect )
mpAlphaVDev->IntersectClipRegion( rRect );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::IntersectClipRegion( const Region& rRegion )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1181,8 +1132,6 @@ void OutputDevice::IntersectClipRegion( const Region& rRegion )
mpAlphaVDev->IntersectClipRegion( rRegion );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetDrawMode( sal_uLong nDrawMode )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1193,8 +1142,6 @@ void OutputDevice::SetDrawMode( sal_uLong nDrawMode )
mpAlphaVDev->SetDrawMode( nDrawMode );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetRasterOp( RasterOp eRasterOp )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1215,8 +1162,6 @@ void OutputDevice::SetRasterOp( RasterOp eRasterOp )
mpAlphaVDev->SetRasterOp( eRasterOp );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetLineColor()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1235,8 +1180,6 @@ void OutputDevice::SetLineColor()
mpAlphaVDev->SetLineColor();
}
-// -----------------------------------------------------------------------
-
Color OutputDevice::ImplDrawModeToColor( const Color& rColor ) const
{
Color aColor( rColor );
@@ -1310,8 +1253,6 @@ void OutputDevice::SetLineColor( const Color& rColor )
mpAlphaVDev->SetLineColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetFillColor()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1330,8 +1271,6 @@ void OutputDevice::SetFillColor()
mpAlphaVDev->SetFillColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetFillColor( const Color& rColor )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1401,8 +1340,6 @@ void OutputDevice::SetFillColor( const Color& rColor )
mpAlphaVDev->SetFillColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetBackground()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1414,8 +1351,6 @@ void OutputDevice::SetBackground()
mpAlphaVDev->SetBackground();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetBackground( const Wallpaper& rBackground )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1431,8 +1366,6 @@ void OutputDevice::SetBackground( const Wallpaper& rBackground )
mpAlphaVDev->SetBackground( rBackground );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetRefPoint()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1447,8 +1380,6 @@ void OutputDevice::SetRefPoint()
mpAlphaVDev->SetRefPoint();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetRefPoint( const Point& rRefPoint )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1463,8 +1394,6 @@ void OutputDevice::SetRefPoint( const Point& rRefPoint )
mpAlphaVDev->SetRefPoint( rRefPoint );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawLine( const Point& rStartPt, const Point& rEndPt )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1525,8 +1454,6 @@ void OutputDevice::DrawLine( const Point& rStartPt, const Point& rEndPt )
mpAlphaVDev->DrawLine( rStartPt, rEndPt );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::impPaintLineGeometryWithEvtlExpand(
const LineInfo& rInfo,
basegfx::B2DPolyPolygon aLinePolyPolygon)
@@ -1663,8 +1590,6 @@ void OutputDevice::impPaintLineGeometryWithEvtlExpand(
mpMetaFile = pOldMetaFile;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawLine( const Point& rStartPt, const Point& rEndPt,
const LineInfo& rLineInfo )
{
@@ -1717,8 +1642,6 @@ void OutputDevice::DrawLine( const Point& rStartPt, const Point& rEndPt,
mpAlphaVDev->DrawLine( rStartPt, rEndPt, rLineInfo );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawRect( const Rectangle& rRect )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1757,8 +1680,6 @@ void OutputDevice::DrawRect( const Rectangle& rRect )
mpAlphaVDev->DrawRect( rRect );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawPolyLine( const Polygon& rPoly )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1834,8 +1755,6 @@ void OutputDevice::DrawPolyLine( const Polygon& rPoly )
mpAlphaVDev->DrawPolyLine( rPoly );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawPolyLine( const Polygon& rPoly, const LineInfo& rLineInfo )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1925,8 +1844,6 @@ void OutputDevice::ImpDrawPolyLineWithLineInfo(const Polygon& rPoly, const LineI
mpAlphaVDev->DrawPolyLine( rPoly, rLineInfo );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawPolygon( const Polygon& rPoly )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2020,8 +1937,6 @@ void OutputDevice::DrawPolygon( const Polygon& rPoly )
mpAlphaVDev->DrawPolygon( rPoly );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawPolyPolygon( const PolyPolygon& rPolyPoly )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2121,8 +2036,6 @@ void OutputDevice::DrawPolyPolygon( const PolyPolygon& rPolyPoly )
mpAlphaVDev->DrawPolyPolygon( rPolyPoly );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawPolygon( const ::basegfx::B2DPolygon& rB2DPolygon)
{
// AW: Do NOT paint empty polygons
@@ -2221,8 +2134,6 @@ void OutputDevice::ImpDrawPolyPolygonWithB2DPolyPolygon(const basegfx::B2DPolyPo
ImplDrawPolyPolygon( aPixelPolyPolygon.Count(), aPixelPolyPolygon );
}
-// -----------------------------------------------------------------------
-
bool OutputDevice::ImpTryDrawPolyLineDirect(
const basegfx::B2DPolygon& rB2DPolygon,
double fLineWidth,
@@ -2366,8 +2277,6 @@ void OutputDevice::DrawPolyLine(
}
}
-// -----------------------------------------------------------------------
-
sal_uInt32 OutputDevice::GetGCStackDepth() const
{
const ImplObjStack* pData = mpObjStack;
@@ -2380,8 +2289,6 @@ sal_uInt32 OutputDevice::GetGCStackDepth() const
return nDepth;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::Push( sal_uInt16 nFlags )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2468,8 +2375,6 @@ void OutputDevice::Push( sal_uInt16 nFlags )
mpAlphaVDev->Push();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::Pop()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2561,15 +2466,11 @@ void OutputDevice::Pop()
mpMetaFile = pOldMetaFile;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetConnectMetaFile( GDIMetaFile* pMtf )
{
mpMetaFile = pMtf;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::EnableOutput( sal_Bool bEnable )
{
mbOutput = (bEnable != 0);
@@ -2578,8 +2479,6 @@ void OutputDevice::EnableOutput( sal_Bool bEnable )
mpAlphaVDev->EnableOutput( bEnable );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetSettings( const AllSettings& rSettings )
{
maSettings = rSettings;
@@ -2588,8 +2487,6 @@ void OutputDevice::SetSettings( const AllSettings& rSettings )
mpAlphaVDev->SetSettings( rSettings );
}
-// -----------------------------------------------------------------------
-
sal_uInt16 OutputDevice::GetBitCount() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2607,8 +2504,6 @@ sal_uInt16 OutputDevice::GetBitCount() const
return (sal_uInt16)mpGraphics->GetBitCount();
}
-// -----------------------------------------------------------------------
-
sal_uInt16 OutputDevice::GetAlphaBitCount() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2622,8 +2517,6 @@ sal_uInt16 OutputDevice::GetAlphaBitCount() const
return 0;
}
-// -----------------------------------------------------------------------
-
sal_uLong OutputDevice::GetColorCount() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -2632,23 +2525,17 @@ sal_uLong OutputDevice::GetColorCount() const
return( ( nBitCount > 31 ) ? ULONG_MAX : ( ( (sal_uLong) 1 ) << nBitCount) );
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::HasAlpha()
{
return mpAlphaVDev != NULL;
}
-// -----------------------------------------------------------------------
-
::com::sun::star::uno::Reference< ::com::sun::star::awt::XGraphics > OutputDevice::CreateUnoGraphics()
{
UnoWrapperBase* pWrapper = Application::GetUnoWrapper();
return pWrapper ? pWrapper->CreateGraphics( this ) : ::com::sun::star::uno::Reference< ::com::sun::star::awt::XGraphics >();
}
-// -----------------------------------------------------------------------
-
SystemGraphicsData OutputDevice::GetSystemGfxData() const
{
if ( !mpGraphics )
@@ -2660,8 +2547,6 @@ SystemGraphicsData OutputDevice::GetSystemGfxData() const
return mpGraphics->GetGraphicsData();
}
-// -----------------------------------------------------------------------
-
::com::sun::star::uno::Any OutputDevice::GetSystemGfxDataAny() const
{
::com::sun::star::uno::Any aRet;
@@ -2672,8 +2557,6 @@ SystemGraphicsData OutputDevice::GetSystemGfxData() const
return uno::makeAny(aSeq);
}
-// -----------------------------------------------------------------------
-
::com::sun::star::uno::Reference< ::com::sun::star::rendering::XCanvas > OutputDevice::GetCanvas() const
{
uno::Sequence< uno::Any > aArg(6);
@@ -2703,6 +2586,4 @@ SystemGraphicsData OutputDevice::GetSystemGfxData() const
return xCanvas;
}
-// -----------------------------------------------------------------------
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/source/gdi/outdev2.cxx b/vcl/source/gdi/outdev2.cxx
index 888e25f5048e..11bdd1188a31 100644
--- a/vcl/source/gdi/outdev2.cxx
+++ b/vcl/source/gdi/outdev2.cxx
@@ -42,12 +42,6 @@
DBG_NAMEEX( OutputDevice )
-// =======================================================================
-
-// -----------
-// - Defines -
-// -----------
-
#define OUTDEV_INIT() \
{ \
if ( !IsDeviceOutputNecessary() ) \
@@ -64,18 +58,12 @@ DBG_NAMEEX( OutputDevice )
return; \
}
-// -------------
-// - externals -
-// -------------
-
extern const sal_uLong nVCLRLut[ 6 ];
extern const sal_uLong nVCLGLut[ 6 ];
extern const sal_uLong nVCLBLut[ 6 ];
extern const sal_uLong nVCLDitherLut[ 256 ];
extern const sal_uLong nVCLLut[ 256 ];
-// =======================================================================
-
sal_uLong ImplAdjustTwoRect( SalTwoRect& rTwoRect, const Size& rSizePix )
{
sal_uLong nMirrFlags = 0;
@@ -133,8 +121,6 @@ sal_uLong ImplAdjustTwoRect( SalTwoRect& rTwoRect, const Size& rSizePix )
return nMirrFlags;
}
-// =======================================================================
-
void ImplAdjustTwoRect( SalTwoRect& rTwoRect, const Rectangle& rValidSrcRect )
{
if( ( rTwoRect.mnSrcX < rValidSrcRect.Left() ) || ( rTwoRect.mnSrcX >= rValidSrcRect.Right() ) ||
@@ -172,8 +158,6 @@ void ImplAdjustTwoRect( SalTwoRect& rTwoRect, const Rectangle& rValidSrcRect )
}
}
-// =======================================================================
-
void OutputDevice::ImplDrawOutDevDirect( const OutputDevice* pSrcDev, void* pVoidPosAry )
{
SalTwoRect* pPosAry = (SalTwoRect*)pVoidPosAry;
diff --git a/vcl/source/gdi/outdev3.cxx b/vcl/source/gdi/outdev3.cxx
index aeb20c4e6a0c..9f022ed94215 100644
--- a/vcl/source/gdi/outdev3.cxx
+++ b/vcl/source/gdi/outdev3.cxx
@@ -91,30 +91,20 @@
#include <algorithm>
-// =======================================================================
-
DBG_NAMEEX( OutputDevice )
DBG_NAMEEX( Font )
-// =======================================================================
-
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
using namespace ::rtl;
using namespace ::vcl;
using namespace ::utl;
-// =======================================================================
-
#define TEXT_DRAW_ELLIPSIS (TEXT_DRAW_ENDELLIPSIS | TEXT_DRAW_PATHELLIPSIS | TEXT_DRAW_NEWSELLIPSIS)
-// =======================================================================
-
#define UNDERLINE_LAST UNDERLINE_BOLDWAVE
#define STRIKEOUT_LAST STRIKEOUT_X
-// =======================================================================
-
static void ImplRotatePos( long nOriginX, long nOriginY, long& rX, long& rY,
int nOrientation )
{
@@ -166,8 +156,6 @@ static void ImplRotatePos( long nOriginX, long nOriginY, long& rX, long& rY,
}
}
-// =======================================================================
-
void OutputDevice::ImplUpdateFontData( bool bNewFontLists )
{
// the currently selected logical font is no longer needed
@@ -245,8 +233,6 @@ void OutputDevice::ImplUpdateFontData( bool bNewFontLists )
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplUpdateAllFontData( bool bNewFontLists )
{
ImplSVData* pSVData = ImplGetSVData();
@@ -302,25 +288,16 @@ void OutputDevice::ImplUpdateAllFontData( bool bNewFontLists )
}
}
-// =======================================================================
-
-
-// =======================================================================
-
// TODO: remove this method when the CWS-gfbfcfg dust has settled
void ImplFreeOutDevFontData()
{}
-// =======================================================================
-
void OutputDevice::BeginFontSubstitution()
{
ImplSVData* pSVData = ImplGetSVData();
pSVData->maGDIData.mbFontSubChanged = sal_False;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::EndFontSubstitution()
{
ImplSVData* pSVData = ImplGetSVData();
@@ -336,8 +313,6 @@ void OutputDevice::EndFontSubstitution()
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::AddFontSubstitute( const XubString& rFontName,
const XubString& rReplaceFontName,
sal_uInt16 nFlags )
@@ -349,16 +324,12 @@ void OutputDevice::AddFontSubstitute( const XubString& rFontName,
ImplGetSVData()->maGDIData.mbFontSubChanged = sal_True;
}
-// -----------------------------------------------------------------------
-
void ImplDirectFontSubstitution::AddFontSubstitute( const String& rFontName,
const String& rSubstFontName, sal_uInt16 nFlags )
{
maFontSubstList.push_back( ImplFontSubstEntry( rFontName, rSubstFontName, nFlags ) );
}
-// -----------------------------------------------------------------------
-
ImplFontSubstEntry::ImplFontSubstEntry( const OUString& rFontName,
const OUString& rSubstFontName, sal_uInt16 nSubstFlags )
: maName( rFontName )
@@ -371,8 +342,6 @@ ImplFontSubstEntry::ImplFontSubstEntry( const OUString& rFontName,
GetEnglishSearchFontName( maSearchReplaceName );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplAddDevFontSubstitute( const XubString& rFontName,
const XubString& rReplaceFontName,
sal_uInt16 nFlags )
@@ -381,8 +350,6 @@ void OutputDevice::ImplAddDevFontSubstitute( const XubString& rFontName,
mpOutDevData->maDevFontSubst.AddFontSubstitute( rFontName, rReplaceFontName, nFlags );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::RemoveFontSubstitute( sal_uInt16 n )
{
ImplDirectFontSubstitution* pSubst = ImplGetSVData()->maGDIData.mpDirectFontSubst;
@@ -390,8 +357,6 @@ void OutputDevice::RemoveFontSubstitute( sal_uInt16 n )
pSubst->RemoveFontSubstitute( n );
}
-// -----------------------------------------------------------------------
-
void ImplDirectFontSubstitution::RemoveFontSubstitute( int nIndex )
{
FontSubstList::iterator it = maFontSubstList.begin();
@@ -400,8 +365,6 @@ void ImplDirectFontSubstitution::RemoveFontSubstitute( int nIndex )
maFontSubstList.erase( it );
}
-// -----------------------------------------------------------------------
-
sal_uInt16 OutputDevice::GetFontSubstituteCount()
{
const ImplDirectFontSubstitution* pSubst = ImplGetSVData()->maGDIData.mpDirectFontSubst;
@@ -411,8 +374,6 @@ sal_uInt16 OutputDevice::GetFontSubstituteCount()
return (sal_uInt16)nCount;
}
-// -----------------------------------------------------------------------
-
bool ImplDirectFontSubstitution::FindFontSubstitute( String& rSubstName,
const String& rSearchName, sal_uInt16 nFlags ) const
{
@@ -432,8 +393,6 @@ bool ImplDirectFontSubstitution::FindFontSubstitute( String& rSubstName,
return false;
}
-// -----------------------------------------------------------------------
-
static void ImplFontSubstitute( OUString& rFontName,
sal_uInt16 nFlags, ImplDirectFontSubstitution* pDevSpecific )
{
@@ -464,8 +423,6 @@ static void ImplFontSubstitute( OUString& rFontName,
}
}
-// -----------------------------------------------------------------------
-
Font OutputDevice::GetDefaultFont( sal_uInt16 nType, LanguageType eLang,
sal_uLong nFlags, const OutputDevice* pOutDev )
{
@@ -666,8 +623,6 @@ Font OutputDevice::GetDefaultFont( sal_uInt16 nType, LanguageType eLang,
return aFont;
}
-// =======================================================================
-
static unsigned ImplIsCJKFont( const String& rFontName )
{
// Test, if Fontname includes CJK characters --> In this case we
@@ -701,8 +656,6 @@ static unsigned ImplIsCJKFont( const String& rFontName )
return 0;
}
-// -----------------------------------------------------------------------
-
static void ImplCalcType( sal_uLong& rType, FontWeight& rWeight, FontWidth& rWidth,
FontFamily eFamily, const FontNameAttr* pFontAttr )
{
@@ -733,8 +686,6 @@ static void ImplCalcType( sal_uLong& rType, FontWeight& rWeight, FontWidth& rWid
}
}
-// =======================================================================
-
PhysicalFontFace::PhysicalFontFace( const ImplDevFontAttributes& rDFA, int nMagic )
: ImplDevFontAttributes( rDFA ),
mnWidth(0),
@@ -749,8 +700,6 @@ PhysicalFontFace::PhysicalFontFace( const ImplDevFontAttributes& rDFA, int nMagi
SetSymbolFlag( true );
}
-// -----------------------------------------------------------------------
-
sal_Int32 PhysicalFontFace::CompareIgnoreSize( const PhysicalFontFace& rOther ) const
{
// compare their width, weight, italic and style name
@@ -773,8 +722,6 @@ sal_Int32 PhysicalFontFace::CompareIgnoreSize( const PhysicalFontFace& rOther )
return eCompare;
}
-// -----------------------------------------------------------------------
-
sal_Int32 PhysicalFontFace::CompareWithSize( const PhysicalFontFace& rOther ) const
{
sal_Int32 eCompare = CompareIgnoreSize( rOther );
@@ -794,8 +741,6 @@ sal_Int32 PhysicalFontFace::CompareWithSize( const PhysicalFontFace& rOther ) co
return COMPARE_EQUAL;
}
-// -----------------------------------------------------------------------
-
struct FontMatchStatus
{
public:
@@ -947,8 +892,6 @@ bool PhysicalFontFace::IsBetterMatch( const FontSelectPattern& rFSD, FontMatchSt
return true;
}
-// =======================================================================
-
ImplFontEntry::ImplFontEntry( const FontSelectPattern& rFontSelData )
: maFontSelData( rFontSelData ),
maMetric( rFontSelData ),
@@ -963,15 +906,11 @@ ImplFontEntry::ImplFontEntry( const FontSelectPattern& rFontSelData )
maFontSelData.mpFontEntry = this;
}
-// -----------------------------------------------------------------------
-
ImplFontEntry::~ImplFontEntry()
{
delete mpUnicodeFallbackList;
}
-// -----------------------------------------------------------------------
-
size_t ImplFontEntry::GFBCacheKey_Hash::operator()( const GFBCacheKey& rData ) const
{
boost::hash<sal_UCS4> a;
@@ -986,8 +925,6 @@ inline void ImplFontEntry::AddFallbackForUnicode( sal_UCS4 cChar, FontWeight eWe
(*mpUnicodeFallbackList)[ GFBCacheKey(cChar,eWeight) ] = rFontName;
}
-// -----------------------------------------------------------------------
-
inline bool ImplFontEntry::GetFallbackForUnicode( sal_UCS4 cChar, FontWeight eWeight, OUString* pFontName ) const
{
if( !mpUnicodeFallbackList )
@@ -1001,8 +938,6 @@ inline bool ImplFontEntry::GetFallbackForUnicode( sal_UCS4 cChar, FontWeight eWe
return true;
}
-// -----------------------------------------------------------------------
-
inline void ImplFontEntry::IgnoreFallbackForUnicode( sal_UCS4 cChar, FontWeight eWeight, const String& rFontName )
{
// DBG_ASSERT( mpUnicodeFallbackList, "ImplFontEntry::IgnoreFallbackForUnicode no list" );
@@ -1014,8 +949,6 @@ inline void ImplFontEntry::IgnoreFallbackForUnicode( sal_UCS4 cChar, FontWeight
mpUnicodeFallbackList->erase( it );
}
-// =======================================================================
-
ImplDevFontListData::ImplDevFontListData( const String& rSearchName )
: mpFirst( NULL ),
maSearchName( rSearchName ),
@@ -1028,8 +961,6 @@ ImplDevFontListData::ImplDevFontListData( const String& rSearchName )
mnMinQuality( -1 )
{}
-// -----------------------------------------------------------------------
-
ImplDevFontListData::~ImplDevFontListData()
{
// release all physical font faces
@@ -1041,8 +972,6 @@ ImplDevFontListData::~ImplDevFontListData()
}
}
-// -----------------------------------------------------------------------
-
bool ImplDevFontListData::AddFontFace( PhysicalFontFace* pNewData )
{
pNewData->mpNext = NULL;
@@ -1141,8 +1070,6 @@ bool ImplDevFontListData::AddFontFace( PhysicalFontFace* pNewData )
return true;
}
-// -----------------------------------------------------------------------
-
// get font attributes using the normalized font family name
void ImplDevFontListData::InitMatchData( const utl::FontSubstConfiguration& rFontSubst,
const String& rSearchName )
@@ -1160,8 +1087,6 @@ void ImplDevFontListData::InitMatchData( const utl::FontSubstConfiguration& rFon
mnMatchType |= ImplIsCJKFont( maName );
}
-// -----------------------------------------------------------------------
-
PhysicalFontFace* ImplDevFontListData::FindBestFontFace( const FontSelectPattern& rFSD ) const
{
if( !mpFirst )
@@ -1187,8 +1112,6 @@ PhysicalFontFace* ImplDevFontListData::FindBestFontFace( const FontSelectPattern
return pBestFontFace;
}
-// -----------------------------------------------------------------------
-
// update device font list with unique font faces, with uniqueness
// meaning different font attributes, but not different fonts sizes
void ImplDevFontListData::UpdateDevFontList( ImplGetDevFontList& rDevFontList ) const
@@ -1202,8 +1125,6 @@ void ImplDevFontListData::UpdateDevFontList( ImplGetDevFontList& rDevFontList )
}
}
-// -----------------------------------------------------------------------
-
void ImplDevFontListData::GetFontHeights( std::set<int>& rHeights ) const
{
// add all available font heights
@@ -1211,8 +1132,6 @@ void ImplDevFontListData::GetFontHeights( std::set<int>& rHeights ) const
rHeights.insert( pFace->GetHeight() );
}
-// -----------------------------------------------------------------------
-
void ImplDevFontListData::UpdateCloneFontList( ImplDevFontList& rDevFontList,
bool bScalable, bool bEmbeddable ) const
{
@@ -1228,8 +1147,6 @@ void ImplDevFontListData::UpdateCloneFontList( ImplDevFontList& rDevFontList,
}
}
-// =======================================================================
-
ImplDevFontList::ImplDevFontList()
: mbMatchData( false )
, mbMapNames( false )
@@ -1239,29 +1156,21 @@ ImplDevFontList::ImplDevFontList()
, mnFallbackCount( -1 )
{}
-// -----------------------------------------------------------------------
-
ImplDevFontList::~ImplDevFontList()
{
Clear();
}
-// -----------------------------------------------------------------------
-
void ImplDevFontList::SetPreMatchHook( ImplPreMatchFontSubstitution* pHook )
{
mpPreMatchHook = pHook;
}
-// -----------------------------------------------------------------------
-
void ImplDevFontList::SetFallbackHook( ImplGlyphFallbackFontSubstitution* pHook )
{
mpFallbackHook = pHook;
}
-// -----------------------------------------------------------------------
-
void ImplDevFontList::Clear()
{
// remove fallback lists
@@ -1283,9 +1192,6 @@ void ImplDevFontList::Clear()
mbMatchData = false;
}
-
-// -----------------------------------------------------------------------
-
void ImplDevFontList::InitGenericGlyphFallback( void ) const
{
// normalized family names of fonts suited for glyph fallback
@@ -1376,8 +1282,6 @@ void ImplDevFontList::InitGenericGlyphFallback( void ) const
mpFallbackList = pFallbackList;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::GetGlyphFallbackFont( FontSelectPattern& rFontSelData,
rtl::OUString& rMissingCodes, int nFallbackLevel ) const
{
@@ -1474,8 +1378,6 @@ ImplDevFontListData* ImplDevFontList::GetGlyphFallbackFont( FontSelectPattern& r
return pFallbackData;
}
-// -----------------------------------------------------------------------
-
void ImplDevFontList::Add( PhysicalFontFace* pNewData )
{
OUString aSearchName = pNewData->GetFamilyName();
@@ -1498,8 +1400,6 @@ void ImplDevFontList::Add( PhysicalFontFace* pNewData )
delete pNewData;
}
-// -----------------------------------------------------------------------
-
// find the font from the normalized font family name
ImplDevFontListData* ImplDevFontList::ImplFindBySearchName( const OUString& rSearchName ) const
{
@@ -1517,8 +1417,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindBySearchName( const OUString& rSea
return pFoundData;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::ImplFindByAliasName(const rtl::OUString& rSearchName,
const rtl::OUString& rShortName) const
{
@@ -1555,8 +1453,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindByAliasName(const rtl::OUString& r
return NULL;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::FindFontFamily( const String& rFontName ) const
{
// normalize the font fomily name and
@@ -1566,8 +1462,6 @@ ImplDevFontListData* ImplDevFontList::FindFontFamily( const String& rFontName )
return pFound;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::ImplFindByTokenNames(const rtl::OUString& rTokenStr) const
{
ImplDevFontListData* pFoundData = NULL;
@@ -1587,8 +1481,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindByTokenNames(const rtl::OUString&
return pFoundData;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::ImplFindBySubstFontAttr( const utl::FontNameAttr& rFontAttr ) const
{
ImplDevFontListData* pFoundData = NULL;
@@ -1622,8 +1514,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindBySubstFontAttr( const utl::FontNa
return NULL;
}
-// -----------------------------------------------------------------------
-
void ImplDevFontList::InitMatchData() const
{
// short circuit if already done
@@ -1644,8 +1534,6 @@ void ImplDevFontList::InitMatchData() const
}
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::ImplFindByAttributes( sal_uLong nSearchType,
FontWeight eSearchWeight, FontWidth eSearchWidth,
FontItalic eSearchItalic, const rtl::OUString& rSearchFamilyName ) const
@@ -2003,8 +1891,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindByAttributes( sal_uLong nSearchTyp
return pFoundData;
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::FindDefaultFont() const
{
// try to find one of the default fonts of the
@@ -2056,8 +1942,6 @@ ImplDevFontListData* ImplDevFontList::FindDefaultFont() const
return pFoundData;
}
-// -----------------------------------------------------------------------
-
ImplDevFontList* ImplDevFontList::Clone( bool bScalable, bool bEmbeddable ) const
{
ImplDevFontList* pClonedList = new ImplDevFontList;
@@ -2079,8 +1963,6 @@ ImplDevFontList* ImplDevFontList::Clone( bool bScalable, bool bEmbeddable ) cons
return pClonedList;
}
-// -----------------------------------------------------------------------
-
ImplGetDevFontList* ImplDevFontList::GetDevFontList() const
{
ImplGetDevFontList* pGetDevFontList = new ImplGetDevFontList;
@@ -2095,8 +1977,6 @@ ImplGetDevFontList* ImplDevFontList::GetDevFontList() const
return pGetDevFontList;
}
-// -----------------------------------------------------------------------
-
ImplGetDevSizeList* ImplDevFontList::GetDevSizeList( const String& rFontName ) const
{
ImplGetDevSizeList* pGetDevSizeList = new ImplGetDevSizeList( rFontName );
@@ -2187,8 +2067,6 @@ void FontSelectPattern::copyAttributes(const FontSelectPatternAttributes &rAttri
static_cast<FontSelectPatternAttributes&>(*this) = rAttributes;
}
-// =======================================================================
-
size_t ImplFontCache::IFSD_Hash::operator()( const FontSelectPattern& rFSD ) const
{
return rFSD.hashCode();
@@ -2258,8 +2136,6 @@ bool FontSelectPatternAttributes::operator==(const FontSelectPatternAttributes&
return true;
}
-// -----------------------------------------------------------------------
-
bool ImplFontCache::IFSD_Equal::operator()(const FontSelectPattern& rA, const FontSelectPattern& rB) const
{
// check normalized font family name
@@ -2317,16 +2193,12 @@ bool ImplFontCache::IFSD_Equal::operator()(const FontSelectPattern& rA, const Fo
return true;
}
-// -----------------------------------------------------------------------
-
ImplFontCache::ImplFontCache( bool bPrinter )
: mpFirstEntry( NULL ),
mnRef0Count( 0 ),
mbPrinter( bPrinter )
{}
-// -----------------------------------------------------------------------
-
ImplFontCache::~ImplFontCache()
{
FontInstanceList::iterator it = maFontInstanceList.begin();
@@ -2337,8 +2209,6 @@ ImplFontCache::~ImplFontCache()
}
}
-// -----------------------------------------------------------------------
-
ImplFontEntry* ImplFontCache::GetFontEntry( ImplDevFontList* pFontList,
const Font& rFont, const Size& rSize, float fExactHeight, ImplDirectFontSubstitution* pDevSpecific )
{
@@ -2349,8 +2219,6 @@ ImplFontEntry* ImplFontCache::GetFontEntry( ImplDevFontList* pFontList,
return GetFontEntry( pFontList, aFontSelData, pDevSpecific );
}
-// -----------------------------------------------------------------------
-
ImplFontEntry* ImplFontCache::GetFontEntry( ImplDevFontList* pFontList,
FontSelectPattern& aFontSelData, ImplDirectFontSubstitution* pDevSpecific )
{
@@ -2484,8 +2352,6 @@ namespace
}
}
-// -----------------------------------------------------------------------
-
ImplDevFontListData* ImplDevFontList::ImplFindByFont( FontSelectPattern& rFSD,
bool bPrinter, ImplDirectFontSubstitution* pDevSpecific ) const
{
@@ -2805,8 +2671,6 @@ ImplDevFontListData* ImplDevFontList::ImplFindByFont( FontSelectPattern& rFSD,
return pFoundData;
}
-// -----------------------------------------------------------------------
-
ImplFontEntry* ImplFontCache::GetGlyphFallbackFont( ImplDevFontList* pFontList,
FontSelectPattern& rFontSelData, int nFallbackLevel, rtl::OUString& rMissingCodes )
{
@@ -2843,8 +2707,6 @@ ImplFontEntry* ImplFontCache::GetGlyphFallbackFont( ImplDevFontList* pFontList,
return pFallbackFont;
}
-// -----------------------------------------------------------------------
-
void ImplFontCache::Release( ImplFontEntry* pEntry )
{
static const int FONTCACHE_MAX = 50;
@@ -2877,8 +2739,6 @@ void ImplFontCache::Release( ImplFontEntry* pEntry )
DBG_ASSERT( (mnRef0Count==0), "ImplFontCache::Release() - refcount0 mismatch" );
}
-// -----------------------------------------------------------------------
-
void ImplFontCache::Invalidate()
{
// delete unreferenced entries
@@ -2900,8 +2760,6 @@ void ImplFontCache::Invalidate()
DBG_ASSERT( (mnRef0Count==0), "ImplFontCache::Invalidate() - mnRef0Count non-zero" );
}
-// =======================================================================
-
ImplMultiTextLineInfo::ImplMultiTextLineInfo()
{
mpLines = new PImplTextLineInfo[MULTITEXTLINEINFO_RESIZE];
@@ -2938,8 +2796,6 @@ void ImplMultiTextLineInfo::Clear()
mnLines = 0;
}
-// =======================================================================
-
FontEmphasisMark OutputDevice::ImplGetEmphasisMarkStyle( const Font& rFont )
{
FontEmphasisMark nEmphasisMark = rFont.GetEmphasisMark();
@@ -2966,8 +2822,6 @@ FontEmphasisMark OutputDevice::ImplGetEmphasisMarkStyle( const Font& rFont )
return nEmphasisMark;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::ImplIsUnderlineAbove( const Font& rFont )
{
if ( !rFont.IsVertical() )
@@ -2981,8 +2835,6 @@ sal_Bool OutputDevice::ImplIsUnderlineAbove( const Font& rFont )
return sal_False;
}
-// =======================================================================
-
void OutputDevice::ImplInitFontList() const
{
if( ! mpFontList->Count() )
@@ -3007,8 +2859,6 @@ void OutputDevice::ImplInitFontList() const
}
}
-// =======================================================================
-
void OutputDevice::ImplInitFont() const
{
DBG_TESTSOLARMUTEX();
@@ -3037,8 +2887,6 @@ void OutputDevice::ImplInitFont() const
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitTextColor()
{
DBG_TESTSOLARMUTEX();
@@ -3050,8 +2898,6 @@ void OutputDevice::ImplInitTextColor()
}
}
-// -----------------------------------------------------------------------
-
bool OutputDevice::ImplNewFont() const
{
DBG_TESTSOLARMUTEX();
@@ -3221,8 +3067,6 @@ bool OutputDevice::ImplNewFont() const
return true;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawTextRect( long nBaseX, long nBaseY,
long nDistX, long nDistY, long nWidth, long nHeight )
{
@@ -3281,8 +3125,6 @@ void OutputDevice::ImplDrawTextRect( long nBaseX, long nBaseY,
mpGraphics->DrawRect( nX, nY, nWidth, nHeight, this );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawTextBackground( const SalLayout& rSalLayout )
{
const long nWidth = rSalLayout.GetTextWidth() / rSalLayout.GetUnitsPerPixel();
@@ -3303,8 +3145,6 @@ void OutputDevice::ImplDrawTextBackground( const SalLayout& rSalLayout )
mpFontEntry->mnLineHeight+mnEmphasisAscent+mnEmphasisDescent );
}
-// -----------------------------------------------------------------------
-
Rectangle OutputDevice::ImplGetTextBoundRect( const SalLayout& rSalLayout )
{
Point aPoint = rSalLayout.GetDrawPosition();
@@ -3341,22 +3181,16 @@ Rectangle OutputDevice::ImplGetTextBoundRect( const SalLayout& rSalLayout )
return Rectangle( Point( nX, nY ), Size( nWidth, nHeight ) );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitTextLineSize()
{
mpFontEntry->maMetric.ImplInitTextLineSize( this );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplInitAboveTextLineSize()
{
mpFontEntry->maMetric.ImplInitAboveTextLineSize();
}
-// -----------------------------------------------------------------------
-
bool ImplFontAttributes::operator==(const ImplFontAttributes& rOther) const
{
if (maName != rOther.maName)
@@ -3386,8 +3220,6 @@ bool ImplFontAttributes::operator==(const ImplFontAttributes& rOther) const
return true;
}
-// -----------------------------------------------------------------------
-
ImplFontMetricData::ImplFontMetricData( const FontSelectPattern& rFontSelData )
: ImplFontAttributes( rFontSelData )
{
@@ -3448,8 +3280,6 @@ ImplFontMetricData::ImplFontMetricData( const FontSelectPattern& rFontSelData )
mnDStrikeoutOffset2 = 0;
}
-// -----------------------------------------------------------------------
-
void ImplFontMetricData::ImplInitTextLineSize( const OutputDevice* pDev )
{
long nDescent = mnDescent;
@@ -3534,8 +3364,6 @@ void ImplFontMetricData::ImplInitTextLineSize( const OutputDevice* pDev )
mnDStrikeoutOffset2 = mnDStrikeoutOffset1 + n2LineDY + n2LineHeight;
}
-// -----------------------------------------------------------------------
-
void ImplFontMetricData::ImplInitAboveTextLineSize()
{
long nIntLeading = mnIntLeading;
@@ -3586,8 +3414,6 @@ void ImplFontMetricData::ImplInitAboveTextLineSize()
mnAboveWUnderlineOffset = nCeiling + (nIntLeading + 1) / 2;
}
-// -----------------------------------------------------------------------
-
static void ImplDrawWavePixel( long nOriginX, long nOriginY,
long nCurX, long nCurY,
short nOrientation,
@@ -3611,8 +3437,6 @@ static void ImplDrawWavePixel( long nOriginX, long nOriginY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY,
long nDistX, long nDistY,
long nWidth, long nHeight,
@@ -3735,8 +3559,6 @@ void OutputDevice::ImplDrawWaveLine( long nBaseX, long nBaseY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawWaveTextLine( long nBaseX, long nBaseY,
long nDistX, long nDistY, long nWidth,
FontUnderline eTextLine,
@@ -3799,8 +3621,6 @@ void OutputDevice::ImplDrawWaveTextLine( long nBaseX, long nBaseY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawStraightTextLine( long nBaseX, long nBaseY,
long nDistX, long nDistY, long nWidth,
FontUnderline eTextLine,
@@ -4031,8 +3851,6 @@ void OutputDevice::ImplDrawStraightTextLine( long nBaseX, long nBaseY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawStrikeoutLine( long nBaseX, long nBaseY,
long nDistX, long nDistY, long nWidth,
FontStrikeout eStrikeout,
@@ -4095,8 +3913,6 @@ void OutputDevice::ImplDrawStrikeoutLine( long nBaseX, long nBaseY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawStrikeoutChar( long nBaseX, long nBaseY,
long nDistX, long nDistY, long nWidth,
FontStrikeout eStrikeout,
@@ -4192,8 +4008,6 @@ void OutputDevice::ImplDrawStrikeoutChar( long nBaseX, long nBaseY,
ImplInitTextColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawTextLine( long nX, long nY,
long nDistX, long nWidth,
FontStrikeout eStrikeout,
@@ -4260,8 +4074,6 @@ void OutputDevice::ImplDrawTextLine( long nX, long nY,
ImplDrawStrikeoutLine( nX, nY, nDistX, 0, nWidth, eStrikeout, aStrikeoutColor );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawTextLines( SalLayout& rSalLayout,
FontStrikeout eStrikeout, FontUnderline eUnderline, FontUnderline eOverline, sal_Bool bWordLine, sal_Bool bUnderlineAbove )
{
@@ -4322,8 +4134,6 @@ void OutputDevice::ImplDrawTextLines( SalLayout& rSalLayout,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawMnemonicLine( long nX, long nY, long nWidth )
{
long nBaseX = nX;
@@ -4339,8 +4149,6 @@ void OutputDevice::ImplDrawMnemonicLine( long nX, long nY, long nWidth )
ImplDrawTextLine( nX, nY, 0, nWidth, STRIKEOUT_NONE, UNDERLINE_SINGLE, UNDERLINE_NONE, sal_False );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplGetEmphasisMark( PolyPolygon& rPolyPoly, sal_Bool& rPolyLine,
Rectangle& rRect1, Rectangle& rRect2,
long& rYOff, long& rWidth,
@@ -4494,8 +4302,6 @@ void OutputDevice::ImplGetEmphasisMark( PolyPolygon& rPolyPoly, sal_Bool& rPolyL
rYOff += nDotSize;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawEmphasisMark( long nBaseX, long nX, long nY,
const PolyPolygon& rPolyPoly, sal_Bool bPolyLine,
const Rectangle& rRect1, const Rectangle& rRect2 )
@@ -4539,8 +4345,6 @@ void OutputDevice::ImplDrawEmphasisMark( long nBaseX, long nX, long nY,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawEmphasisMarks( SalLayout& rSalLayout )
{
Color aOldLineColor = GetLineColor();
@@ -4623,8 +4427,6 @@ void OutputDevice::ImplDrawEmphasisMarks( SalLayout& rSalLayout )
mpMetaFile = pOldMetaFile;
}
-// -----------------------------------------------------------------------
-
bool OutputDevice::ImplDrawRotateText( SalLayout& rSalLayout )
{
int nX = rSalLayout.DrawBase().X();
@@ -4698,8 +4500,6 @@ bool OutputDevice::ImplDrawRotateText( SalLayout& rSalLayout )
return true;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawTextDirect( SalLayout& rSalLayout, sal_Bool bTextLines )
{
if( mpFontEntry->mnOwnOrientation )
@@ -4747,8 +4547,6 @@ void OutputDevice::ImplDrawTextDirect( SalLayout& rSalLayout, sal_Bool bTextLine
ImplDrawEmphasisMarks( rSalLayout );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawSpecialText( SalLayout& rSalLayout )
{
Color aOldColor = GetTextColor();
@@ -4868,8 +4666,6 @@ void OutputDevice::ImplDrawSpecialText( SalLayout& rSalLayout )
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawText( SalLayout& rSalLayout )
{
if( mbInitClipRegion )
@@ -4890,8 +4686,6 @@ void OutputDevice::ImplDrawText( SalLayout& rSalLayout )
ImplDrawTextDirect( rSalLayout, mbTextLines );
}
-// -----------------------------------------------------------------------
-
long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo,
long nWidth, const XubString& rStr,
sal_uInt16 nStyle, const ::vcl::ITextLayout& _rLayout )
@@ -5094,8 +4888,6 @@ long OutputDevice::ImplGetTextLines( ImplMultiTextLineInfo& rLineInfo,
return nMaxLineWidth;
}
-// =======================================================================
-
void OutputDevice::SetAntialiasing( sal_uInt16 nMode )
{
if ( mnAntialiasing != nMode )
@@ -5113,8 +4905,6 @@ void OutputDevice::SetAntialiasing( sal_uInt16 nMode )
mpAlphaVDev->SetAntialiasing( nMode );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetFont( const Font& rNewFont )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5224,8 +5014,6 @@ void OutputDevice::SetFont( const Font& rNewFont )
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetLayoutMode( sal_uLong nTextLayoutMode )
{
if( mpMetaFile )
@@ -5237,8 +5025,6 @@ void OutputDevice::SetLayoutMode( sal_uLong nTextLayoutMode )
mpAlphaVDev->SetLayoutMode( nTextLayoutMode );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetDigitLanguage( LanguageType eTextLanguage )
{
if( mpMetaFile )
@@ -5250,8 +5036,6 @@ void OutputDevice::SetDigitLanguage( LanguageType eTextLanguage )
mpAlphaVDev->SetDigitLanguage( eTextLanguage );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetTextColor( const Color& rColor )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5295,8 +5079,6 @@ void OutputDevice::SetTextColor( const Color& rColor )
mpAlphaVDev->SetTextColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetTextFillColor()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5313,8 +5095,6 @@ void OutputDevice::SetTextFillColor()
mpAlphaVDev->SetTextFillColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetTextFillColor( const Color& rColor )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5366,8 +5146,6 @@ void OutputDevice::SetTextFillColor( const Color& rColor )
mpAlphaVDev->SetTextFillColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
Color OutputDevice::GetTextFillColor() const
{
if ( maFont.IsTransparent() )
@@ -5376,8 +5154,6 @@ Color OutputDevice::GetTextFillColor() const
return maFont.GetFillColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetTextLineColor()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5391,8 +5167,6 @@ void OutputDevice::SetTextLineColor()
mpAlphaVDev->SetTextLineColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetTextLineColor( const Color& rColor )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5433,8 +5207,6 @@ void OutputDevice::SetTextLineColor( const Color& rColor )
mpAlphaVDev->SetTextLineColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetOverlineColor()
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5448,8 +5220,6 @@ void OutputDevice::SetOverlineColor()
mpAlphaVDev->SetOverlineColor();
}
-// -----------------------------------------------------------------------
-
void OutputDevice::SetOverlineColor( const Color& rColor )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5490,9 +5260,6 @@ void OutputDevice::SetOverlineColor( const Color& rColor )
mpAlphaVDev->SetOverlineColor( COL_BLACK );
}
-// -----------------------------------------------------------------------
-
-
void OutputDevice::SetTextAlign( TextAlign eAlign )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5510,8 +5277,6 @@ void OutputDevice::SetTextAlign( TextAlign eAlign )
mpAlphaVDev->SetTextAlign( eAlign );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawTextLine( const Point& rPos, long nWidth,
FontStrikeout eStrikeout,
FontUnderline eUnderline,
@@ -5556,8 +5321,6 @@ void OutputDevice::DrawTextLine( const Point& rPos, long nWidth,
mpAlphaVDev->DrawTextLine( rPos, nWidth, eStrikeout, eUnderline, eOverline, bUnderlineAbove );
}
-// ------------------------------------------------------------------------
-
void OutputDevice::DrawWaveLine( const Point& rStartPos, const Point& rEndPos,
sal_uInt16 nStyle )
{
@@ -5626,8 +5389,6 @@ void OutputDevice::DrawWaveLine( const Point& rStartPos, const Point& rEndPos,
mpAlphaVDev->DrawWaveLine( rStartPos, rEndPos, nStyle );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawText( const Point& rStartPt, const String& rStr,
xub_StrLen nIndex, xub_StrLen nLen,
MetricVector* pVector, OUString* pDisplayText
@@ -5709,8 +5470,6 @@ void OutputDevice::DrawText( const Point& rStartPt, const String& rStr,
mpAlphaVDev->DrawText( rStartPt, rStr, nIndex, nLen, pVector, pDisplayText );
}
-// -----------------------------------------------------------------------
-
long OutputDevice::GetTextWidth( const String& rStr,
xub_StrLen nIndex, xub_StrLen nLen ) const
{
@@ -5720,8 +5479,6 @@ long OutputDevice::GetTextWidth( const String& rStr,
return nWidth;
}
-// -----------------------------------------------------------------------
-
long OutputDevice::GetTextHeight() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -5746,8 +5503,6 @@ float OutputDevice::approximate_char_width() const
return GetTextWidth(rtl::OUString("aemnnxEM")) / 8.0;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawTextArray( const Point& rStartPt, const String& rStr,
const sal_Int32* pDXAry,
xub_StrLen nIndex, xub_StrLen nLen )
@@ -5777,8 +5532,6 @@ void OutputDevice::DrawTextArray( const Point& rStartPt, const String& rStr,
mpAlphaVDev->DrawTextArray( rStartPt, rStr, pDXAry, nIndex, nLen );
}
-// -----------------------------------------------------------------------
-
long OutputDevice::GetTextArray( const String& rStr, sal_Int32* pDXAry,
xub_StrLen nIndex, xub_StrLen nLen ) const
{
@@ -5823,8 +5576,6 @@ long OutputDevice::GetTextArray( const String& rStr, sal_Int32* pDXAry,
return nWidth;
}
-// -----------------------------------------------------------------------
-
bool OutputDevice::GetCaretPositions( const XubString& rStr, sal_Int32* pCaretXArray,
xub_StrLen nIndex, xub_StrLen nLen,
sal_Int32* pDXAry, long nLayoutWidth,
@@ -5891,8 +5642,6 @@ bool OutputDevice::GetCaretPositions( const XubString& rStr, sal_Int32* pCaretXA
return true;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawStretchText( const Point& rStartPt, sal_uLong nWidth,
const String& rStr,
xub_StrLen nIndex, xub_StrLen nLen )
@@ -5916,8 +5665,6 @@ void OutputDevice::DrawStretchText( const Point& rStartPt, sal_uLong nWidth,
mpAlphaVDev->DrawStretchText( rStartPt, nWidth, rStr, nIndex, nLen );
}
-// -----------------------------------------------------------------------
-
ImplLayoutArgs OutputDevice::ImplPrepareLayoutArgs( String& rStr,
xub_StrLen nMinIndex, xub_StrLen nLen,
long nPixelWidth, const sal_Int32* pDXArray ) const
@@ -6028,8 +5775,6 @@ ImplLayoutArgs OutputDevice::ImplPrepareLayoutArgs( String& rStr,
return aLayoutArgs;
}
-// -----------------------------------------------------------------------
-
SalLayout* OutputDevice::ImplLayout( const String& rOrigStr,
xub_StrLen nMinIndex,
xub_StrLen nLen,
@@ -6238,8 +5983,6 @@ SalLayout* OutputDevice::getFallbackFontThatFits(ImplFontEntry &rFallbackFont,
return pFallback;
}
-// -----------------------------------------------------------------------
-
SalLayout* OutputDevice::ImplGlyphFallbackLayout( SalLayout* pSalLayout, ImplLayoutArgs& rLayoutArgs ) const
{
// prepare multi level glyph fallback
@@ -6326,8 +6069,6 @@ SalLayout* OutputDevice::ImplGlyphFallbackLayout( SalLayout* pSalLayout, ImplLay
return pSalLayout;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetTextIsRTL(
const String& rString,
xub_StrLen nIndex, xub_StrLen nLen ) const
@@ -6340,8 +6081,6 @@ sal_Bool OutputDevice::GetTextIsRTL(
return (nCharPos != nIndex) ? sal_True : sal_False;
}
-// -----------------------------------------------------------------------
-
xub_StrLen OutputDevice::GetTextBreak( const String& rStr, long nTextWidth,
xub_StrLen nIndex, xub_StrLen nLen,
long nCharExtra, sal_Bool /*TODO: bCellBreaking*/ ) const
@@ -6374,8 +6113,6 @@ xub_StrLen OutputDevice::GetTextBreak( const String& rStr, long nTextWidth,
return nRetVal;
}
-// -----------------------------------------------------------------------
-
xub_StrLen OutputDevice::GetTextBreak( const String& rStr, long nTextWidth,
sal_Unicode nHyphenatorChar, xub_StrLen& rHyphenatorPos,
xub_StrLen nIndex, xub_StrLen nLen,
@@ -6433,8 +6170,6 @@ xub_StrLen OutputDevice::GetTextBreak( const String& rStr, long nTextWidth,
return nRetVal;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawText( OutputDevice& rTargetDevice, const Rectangle& rRect,
const String& rOrigStr, sal_uInt16 nStyle,
MetricVector* pVector, OUString* pDisplayText,
@@ -6705,8 +6440,6 @@ void OutputDevice::ImplDrawText( OutputDevice& rTargetDevice, const Rectangle& r
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::AddTextRectActions( const Rectangle& rRect,
const String& rOrigStr,
sal_uInt16 nStyle,
@@ -6741,8 +6474,6 @@ void OutputDevice::AddTextRectActions( const Rectangle& rRect,
mpMetaFile = pMtf;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawText( const Rectangle& rRect, const String& rOrigStr, sal_uInt16 nStyle,
MetricVector* pVector, OUString* pDisplayText,
::vcl::ITextLayout* _pTextLayout )
@@ -6788,8 +6519,6 @@ void OutputDevice::DrawText( const Rectangle& rRect, const String& rOrigStr, sal
mpAlphaVDev->DrawText( rRect, rOrigStr, nStyle, pVector, pDisplayText );
}
-// -----------------------------------------------------------------------
-
Rectangle OutputDevice::GetTextRect( const Rectangle& rRect,
const XubString& rStr, sal_uInt16 nStyle,
TextRectInfo* pInfo,
@@ -6908,8 +6637,6 @@ Rectangle OutputDevice::GetTextRect( const Rectangle& rRect,
return aRect;
}
-// -----------------------------------------------------------------------
-
static sal_Bool ImplIsCharIn( sal_Unicode c, const sal_Char* pStr )
{
while ( *pStr )
@@ -6922,8 +6649,6 @@ static sal_Bool ImplIsCharIn( sal_Unicode c, const sal_Char* pStr )
return sal_False;
}
-// -----------------------------------------------------------------------
-
OUString OutputDevice::GetEllipsisString( const String& rOrigStr, long nMaxWidth,
sal_uInt16 nStyle ) const
{
@@ -6932,8 +6657,6 @@ OUString OutputDevice::GetEllipsisString( const String& rOrigStr, long nMaxWidth
return ImplGetEllipsisString( *this, rOrigStr, nMaxWidth, nStyle, aTextLayout );
}
-// -----------------------------------------------------------------------
-
String OutputDevice::ImplGetEllipsisString( const OutputDevice& rTargetDevice, const XubString& rOrigStr, long nMaxWidth,
sal_uInt16 nStyle, const ::vcl::ITextLayout& _rLayout )
{
@@ -7062,8 +6785,6 @@ String OutputDevice::ImplGetEllipsisString( const OutputDevice& rTargetDevice, c
return aStr;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawCtrlText( const Point& rPos, const XubString& rStr,
xub_StrLen nIndex, xub_StrLen nLen,
sal_uInt16 nStyle, MetricVector* pVector, OUString* pDisplayText )
@@ -7194,8 +6915,6 @@ void OutputDevice::DrawCtrlText( const Point& rPos, const XubString& rStr,
mpAlphaVDev->DrawCtrlText( rPos, rStr, nIndex, nLen, nStyle, pVector, pDisplayText );
}
-// -----------------------------------------------------------------------
-
long OutputDevice::GetCtrlTextWidth( const String& rStr,
xub_StrLen nIndex, xub_StrLen nLen,
sal_uInt16 nStyle ) const
@@ -7220,8 +6939,6 @@ long OutputDevice::GetCtrlTextWidth( const String& rStr,
return GetTextWidth( rStr, nIndex, nLen );
}
-// -----------------------------------------------------------------------
-
String OutputDevice::GetNonMnemonicString( const String& rStr, xub_StrLen& rMnemonicPos )
{
String aStr = rStr;
@@ -7254,8 +6971,6 @@ String OutputDevice::GetNonMnemonicString( const String& rStr, xub_StrLen& rMnem
return aStr;
}
-// -----------------------------------------------------------------------
-
int OutputDevice::GetDevFontCount() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7265,8 +6980,6 @@ int OutputDevice::GetDevFontCount() const
return mpGetDevFontList->Count();
}
-// -----------------------------------------------------------------------
-
FontInfo OutputDevice::GetDevFont( int nDevFontIndex ) const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7296,8 +7009,6 @@ FontInfo OutputDevice::GetDevFont( int nDevFontIndex ) const
return aFontInfo;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::AddTempDevFont( const String& rFileURL, const String& rFontName )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7318,8 +7029,6 @@ sal_Bool OutputDevice::AddTempDevFont( const String& rFileURL, const String& rFo
return sal_True;
}
-// -----------------------------------------------------------------------
-
int OutputDevice::GetDevFontSizeCount( const Font& rFont ) const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7331,8 +7040,6 @@ int OutputDevice::GetDevFontSizeCount( const Font& rFont ) const
return mpGetDevSizeList->Count();
}
-// -----------------------------------------------------------------------
-
Size OutputDevice::GetDevFontSize( const Font& rFont, int nSizeIndex ) const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7365,8 +7072,6 @@ Size OutputDevice::GetDevFontSize( const Font& rFont, int nSizeIndex ) const
return aSize;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::IsFontAvailable( const String& rFontName ) const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7375,8 +7080,6 @@ sal_Bool OutputDevice::IsFontAvailable( const String& rFontName ) const
return (pFound != NULL);
}
-// -----------------------------------------------------------------------
-
FontMetric OutputDevice::GetFontMetric() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7431,8 +7134,6 @@ FontMetric OutputDevice::GetFontMetric() const
return aMetric;
}
-// -----------------------------------------------------------------------
-
FontMetric OutputDevice::GetFontMetric( const Font& rFont ) const
{
// select font, query metrics, select original font again
@@ -7443,8 +7144,6 @@ FontMetric OutputDevice::GetFontMetric( const Font& rFont ) const
return aMetric;
}
-// -----------------------------------------------------------------------
-
/** OutputDevice::GetSysFontData
*
* @param nFallbacklevel Fallback font level (0 = best matching font)
@@ -7464,9 +7163,6 @@ SystemFontData OutputDevice::GetSysFontData(int nFallbacklevel) const
return aSysFontData;
}
-
-// -----------------------------------------------------------------------
-
/** OutputDevice::GetSysTextLayoutData
*
* @param rStartPt Start point of the text
@@ -7531,9 +7227,6 @@ SystemTextLayoutData OutputDevice::GetSysTextLayoutData(const Point& rStartPt, c
return aSysLayoutData;
}
-// -----------------------------------------------------------------------
-
-
long OutputDevice::GetMinKashida() const
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -7545,7 +7238,6 @@ long OutputDevice::GetMinKashida() const
return ImplDevicePixelToLogicWidth( pMetric->mnMinKashida );
}
-// -----------------------------------------------------------------------
xub_StrLen OutputDevice::ValidateKashidas ( const String& rTxt,
xub_StrLen nIdx, xub_StrLen nLen,
xub_StrLen nKashCount,
@@ -7569,8 +7261,6 @@ xub_StrLen OutputDevice::ValidateKashidas ( const String& rTxt,
return nDropped;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetGlyphBoundRects( const Point& rOrigin, const String& rStr,
int nIndex, int nLen, int nBase, MetricVector& rVector )
{
@@ -7593,8 +7283,6 @@ sal_Bool OutputDevice::GetGlyphBoundRects( const Point& rOrigin, const String& r
return (nLen == (int)rVector.size());
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetTextBoundRect( Rectangle& rRect,
const String& rStr, xub_StrLen nBase, xub_StrLen nIndex, xub_StrLen nLen,
sal_uLong nLayoutWidth, const sal_Int32* pDXAry ) const
@@ -7770,8 +7458,6 @@ sal_Bool OutputDevice::GetTextBoundRect( Rectangle& rRect,
return sal_False;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetTextOutlines( ::basegfx::B2DPolyPolygonVector& rVector,
const String& rStr, xub_StrLen nBase, xub_StrLen nIndex, xub_StrLen nLen,
sal_Bool bOptimize, sal_uLong nTWidth, const sal_Int32* pDXArray ) const
@@ -7999,8 +7685,6 @@ sal_Bool OutputDevice::GetTextOutlines( ::basegfx::B2DPolyPolygonVector& rVector
return bRet;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetTextOutlines( PolyPolyVector& rResultVector,
const String& rStr, xub_StrLen nBase, xub_StrLen nIndex,
xub_StrLen nLen, sal_Bool bOptimize, sal_uLong nTWidth, const sal_Int32* pDXArray ) const
@@ -8022,8 +7706,6 @@ sal_Bool OutputDevice::GetTextOutlines( PolyPolyVector& rResultVector,
return sal_True;
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetTextOutline( PolyPolygon& rPolyPoly,
const String& rStr, xub_StrLen nBase, xub_StrLen nIndex, xub_StrLen nLen,
sal_Bool bOptimize, sal_uLong nTWidth, const sal_Int32* pDXArray ) const
@@ -8061,8 +7743,6 @@ bool OutputDevice::GetFontCapabilities( FontCapabilities& rFontCapabilities ) co
return mpGraphics->GetImplFontCapabilities(rFontCapabilities);
}
-// -----------------------------------------------------------------------
-
sal_Bool OutputDevice::GetFontCharMap( FontCharMap& rFontCharMap ) const
{
rFontCharMap.Reset();
@@ -8120,8 +7800,6 @@ sal_Bool OutputDevice::GetFontCharMap( FontCharMap& rFontCharMap ) const
return sal_True;
}
-// -----------------------------------------------------------------------
-
xub_StrLen OutputDevice::HasGlyphs( const Font& rTempFont, const String& rStr,
xub_StrLen nIndex, xub_StrLen nLen ) const
{
@@ -8153,6 +7831,4 @@ xub_StrLen OutputDevice::HasGlyphs( const Font& rTempFont, const String& rStr,
return STRING_LEN;
}
-// -----------------------------------------------------------------------
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/source/gdi/outdev4.cxx b/vcl/source/gdi/outdev4.cxx
index f487e808442f..fa4a667fd8c3 100644
--- a/vcl/source/gdi/outdev4.cxx
+++ b/vcl/source/gdi/outdev4.cxx
@@ -43,17 +43,9 @@
#include <basegfx/polygon/b2dpolypolygon.hxx>
#include <basegfx/matrix/b2dhommatrix.hxx>
-// -----------
-// - Defines -
-// -----------
-
#define HATCH_MAXPOINTS 1024
#define GRADIENT_DEFAULT_STEPCOUNT 0
-// ----------------
-// - Cmp-Function -
-// ----------------
-
extern "C" int SAL_CALL ImplHatchCmpFnc( const void* p1, const void* p2 )
{
const long nX1 = ( (Point*) p1 )->X();
@@ -64,13 +56,9 @@ extern "C" int SAL_CALL ImplHatchCmpFnc( const void* p1, const void* p2 )
return ( nX1 > nX2 ? 1 : nX1 == nX2 ? nY1 > nY2 ? 1: nY1 == nY2 ? 0 : -1 : -1 );
}
-// =======================================================================
-
DBG_NAMEEX( OutputDevice )
DBG_NAMEEX( Gradient )
-// =======================================================================
-
void OutputDevice::ImplDrawPolygon( const Polygon& rPoly, const PolyPolygon* pClipPolyPoly )
{
if( pClipPolyPoly )
@@ -87,8 +75,6 @@ void OutputDevice::ImplDrawPolygon( const Polygon& rPoly, const PolyPolygon* pCl
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawPolyPolygon( const PolyPolygon& rPolyPoly, const PolyPolygon* pClipPolyPoly )
{
PolyPolygon* pPolyPoly;
@@ -146,8 +132,6 @@ void OutputDevice::ImplDrawPolyPolygon( const PolyPolygon& rPolyPoly, const Poly
delete pPolyPoly;
}
-// -----------------------------------------------------------------------
-
inline sal_uInt8 ImplGetGradientColorValue( long nValue )
{
if ( nValue < 0 )
@@ -158,8 +142,6 @@ inline sal_uInt8 ImplGetGradientColorValue( long nValue )
return (sal_uInt8)nValue;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawLinearGradient( const Rectangle& rRect,
const Gradient& rGradient,
sal_Bool bMtf, const PolyPolygon* pClipPolyPoly )
@@ -400,8 +382,6 @@ void OutputDevice::ImplDrawLinearGradient( const Rectangle& rRect,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawComplexGradient( const Rectangle& rRect,
const Gradient& rGradient,
sal_Bool bMtf, const PolyPolygon* pClipPolyPoly )
@@ -614,8 +594,6 @@ void OutputDevice::ImplDrawComplexGradient( const Rectangle& rRect,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawGradient( const Rectangle& rRect,
const Gradient& rGradient )
{
@@ -744,8 +722,6 @@ void OutputDevice::DrawGradient( const Rectangle& rRect,
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawGradient( const PolyPolygon& rPolyPoly,
const Gradient& rGradient )
{
@@ -967,8 +943,6 @@ void OutputDevice::DrawGradient( const PolyPolygon& rPolyPoly,
mpAlphaVDev->DrawPolyPolygon( rPolyPoly );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::AddGradientActions( const Rectangle& rRect, const Gradient& rGradient,
GDIMetaFile& rMtf )
{
@@ -1011,8 +985,6 @@ void OutputDevice::AddGradientActions( const Rectangle& rRect, const Gradient& r
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::DrawHatch( const PolyPolygon& rPolyPoly, const Hatch& rHatch )
{
DBG_CHKTHIS( OutputDevice, ImplDbgCheckOutputDevice );
@@ -1088,8 +1060,6 @@ void OutputDevice::DrawHatch( const PolyPolygon& rPolyPoly, const Hatch& rHatch
mpAlphaVDev->DrawHatch( rPolyPoly, rHatch );
}
-// -----------------------------------------------------------------------
-
void OutputDevice::AddHatchActions( const PolyPolygon& rPolyPoly, const Hatch& rHatch,
GDIMetaFile& rMtf )
{
@@ -1111,8 +1081,6 @@ void OutputDevice::AddHatchActions( const PolyPolygon& rPolyPoly, const Hatch& r
}
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplDrawHatch( const PolyPolygon& rPolyPoly, const Hatch& rHatch, sal_Bool bMtf )
{
Rectangle aRect( rPolyPoly.GetBoundRect() );
@@ -1162,8 +1130,6 @@ void OutputDevice::ImplDrawHatch( const PolyPolygon& rPolyPoly, const Hatch& rHa
delete[] pPtBuffer;
}
-// -----------------------------------------------------------------------
-
void OutputDevice::ImplCalcHatchValues( const Rectangle& rRect, long nDist, sal_uInt16 nAngle10,
Point& rPt1, Point& rPt2, Size& rInc, Point& rEndPt1 )
{
@@ -1272,8 +1238,6 @@ void OutputDevice::ImplCalcHatchValues( const Rectangle& rRect, long nDist, sal_
}
}
-// ------------------------------------------------------------------------
-
void OutputDevice::ImplDrawHatchLine( const Line& rLine, const PolyPolygon& rPolyPoly,
Point* pPtBuffer, sal_Bool bMtf )
{
diff --git a/vcl/source/gdi/pngread.cxx b/vcl/source/gdi/pngread.cxx
index bafafd56cd0b..f1ae86514a3a 100644
--- a/vcl/source/gdi/pngread.cxx
+++ b/vcl/source/gdi/pngread.cxx
@@ -30,10 +30,6 @@
#include <vcl/alpha.hxx>
#include <osl/endian.h>
-// -----------
-// - Defines -
-// -----------
-
#define PNGCHUNK_IHDR 0x49484452
#define PNGCHUNK_PLTE 0x504c5445
#define PNGCHUNK_IDAT 0x49444154
@@ -48,11 +44,6 @@
namespace vcl
{
-// -----------
-// - statics -
-// -----------
-
-// ------------------------------------------------------------------------------
static const sal_uInt8 mpDefaultColorTable[ 256 ] =
{ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
@@ -73,10 +64,6 @@ static const sal_uInt8 mpDefaultColorTable[ 256 ] =
0xf0, 0xf1, 0xf2, 0xf3, 0xf4, 0xf5, 0xf6, 0xf7, 0xf8, 0xf9, 0xfa, 0xfb, 0xfc, 0xfd, 0xfe, 0xff
};
-// -------------
-// - PNGReaderImpl -
-// -------------
-
class PNGReaderImpl
{
private:
@@ -167,8 +154,6 @@ public:
void SetIgnoreGammaChunk( sal_Bool bIgnore ){ mbIgnoreGammaChunk = bIgnore; };
};
-// ------------------------------------------------------------------------------
-
PNGReaderImpl::PNGReaderImpl( SvStream& rPNGStream )
: mrPNGStream( rPNGStream ),
mpBmp ( NULL ),
@@ -216,8 +201,6 @@ PNGReaderImpl::PNGReaderImpl( SvStream& rPNGStream )
mnPreviewMask = (1 << mnPreviewShift) - 1;
}
-// ------------------------------------------------------------------------
-
PNGReaderImpl::~PNGReaderImpl()
{
mrPNGStream.SetNumberFormatInt( mnOrigStreamMode );
@@ -237,8 +220,6 @@ PNGReaderImpl::~PNGReaderImpl()
delete mpZCodec;
}
-// ------------------------------------------------------------------------
-
bool PNGReaderImpl::ReadNextChunk()
{
if( maChunkIter == maChunkSeq.end() )
@@ -304,24 +285,18 @@ bool PNGReaderImpl::ReadNextChunk()
return true;
}
-// ------------------------------------------------------------------------
-
// read the remaining chunks from mrPNGStream
void PNGReaderImpl::ReadRemainingChunks()
{
while( ReadNextChunk() ) ;
}
-// ------------------------------------------------------------------------
-
const std::vector< vcl::PNGReader::ChunkData >& PNGReaderImpl::GetAllChunks()
{
ReadRemainingChunks();
return maChunkSeq;
}
-// ------------------------------------------------------------------------
-
BitmapEx PNGReaderImpl::GetBitmapEx( const Size& rPreviewSizeHint )
{
// reset to the first chunk
@@ -448,8 +423,6 @@ BitmapEx PNGReaderImpl::GetBitmapEx( const Size& rPreviewSizeHint )
return aRet;
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGReaderImpl::ImplReadHeader( const Size& rPreviewSizeHint )
{
if( mnChunkLen < 13 )
@@ -676,8 +649,6 @@ sal_Bool PNGReaderImpl::ImplReadHeader( const Size& rPreviewSizeHint )
return sal_True;
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplGetGrayPalette( sal_uInt16 nBitDepth )
{
if( nBitDepth > 8 )
@@ -697,8 +668,6 @@ void PNGReaderImpl::ImplGetGrayPalette( sal_uInt16 nBitDepth )
mpColorTable[ nStart ], mpColorTable[ nStart ] ) );
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGReaderImpl::ImplReadPalette()
{
sal_uInt16 nCount = static_cast<sal_uInt16>( mnChunkLen / 3 );
@@ -722,8 +691,6 @@ sal_Bool PNGReaderImpl::ImplReadPalette()
return mbStatus;
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGReaderImpl::ImplReadTransparent()
{
bool bNeedAlpha = false;
@@ -803,8 +770,6 @@ sal_Bool PNGReaderImpl::ImplReadTransparent()
return sal_True;
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplGetGamma()
{
if( mnChunkLen < 4 )
@@ -829,8 +794,6 @@ void PNGReaderImpl::ImplGetGamma()
}
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplGetBackground()
{
switch ( mnColorType )
@@ -877,8 +840,6 @@ void PNGReaderImpl::ImplGetBackground()
}
}
-// ------------------------------------------------------------------------
-
// for color type 0 and 4 (greyscale) the return value is always index to the color
// 2 and 6 (RGB) the return value is always the 8 bit color component
sal_uInt8 PNGReaderImpl::ImplScaleColor()
@@ -894,7 +855,6 @@ sal_uInt8 PNGReaderImpl::ImplScaleColor()
return (sal_uInt8) nCol;
}
-// ------------------------------------------------------------------------
// ImplReadIDAT reads as much image data as needed
void PNGReaderImpl::ImplReadIDAT()
@@ -951,8 +911,6 @@ void PNGReaderImpl::ImplReadIDAT()
}
}
-// ---------------------------------------------------------------------------------------------------
-
bool PNGReaderImpl::ImplPreparePass()
{
struct InterlaceParams{ int mnXStart, mnYStart, mnXAdd, mnYAdd; };
@@ -1015,7 +973,6 @@ bool PNGReaderImpl::ImplPreparePass()
return true;
}
-// ----------------------------------------------------------------------------
// ImplApplyFilter writes the complete Scanline (nY)
// in interlace mode the parameter nXStart and nXAdd are non-zero
@@ -1122,7 +1079,6 @@ void PNGReaderImpl::ImplApplyFilter()
memcpy( mpScanPrior, mpInflateInBuf, mnScansize );
}
-// ---------------------------------------------------------------------------------------------------
// ImplDrawScanlines draws the complete Scanline (nY) into the target bitmap
// In interlace mode the parameter nXStart and nXAdd append to the currently used pass
@@ -1436,8 +1392,6 @@ void PNGReaderImpl::ImplDrawScanline( sal_uInt32 nXStart, sal_uInt32 nXAdd )
}
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplSetPixel( sal_uInt32 nY, sal_uInt32 nX, const BitmapColor& rBitmapColor )
{
// TODO: get preview mode checks out of inner loop
@@ -1448,8 +1402,6 @@ void PNGReaderImpl::ImplSetPixel( sal_uInt32 nY, sal_uInt32 nX, const BitmapColo
mpAcc->SetPixel( nY, nX, rBitmapColor );
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplSetPixel( sal_uInt32 nY, sal_uInt32 nX, sal_uInt8 nPalIndex )
{
// TODO: get preview mode checks out of inner loop
@@ -1460,8 +1412,6 @@ void PNGReaderImpl::ImplSetPixel( sal_uInt32 nY, sal_uInt32 nX, sal_uInt8 nPalIn
mpAcc->SetPixel( nY, nX, nPalIndex );
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplSetTranspPixel( sal_uInt32 nY, sal_uInt32 nX, const BitmapColor& rBitmapColor, sal_Bool bTrans )
{
// TODO: get preview mode checks out of inner loop
@@ -1477,8 +1427,6 @@ void PNGReaderImpl::ImplSetTranspPixel( sal_uInt32 nY, sal_uInt32 nX, const Bitm
mpMaskAcc->SetPixel( nY, nX, mcOpaqueColor );
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplSetAlphaPixel( sal_uInt32 nY, sal_uInt32 nX,
sal_uInt8 nPalIndex, sal_uInt8 nAlpha )
{
@@ -1491,8 +1439,6 @@ void PNGReaderImpl::ImplSetAlphaPixel( sal_uInt32 nY, sal_uInt32 nX,
mpMaskAcc->SetPixel( nY, nX, ~nAlpha );
}
-// ------------------------------------------------------------------------
-
void PNGReaderImpl::ImplSetAlphaPixel( sal_uInt32 nY, sal_uInt32 nX,
const BitmapColor& rBitmapColor, sal_uInt8 nAlpha )
{
@@ -1505,8 +1451,6 @@ void PNGReaderImpl::ImplSetAlphaPixel( sal_uInt32 nY, sal_uInt32 nX,
mpMaskAcc->SetPixel( nY, nX, ~nAlpha );
}
-// ------------------------------------------------------------------------
-
sal_uInt32 PNGReaderImpl::ImplReadsal_uInt32()
{
sal_uInt32 nRet;
@@ -1520,40 +1464,26 @@ sal_uInt32 PNGReaderImpl::ImplReadsal_uInt32()
return nRet;
}
-// ------------------------------------------------------------------------
-
-// -------------
-// - PNGReader -
-// -------------
-
PNGReader::PNGReader( SvStream& rIStm ) :
mpImpl( new ::vcl::PNGReaderImpl( rIStm ) )
{
}
-// ------------------------------------------------------------------------
-
PNGReader::~PNGReader()
{
delete mpImpl;
}
-// ------------------------------------------------------------------------
-
BitmapEx PNGReader::Read( const Size& i_rPreviewSizeHint )
{
return mpImpl->GetBitmapEx( i_rPreviewSizeHint );
}
-// ------------------------------------------------------------------------
-
const std::vector< vcl::PNGReader::ChunkData >& PNGReader::GetChunks() const
{
return mpImpl->GetAllChunks();
}
-// ------------------------------------------------------------------------
-
void PNGReader::SetIgnoreGammaChunk( sal_Bool b )
{
mpImpl->SetIgnoreGammaChunk( b );
diff --git a/vcl/source/gdi/pngwrite.cxx b/vcl/source/gdi/pngwrite.cxx
index 501e7d5214dc..8d204efd5445 100644
--- a/vcl/source/gdi/pngwrite.cxx
+++ b/vcl/source/gdi/pngwrite.cxx
@@ -31,10 +31,6 @@
#include <vcl/alpha.hxx>
#include <osl/endian.h>
-// -----------
-// - Defines -
-// -----------
-
#define PNG_DEF_COMPRESSION 6
#define PNGCHUNK_IHDR 0x49484452
@@ -48,9 +44,6 @@
namespace vcl
{
-// -----------------
-// - PNGWriterImplImpl -
-// -----------------
class PNGWriterImpl
{
@@ -103,8 +96,6 @@ private:
void ImplCloseChunk( void ) const;
};
-// ------------------------------------------------------------------------
-
PNGWriterImpl::PNGWriterImpl( const BitmapEx& rBmpEx,
const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >* pFilterData ) :
mnCompLevel ( PNG_DEF_COMPRESSION ),
@@ -239,15 +230,11 @@ PNGWriterImpl::PNGWriterImpl( const BitmapEx& rBmpEx,
}
}
-// ------------------------------------------------------------------------
-
PNGWriterImpl::~PNGWriterImpl()
{
delete mpZCodec;
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGWriterImpl::Write( SvStream& rOStm )
{
/* png signature is always an array of 8 bytes */
@@ -279,15 +266,11 @@ sal_Bool PNGWriterImpl::Write( SvStream& rOStm )
return mbStatus;
}
-// ------------------------------------------------------------------------
-
std::vector< vcl::PNGWriter::ChunkData >& PNGWriterImpl::GetChunks()
{
return maChunkSeq;
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGWriterImpl::ImplWriteHeader()
{
ImplOpenChunk(PNGCHUNK_IHDR);
@@ -324,8 +307,6 @@ sal_Bool PNGWriterImpl::ImplWriteHeader()
return mbStatus;
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplWritePalette()
{
const sal_uLong nCount = mpAccess->GetPaletteEntryCount();
@@ -346,8 +327,6 @@ void PNGWriterImpl::ImplWritePalette()
delete[] pTempBuf;
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplWriteTransparent ()
{
const sal_uLong nTransIndex = mpAccess->GetBestMatchingColor( BMP_COL_TRANS );
@@ -360,8 +339,6 @@ void PNGWriterImpl::ImplWriteTransparent ()
ImplCloseChunk();
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplWritepHYs( const BitmapEx& rBmpEx )
{
if ( rBmpEx.GetPrefMapMode() == MAP_100TH_MM )
@@ -381,8 +358,6 @@ void PNGWriterImpl::ImplWritepHYs( const BitmapEx& rBmpEx )
}
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplWriteIDAT ()
{
mnDeflateInSize = mnBitsPerPixel;
@@ -472,7 +447,6 @@ void PNGWriterImpl::ImplWriteIDAT ()
}
}
-// ---------------------------------------------------------------------------------------------------
// ImplGetFilter writes the complete Scanline (nY) - in interlace mode the parameter nXStart and nXAdd
// appends to the currently used pass
// the complete size of scanline will be returned - in interlace mode zero is possible!
@@ -633,24 +607,18 @@ sal_uLong PNGWriterImpl::ImplGetFilter ( sal_uLong nY, sal_uLong nXStart, sal_uL
return ( mnDeflateInSize );
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplClearFirstScanline()
{
if ( mnFilterType )
memset( mpPreviousScan, 0, mnDeflateInSize );
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplOpenChunk ( sal_uLong nChunkType )
{
maChunkSeq.resize( maChunkSeq.size() + 1 );
maChunkSeq.back().nType = nChunkType;
}
-// ------------------------------------------------------------------------
-
void PNGWriterImpl::ImplWriteChunk ( sal_uInt8 nSource )
{
maChunkSeq.back().aData.push_back( nSource );
@@ -676,38 +644,27 @@ void PNGWriterImpl::ImplWriteChunk ( unsigned char* pSource, sal_uInt32 nDatSize
}
}
-// ------------------------------------------------------------------------
// nothing to do
void PNGWriterImpl::ImplCloseChunk ( void ) const
{
}
-// -------------
-// - PNGWriter -
-// -------------
-
PNGWriter::PNGWriter( const BitmapEx& rBmpEx,
const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >* pFilterData ) :
mpImpl( new ::vcl::PNGWriterImpl( rBmpEx, pFilterData ) )
{
}
-// ------------------------------------------------------------------------
-
PNGWriter::~PNGWriter()
{
delete mpImpl;
}
-// ------------------------------------------------------------------------
-
sal_Bool PNGWriter::Write( SvStream& rIStm )
{
return mpImpl->Write( rIStm );
}
-// ------------------------------------------------------------------------
-
std::vector< vcl::PNGWriter::ChunkData >& PNGWriter::GetChunks()
{
return mpImpl->GetChunks();
diff --git a/vcl/source/gdi/print2.cxx b/vcl/source/gdi/print2.cxx
index e1fe203b6ca8..0614a1807318 100644
--- a/vcl/source/gdi/print2.cxx
+++ b/vcl/source/gdi/print2.cxx
@@ -39,17 +39,9 @@
#include "pdfwriter_impl.hxx"
-// -----------
-// - Defines -
-// -----------
-
#define MAX_TILE_WIDTH 1024
#define MAX_TILE_HEIGHT 1024
-// ---------
-// - Types -
-// ---------
-
typedef ::std::pair< MetaAction*, int > Component; // MetaAction plus index in metafile
typedef ::std::list< Component > ComponentList;
@@ -74,11 +66,6 @@ struct ConnectedComponents
typedef ::std::list< ConnectedComponents > ConnectedComponentsList;
-
-// -----------
-// - Printer -
-// -----------
-
/** #i10613# Extracted from Printer::GetPreparedMetaFile. Returns true
if given action requires special handling (usually because of
transparency)
@@ -1358,8 +1345,6 @@ bool OutputDevice::RemoveTransparenciesFromMetaFile( const GDIMetaFile& rInMtf,
return bTransparent;
}
-// -----------------------------------------------------------------------------
-
Bitmap OutputDevice::GetDownsampledBitmap( const Size& rDstSz,
const Point& rSrcPt, const Size& rSrcSz,
const Bitmap& rBmp, long nMaxBmpDPIX, long nMaxBmpDPIY )
@@ -1427,8 +1412,6 @@ Bitmap OutputDevice::GetDownsampledBitmap( const Size& rDstSz,
return aBmp;
}
-// -----------------------------------------------------------------------------
-
void Printer::DrawGradientEx( OutputDevice* pOut, const Rectangle& rRect, const Gradient& rGradient )
{
const PrinterOptions& rPrinterOptions = GetPrinterOptions();
diff --git a/vcl/source/gdi/salmisc.cxx b/vcl/source/gdi/salmisc.cxx
index 702470ca1329..79e554e47fab 100644
--- a/vcl/source/gdi/salmisc.cxx
+++ b/vcl/source/gdi/salmisc.cxx
@@ -21,17 +21,11 @@
#include <vcl/salbtype.hxx>
#include <bmpfast.hxx>
-// -----------
-// - Defines -
-// -----------
-
#define IMPL_CASE_GET_FORMAT( Format ) \
case( BMP_FORMAT##Format ): \
pFncGetPixel = BitmapReadAccess::GetPixelFor##Format; \
break
-// -----------------------------------------------------------------------------
-
#define IMPL_CASE_SET_FORMAT( Format, BitCount ) \
case( BMP_FORMAT##Format ): \
{ \
@@ -40,8 +34,6 @@ case( BMP_FORMAT##Format ): \
} \
break
-// -----------------------------------------------------------------------------
-
#define DOUBLE_SCANLINES() \
while( ( nActY < nHeight1 ) && ( pMapY[ nActY + 1 ] == nMapY ) ) \
{ \
@@ -49,10 +41,6 @@ while( ( nActY < nHeight1 ) && ( pMapY[ nActY + 1 ] == nMapY ) )
nActY++; \
}
-// -----------
-// - Inlines -
-// -----------
-
#define TC_TO_PAL_COLORS 4096
static long ImplIndexFromColor( const BitmapColor& rCol )
@@ -72,10 +60,6 @@ static long ImplIndexFromColor( const BitmapColor& rCol )
#endif
}
-// ------------------------
-// - conversion functions -
-// ------------------------
-
static void ImplPALToPAL( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffer,
FncGetPixel pFncGetPixel, FncSetPixel pFncSetPixel,
Scanline* pSrcScanMap, Scanline* pDstScanMap, long* pMapX, long* pMapY )
@@ -108,8 +92,6 @@ static void ImplPALToPAL( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuff
}
}
-// -----------------------------------------------------------------------------
-
static void ImplPALToTC( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffer,
FncGetPixel pFncGetPixel, FncSetPixel pFncSetPixel,
Scanline* pSrcScanMap, Scanline* pDstScanMap, long* pMapX, long* pMapY )
@@ -185,8 +167,6 @@ static void ImplPALToTC( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffe
}
}
-// -----------------------------------------------------------------------------
-
static void ImplTCToTC( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffer,
FncGetPixel pFncGetPixel, FncSetPixel pFncSetPixel,
Scanline* pSrcScanMap, Scanline* pDstScanMap, long* pMapX, long* pMapY )
@@ -229,8 +209,6 @@ static void ImplTCToTC( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffer
}
}
-// -----------------------------------------------------------------------------
-
static void ImplTCToPAL( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffer,
FncGetPixel pFncGetPixel, FncSetPixel pFncSetPixel,
Scanline* pSrcScanMap, Scanline* pDstScanMap, long* pMapX, long* pMapY )
@@ -272,12 +250,6 @@ static void ImplTCToPAL( const BitmapBuffer& rSrcBuffer, BitmapBuffer& rDstBuffe
delete[] pColToPalMap;
}
-// -----------------------------------------------------------------------------
-
-// ---------------------
-// - StretchAndConvert -
-// ---------------------
-
BitmapBuffer* StretchAndConvert( const BitmapBuffer& rSrcBuffer, const SalTwoRect& rTwoRect,
sal_uLong nDstBitmapFormat, BitmapPalette* pDstPal, ColorMask* pDstMask )
{