summaryrefslogtreecommitdiff
path: root/vcl/source/filter/wmf
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-02-21 12:53:51 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-02-21 12:53:51 +0100
commite8f8f24c8415898c787bbfb629247ed62e73a2b9 (patch)
treedae18a3acbf29c192118e7c003f80df8da8e21ae /vcl/source/filter/wmf
parent1c8402465cfd4df862409dc310f5f099d044c4d8 (diff)
vcl: sal_Bool -> bool
Change-Id: I2a3e3d3e3266ea0f0fafdd91362076a4aa160f0e
Diffstat (limited to 'vcl/source/filter/wmf')
-rw-r--r--vcl/source/filter/wmf/emfwr.cxx34
-rw-r--r--vcl/source/filter/wmf/emfwr.hxx18
-rw-r--r--vcl/source/filter/wmf/enhwmf.cxx84
-rw-r--r--vcl/source/filter/wmf/winmtf.cxx96
-rw-r--r--vcl/source/filter/wmf/winmtf.hxx88
-rw-r--r--vcl/source/filter/wmf/winwmf.cxx26
-rw-r--r--vcl/source/filter/wmf/wmf.cxx10
7 files changed, 178 insertions, 178 deletions
diff --git a/vcl/source/filter/wmf/emfwr.cxx b/vcl/source/filter/wmf/emfwr.cxx
index 9a6909f2c418..79497fb344e1 100644
--- a/vcl/source/filter/wmf/emfwr.cxx
+++ b/vcl/source/filter/wmf/emfwr.cxx
@@ -178,7 +178,7 @@ void EMFWriter::ImplBeginPlusRecord( sal_uInt16 nType, sal_uInt16 nFlags )
if( !mbRecordPlusOpen )
{
- mbRecordPlusOpen = sal_True;
+ mbRecordPlusOpen = true;
mnRecordPlusPos = m_rStm.Tell();
m_rStm.WriteUInt16( (sal_uInt16) nType ).WriteUInt16( (sal_uInt16) nFlags );
@@ -198,7 +198,7 @@ void EMFWriter::ImplEndPlusRecord()
m_rStm.WriteUInt32( (sal_uInt32)( nSize ) ) // Size
.WriteUInt32( (sal_uInt32) ( nSize - 0xc ) ); // Data Size
m_rStm.Seek( nActPos );
- mbRecordPlusOpen = sal_False;
+ mbRecordPlusOpen = false;
}
}
@@ -283,11 +283,11 @@ void EMFWriter::ImplWritePlusFillPolygonRecord( const Polygon& rPoly, const sal_
ImplEndCommentRecord();
}
-sal_Bool EMFWriter::WriteEMF( const GDIMetaFile& rMtf, FilterConfigItem* pFilterConfigItem )
+bool EMFWriter::WriteEMF( const GDIMetaFile& rMtf, FilterConfigItem* pFilterConfigItem )
{
const sal_uLong nHeaderPos = m_rStm.Tell();
- maVDev.EnableOutput( sal_False );
+ maVDev.EnableOutput( false );
maVDev.SetMapMode( rMtf.GetPrefMapMode() );
// don't work with pixel as destination map mode -> higher resolution preferrable
maDestMapMode.SetMapUnit( MAP_100TH_MM );
@@ -401,7 +401,7 @@ void EMFWriter::ImplBeginRecord( sal_uInt32 nType )
if( !mbRecordOpen )
{
- mbRecordOpen = sal_True;
+ mbRecordOpen = true;
mnRecordPos = m_rStm.Tell();
m_rStm.WriteUInt32( nType );
@@ -426,11 +426,11 @@ void EMFWriter::ImplEndRecord()
while( nFillBytes-- )
m_rStm.WriteUChar( (sal_uInt8)0 );
mnRecordCount++;
- mbRecordOpen = sal_False;
+ mbRecordOpen = false;
}
}
-sal_Bool EMFWriter::ImplPrepareHandleSelect( sal_uInt32& rHandle, sal_uLong nSelectType )
+bool EMFWriter::ImplPrepareHandleSelect( sal_uInt32& rHandle, sal_uLong nSelectType )
{
if( rHandle != HANDLE_INVALID )
{
@@ -664,7 +664,7 @@ void EMFWriter::ImplWriteRect( const Rectangle& rRect )
.WriteInt32( static_cast<sal_Int32>(aRect.Bottom()) );
}
-void EMFWriter::ImplWritePolygonRecord( const Polygon& rPoly, sal_Bool bClose )
+void EMFWriter::ImplWritePolygonRecord( const Polygon& rPoly, bool bClose )
{
if( rPoly.GetSize() )
{
@@ -696,7 +696,7 @@ void EMFWriter::ImplWritePolyPolygonRecord( const PolyPolygon& rPolyPoly )
if( nPolyCount )
{
if( 1 == nPolyCount )
- ImplWritePolygonRecord( rPolyPoly[ 0 ], sal_True );
+ ImplWritePolygonRecord( rPolyPoly[ 0 ], true );
else
{
bool bHasFlags = false;
@@ -711,7 +711,7 @@ void EMFWriter::ImplWritePolyPolygonRecord( const PolyPolygon& rPolyPoly )
if( nTotalPoints )
{
if ( bHasFlags )
- ImplWritePath( rPolyPoly, sal_True );
+ ImplWritePath( rPolyPoly, true );
else
{
ImplCheckFillAttr();
@@ -738,7 +738,7 @@ void EMFWriter::ImplWritePolyPolygonRecord( const PolyPolygon& rPolyPoly )
}
}
-void EMFWriter::ImplWritePath( const PolyPolygon& rPolyPoly, sal_Bool bClosed )
+void EMFWriter::ImplWritePath( const PolyPolygon& rPolyPoly, bool bClosed )
{
if ( bClosed )
ImplCheckFillAttr();
@@ -957,7 +957,7 @@ void EMFWriter::Impl_handleLineInfoPolyPolygons(const LineInfo& rInfo, const bas
for(sal_uInt32 a(0); a < aLinePolyPolygon.count(); a++)
{
const basegfx::B2DPolygon aCandidate(aLinePolyPolygon.getB2DPolygon(a));
- ImplWritePolygonRecord( Polygon(aCandidate), sal_False );
+ ImplWritePolygonRecord( Polygon(aCandidate), false );
}
}
@@ -1154,7 +1154,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf )
{
if(pA->GetLineInfo().IsDefault())
{
- ImplWritePolygonRecord( rPoly, sal_False );
+ ImplWritePolygonRecord( rPoly, false );
}
else
{
@@ -1394,14 +1394,14 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf )
case( META_LINECOLOR_ACTION ):
{
( (MetaAction*) pAction )->Execute( &maVDev );
- mbLineChanged = sal_True;
+ mbLineChanged = true;
}
break;
case( META_FILLCOLOR_ACTION ):
{
( (MetaAction*) pAction )->Execute( &maVDev );
- mbFillChanged = sal_True;
+ mbFillChanged = true;
}
break;
@@ -1412,7 +1412,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf )
case( META_FONT_ACTION ):
{
( (MetaAction*) pAction )->Execute( &maVDev );
- mbTextChanged = sal_True;
+ mbTextChanged = true;
}
break;
@@ -1457,7 +1457,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf )
ImplEndRecord();
ImplWriteRasterOp( maVDev.GetRasterOp() );
- mbLineChanged = mbFillChanged = mbTextChanged = sal_True;
+ mbLineChanged = mbFillChanged = mbTextChanged = true;
}
break;
diff --git a/vcl/source/filter/wmf/emfwr.hxx b/vcl/source/filter/wmf/emfwr.hxx
index 54228e6cd8c6..1eddc51e2029 100644
--- a/vcl/source/filter/wmf/emfwr.hxx
+++ b/vcl/source/filter/wmf/emfwr.hxx
@@ -47,13 +47,13 @@ private:
sal_uLong mnRecordCount;
sal_uLong mnRecordPos;
sal_uLong mnRecordPlusPos;
- sal_Bool mbRecordOpen;
- sal_Bool mbRecordPlusOpen;
- sal_Bool mbLineChanged;
+ bool mbRecordOpen;
+ bool mbRecordPlusOpen;
+ bool mbLineChanged;
sal_uInt32 mnLineHandle;
- sal_Bool mbFillChanged;
+ bool mbFillChanged;
sal_uInt32 mnFillHandle;
- sal_Bool mbTextChanged;
+ bool mbTextChanged;
sal_uInt32 mnTextHandle;
sal_uInt32 mnHorTextAlign;
@@ -68,7 +68,7 @@ private:
sal_uLong ImplAcquireHandle();
void ImplReleaseHandle( sal_uLong nHandle );
- sal_Bool ImplPrepareHandleSelect( sal_uInt32& rHandle, sal_uLong nSelectType );
+ bool ImplPrepareHandleSelect( sal_uInt32& rHandle, sal_uLong nSelectType );
void ImplCheckLineAttr();
void ImplCheckFillAttr();
void ImplCheckTextAttr();
@@ -79,8 +79,8 @@ private:
void ImplWritePoint( const Point& rPoint );
void ImplWriteSize( const Size& rSize);
void ImplWriteRect( const Rectangle& rRect );
- void ImplWritePath( const PolyPolygon& rPolyPoly, sal_Bool bClose );
- void ImplWritePolygonRecord( const Polygon& rPoly, sal_Bool bClose );
+ void ImplWritePath( const PolyPolygon& rPolyPoly, bool bClose );
+ void ImplWritePolygonRecord( const Polygon& rPoly, bool bClose );
void ImplWritePolyPolygonRecord( const PolyPolygon& rPolyPoly );
void ImplWriteBmpRecord( const Bitmap& rBmp, const Point& rPt, const Size& rSz, sal_uInt32 nROP );
void ImplWriteTextRecord( const Point& rPos, const OUString rText, const sal_Int32* pDXArray, sal_uInt32 nWidth );
@@ -97,7 +97,7 @@ public:
EMFWriter(SvStream &rStream) : m_rStm(rStream) {}
- sal_Bool WriteEMF( const GDIMetaFile& rMtf, FilterConfigItem* pConfigItem = NULL );
+ bool WriteEMF( const GDIMetaFile& rMtf, FilterConfigItem* pConfigItem = NULL );
};
#endif // INCLUDED_VCL_SOURCE_FILTER_WMF_EMFWR_HXX
diff --git a/vcl/source/filter/wmf/enhwmf.cxx b/vcl/source/filter/wmf/enhwmf.cxx
index e2292a0b8f5f..9023c50ad3ed 100644
--- a/vcl/source/filter/wmf/enhwmf.cxx
+++ b/vcl/source/filter/wmf/enhwmf.cxx
@@ -236,7 +236,7 @@ static bool ImplReadRegion( PolyPolygon& rPolyPoly, SvStream& rSt, sal_uInt32 nL
return bOk;
}
-void EnhWMFReader::ReadEMFPlusComment(sal_uInt32 length, sal_Bool& bHaveDC)
+void EnhWMFReader::ReadEMFPlusComment(sal_uInt32 length, bool& bHaveDC)
{
if (!bEMFPlus) {
pOut->PassEMFPlusHeaderInfo();
@@ -306,7 +306,7 @@ void EnhWMFReader::ReadEMFPlusComment(sal_uInt32 length, sal_Bool& bHaveDC)
* skipFirst: if the first point read is the 0th point or the 1st point in the array.
* */
template <class T, class Drawer>
-void EnhWMFReader::ReadAndDrawPolygon(Drawer drawer, const sal_Bool skipFirst)
+void EnhWMFReader::ReadAndDrawPolygon(Drawer drawer, const bool skipFirst)
{
sal_uInt32 nPoints(0), nStartIndex(0);
pWMF->SeekRel( 16 );
@@ -379,7 +379,7 @@ void EnhWMFReader::ReadAndDrawPolyLine()
for ( i = 0; ( i < nPoly ) && pWMF->good(); i++ )
{
Polygon aPolygon = ReadPolygon<T>(0, pnPoints[i]);
- pOut->DrawPolyLine( aPolygon, sal_False, bRecordPath );
+ pOut->DrawPolyLine( aPolygon, false, bRecordPath );
}
delete[] pnPoints;
}
@@ -450,7 +450,7 @@ void EnhWMFReader::ReadAndDrawPolyPolygon()
}
}
-sal_Bool EnhWMFReader::ReadEnhWMF()
+bool EnhWMFReader::ReadEnhWMF()
{
sal_uInt32 nStretchBltMode = 0;
sal_uInt32 nRecType(0), nRecSize(0), nNextPos(0),
@@ -458,8 +458,8 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
nDat32(0), nNom1(0), nDen1(0), nNom2(0), nDen2(0);
sal_Int32 nX32(0), nY32(0), nx32(0), ny32(0);
- sal_Bool bFlag(sal_False), bStatus = ReadHeader();
- sal_Bool bHaveDC = false;
+ bool bFlag(false), bStatus = ReadHeader();
+ bool bHaveDC = false;
static bool bEnableEMFPlus = ( getenv( "EMF_PLUS_DISABLE" ) == NULL );
@@ -469,7 +469,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
if ( !pWMF->good() || ( nRecSize < 8 ) || ( nRecSize & 3 ) ) // Parameters are always divisible by 4
{
- bStatus = sal_False;
+ bStatus = false;
break;
}
@@ -477,7 +477,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
if ( !pWMF->good() || nNextPos > nEndPos )
{
- bStatus = sal_False;
+ bStatus = false;
break;
}
@@ -488,7 +488,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
pOut->ResolveBitmapActions( aBmpSaveList );
}
- bFlag = sal_False;
+ bFlag = false;
SAL_INFO ("vcl.emf", "0x" << std::hex << (nNextPos - nRecSize) << "-0x" << nNextPos << " record type: " << std::dec << nRecType << " size: " << nRecSize << std::dec);
@@ -522,21 +522,21 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
switch( nRecType )
{
case EMR_POLYBEZIERTO :
- ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), sal_True);
+ ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), true);
break;
case EMR_POLYBEZIER :
- ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), false);
break;
case EMR_POLYGON :
- ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolygon, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolygon, _1, _2, _3, _4), false);
break;
case EMR_POLYLINETO :
- ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), sal_True);
+ ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), true);
break;
case EMR_POLYLINE :
- ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int32>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), false);
break;
case EMR_POLYPOLYLINE :
@@ -727,7 +727,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
if ( aSize.Width() )
aLineInfo.SetWidth( aSize.Width() );
- sal_Bool bTransparent = sal_False;
+ bool bTransparent = false;
switch( nStyle & 0xFF )
{
case PS_DASHDOTDOT :
@@ -761,7 +761,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
aLineInfo.SetDistance( 100 );
break;
case PS_NULL :
- bTransparent = sal_True;
+ bTransparent = true;
aLineInfo.SetStyle( LINE_NONE );
break;
case PS_INSIDEFRAME :
@@ -817,7 +817,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
if ( nWidth )
aLineInfo.SetWidth( nWidth );
- sal_Bool bTransparent = sal_False;
+ bool bTransparent = false;
sal_uInt16 nDashCount = 0;
sal_uInt16 nDotCount = 0;
@@ -834,7 +834,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
nDashCount++;
break;
case PS_NULL :
- bTransparent = sal_True;
+ bTransparent = true;
aLineInfo.SetStyle( LINE_NONE );
break;
@@ -938,21 +938,21 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
{
sal_uInt32 nStartX, nStartY, nEndX, nEndY;
pWMF->ReadInt32( nX32 ).ReadInt32( nY32 ).ReadInt32( nx32 ).ReadInt32( ny32 ).ReadUInt32( nStartX ).ReadUInt32( nStartY ).ReadUInt32( nEndX ).ReadUInt32( nEndY );
- pOut->DrawArc( ReadRectangle( nX32, nY32, nx32, ny32 ), Point( nStartX, nStartY ), Point( nEndX, nEndY ), sal_True );
+ pOut->DrawArc( ReadRectangle( nX32, nY32, nx32, ny32 ), Point( nStartX, nStartY ), Point( nEndX, nEndY ), true );
}
break;
case EMR_BEGINPATH :
{
pOut->ClearPath();
- bRecordPath = sal_True;
+ bRecordPath = true;
}
break;
case EMR_ABORTPATH :
pOut->ClearPath();
case EMR_ENDPATH :
- bRecordPath = sal_False;
+ bRecordPath = false;
break;
case EMR_CLOSEFIGURE :
@@ -960,22 +960,22 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
break;
case EMR_FILLPATH :
- pOut->StrokeAndFillPath( sal_False, sal_True );
+ pOut->StrokeAndFillPath( false, true );
break;
case EMR_STROKEANDFILLPATH :
- pOut->StrokeAndFillPath( sal_True, sal_True );
+ pOut->StrokeAndFillPath( true, true );
break;
case EMR_STROKEPATH :
- pOut->StrokeAndFillPath( sal_True, sal_False );
+ pOut->StrokeAndFillPath( true, false );
break;
case EMR_SELECTCLIPPATH :
{
sal_Int32 nClippingMode;
pWMF->ReadInt32( nClippingMode );
- pOut->SetClipPath( pOut->GetPathObj(), nClippingMode, sal_True );
+ pOut->SetClipPath( pOut->GetPathObj(), nClippingMode, true );
}
break;
@@ -988,7 +988,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
PolyPolygon aPolyPoly;
if ( cbRgnData )
ImplReadRegion( aPolyPoly, *pWMF, nRecSize );
- pOut->SetClipPath( aPolyPoly, iMode, sal_True );
+ pOut->SetClipPath( aPolyPoly, iMode, true );
}
break;
@@ -1018,7 +1018,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
Rectangle aRect( Point( xDest, yDest ), Size( cxDest+1, cyDest+1 ) );
if ( (cbBitsSrc > (SAL_MAX_UINT32 - 14)) || ((SAL_MAX_UINT32 - 14) - cbBitsSrc < cbBmiSrc) )
- bStatus = sal_False;
+ bStatus = false;
else
{
sal_uInt32 nSize = cbBmiSrc + cbBitsSrc + 14;
@@ -1082,7 +1082,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
cyDest = abs( (int)cyDest ); // and also 122889
if ( (cbBitsSrc > (SAL_MAX_UINT32 - 14)) || ((SAL_MAX_UINT32 - 14) - cbBitsSrc < cbBmiSrc) )
- bStatus = sal_False;
+ bStatus = false;
else
{
sal_uInt32 nSize = cbBmiSrc + cbBitsSrc + 14;
@@ -1151,7 +1151,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
|| ((SAL_MAX_UINT32 - 14) - cbBitsSrc < cbBmiSrc )
)
{
- bStatus = sal_False;
+ bStatus = false;
}
else
{
@@ -1238,7 +1238,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
break;
case EMR_EXTTEXTOUTA :
- bFlag = sal_True;
+ bFlag = true;
case EMR_EXTTEXTOUTW :
{
sal_Int32 nLeft, nTop, nRight, nBottom, ptlReferenceX, ptlReferenceY, nGfxMode, nXScale, nYScale;
@@ -1328,21 +1328,21 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
break;
case EMR_POLYBEZIERTO16 :
- ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), sal_True);
+ ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), true);
break;
case EMR_POLYBEZIER16 :
- ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyBezier, _1, _2, _3, _4), false);
break;
case EMR_POLYGON16 :
- ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolygon, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolygon, _1, _2, _3, _4), false);
break;
case EMR_POLYLINETO16 :
- ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), sal_True);
+ ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), true);
break;
case EMR_POLYLINE16 :
- ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), sal_False);
+ ReadAndDrawPolygon<sal_Int16>(boost::bind(&WinMtfOutput::DrawPolyLine, _1, _2, _3, _4), false);
break;
case EMR_POLYPOLYLINE16 :
@@ -1364,7 +1364,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
{
pOut->Push();
pOut->SelectObject( nIndex );
- pOut->DrawPolyPolygon( aPolyPoly, sal_False );
+ pOut->DrawPolyPolygon( aPolyPoly, false );
pOut->Pop();
}
}
@@ -1388,7 +1388,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
pWMF->ReadUInt32( cbBits );
if ( (cbBits > (SAL_MAX_UINT32 - 14)) || ((SAL_MAX_UINT32 - 14) - cbBits < cbBmi) )
- bStatus = sal_False;
+ bStatus = false;
else if ( offBmi )
{
sal_uInt32 nSize = cbBmi + cbBits + 14;
@@ -1488,7 +1488,7 @@ sal_Bool EnhWMFReader::ReadEnhWMF()
};
-sal_Bool EnhWMFReader::ReadHeader()
+bool EnhWMFReader::ReadHeader()
{
sal_uInt32 nType, nSignature, nVersion;
sal_uInt32 nHeaderSize, nPalEntries;
@@ -1499,7 +1499,7 @@ sal_Bool EnhWMFReader::ReadHeader()
pWMF->ReadUInt32( nType ).ReadUInt32( nHeaderSize );
if ( nType != 1 ) { // per [MS-EMF] 2.3.4.2 EMF Header Record Types, type MUST be 0x00000001
SAL_WARN("vcl.emf", "EMF header type is not set to 0x00000001 - possibly corrupted file?");
- return sal_False;
+ return false;
}
// Start reading the EMR_HEADER Header object
@@ -1526,7 +1526,7 @@ sal_Bool EnhWMFReader::ReadHeader()
// and 2.1.14 FormatSignature Enumeration
if ( nSignature != 0x464d4520 ) {
SAL_WARN("vcl.emf", "EMF\t\tSignature is not 0x464d4520 (\"FME\") - possibly corrupted file?");
- return sal_False;
+ return false;
}
pWMF->ReadUInt32( nVersion ); // according to [WS-EMF] 2.2.9, this SHOULD be 0x0001000, however
@@ -1555,7 +1555,7 @@ sal_Bool EnhWMFReader::ReadHeader()
if ( !nRecordCount ) {
SAL_WARN("vcl.emf", "EMF\t\tEMF Header object shows record counter as 0! This shouldn't "
"be possible... indicator of possible file corruption?");
- return sal_False;
+ return false;
}
// the number of "handles", or graphics objects used in the metafile
@@ -1591,7 +1591,7 @@ sal_Bool EnhWMFReader::ReadHeader()
pOut->SetRefMill( Size( nMillX, nMillY ) );
pWMF->Seek( nStartPos + nHeaderSize );
- return sal_True;
+ return true;
}
diff --git a/vcl/source/filter/wmf/winmtf.cxx b/vcl/source/filter/wmf/winmtf.cxx
index 7d0d479832b9..eca0d4f76798 100644
--- a/vcl/source/filter/wmf/winmtf.cxx
+++ b/vcl/source/filter/wmf/winmtf.cxx
@@ -95,7 +95,7 @@ void WinMtfPathObj::AddPoint( const Point& rPoint )
Insert( Polygon(), POLYPOLY_APPEND );
Polygon& rPoly = ((PolyPolygon&)*this)[ Count() - 1 ];
rPoly.Insert( rPoly.GetSize(), rPoint, POLY_NORMAL );
- bClosed = sal_False;
+ bClosed = false;
}
void WinMtfPathObj::AddPolyLine( const Polygon& rPolyLine )
@@ -104,13 +104,13 @@ void WinMtfPathObj::AddPolyLine( const Polygon& rPolyLine )
Insert( Polygon(), POLYPOLY_APPEND );
Polygon& rPoly = ((PolyPolygon&)*this)[ Count() - 1 ];
rPoly.Insert( rPoly.GetSize(), rPolyLine );
- bClosed = sal_False;
+ bClosed = false;
}
void WinMtfPathObj::AddPolygon( const Polygon& rPoly )
{
Insert( rPoly, POLYPOLY_APPEND );
- bClosed = sal_True;
+ bClosed = true;
}
void WinMtfPathObj::AddPolyPolygon( const PolyPolygon& rPolyPoly )
@@ -118,7 +118,7 @@ void WinMtfPathObj::AddPolyPolygon( const PolyPolygon& rPolyPoly )
sal_uInt16 i, nCount = rPolyPoly.Count();
for ( i = 0; i < nCount; i++ )
Insert( rPolyPoly[ i ], POLYPOLY_APPEND );
- bClosed = sal_True;
+ bClosed = true;
}
void WinMtfPathObj::ClosePath()
@@ -133,7 +133,7 @@ void WinMtfPathObj::ClosePath()
rPoly.Insert( rPoly.GetSize(), aFirst, POLY_NORMAL );
}
}
- bClosed = sal_True;
+ bClosed = true;
}
@@ -594,7 +594,7 @@ void WinMtfOutput::SelectObject( sal_Int32 nIndex )
break;
case NULL_PEN :
{
- pGDIObj->Set( GDI_PEN, new WinMtfLineStyle( Color( COL_TRANSPARENT ), sal_True ) );
+ pGDIObj->Set( GDI_PEN, new WinMtfLineStyle( Color( COL_TRANSPARENT ), true ) );
}
break;
default:
@@ -611,7 +611,7 @@ void WinMtfOutput::SelectObject( sal_Int32 nIndex )
case GDI_BRUSH :
{
maFillStyle = (WinMtfFillStyle*)pGDIObj->pStyle;
- mbFillStyleSelected = sal_True;
+ mbFillStyleSelected = true;
}
break;
case GDI_FONT :
@@ -813,7 +813,7 @@ void WinMtfOutput::MoveClipRegion( const Size& rSize )
aClipPath.moveClipRegion( ImplMap( rSize ) );
}
-void WinMtfOutput::SetClipPath( const PolyPolygon& rPolyPolygon, sal_Int32 nClippingMode, sal_Bool bIsMapped )
+void WinMtfOutput::SetClipPath( const PolyPolygon& rPolyPolygon, sal_Int32 nClippingMode, bool bIsMapped )
{
mbClipNeedsUpdate=true;
if ( bIsMapped )
@@ -841,8 +841,8 @@ WinMtfOutput::WinMtfOutput( GDIMetaFile& rGDIMetaFile ) :
meLatestRasterOp ( ROP_INVERT ),
meRasterOp ( ROP_OVERPAINT ),
maActPos ( Point() ),
- mbNopMode ( sal_False ),
- mbFillStyleSelected ( sal_False ),
+ mbNopMode ( false ),
+ mbFillStyleSelected ( false ),
mbClipNeedsUpdate ( true ),
mbComplexClip ( false ),
mnGfxMode ( GM_COMPATIBLE ),
@@ -861,8 +861,8 @@ WinMtfOutput::WinMtfOutput( GDIMetaFile& rGDIMetaFile ) :
mnMillY ( 1 ),
mpGDIMetaFile ( &rGDIMetaFile )
{
- mbIsMapWinSet = sal_False;
- mbIsMapDevSet = sal_False;
+ mbIsMapWinSet = false;
+ mbIsMapDevSet = false;
mpGDIMetaFile->AddAction( new MetaPushAction( PUSH_CLIPREGION ) ); // The original clipregion has to be on top
// of the stack so it can always be restored
// this is necessary to be able to support
@@ -923,7 +923,7 @@ void WinMtfOutput::UpdateClipRegion()
void WinMtfOutput::ImplSetNonPersistentLineColorTransparenz()
{
Color aColor( COL_TRANSPARENT);
- WinMtfLineStyle aTransparentLine( aColor, sal_True );
+ WinMtfLineStyle aTransparentLine( aColor, true );
if ( ! ( maLatestLineStyle == aTransparentLine ) )
{
maLatestLineStyle = aTransparentLine;
@@ -968,7 +968,7 @@ sal_uInt32 WinMtfOutput::SetRasterOp( sal_uInt32 nRasterOp )
{ // changing modes from R2_NOP so set pen and brush
maFillStyle = aNopFillStyle;
maLineStyle = aNopLineStyle;
- mbNopMode = sal_False;
+ mbNopMode = false;
}
switch( nRasterOp )
{
@@ -983,13 +983,13 @@ sal_uInt32 WinMtfOutput::SetRasterOp( sal_uInt32 nRasterOp )
case R2_NOP:
{
meRasterOp = ROP_OVERPAINT;
- if( mbNopMode == sal_False )
+ if( !mbNopMode )
{
aNopFillStyle = maFillStyle;
aNopLineStyle = maLineStyle;
maFillStyle = WinMtfFillStyle( Color( COL_TRANSPARENT ), true );
- maLineStyle = WinMtfLineStyle( Color( COL_TRANSPARENT ), sal_True );
- mbNopMode = sal_True;
+ maLineStyle = WinMtfLineStyle( Color( COL_TRANSPARENT ), true );
+ mbNopMode = true;
}
}
break;
@@ -1005,7 +1005,7 @@ sal_uInt32 WinMtfOutput::SetRasterOp( sal_uInt32 nRasterOp )
};
-void WinMtfOutput::StrokeAndFillPath( sal_Bool bStroke, sal_Bool bFill )
+void WinMtfOutput::StrokeAndFillPath( bool bStroke, bool bFill )
{
if ( aPathObj.Count() )
{
@@ -1017,7 +1017,7 @@ void WinMtfOutput::StrokeAndFillPath( sal_Bool bStroke, sal_Bool bFill )
if ( !bStroke )
{
mpGDIMetaFile->AddAction( new MetaPushAction( PUSH_LINECOLOR ) );
- mpGDIMetaFile->AddAction( new MetaLineColorAction( Color(), sal_False ) );
+ mpGDIMetaFile->AddAction( new MetaLineColorAction( Color(), false ) );
}
if ( aPathObj.Count() == 1 )
mpGDIMetaFile->AddAction( new MetaPolygonAction( aPathObj.GetObject( 0 ) ) );
@@ -1044,7 +1044,7 @@ void WinMtfOutput::DrawPixel( const Point& rSource, const Color& rColor )
}
-void WinMtfOutput::MoveTo( const Point& rPoint, sal_Bool bRecordPath )
+void WinMtfOutput::MoveTo( const Point& rPoint, bool bRecordPath )
{
Point aDest( ImplMap( rPoint ) );
if ( bRecordPath )
@@ -1059,7 +1059,7 @@ void WinMtfOutput::MoveTo( const Point& rPoint, sal_Bool bRecordPath )
}
-void WinMtfOutput::LineTo( const Point& rPoint, sal_Bool bRecordPath )
+void WinMtfOutput::LineTo( const Point& rPoint, bool bRecordPath )
{
UpdateClipRegion();
Point aDest( ImplMap( rPoint ) );
@@ -1074,7 +1074,7 @@ void WinMtfOutput::LineTo( const Point& rPoint, sal_Bool bRecordPath )
}
-void WinMtfOutput::DrawRect( const Rectangle& rRect, sal_Bool bEdge )
+void WinMtfOutput::DrawRect( const Rectangle& rRect, bool bEdge )
{
UpdateClipRegion();
UpdateFillStyle();
@@ -1145,7 +1145,7 @@ void WinMtfOutput::DrawEllipse( const Rectangle& rRect )
}
-void WinMtfOutput::DrawArc( const Rectangle& rRect, const Point& rStart, const Point& rEnd, sal_Bool bTo )
+void WinMtfOutput::DrawArc( const Rectangle& rRect, const Point& rStart, const Point& rEnd, bool bTo )
{
UpdateClipRegion();
UpdateLineStyle();
@@ -1223,7 +1223,7 @@ void WinMtfOutput::DrawChord( const Rectangle& rRect, const Point& rStart, const
}
-void WinMtfOutput::DrawPolygon( Polygon& rPolygon, sal_Bool bRecordPath )
+void WinMtfOutput::DrawPolygon( Polygon& rPolygon, bool bRecordPath )
{
UpdateClipRegion();
ImplMap( rPolygon );
@@ -1296,7 +1296,7 @@ void WinMtfOutput::DrawPolygon( Polygon& rPolygon, sal_Bool bRecordPath )
}
-void WinMtfOutput::DrawPolyPolygon( PolyPolygon& rPolyPolygon, sal_Bool bRecordPath )
+void WinMtfOutput::DrawPolyPolygon( PolyPolygon& rPolyPolygon, bool bRecordPath )
{
UpdateClipRegion();
@@ -1323,7 +1323,7 @@ void WinMtfOutput::DrawPolyPolygon( PolyPolygon& rPolyPolygon, sal_Bool bRecordP
}
-void WinMtfOutput::DrawPolyLine( Polygon& rPolygon, sal_Bool bTo, sal_Bool bRecordPath )
+void WinMtfOutput::DrawPolyLine( Polygon& rPolygon, bool bTo, bool bRecordPath )
{
UpdateClipRegion();
@@ -1343,7 +1343,7 @@ void WinMtfOutput::DrawPolyLine( Polygon& rPolygon, sal_Bool bTo, sal_Bool bReco
}
-void WinMtfOutput::DrawPolyBezier( Polygon& rPolygon, sal_Bool bTo, sal_Bool bRecordPath )
+void WinMtfOutput::DrawPolyBezier( Polygon& rPolygon, bool bTo, bool bRecordPath )
{
UpdateClipRegion();
@@ -1374,7 +1374,7 @@ void WinMtfOutput::DrawPolyBezier( Polygon& rPolygon, sal_Bool bTo, sal_Bool bRe
}
-void WinMtfOutput::DrawText( Point& rPosition, OUString& rText, sal_Int32* pDXArry, sal_Bool bRecordPath, sal_Int32 nGfxMode )
+void WinMtfOutput::DrawText( Point& rPosition, OUString& rText, sal_Int32* pDXArry, bool bRecordPath, sal_Int32 nGfxMode )
{
UpdateClipRegion();
rPosition = ImplMap( rPosition );
@@ -1443,9 +1443,9 @@ void WinMtfOutput::DrawText( Point& rPosition, OUString& rText, sal_Int32* pDXAr
aTmp.SetFillColor( maBkColor );
if( mnBkMode == TRANSPARENT )
- aTmp.SetTransparent( sal_True );
+ aTmp.SetTransparent( true );
else
- aTmp.SetTransparent( sal_False );
+ aTmp.SetTransparent( false );
if ( ( mnTextAlign & TA_BASELINE) == TA_BASELINE )
aTmp.SetAlign( ALIGN_BASELINE );
@@ -1566,7 +1566,7 @@ void WinMtfOutput::ImplDrawBitmap( const Point& rPos, const Size& rSize, const B
const Point aEmptyPoint;
// #i50672# Extract whole VDev content (to match size of rBitmap)
- aVDev.EnableMapMode( sal_False );
+ aVDev.EnableMapMode( false );
Bitmap aMask( aVDev.GetBitmap( aEmptyPoint, aSizePixel ).CreateMask( Color( COL_WHITE ) ) );
if ( aBmpEx.IsTransparent() )
@@ -1636,7 +1636,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
{ // patterns aren't well supported yet
sal_uInt32 nOldRop = SetRasterOp( ROP_OVERPAINT ); // in this case nRasterOperation is either 0 or 0xff
UpdateFillStyle();
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
SetRasterOp( nOldRop );
}
else
@@ -1701,7 +1701,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
if ( nOperation == 0x1 )
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
}
break;
@@ -1719,7 +1719,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
if ( nOperation == 0x7 )
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
}
break;
@@ -1728,7 +1728,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
case 0xb :
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
SetRasterOp( R2_COPYPEN );
Bitmap aMask( aBitmap );
aBitmap.Invert();
@@ -1739,7 +1739,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
if ( nOperation == 0xb )
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
}
break;
@@ -1756,7 +1756,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
if ( nOperation == 0xd )
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
}
break;
@@ -1768,7 +1768,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
if ( nOperation == 0x9 )
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
}
break;
@@ -1778,7 +1778,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
{ // in this case nRasterOperation is either 0 or 0xff
maFillStyle = WinMtfFillStyle( Color( nRasterOperation, nRasterOperation, nRasterOperation ) );
UpdateFillStyle();
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
break;
@@ -1794,7 +1794,7 @@ void WinMtfOutput::ResolveBitmapActions( BSaveStructList_impl& rSaveList )
case 0x5 : // only destination is used
{
SetRasterOp( R2_NOT );
- DrawRect( aRect, sal_False );
+ DrawRect( aRect, false );
}
case 0xa : // no operation
break;
@@ -1830,7 +1830,7 @@ void WinMtfOutput::SetDevOrgOffset( sal_Int32 nXAdd, sal_Int32 nYAdd )
-void WinMtfOutput::SetDevExt( const Size& rSize ,sal_Bool regular)
+void WinMtfOutput::SetDevExt( const Size& rSize ,bool regular)
{
if ( rSize.Width() && rSize.Height() )
{
@@ -1845,7 +1845,7 @@ void WinMtfOutput::SetDevExt( const Size& rSize ,sal_Bool regular)
}
if (regular)
{
- mbIsMapDevSet=sal_True;
+ mbIsMapDevSet=true;
}
}
}
@@ -1860,7 +1860,7 @@ void WinMtfOutput::ScaleDevExt( double fX, double fY )
-void WinMtfOutput::SetWinOrg( const Point& rPoint , sal_Bool bIsEMF)
+void WinMtfOutput::SetWinOrg( const Point& rPoint , bool bIsEMF)
{
mnWinOrgX = rPoint.X();
mnWinOrgY = rPoint.Y();
@@ -1868,7 +1868,7 @@ void WinMtfOutput::SetWinOrg( const Point& rPoint , sal_Bool bIsEMF)
{
SetDevByWin();
}
- mbIsMapWinSet=sal_True;
+ mbIsMapWinSet=true;
}
@@ -1887,14 +1887,14 @@ void WinMtfOutput::SetDevByWin() //mnWinExt...-stuff has to be assigned before.
{
if ( mnMapMode == MM_ISOTROPIC ) //TODO: WHAT ABOUT ANISOTROPIC???
{
- SetDevExt(Size((mnWinExtX+mnWinOrgX)>>MS_FIXPOINT_BITCOUNT_28_4,-((mnWinExtY-mnWinOrgY)>>MS_FIXPOINT_BITCOUNT_28_4)),sal_False);
+ SetDevExt(Size((mnWinExtX+mnWinOrgX)>>MS_FIXPOINT_BITCOUNT_28_4,-((mnWinExtY-mnWinOrgY)>>MS_FIXPOINT_BITCOUNT_28_4)),false);
}
}
}
-void WinMtfOutput::SetWinExt( const Size& rSize, sal_Bool bIsEMF )
+void WinMtfOutput::SetWinExt( const Size& rSize, bool bIsEMF )
{
if( rSize.Width() && rSize.Height() )
{
@@ -1909,7 +1909,7 @@ void WinMtfOutput::SetWinExt( const Size& rSize, sal_Bool bIsEMF )
{
SetDevByWin();
}
- mbIsMapWinSet=sal_True;
+ mbIsMapWinSet=true;
}
}
}
@@ -2184,7 +2184,7 @@ void WinMtfOutput::PassEMFPlusHeaderInfo()
mem.Flush();
mpGDIMetaFile->AddAction( new MetaCommentAction( "EMF_PLUS_HEADER_INFO", 0, (const sal_uInt8*) mem.GetData(), mem.GetEndOfData() ) );
- mpGDIMetaFile->UseCanvas( sal_True );
+ mpGDIMetaFile->UseCanvas( true );
}
void WinMtfOutput::PassEMFPlus( void* pBuffer, sal_uInt32 nLength )
diff --git a/vcl/source/filter/wmf/winmtf.hxx b/vcl/source/filter/wmf/winmtf.hxx
index c20090725f6b..ab7291986de3 100644
--- a/vcl/source/filter/wmf/winmtf.hxx
+++ b/vcl/source/filter/wmf/winmtf.hxx
@@ -307,12 +307,12 @@ public :
class WinMtfPathObj : public PolyPolygon
{
- sal_Bool bClosed;
+ bool bClosed;
public :
- WinMtfPathObj() { bClosed = sal_True; }
- void Init() { Clear(); bClosed = sal_True; };
+ WinMtfPathObj() { bClosed = true; }
+ void Init() { Clear(); bClosed = true; };
void ClosePath();
void AddPoint( const Point& rPoint );
void AddPolygon( const Polygon& rPoly );
@@ -400,29 +400,29 @@ struct WinMtfLineStyle
{
Color aLineColor;
LineInfo aLineInfo;
- sal_Bool bTransparent;
+ bool bTransparent;
WinMtfLineStyle() :
aLineColor ( COL_BLACK ),
- bTransparent( sal_False ) {}
+ bTransparent( false ) {}
- WinMtfLineStyle( const Color& rColor, sal_Bool bTrans = sal_False ) :
+ WinMtfLineStyle( const Color& rColor, bool bTrans = false ) :
aLineColor ( rColor ),
bTransparent( bTrans ) {}
- WinMtfLineStyle( const Color& rColor, const LineInfo& rStyle, sal_Bool bTrans = sal_False ) :
+ WinMtfLineStyle( const Color& rColor, const LineInfo& rStyle, bool bTrans = false ) :
aLineColor ( rColor ),
aLineInfo ( rStyle ),
bTransparent( bTrans ) {}
- sal_Bool operator==( const WinMtfLineStyle& rStyle )
+ bool operator==( const WinMtfLineStyle& rStyle )
{
return ( ( aLineColor == rStyle.aLineColor )
&& ( bTransparent == rStyle.bTransparent )
&& ( aLineInfo == rStyle.aLineInfo )
);
}
- sal_Bool operator==( WinMtfLineStyle* pStyle )
+ bool operator==( WinMtfLineStyle* pStyle )
{
return ( ( aLineColor == pStyle->aLineColor )
&& ( bTransparent == pStyle->bTransparent )
@@ -485,8 +485,8 @@ struct SaveStruct
WinMtfClipPath aClipPath;
XForm aXForm;
- sal_Bool bRecordPath;
- sal_Bool bFillStyleSelected;
+ bool bRecordPath;
+ bool bFillStyleSelected;
};
typedef ::boost::shared_ptr< SaveStruct > SaveStructPtr;
@@ -601,10 +601,10 @@ class WinMtfOutput
Point maActPos;
sal_uInt32 mnRop;
- sal_Bool mbNopMode;
- sal_Bool mbFillStyleSelected;
- sal_Bool mbClipNeedsUpdate;
- sal_Bool mbComplexClip;
+ bool mbNopMode;
+ bool mbFillStyleSelected;
+ bool mbClipNeedsUpdate;
+ bool mbComplexClip;
std::vector< SaveStructPtr > vSaveStack;
@@ -616,8 +616,8 @@ class WinMtfOutput
sal_Int32 mnDevWidth, mnDevHeight;
sal_Int32 mnWinOrgX, mnWinOrgY; // aktuel window origin
sal_Int32 mnWinExtX, mnWinExtY; // aktuel window extend
- sal_Bool mbIsMapWinSet;
- sal_Bool mbIsMapDevSet;
+ bool mbIsMapWinSet;
+ bool mbIsMapDevSet;
sal_Int32 mnPixX, mnPixY; // Reference Device in pixel
sal_Int32 mnMillX, mnMillY; // Reference Device in Mill
@@ -648,12 +648,12 @@ public:
void SetDevByWin(); //Hack to set varying defaults for incompletely defined files.
void SetDevOrg( const Point& rPoint );
void SetDevOrgOffset( sal_Int32 nXAdd, sal_Int32 nYAdd );
- void SetDevExt( const Size& rSize ,sal_Bool regular = true);
+ void SetDevExt( const Size& rSize ,bool regular = true);
void ScaleDevExt( double fX, double fY );
- void SetWinOrg( const Point& rPoint , sal_Bool bIsEMF = false);
+ void SetWinOrg( const Point& rPoint , bool bIsEMF = false);
void SetWinOrgOffset( sal_Int32 nX, sal_Int32 nY );
- void SetWinExt( const Size& rSize , sal_Bool bIsEMF = false);
+ void SetWinExt( const Size& rSize , bool bIsEMF = false);
void ScaleWinExt( double fX, double fY );
void SetrclBounds( const Rectangle& rRect );
@@ -671,7 +671,7 @@ public:
void Pop();
sal_uInt32 SetRasterOp( sal_uInt32 nRasterOp );
- void StrokeAndFillPath( sal_Bool bStroke, sal_Bool bFill );
+ void StrokeAndFillPath( bool bStroke, bool bFill );
void SetGfxMode( sal_Int32 nGfxMode ){ mnGfxMode = nGfxMode; };
sal_Int32 GetGfxMode() const { return mnGfxMode; };
@@ -692,17 +692,17 @@ public:
void ClosePath(){ aPathObj.ClosePath(); };
const PolyPolygon& GetPathObj(){ return aPathObj; };
- void MoveTo( const Point& rPoint, sal_Bool bRecordPath = sal_False );
- void LineTo( const Point& rPoint, sal_Bool bRecordPath = sal_False );
+ void MoveTo( const Point& rPoint, bool bRecordPath = false );
+ void LineTo( const Point& rPoint, bool bRecordPath = false );
void DrawPixel( const Point& rSource, const Color& rColor );
- void DrawRect( const Rectangle& rRect, sal_Bool bEdge = sal_True );
+ void DrawRect( const Rectangle& rRect, bool bEdge = true );
void DrawRoundRect( const Rectangle& rRect, const Size& rSize );
void DrawEllipse( const Rectangle& rRect );
void DrawArc(
const Rectangle& rRect,
const Point& rStartAngle,
const Point& rEndAngle,
- sal_Bool bDrawTo = sal_False
+ bool bDrawTo = false
);
void DrawPie(
const Rectangle& rRect,
@@ -714,28 +714,28 @@ public:
const Point& rStartAngle,
const Point& rEndAngle
);
- void DrawPolygon( Polygon& rPolygon, sal_Bool bRecordPath = sal_False );
- void DrawPolygon( Polygon& rPolygon, sal_Bool /*bDrawTo*/, sal_Bool bRecordPath)
+ void DrawPolygon( Polygon& rPolygon, bool bRecordPath = false );
+ void DrawPolygon( Polygon& rPolygon, bool /*bDrawTo*/, bool bRecordPath)
{
//For ReadAndDrawPolygon template compatibility
DrawPolygon(rPolygon, bRecordPath);
}
- void DrawPolyPolygon( PolyPolygon& rPolyPolygon, sal_Bool bRecordPath = sal_False );
+ void DrawPolyPolygon( PolyPolygon& rPolyPolygon, bool bRecordPath = false );
void DrawPolyLine(
Polygon& rPolygon,
- sal_Bool bDrawTo = sal_False,
- sal_Bool bRecordPath = sal_False
+ bool bDrawTo = false,
+ bool bRecordPath = false
);
void DrawPolyBezier(
Polygon& rPolygin,
- sal_Bool bDrawTo = sal_False,
- sal_Bool bRecordPath = sal_False
+ bool bDrawTo = false,
+ bool bRecordPath = false
);
void DrawText(
Point& rPosition,
OUString& rString,
sal_Int32* pDXArry = NULL,
- sal_Bool bRecordPath = sal_False,
+ bool bRecordPath = false,
sal_Int32 nGraphicsMode = GM_COMPATIBLE
);
void ResolveBitmapActions( BSaveStructList_impl& rSaveList );
@@ -746,7 +746,7 @@ public:
void SetClipPath(
const PolyPolygon& rPolyPoly,
sal_Int32 nClippingMode,
- sal_Bool bIsMapped
+ bool bIsMapped
);
void UpdateClipRegion();
void AddFromGDIMetaFile( GDIMetaFile& rGDIMetaFile );
@@ -791,12 +791,12 @@ protected:
class EnhWMFReader : public WinMtf
{
- sal_Bool bRecordPath;
+ bool bRecordPath;
sal_Int32 nRecordCount;
- sal_Bool bEMFPlus;
+ bool bEMFPlus;
- sal_Bool ReadHeader();
+ bool ReadHeader();
// reads and converts the rectangle
Rectangle ReadRectangle( sal_Int32, sal_Int32, sal_Int32, sal_Int32 );
@@ -809,18 +809,18 @@ public:
: WinMtf( new WinMtfOutput( rGDIMetaFile )
, rStreamWMF
, pConfigItem )
- , bRecordPath( sal_False )
- , bEMFPlus( sal_False )
+ , bRecordPath( false )
+ , bEMFPlus( false )
{};
~EnhWMFReader();
- sal_Bool ReadEnhWMF();
- void ReadEMFPlusComment(sal_uInt32 length, sal_Bool& bHaveDC);
+ bool ReadEnhWMF();
+ void ReadEMFPlusComment(sal_uInt32 length, bool& bHaveDC);
private:
template <class T> void ReadAndDrawPolyPolygon();
template <class T> void ReadAndDrawPolyLine();
template <class T> Polygon ReadPolygon(sal_uInt32 nStartIndex, sal_uInt32 nPoints);
- template <class T, class Drawer> void ReadAndDrawPolygon(Drawer drawer, const sal_Bool skipFirst);
+ template <class T, class Drawer> void ReadAndDrawPolygon(Drawer drawer, const bool skipFirst);
};
//============================ WMFReader ==================================
@@ -851,7 +851,7 @@ private:
WMF_EXTERNALHEADER* pExternalHeader;
// reads header of the WMF-Datei
- sal_Bool ReadHeader();
+ bool ReadHeader();
// reads parameters of the record with the functionnumber nFunction.
void ReadRecordParams( sal_uInt16 nFunction );
@@ -860,7 +860,7 @@ private:
Point ReadYX(); // reads and converts a point (first Y then X)
Rectangle ReadRectangle(); // reads and converts a rectangle
Size ReadYXExt();
- sal_Bool GetPlaceableBound( Rectangle& rSize, SvStream* pStrm );
+ bool GetPlaceableBound( Rectangle& rSize, SvStream* pStrm );
public:
diff --git a/vcl/source/filter/wmf/winwmf.cxx b/vcl/source/filter/wmf/winwmf.cxx
index f53e396bc3ce..8d6fd89787aa 100644
--- a/vcl/source/filter/wmf/winwmf.cxx
+++ b/vcl/source/filter/wmf/winwmf.cxx
@@ -748,7 +748,7 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
if ( nWidth )
aLineInfo.SetWidth( nWidth );
- sal_Bool bTransparent = sal_False;
+ bool bTransparent = false;
switch( nStyle & 0xFF )
{
case PS_DASHDOTDOT :
@@ -782,7 +782,7 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
aLineInfo.SetDistance( 100 );
break;
case PS_NULL :
- bTransparent = sal_True;
+ bTransparent = true;
aLineInfo.SetStyle( LINE_NONE );
break;
default :
@@ -891,7 +891,7 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
pWMF->ReadUInt32( nROP );
Size aSize = ReadYXExt();
nOldROP = pOut->SetRasterOp( nROP );
- pOut->DrawRect( Rectangle( ReadYX(), aSize ), sal_False );
+ pOut->DrawRect( Rectangle( ReadYX(), aSize ), false );
pOut->SetRasterOp( nOldROP );
}
break;
@@ -903,7 +903,7 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
if ( !nObjIndex )
{
PolyPolygon aEmptyPolyPoly;
- pOut->SetClipPath( aEmptyPolyPoly, RGN_COPY, sal_True );
+ pOut->SetClipPath( aEmptyPolyPoly, RGN_COPY, true );
}
}
break;
@@ -1091,7 +1091,7 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
// ------------------------------------------------------------------------
-sal_Bool WMFReader::ReadHeader()
+bool WMFReader::ReadHeader()
{
sal_Size nStrmPos = pWMF->Tell();
@@ -1200,7 +1200,7 @@ void WMFReader::ReadWMF()
nEMFRec = 0;
nEMFSize = 0;
- sal_Bool bEMFAvailable = sal_False;
+ bool bEMFAvailable = false;
pOut->SetMapMode( MM_ANISOTROPIC );
pOut->SetWinOrg( Point() );
@@ -1306,9 +1306,9 @@ void WMFReader::ReadWMF()
// ------------------------------------------------------------------------
-sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pStm )
+bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pStm )
{
- sal_Bool bRet = sal_True;
+ bool bRet = true;
rPlaceableBound.Left() = (sal_Int32)0x7fffffff;
rPlaceableBound.Top() = (sal_Int32)0x7fffffff;
@@ -1335,7 +1335,7 @@ sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pSt
if( pStm->IsEof() )
{
pStm->SetError( SVSTREAM_FILEFORMAT_ERROR );
- bRet = sal_False;
+ bRet = false;
}
break;
}
@@ -1419,7 +1419,7 @@ sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pSt
if (!bRecordOk)
{
pStm->SetError( SVSTREAM_FILEFORMAT_ERROR );
- bRet = sal_False;
+ bRet = false;
break;
}
@@ -1431,7 +1431,7 @@ sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pSt
if (!bRecordOk)
{
pStm->SetError( SVSTREAM_FILEFORMAT_ERROR );
- bRet = sal_False;
+ bRet = false;
break;
}
}
@@ -1531,7 +1531,7 @@ sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pSt
else
{
pStm->SetError( SVSTREAM_FILEFORMAT_ERROR );
- bRet = sal_False;
+ bRet = false;
}
}
@@ -1539,7 +1539,7 @@ sal_Bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pSt
else
{
pStm->SetError( SVSTREAM_GENERALERROR );
- bRet = sal_False;
+ bRet = false;
}
return bRet;
}
diff --git a/vcl/source/filter/wmf/wmf.cxx b/vcl/source/filter/wmf/wmf.cxx
index 002756aaaeed..f9e51a2a8724 100644
--- a/vcl/source/filter/wmf/wmf.cxx
+++ b/vcl/source/filter/wmf/wmf.cxx
@@ -27,7 +27,7 @@
// -----------------------------------------------------------------------------
-sal_Bool ConvertWMFToGDIMetaFile( SvStream & rStreamWMF, GDIMetaFile & rGDIMetaFile, FilterConfigItem* pConfigItem, WMF_EXTERNALHEADER *pExtHeader )
+bool ConvertWMFToGDIMetaFile( SvStream & rStreamWMF, GDIMetaFile & rGDIMetaFile, FilterConfigItem* pConfigItem, WMF_EXTERNALHEADER *pExtHeader )
{
sal_uInt32 nMetaType;
sal_uInt32 nOrgPos = rStreamWMF.Tell();
@@ -38,7 +38,7 @@ sal_Bool ConvertWMFToGDIMetaFile( SvStream & rStreamWMF, GDIMetaFile & rGDIMetaF
rStreamWMF.Seek( nOrgPos );
if ( nMetaType == 0x464d4520 )
{
- if ( EnhWMFReader( rStreamWMF, rGDIMetaFile, pConfigItem ).ReadEnhWMF() == sal_False )
+ if ( !EnhWMFReader( rStreamWMF, rGDIMetaFile, pConfigItem ).ReadEnhWMF() )
rStreamWMF.SetError( SVSTREAM_FILEFORMAT_ERROR );
}
else
@@ -58,7 +58,7 @@ sal_Bool ConvertWMFToGDIMetaFile( SvStream & rStreamWMF, GDIMetaFile & rGDIMetaF
// -----------------------------------------------------------------------------
-sal_Bool ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF, FilterConfigItem* pFilterConfigItem )
+bool ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF, FilterConfigItem* pFilterConfigItem )
{
sal_uInt32 nMetaType(0);
sal_uInt32 nOrgPos = rStream.Tell();
@@ -79,7 +79,7 @@ sal_Bool ReadWindowMetafile( SvStream& rStream, GDIMetaFile& rMTF, FilterConfigI
if ( nMetaType == 0x464d4520 )
{
- if ( EnhWMFReader( rStream, rMTF, NULL ).ReadEnhWMF() == sal_False )
+ if ( !EnhWMFReader( rStream, rMTF, NULL ).ReadEnhWMF() )
rStream.SetError( SVSTREAM_FILEFORMAT_ERROR );
}
else
@@ -111,7 +111,7 @@ bool ConvertGDIMetaFileToWMF( const GDIMetaFile & rMTF, SvStream & rTargetStream
// -----------------------------------------------------------------------------
-sal_Bool ConvertGDIMetaFileToEMF( const GDIMetaFile & rMTF, SvStream & rTargetStream,
+bool ConvertGDIMetaFileToEMF( const GDIMetaFile & rMTF, SvStream & rTargetStream,
FilterConfigItem* pConfigItem )
{
EMFWriter aEMFWriter(rTargetStream);