summaryrefslogtreecommitdiffstats
path: root/vcl
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.com>2014-05-07 21:15:17 +0200
committerTomaž Vajngerl <tomaz.vajngerl@collabora.com>2014-05-15 19:51:05 +0200
commit7d69e253549f12a02474b3ce21f767b573f4ef3f (patch)
tree420d44626b097066f204b3c0ab140785a257f69b /vcl
parentfdo#70498 work-around scaling in SetClipPath (diff)
downloadcore-7d69e253549f12a02474b3ce21f767b573f4ef3f.tar.gz
core-7d69e253549f12a02474b3ce21f767b573f4ef3f.zip
vcl WMF: some code clean-up
Change-Id: I0b8d433d3d3bf03e3f414b2586a718146380ee2a
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/filter/wmf/winmtf.cxx19
-rw-r--r--vcl/source/filter/wmf/winwmf.cxx4
2 files changed, 13 insertions, 10 deletions
diff --git a/vcl/source/filter/wmf/winmtf.cxx b/vcl/source/filter/wmf/winmtf.cxx
index 390ded430180..ea42a074cf18 100644
--- a/vcl/source/filter/wmf/winmtf.cxx
+++ b/vcl/source/filter/wmf/winmtf.cxx
@@ -784,8 +784,8 @@ void WinMtfOutput::MoveClipRegion( const Size& rSize )
void WinMtfOutput::SetClipPath( const PolyPolygon& rPolyPolygon, sal_Int32 nClippingMode, bool bIsMapped )
{
- mbClipNeedsUpdate=true;
- if ( bIsMapped )
+ mbClipNeedsUpdate = true;
+ if (bIsMapped)
{
PolyPolygon aPP( rPolyPolygon );
aClipPath.setClipPath( ImplScale( aPP ), nClippingMode );
@@ -845,7 +845,7 @@ WinMtfOutput::WinMtfOutput( GDIMetaFile& rGDIMetaFile ) :
mnRop = R2_BLACK + 1;
SetRasterOp( R2_BLACK );
-};
+}
WinMtfOutput::~WinMtfOutput()
{
@@ -858,7 +858,7 @@ WinMtfOutput::~WinMtfOutput()
for ( sal_uInt32 i = 0; i < vGDIObj.size(); i++ )
delete vGDIObj[ i ];
-};
+}
void WinMtfOutput::UpdateClipRegion()
{
@@ -1827,14 +1827,17 @@ 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)),false);
+ Size aSize( (mnWinExtX + mnWinOrgX) >> MS_FIXPOINT_BITCOUNT_28_4,
+ -((mnWinExtY - mnWinOrgY) >> MS_FIXPOINT_BITCOUNT_28_4));
+
+ SetDevExt(aSize, false);
}
}
}
-void WinMtfOutput::SetWinExt( const Size& rSize, bool bIsEMF )
+void WinMtfOutput::SetWinExt(const Size& rSize, bool bIsEMF)
{
- if( rSize.Width() && rSize.Height() )
+ if (rSize.Width() && rSize.Height())
{
switch( mnMapMode )
{
@@ -1847,7 +1850,7 @@ void WinMtfOutput::SetWinExt( const Size& rSize, bool bIsEMF )
{
SetDevByWin();
}
- mbIsMapWinSet=true;
+ mbIsMapWinSet = true;
}
}
}
diff --git a/vcl/source/filter/wmf/winwmf.cxx b/vcl/source/filter/wmf/winwmf.cxx
index 8b1936b0e8c7..7dd4d0ac4171 100644
--- a/vcl/source/filter/wmf/winwmf.cxx
+++ b/vcl/source/filter/wmf/winwmf.cxx
@@ -464,7 +464,8 @@ void WMFReader::ReadRecordParams( sal_uInt16 nFunc )
pWMF->ReadInt32( nRecordSize );
pWMF->SeekRel(2);
aPosition = ReadYX();
- pWMF->ReadUInt16( nLen ).ReadUInt16( nOptions );
+ pWMF->ReadUInt16( nLen );
+ pWMF->ReadUInt16( nOptions );
sal_Int32 nTextLayoutMode = TEXT_LAYOUT_DEFAULT;
if ( nOptions & ETO_RTLREADING )
@@ -1560,7 +1561,6 @@ bool WMFReader::GetPlaceableBound( Rectangle& rPlaceableBound, SvStream* pStm )
pStm->SetError( SVSTREAM_FILEFORMAT_ERROR );
bRet = false;
}
-
}
}
else