diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-09-05 08:29:58 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-09-06 08:43:33 +0200 |
commit | dccd1633a111ba124f9868a4a51579c95200d745 (patch) | |
tree | 221a16d33215ffde2b249c7aca6f8c83981dbec4 /vcl | |
parent | 9c34471f54870fc685c343f4af30310e75d3a9ca (diff) |
loplugin:unnecessaryparen include case statements
Change-Id: I79fb3eec0d5d466e33b2e18621a7169695edf82f
Reviewed-on: https://gerrit.libreoffice.org/41920
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/filter/graphicfilter.cxx | 22 | ||||
-rw-r--r-- | vcl/source/filter/graphicfilter2.cxx | 50 | ||||
-rw-r--r-- | vcl/source/filter/wmf/emfwr.cxx | 84 | ||||
-rw-r--r-- | vcl/source/filter/wmf/wmfwr.cxx | 2 | ||||
-rw-r--r-- | vcl/source/gdi/gdimtf.cxx | 252 | ||||
-rw-r--r-- | vcl/source/gdi/pdfwriter_impl2.cxx | 102 | ||||
-rw-r--r-- | vcl/source/outdev/mask.cxx | 6 | ||||
-rw-r--r-- | vcl/source/outdev/wallpaper.cxx | 20 | ||||
-rw-r--r-- | vcl/source/window/scrwnd.cxx | 16 |
9 files changed, 277 insertions, 277 deletions
diff --git a/vcl/source/filter/graphicfilter.cxx b/vcl/source/filter/graphicfilter.cxx index 47f755b368b3..377403057860 100644 --- a/vcl/source/filter/graphicfilter.cxx +++ b/vcl/source/filter/graphicfilter.cxx @@ -2357,17 +2357,17 @@ IMPL_LINK( GraphicFilter, FilterCallback, ConvertData&, rData, bool ) OString aShortName; switch( rData.mnFormat ) { - case( ConvertDataFormat::BMP ): aShortName = BMP_SHORTNAME; break; - case( ConvertDataFormat::GIF ): aShortName = GIF_SHORTNAME; break; - case( ConvertDataFormat::JPG ): aShortName = JPG_SHORTNAME; break; - case( ConvertDataFormat::MET ): aShortName = MET_SHORTNAME; break; - case( ConvertDataFormat::PCT ): aShortName = PCT_SHORTNAME; break; - case( ConvertDataFormat::PNG ): aShortName = PNG_SHORTNAME; break; - case( ConvertDataFormat::SVM ): aShortName = SVM_SHORTNAME; break; - case( ConvertDataFormat::TIF ): aShortName = TIF_SHORTNAME; break; - case( ConvertDataFormat::WMF ): aShortName = WMF_SHORTNAME; break; - case( ConvertDataFormat::EMF ): aShortName = EMF_SHORTNAME; break; - case( ConvertDataFormat::SVG ): aShortName = SVG_SHORTNAME; break; + case ConvertDataFormat::BMP: aShortName = BMP_SHORTNAME; break; + case ConvertDataFormat::GIF: aShortName = GIF_SHORTNAME; break; + case ConvertDataFormat::JPG: aShortName = JPG_SHORTNAME; break; + case ConvertDataFormat::MET: aShortName = MET_SHORTNAME; break; + case ConvertDataFormat::PCT: aShortName = PCT_SHORTNAME; break; + case ConvertDataFormat::PNG: aShortName = PNG_SHORTNAME; break; + case ConvertDataFormat::SVM: aShortName = SVM_SHORTNAME; break; + case ConvertDataFormat::TIF: aShortName = TIF_SHORTNAME; break; + case ConvertDataFormat::WMF: aShortName = WMF_SHORTNAME; break; + case ConvertDataFormat::EMF: aShortName = EMF_SHORTNAME; break; + case ConvertDataFormat::SVG: aShortName = SVG_SHORTNAME; break; default: break; diff --git a/vcl/source/filter/graphicfilter2.cxx b/vcl/source/filter/graphicfilter2.cxx index 780d11d24eba..ba1d2180ab65 100644 --- a/vcl/source/filter/graphicfilter2.cxx +++ b/vcl/source/filter/graphicfilter2.cxx @@ -1099,31 +1099,31 @@ OUString GraphicDescriptor::GetImportFormatShortName( GraphicFileFormat nFormat switch( nFormat ) { - case( GraphicFileFormat::BMP ) : pKeyName = "bmp"; break; - case( GraphicFileFormat::GIF ) : pKeyName = "gif"; break; - case( GraphicFileFormat::JPG ) : pKeyName = "jpg"; break; - case( GraphicFileFormat::PCD ) : pKeyName = "pcd"; break; - case( GraphicFileFormat::PCX ) : pKeyName = "pcx"; break; - case( GraphicFileFormat::PNG ) : pKeyName = "png"; break; - case( GraphicFileFormat::XBM ) : pKeyName = "xbm"; break; - case( GraphicFileFormat::XPM ) : pKeyName = "xpm"; break; - case( GraphicFileFormat::PBM ) : pKeyName = "pbm"; break; - case( GraphicFileFormat::PGM ) : pKeyName = "pgm"; break; - case( GraphicFileFormat::PPM ) : pKeyName = "ppm"; break; - case( GraphicFileFormat::RAS ) : pKeyName = "ras"; break; - case( GraphicFileFormat::TGA ) : pKeyName = "tga"; break; - case( GraphicFileFormat::PSD ) : pKeyName = "psd"; break; - case( GraphicFileFormat::EPS ) : pKeyName = "eps"; break; - case( GraphicFileFormat::TIF ) : pKeyName = "tif"; break; - case( GraphicFileFormat::DXF ) : pKeyName = "dxf"; break; - case( GraphicFileFormat::MET ) : pKeyName = "met"; break; - case( GraphicFileFormat::PCT ) : pKeyName = "pct"; break; - case( GraphicFileFormat::SGF ) : pKeyName = "sgf"; break; - case( GraphicFileFormat::SGV ) : pKeyName = "sgv"; break; - case( GraphicFileFormat::SVM ) : pKeyName = "svm"; break; - case( GraphicFileFormat::WMF ) : pKeyName = "wmf"; break; - case( GraphicFileFormat::EMF ) : pKeyName = "emf"; break; - case( GraphicFileFormat::SVG ) : pKeyName = "svg"; break; + case GraphicFileFormat::BMP : pKeyName = "bmp"; break; + case GraphicFileFormat::GIF : pKeyName = "gif"; break; + case GraphicFileFormat::JPG : pKeyName = "jpg"; break; + case GraphicFileFormat::PCD : pKeyName = "pcd"; break; + case GraphicFileFormat::PCX : pKeyName = "pcx"; break; + case GraphicFileFormat::PNG : pKeyName = "png"; break; + case GraphicFileFormat::XBM : pKeyName = "xbm"; break; + case GraphicFileFormat::XPM : pKeyName = "xpm"; break; + case GraphicFileFormat::PBM : pKeyName = "pbm"; break; + case GraphicFileFormat::PGM : pKeyName = "pgm"; break; + case GraphicFileFormat::PPM : pKeyName = "ppm"; break; + case GraphicFileFormat::RAS : pKeyName = "ras"; break; + case GraphicFileFormat::TGA : pKeyName = "tga"; break; + case GraphicFileFormat::PSD : pKeyName = "psd"; break; + case GraphicFileFormat::EPS : pKeyName = "eps"; break; + case GraphicFileFormat::TIF : pKeyName = "tif"; break; + case GraphicFileFormat::DXF : pKeyName = "dxf"; break; + case GraphicFileFormat::MET : pKeyName = "met"; break; + case GraphicFileFormat::PCT : pKeyName = "pct"; break; + case GraphicFileFormat::SGF : pKeyName = "sgf"; break; + case GraphicFileFormat::SGV : pKeyName = "sgv"; break; + case GraphicFileFormat::SVM : pKeyName = "svm"; break; + case GraphicFileFormat::WMF : pKeyName = "wmf"; break; + case GraphicFileFormat::EMF : pKeyName = "emf"; break; + case GraphicFileFormat::SVG : pKeyName = "svg"; break; default: assert(false); } diff --git a/vcl/source/filter/wmf/emfwr.cxx b/vcl/source/filter/wmf/emfwr.cxx index 5438652aef72..ccfa8860510f 100644 --- a/vcl/source/filter/wmf/emfwr.cxx +++ b/vcl/source/filter/wmf/emfwr.cxx @@ -948,7 +948,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) switch( nType ) { - case( MetaActionType::PIXEL ): + case MetaActionType::PIXEL: { const MetaPixelAction* pA = static_cast<const MetaPixelAction*>(pAction); @@ -960,7 +960,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::POINT ): + case MetaActionType::POINT: { if( maVDev->IsLineColor() ) { @@ -975,7 +975,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::LINE ): + case MetaActionType::LINE: { if( maVDev->IsLineColor() ) { @@ -1010,7 +1010,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::RECT ): + case MetaActionType::RECT: { if( maVDev->IsLineColor() || maVDev->IsFillColor() ) { @@ -1026,7 +1026,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::ROUNDRECT ): + case MetaActionType::ROUNDRECT: { if( maVDev->IsLineColor() || maVDev->IsFillColor() ) { @@ -1043,7 +1043,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::ELLIPSE ): + case MetaActionType::ELLIPSE: { if( maVDev->IsLineColor() || maVDev->IsFillColor() ) { @@ -1059,10 +1059,10 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::ARC ): - case( MetaActionType::PIE ): - case( MetaActionType::CHORD ): - case( MetaActionType::POLYGON ): + case MetaActionType::ARC: + case MetaActionType::PIE: + case MetaActionType::CHORD: + case MetaActionType::POLYGON: { if( maVDev->IsLineColor() || maVDev->IsFillColor() ) { @@ -1070,28 +1070,28 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) switch( nType ) { - case( MetaActionType::ARC ): + case MetaActionType::ARC: { const MetaArcAction* pA = static_cast<const MetaArcAction*>(pAction); aPoly = tools::Polygon( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint(), PolyStyle::Arc ); } break; - case( MetaActionType::PIE ): + case MetaActionType::PIE: { const MetaPieAction* pA = static_cast<const MetaPieAction*>(pAction); aPoly = tools::Polygon( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint(), PolyStyle::Pie ); } break; - case( MetaActionType::CHORD ): + case MetaActionType::CHORD: { const MetaChordAction* pA = static_cast<const MetaChordAction*>(pAction); aPoly = tools::Polygon( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint(), PolyStyle::Chord ); } break; - case( MetaActionType::POLYGON ): + case MetaActionType::POLYGON: aPoly = static_cast<const MetaPolygonAction*>(pAction)->GetPolygon(); break; default: break; @@ -1102,7 +1102,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::POLYLINE ): + case MetaActionType::POLYLINE: { if( maVDev->IsLineColor() ) { @@ -1125,14 +1125,14 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::POLYPOLYGON ): + case MetaActionType::POLYPOLYGON: { if( maVDev->IsLineColor() || maVDev->IsFillColor() ) ImplWritePolyPolygonRecord( static_cast<const MetaPolyPolygonAction*>(pAction)->GetPolyPolygon() ); } break; - case( MetaActionType::GRADIENT ): + case MetaActionType::GRADIENT: { const MetaGradientAction* pA = static_cast<const MetaGradientAction*>(pAction); GDIMetaFile aTmpMtf; @@ -1200,7 +1200,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::EPS ): + case MetaActionType::EPS: { const MetaEPSAction* pA = static_cast<const MetaEPSAction*>(pAction); const GDIMetaFile aSubstitute( pA->GetSubstitute() ); @@ -1352,32 +1352,32 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::LINECOLOR ): + case MetaActionType::LINECOLOR: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); mbLineChanged = true; } break; - case( MetaActionType::FILLCOLOR ): + case MetaActionType::FILLCOLOR: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); mbFillChanged = true; } break; - case( MetaActionType::TEXTCOLOR ): - case( MetaActionType::TEXTLINECOLOR ): - case( MetaActionType::TEXTFILLCOLOR ): - case( MetaActionType::TEXTALIGN ): - case( MetaActionType::FONT ): + case MetaActionType::TEXTCOLOR: + case MetaActionType::TEXTLINECOLOR: + case MetaActionType::TEXTFILLCOLOR: + case MetaActionType::TEXTALIGN: + case MetaActionType::FONT: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); mbTextChanged = true; } break; - case( MetaActionType::ISECTRECTCLIPREGION ): + case MetaActionType::ISECTRECTCLIPREGION: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); @@ -1387,20 +1387,20 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::CLIPREGION ): - case( MetaActionType::ISECTREGIONCLIPREGION ): - case( MetaActionType::MOVECLIPREGION ): + case MetaActionType::CLIPREGION: + case MetaActionType::ISECTREGIONCLIPREGION: + case MetaActionType::MOVECLIPREGION: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); } break; - case( MetaActionType::REFPOINT ): - case( MetaActionType::MAPMODE ): + case MetaActionType::REFPOINT: + case MetaActionType::MAPMODE: const_cast<MetaAction*>(pAction)->Execute( maVDev ); break; - case( MetaActionType::PUSH ): + case MetaActionType::PUSH: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); @@ -1409,7 +1409,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::POP ): + case MetaActionType::POP: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); @@ -1422,14 +1422,14 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::RASTEROP ): + case MetaActionType::RASTEROP: { const_cast<MetaAction*>(pAction)->Execute( maVDev ); ImplWriteRasterOp( static_cast<const MetaRasterOpAction*>(pAction)->GetRasterOp() ); } break; - case( MetaActionType::LAYOUTMODE ): + case MetaActionType::LAYOUTMODE: { ComplexTextLayoutFlags nLayoutMode = static_cast<const MetaLayoutModeAction*>(pAction)->GetLayoutMode(); mnHorTextAlign = 0; @@ -1444,7 +1444,7 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) break; } - case( MetaActionType::COMMENT ): + case MetaActionType::COMMENT: { MetaCommentAction const*const pCommentAction( static_cast<MetaCommentAction const*>(pAction)); @@ -1458,12 +1458,12 @@ void EMFWriter::ImplWrite( const GDIMetaFile& rMtf ) } break; - case( MetaActionType::MASK ): - case( MetaActionType::MASKSCALE ): - case( MetaActionType::MASKSCALEPART ): - case( MetaActionType::WALLPAPER ): - case( MetaActionType::TEXTLINE ): - case( MetaActionType::GRADIENTEX ): + case MetaActionType::MASK: + case MetaActionType::MASKSCALE: + case MetaActionType::MASKSCALEPART: + case MetaActionType::WALLPAPER: + case MetaActionType::TEXTLINE: + case MetaActionType::GRADIENTEX: // Explicitly ignored cases break; diff --git a/vcl/source/filter/wmf/wmfwr.cxx b/vcl/source/filter/wmf/wmfwr.cxx index 8013c1e2f09c..51c7a6807bb5 100644 --- a/vcl/source/filter/wmf/wmfwr.cxx +++ b/vcl/source/filter/wmf/wmfwr.cxx @@ -1589,7 +1589,7 @@ void WMFWriter::WriteRecords( const GDIMetaFile & rMTF ) } break; - case( MetaActionType::LAYOUTMODE ): + case MetaActionType::LAYOUTMODE: { ComplexTextLayoutFlags nLayoutMode = static_cast<const MetaLayoutModeAction*>(pMA)->GetLayoutMode(); eSrcHorTextAlign = 0; // TA_LEFT diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx index 5fe087fa478e..f0b9ce1fbbbb 100644 --- a/vcl/source/gdi/gdimtf.cxx +++ b/vcl/source/gdi/gdimtf.cxx @@ -869,7 +869,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) switch( nActionType ) { - case( MetaActionType::PIXEL ): + case MetaActionType::PIXEL: { MetaPixelAction* pAct = static_cast<MetaPixelAction*>(pAction); aMtf.AddAction( new MetaPixelAction( ImplGetRotatedPoint( pAct->GetPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -877,14 +877,14 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::POINT ): + case MetaActionType::POINT: { MetaPointAction* pAct = static_cast<MetaPointAction*>(pAction); aMtf.AddAction( new MetaPointAction( ImplGetRotatedPoint( pAct->GetPoint(), aRotAnchor, aRotOffset, fSin, fCos ) ) ); } break; - case( MetaActionType::LINE ): + case MetaActionType::LINE: { MetaLineAction* pAct = static_cast<MetaLineAction*>(pAction); aMtf.AddAction( new MetaLineAction( ImplGetRotatedPoint( pAct->GetStartPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -893,14 +893,14 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::RECT ): + case MetaActionType::RECT: { MetaRectAction* pAct = static_cast<MetaRectAction*>(pAction); aMtf.AddAction( new MetaPolygonAction( ImplGetRotatedPolygon( pAct->GetRect(), aRotAnchor, aRotOffset, fSin, fCos ) ) ); } break; - case( MetaActionType::ROUNDRECT ): + case MetaActionType::ROUNDRECT: { MetaRoundRectAction* pAct = static_cast<MetaRoundRectAction*>(pAction); const tools::Polygon aRoundRectPoly( pAct->GetRect(), pAct->GetHorzRound(), pAct->GetVertRound() ); @@ -909,7 +909,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::ELLIPSE ): + case MetaActionType::ELLIPSE: { MetaEllipseAction* pAct = static_cast<MetaEllipseAction*>(pAction); const tools::Polygon aEllipsePoly( pAct->GetRect().Center(), pAct->GetRect().GetWidth() >> 1, pAct->GetRect().GetHeight() >> 1 ); @@ -918,7 +918,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::ARC ): + case MetaActionType::ARC: { MetaArcAction* pAct = static_cast<MetaArcAction*>(pAction); const tools::Polygon aArcPoly( pAct->GetRect(), pAct->GetStartPoint(), pAct->GetEndPoint(), PolyStyle::Arc ); @@ -927,7 +927,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::PIE ): + case MetaActionType::PIE: { MetaPieAction* pAct = static_cast<MetaPieAction*>(pAction); const tools::Polygon aPiePoly( pAct->GetRect(), pAct->GetStartPoint(), pAct->GetEndPoint(), PolyStyle::Pie ); @@ -936,7 +936,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::CHORD ): + case MetaActionType::CHORD: { MetaChordAction* pAct = static_cast<MetaChordAction*>(pAction); const tools::Polygon aChordPoly( pAct->GetRect(), pAct->GetStartPoint(), pAct->GetEndPoint(), PolyStyle::Chord ); @@ -945,28 +945,28 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::POLYLINE ): + case MetaActionType::POLYLINE: { MetaPolyLineAction* pAct = static_cast<MetaPolyLineAction*>(pAction); aMtf.AddAction( new MetaPolyLineAction( ImplGetRotatedPolygon( pAct->GetPolygon(), aRotAnchor, aRotOffset, fSin, fCos ), pAct->GetLineInfo() ) ); } break; - case( MetaActionType::POLYGON ): + case MetaActionType::POLYGON: { MetaPolygonAction* pAct = static_cast<MetaPolygonAction*>(pAction); aMtf.AddAction( new MetaPolygonAction( ImplGetRotatedPolygon( pAct->GetPolygon(), aRotAnchor, aRotOffset, fSin, fCos ) ) ); } break; - case( MetaActionType::POLYPOLYGON ): + case MetaActionType::POLYPOLYGON: { MetaPolyPolygonAction* pAct = static_cast<MetaPolyPolygonAction*>(pAction); aMtf.AddAction( new MetaPolyPolygonAction( ImplGetRotatedPolyPolygon( pAct->GetPolyPolygon(), aRotAnchor, aRotOffset, fSin, fCos ) ) ); } break; - case( MetaActionType::TEXT ): + case MetaActionType::TEXT: { MetaTextAction* pAct = static_cast<MetaTextAction*>(pAction); aMtf.AddAction( new MetaTextAction( ImplGetRotatedPoint( pAct->GetPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -974,7 +974,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::TEXTARRAY ): + case MetaActionType::TEXTARRAY: { MetaTextArrayAction* pAct = static_cast<MetaTextArrayAction*>(pAction); aMtf.AddAction( new MetaTextArrayAction( ImplGetRotatedPoint( pAct->GetPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -982,7 +982,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::STRETCHTEXT ): + case MetaActionType::STRETCHTEXT: { MetaStretchTextAction* pAct = static_cast<MetaStretchTextAction*>(pAction); aMtf.AddAction( new MetaStretchTextAction( ImplGetRotatedPoint( pAct->GetPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -990,7 +990,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::TEXTLINE ): + case MetaActionType::TEXTLINE: { MetaTextLineAction* pAct = static_cast<MetaTextLineAction*>(pAction); aMtf.AddAction( new MetaTextLineAction( ImplGetRotatedPoint( pAct->GetStartPoint(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -998,7 +998,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::BMPSCALE ): + case MetaActionType::BMPSCALE: { MetaBmpScaleAction* pAct = static_cast<MetaBmpScaleAction*>(pAction); tools::Polygon aBmpPoly( ImplGetRotatedPolygon( tools::Rectangle( pAct->GetPoint(), pAct->GetSize() ), aRotAnchor, aRotOffset, fSin, fCos ) ); @@ -1011,7 +1011,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::BMPSCALEPART ): + case MetaActionType::BMPSCALEPART: { MetaBmpScalePartAction* pAct = static_cast<MetaBmpScalePartAction*>(pAction); tools::Polygon aBmpPoly( ImplGetRotatedPolygon( tools::Rectangle( pAct->GetDestPoint(), pAct->GetDestSize() ), aRotAnchor, aRotOffset, fSin, fCos ) ); @@ -1025,7 +1025,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::BMPEXSCALE ): + case MetaActionType::BMPEXSCALE: { MetaBmpExScaleAction* pAct = static_cast<MetaBmpExScaleAction*>(pAction); tools::Polygon aBmpPoly( ImplGetRotatedPolygon( tools::Rectangle( pAct->GetPoint(), pAct->GetSize() ), aRotAnchor, aRotOffset, fSin, fCos ) ); @@ -1038,7 +1038,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::BMPEXSCALEPART ): + case MetaActionType::BMPEXSCALEPART: { MetaBmpExScalePartAction* pAct = static_cast<MetaBmpExScalePartAction*>(pAction); tools::Polygon aBmpPoly( ImplGetRotatedPolygon( tools::Rectangle( pAct->GetDestPoint(), pAct->GetDestSize() ), aRotAnchor, aRotOffset, fSin, fCos ) ); @@ -1052,7 +1052,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::GRADIENT ): + case MetaActionType::GRADIENT: { MetaGradientAction* pAct = static_cast<MetaGradientAction*>(pAction); @@ -1062,7 +1062,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::GRADIENTEX ): + case MetaActionType::GRADIENTEX: { MetaGradientExAction* pAct = static_cast<MetaGradientExAction*>(pAction); aMtf.AddAction( new MetaGradientExAction( ImplGetRotatedPolyPolygon( pAct->GetPolyPolygon(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -1071,7 +1071,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) break; // Handle gradientex comment block correctly - case( MetaActionType::COMMENT ): + case MetaActionType::COMMENT: { MetaCommentAction* pCommentAct = static_cast<MetaCommentAction*>(pAction); if( pCommentAct->GetComment() == "XGRAD_SEQ_BEGIN" ) @@ -1159,7 +1159,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::HATCH ): + case MetaActionType::HATCH: { MetaHatchAction* pAct = static_cast<MetaHatchAction*>(pAction); Hatch aHatch( pAct->GetHatch() ); @@ -1170,7 +1170,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::Transparent ): + case MetaActionType::Transparent: { MetaTransparentAction* pAct = static_cast<MetaTransparentAction*>(pAction); aMtf.AddAction( new MetaTransparentAction( ImplGetRotatedPolyPolygon( pAct->GetPolyPolygon(), aRotAnchor, aRotOffset, fSin, fCos ), @@ -1178,7 +1178,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::FLOATTRANSPARENT ): + case MetaActionType::FLOATTRANSPARENT: { MetaFloatTransparentAction* pAct = static_cast<MetaFloatTransparentAction*>(pAction); GDIMetaFile aTransMtf( pAct->GetGDIMetaFile() ); @@ -1191,7 +1191,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::EPS ): + case MetaActionType::EPS: { MetaEPSAction* pAct = static_cast<MetaEPSAction*>(pAction); GDIMetaFile aEPSMtf( pAct->GetSubstitute() ); @@ -1204,7 +1204,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::CLIPREGION ): + case MetaActionType::CLIPREGION: { MetaClipRegionAction* pAct = static_cast<MetaClipRegionAction*>(pAction); @@ -1218,7 +1218,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::ISECTRECTCLIPREGION ): + case MetaActionType::ISECTRECTCLIPREGION: { MetaISectRectClipRegionAction* pAct = static_cast<MetaISectRectClipRegionAction*>(pAction); aMtf.AddAction( new MetaISectRegionClipRegionAction(vcl::Region( @@ -1227,7 +1227,7 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::ISECTREGIONCLIPREGION ): + case MetaActionType::ISECTREGIONCLIPREGION: { MetaISectRegionClipRegionAction* pAct = static_cast<MetaISectRegionClipRegionAction*>(pAction); const vcl::Region& rRegion = pAct->GetRegion(); @@ -1242,14 +1242,14 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::REFPOINT ): + case MetaActionType::REFPOINT: { MetaRefPointAction* pAct = static_cast<MetaRefPointAction*>(pAction); aMtf.AddAction( new MetaRefPointAction( ImplGetRotatedPoint( pAct->GetRefPoint(), aRotAnchor, aRotOffset, fSin, fCos ), pAct->IsSetting() ) ); } break; - case( MetaActionType::FONT ): + case MetaActionType::FONT: { MetaFontAction* pAct = static_cast<MetaFontAction*>(pAction); vcl::Font aFont( pAct->GetFont() ); @@ -1259,14 +1259,14 @@ void GDIMetaFile::Rotate( long nAngle10 ) } break; - case( MetaActionType::BMP ): - case( MetaActionType::BMPEX ): - case( MetaActionType::MASK ): - case( MetaActionType::MASKSCALE ): - case( MetaActionType::MASKSCALEPART ): - case( MetaActionType::WALLPAPER ): - case( MetaActionType::TEXTRECT ): - case( MetaActionType::MOVECLIPREGION ): + case MetaActionType::BMP: + case MetaActionType::BMPEX: + case MetaActionType::MASK: + case MetaActionType::MASKSCALE: + case MetaActionType::MASKSCALEPART: + case MetaActionType::WALLPAPER: + case MetaActionType::TEXTRECT: + case MetaActionType::MOVECLIPREGION: { OSL_FAIL( "GDIMetaFile::Rotate(): unsupported action" ); } @@ -1349,7 +1349,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R switch( nActionType ) { - case( MetaActionType::PIXEL ): + case MetaActionType::PIXEL: { MetaPixelAction* pAct = static_cast<MetaPixelAction*>(pAction); ImplActionBounds( aBound, @@ -1359,7 +1359,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::POINT ): + case MetaActionType::POINT: { MetaPointAction* pAct = static_cast<MetaPointAction*>(pAction); ImplActionBounds( aBound, @@ -1369,7 +1369,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::LINE ): + case MetaActionType::LINE: { MetaLineAction* pAct = static_cast<MetaLineAction*>(pAction); Point aP1( pAct->GetStartPoint() ), aP2( pAct->GetEndPoint() ); @@ -1388,28 +1388,28 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::RECT ): + case MetaActionType::RECT: { MetaRectAction* pAct = static_cast<MetaRectAction*>(pAction); ImplActionBounds( aBound, OutputDevice::LogicToLogic( pAct->GetRect(), aMapVDev->GetMapMode(), GetPrefMapMode() ), aClipStack, pUseHairline ); } break; - case( MetaActionType::ROUNDRECT ): + case MetaActionType::ROUNDRECT: { MetaRoundRectAction* pAct = static_cast<MetaRoundRectAction*>(pAction); ImplActionBounds( aBound, OutputDevice::LogicToLogic( pAct->GetRect(), aMapVDev->GetMapMode(), GetPrefMapMode() ), aClipStack, pUseHairline ); } break; - case( MetaActionType::ELLIPSE ): + case MetaActionType::ELLIPSE: { MetaEllipseAction* pAct = static_cast<MetaEllipseAction*>(pAction); ImplActionBounds( aBound, OutputDevice::LogicToLogic( pAct->GetRect(), aMapVDev->GetMapMode(), GetPrefMapMode() ), aClipStack, pUseHairline ); } break; - case( MetaActionType::ARC ): + case MetaActionType::ARC: { MetaArcAction* pAct = static_cast<MetaArcAction*>(pAction); // FIXME: this is imprecise @@ -1418,7 +1418,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::PIE ): + case MetaActionType::PIE: { MetaPieAction* pAct = static_cast<MetaPieAction*>(pAction); // FIXME: this is imprecise @@ -1427,7 +1427,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::CHORD ): + case MetaActionType::CHORD: { MetaChordAction* pAct = static_cast<MetaChordAction*>(pAction); // FIXME: this is imprecise @@ -1436,7 +1436,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::POLYLINE ): + case MetaActionType::POLYLINE: { MetaPolyLineAction* pAct = static_cast<MetaPolyLineAction*>(pAction); tools::Rectangle aRect( pAct->GetPolygon().GetBoundRect() ); @@ -1453,7 +1453,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::POLYGON ): + case MetaActionType::POLYGON: { MetaPolygonAction* pAct = static_cast<MetaPolygonAction*>(pAction); tools::Rectangle aRect( pAct->GetPolygon().GetBoundRect() ); @@ -1461,7 +1461,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::POLYPOLYGON ): + case MetaActionType::POLYPOLYGON: { MetaPolyPolygonAction* pAct = static_cast<MetaPolyPolygonAction*>(pAction); tools::Rectangle aRect( pAct->GetPolyPolygon().GetBoundRect() ); @@ -1469,7 +1469,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::TEXT ): + case MetaActionType::TEXT: { MetaTextAction* pAct = static_cast<MetaTextAction*>(pAction); tools::Rectangle aRect; @@ -1481,7 +1481,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::TEXTARRAY ): + case MetaActionType::TEXTARRAY: { MetaTextArrayAction* pAct = static_cast<MetaTextArrayAction*>(pAction); tools::Rectangle aRect; @@ -1494,7 +1494,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::STRETCHTEXT ): + case MetaActionType::STRETCHTEXT: { MetaStretchTextAction* pAct = static_cast<MetaStretchTextAction*>(pAction); tools::Rectangle aRect; @@ -1507,7 +1507,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::TEXTLINE ): + case MetaActionType::TEXTLINE: { MetaTextLineAction* pAct = static_cast<MetaTextLineAction*>(pAction); // measure a test string to get ascend and descent right @@ -1523,7 +1523,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMPSCALE ): + case MetaActionType::BMPSCALE: { MetaBmpScaleAction* pAct = static_cast<MetaBmpScaleAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), pAct->GetSize() ); @@ -1531,7 +1531,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMPSCALEPART ): + case MetaActionType::BMPSCALEPART: { MetaBmpScalePartAction* pAct = static_cast<MetaBmpScalePartAction*>(pAction); tools::Rectangle aRect( pAct->GetDestPoint(), pAct->GetDestSize() ); @@ -1539,7 +1539,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMPEXSCALE ): + case MetaActionType::BMPEXSCALE: { MetaBmpExScaleAction* pAct = static_cast<MetaBmpExScaleAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), pAct->GetSize() ); @@ -1547,7 +1547,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMPEXSCALEPART ): + case MetaActionType::BMPEXSCALEPART: { MetaBmpExScalePartAction* pAct = static_cast<MetaBmpExScalePartAction*>(pAction); tools::Rectangle aRect( pAct->GetDestPoint(), pAct->GetDestSize() ); @@ -1555,7 +1555,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::GRADIENT ): + case MetaActionType::GRADIENT: { MetaGradientAction* pAct = static_cast<MetaGradientAction*>(pAction); tools::Rectangle aRect( pAct->GetRect() ); @@ -1563,7 +1563,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::GRADIENTEX ): + case MetaActionType::GRADIENTEX: { MetaGradientExAction* pAct = static_cast<MetaGradientExAction*>(pAction); tools::Rectangle aRect( pAct->GetPolyPolygon().GetBoundRect() ); @@ -1571,13 +1571,13 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::COMMENT ): + case MetaActionType::COMMENT: { // nothing to do }; break; - case( MetaActionType::HATCH ): + case MetaActionType::HATCH: { MetaHatchAction* pAct = static_cast<MetaHatchAction*>(pAction); tools::Rectangle aRect( pAct->GetPolyPolygon().GetBoundRect() ); @@ -1585,7 +1585,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::Transparent ): + case MetaActionType::Transparent: { MetaTransparentAction* pAct = static_cast<MetaTransparentAction*>(pAction); tools::Rectangle aRect( pAct->GetPolyPolygon().GetBoundRect() ); @@ -1593,7 +1593,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::FLOATTRANSPARENT ): + case MetaActionType::FLOATTRANSPARENT: { MetaFloatTransparentAction* pAct = static_cast<MetaFloatTransparentAction*>(pAction); // MetaFloatTransparentAction is defined limiting its content Metafile @@ -1603,7 +1603,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::EPS ): + case MetaActionType::EPS: { MetaEPSAction* pAct = static_cast<MetaEPSAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), pAct->GetSize() ); @@ -1611,7 +1611,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::CLIPREGION ): + case MetaActionType::CLIPREGION: { MetaClipRegionAction* pAct = static_cast<MetaClipRegionAction*>(pAction); if( pAct->IsClipping() ) @@ -1621,7 +1621,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::ISECTRECTCLIPREGION ): + case MetaActionType::ISECTRECTCLIPREGION: { MetaISectRectClipRegionAction* pAct = static_cast<MetaISectRectClipRegionAction*>(pAction); tools::Rectangle aRect( OutputDevice::LogicToLogic( pAct->GetRect(), aMapVDev->GetMapMode(), GetPrefMapMode() ) ); @@ -1632,7 +1632,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::ISECTREGIONCLIPREGION ): + case MetaActionType::ISECTREGIONCLIPREGION: { MetaISectRegionClipRegionAction* pAct = static_cast<MetaISectRegionClipRegionAction*>(pAction); tools::Rectangle aRect( OutputDevice::LogicToLogic( pAct->GetRegion().GetBoundRect(), aMapVDev->GetMapMode(), GetPrefMapMode() ) ); @@ -1643,7 +1643,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMP ): + case MetaActionType::BMP: { MetaBmpAction* pAct = static_cast<MetaBmpAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), aMapVDev->PixelToLogic( pAct->GetBitmap().GetSizePixel() ) ); @@ -1651,7 +1651,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::BMPEX ): + case MetaActionType::BMPEX: { MetaBmpExAction* pAct = static_cast<MetaBmpExAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), aMapVDev->PixelToLogic( pAct->GetBitmapEx().GetSizePixel() ) ); @@ -1659,7 +1659,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::MASK ): + case MetaActionType::MASK: { MetaMaskAction* pAct = static_cast<MetaMaskAction*>(pAction); tools::Rectangle aRect( pAct->GetPoint(), aMapVDev->PixelToLogic( pAct->GetBitmap().GetSizePixel() ) ); @@ -1667,7 +1667,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::MASKSCALE ): + case MetaActionType::MASKSCALE: { MetaMaskScalePartAction* pAct = static_cast<MetaMaskScalePartAction*>(pAction); tools::Rectangle aRect( pAct->GetDestPoint(), pAct->GetDestSize() ); @@ -1675,7 +1675,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::MASKSCALEPART ): + case MetaActionType::MASKSCALEPART: { MetaMaskScalePartAction* pAct = static_cast<MetaMaskScalePartAction*>(pAction); tools::Rectangle aRect( pAct->GetDestPoint(), pAct->GetDestSize() ); @@ -1683,7 +1683,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::WALLPAPER ): + case MetaActionType::WALLPAPER: { MetaWallpaperAction* pAct = static_cast<MetaWallpaperAction*>(pAction); tools::Rectangle aRect( pAct->GetRect() ); @@ -1691,7 +1691,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::TEXTRECT ): + case MetaActionType::TEXTRECT: { MetaTextRectAction* pAct = static_cast<MetaTextRectAction*>(pAction); tools::Rectangle aRect( pAct->GetRect() ); @@ -1699,7 +1699,7 @@ tools::Rectangle GDIMetaFile::GetBoundRect( OutputDevice& i_rReference, tools::R } break; - case( MetaActionType::MOVECLIPREGION ): + case MetaActionType::MOVECLIPREGION: { MetaMoveClipRegionAction* pAct = static_cast<MetaMoveClipRegionAction*>(pAction); if( ! aClipStack.back().IsEmpty() ) @@ -1854,14 +1854,14 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol switch( nType ) { - case( MetaActionType::PIXEL ): + case MetaActionType::PIXEL: { MetaPixelAction* pAct = static_cast<MetaPixelAction*>(pAction); aMtf.push_back( new MetaPixelAction( pAct->GetPoint(), pFncCol( pAct->GetColor(), pColParam ) ) ); } break; - case( MetaActionType::LINECOLOR ): + case MetaActionType::LINECOLOR: { MetaLineColorAction* pAct = static_cast<MetaLineColorAction*>(pAction); @@ -1874,7 +1874,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::FILLCOLOR ): + case MetaActionType::FILLCOLOR: { MetaFillColorAction* pAct = static_cast<MetaFillColorAction*>(pAction); @@ -1887,14 +1887,14 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::TEXTCOLOR ): + case MetaActionType::TEXTCOLOR: { MetaTextColorAction* pAct = static_cast<MetaTextColorAction*>(pAction); aMtf.push_back( new MetaTextColorAction( pFncCol( pAct->GetColor(), pColParam ) ) ); } break; - case( MetaActionType::TEXTFILLCOLOR ): + case MetaActionType::TEXTFILLCOLOR: { MetaTextFillColorAction* pAct = static_cast<MetaTextFillColorAction*>(pAction); @@ -1907,7 +1907,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::TEXTLINECOLOR ): + case MetaActionType::TEXTLINECOLOR: { MetaTextLineColorAction* pAct = static_cast<MetaTextLineColorAction*>(pAction); @@ -1920,7 +1920,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::OVERLINECOLOR ): + case MetaActionType::OVERLINECOLOR: { MetaOverlineColorAction* pAct = static_cast<MetaOverlineColorAction*>(pAction); @@ -1933,7 +1933,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::FONT ): + case MetaActionType::FONT: { MetaFontAction* pAct = static_cast<MetaFontAction*>(pAction); vcl::Font aFont( pAct->GetFont() ); @@ -1944,7 +1944,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::WALLPAPER ): + case MetaActionType::WALLPAPER: { MetaWallpaperAction* pAct = static_cast<MetaWallpaperAction*>(pAction); Wallpaper aWall( pAct->GetWallpaper() ); @@ -1968,15 +1968,15 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::BMP ): - case( MetaActionType::BMPEX ): - case( MetaActionType::MASK ): + case MetaActionType::BMP: + case MetaActionType::BMPEX: + case MetaActionType::MASK: { OSL_FAIL( "Don't use bitmap actions of this type in metafiles!" ); } break; - case( MetaActionType::BMPSCALE ): + case MetaActionType::BMPSCALE: { MetaBmpScaleAction* pAct = static_cast<MetaBmpScaleAction*>(pAction); aMtf.push_back( new MetaBmpScaleAction( pAct->GetPoint(), pAct->GetSize(), @@ -1984,7 +1984,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::BMPSCALEPART ): + case MetaActionType::BMPSCALEPART: { MetaBmpScalePartAction* pAct = static_cast<MetaBmpScalePartAction*>(pAction); aMtf.push_back( new MetaBmpScalePartAction( pAct->GetDestPoint(), pAct->GetDestSize(), @@ -1994,7 +1994,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::BMPEXSCALE ): + case MetaActionType::BMPEXSCALE: { MetaBmpExScaleAction* pAct = static_cast<MetaBmpExScaleAction*>(pAction); aMtf.push_back( new MetaBmpExScaleAction( pAct->GetPoint(), pAct->GetSize(), @@ -2003,7 +2003,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::BMPEXSCALEPART ): + case MetaActionType::BMPEXSCALEPART: { MetaBmpExScalePartAction* pAct = static_cast<MetaBmpExScalePartAction*>(pAction); aMtf.push_back( new MetaBmpExScalePartAction( pAct->GetDestPoint(), pAct->GetDestSize(), @@ -2013,7 +2013,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::MASKSCALE ): + case MetaActionType::MASKSCALE: { MetaMaskScaleAction* pAct = static_cast<MetaMaskScaleAction*>(pAction); aMtf.push_back( new MetaMaskScaleAction( pAct->GetPoint(), pAct->GetSize(), @@ -2023,7 +2023,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::MASKSCALEPART ): + case MetaActionType::MASKSCALEPART: { MetaMaskScalePartAction* pAct = static_cast<MetaMaskScalePartAction*>(pAction); aMtf.push_back( new MetaMaskScalePartAction( pAct->GetDestPoint(), pAct->GetDestSize(), @@ -2034,7 +2034,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::GRADIENT ): + case MetaActionType::GRADIENT: { MetaGradientAction* pAct = static_cast<MetaGradientAction*>(pAction); Gradient aGradient( pAct->GetGradient() ); @@ -2045,7 +2045,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::GRADIENTEX ): + case MetaActionType::GRADIENTEX: { MetaGradientExAction* pAct = static_cast<MetaGradientExAction*>(pAction); Gradient aGradient( pAct->GetGradient() ); @@ -2056,7 +2056,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::HATCH ): + case MetaActionType::HATCH: { MetaHatchAction* pAct = static_cast<MetaHatchAction*>(pAction); Hatch aHatch( pAct->GetHatch() ); @@ -2066,7 +2066,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::FLOATTRANSPARENT ): + case MetaActionType::FLOATTRANSPARENT: { MetaFloatTransparentAction* pAct = static_cast<MetaFloatTransparentAction*>(pAction); GDIMetaFile aTransMtf( pAct->GetGDIMetaFile() ); @@ -2079,7 +2079,7 @@ void GDIMetaFile::ImplExchangeColors( ColorExchangeFnc pFncCol, const void* pCol } break; - case( MetaActionType::EPS ): + case MetaActionType::EPS: { MetaEPSAction* pAct = static_cast<MetaEPSAction*>(pAction); GDIMetaFile aSubst( pAct->GetSubstitute() ); @@ -2278,7 +2278,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const switch( pAction->GetType() ) { - case( MetaActionType::BMP ): + case MetaActionType::BMP: { MetaBmpAction* pAct = static_cast<MetaBmpAction*>(pAction); @@ -2296,7 +2296,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::BMPSCALE ): + case MetaActionType::BMPSCALE: { MetaBmpScaleAction* pAct = static_cast<MetaBmpScaleAction*>(pAction); @@ -2320,7 +2320,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::BMPSCALEPART ): + case MetaActionType::BMPSCALEPART: { MetaBmpScalePartAction* pAct = static_cast<MetaBmpScalePartAction*>(pAction); @@ -2356,7 +2356,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::BMPEX ): + case MetaActionType::BMPEX: { MetaBmpExAction* pAct = static_cast<MetaBmpExAction*>(pAction); @@ -2374,7 +2374,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::BMPEXSCALE ): + case MetaActionType::BMPEXSCALE: { MetaBmpExScaleAction* pAct = static_cast<MetaBmpExScaleAction*>(pAction); @@ -2398,7 +2398,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::BMPEXSCALEPART ): + case MetaActionType::BMPEXSCALEPART: { MetaBmpExScalePartAction* pAct = static_cast<MetaBmpExScalePartAction*>(pAction); @@ -2434,7 +2434,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::MASK ): + case MetaActionType::MASK: { MetaMaskAction* pAct = static_cast<MetaMaskAction*>(pAction); @@ -2455,7 +2455,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::MASKSCALE ): + case MetaActionType::MASKSCALE: { MetaMaskScaleAction* pAct = static_cast<MetaMaskScaleAction*>(pAction); @@ -2482,7 +2482,7 @@ BitmapChecksum GDIMetaFile::GetChecksum() const } break; - case( MetaActionType::MASKSCALEPART ): + case MetaActionType::MASKSCALEPART: { MetaMaskScalePartAction* pAct = static_cast<MetaMaskScalePartAction*>(pAction); @@ -2621,21 +2621,21 @@ sal_uLong GDIMetaFile::GetSizeBytes() const // add sizes for large action content switch( pAction->GetType() ) { - case( MetaActionType::BMP ): nSizeBytes += static_cast<MetaBmpAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::BMPSCALE ): nSizeBytes += static_cast<MetaBmpScaleAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::BMPSCALEPART ): nSizeBytes += static_cast<MetaBmpScalePartAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::BMP: nSizeBytes += static_cast<MetaBmpAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::BMPSCALE: nSizeBytes += static_cast<MetaBmpScaleAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::BMPSCALEPART: nSizeBytes += static_cast<MetaBmpScalePartAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::BMPEX ): nSizeBytes += static_cast<MetaBmpExAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; - case( MetaActionType::BMPEXSCALE ): nSizeBytes += static_cast<MetaBmpExScaleAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; - case( MetaActionType::BMPEXSCALEPART ): nSizeBytes += static_cast<MetaBmpExScalePartAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; + case MetaActionType::BMPEX: nSizeBytes += static_cast<MetaBmpExAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; + case MetaActionType::BMPEXSCALE: nSizeBytes += static_cast<MetaBmpExScaleAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; + case MetaActionType::BMPEXSCALEPART: nSizeBytes += static_cast<MetaBmpExScalePartAction*>( pAction )->GetBitmapEx().GetSizeBytes(); break; - case( MetaActionType::MASK ): nSizeBytes += static_cast<MetaMaskAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::MASKSCALE ): nSizeBytes += static_cast<MetaMaskScaleAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::MASKSCALEPART ): nSizeBytes += static_cast<MetaMaskScalePartAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::MASK: nSizeBytes += static_cast<MetaMaskAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::MASKSCALE: nSizeBytes += static_cast<MetaMaskScaleAction*>( pAction )->GetBitmap().GetSizeBytes(); break; + case MetaActionType::MASKSCALEPART: nSizeBytes += static_cast<MetaMaskScalePartAction*>( pAction )->GetBitmap().GetSizeBytes(); break; - case( MetaActionType::POLYLINE ): nSizeBytes += static_cast<MetaPolyLineAction*>( pAction )->GetPolygon().GetSize() * sizeof( Point ); break; - case( MetaActionType::POLYGON ): nSizeBytes += static_cast<MetaPolygonAction*>( pAction )->GetPolygon().GetSize() * sizeof( Point ); break; - case( MetaActionType::POLYPOLYGON ): + case MetaActionType::POLYLINE: nSizeBytes += static_cast<MetaPolyLineAction*>( pAction )->GetPolygon().GetSize() * sizeof( Point ); break; + case MetaActionType::POLYGON: nSizeBytes += static_cast<MetaPolygonAction*>( pAction )->GetPolygon().GetSize() * sizeof( Point ); break; + case MetaActionType::POLYPOLYGON: { const tools::PolyPolygon& rPolyPoly = static_cast<MetaPolyPolygonAction*>( pAction )->GetPolyPolygon(); @@ -2644,10 +2644,10 @@ sal_uLong GDIMetaFile::GetSizeBytes() const } break; - case( MetaActionType::TEXT ): nSizeBytes += static_cast<MetaTextAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; - case( MetaActionType::STRETCHTEXT ): nSizeBytes += static_cast<MetaStretchTextAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; - case( MetaActionType::TEXTRECT ): nSizeBytes += static_cast<MetaTextRectAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; - case( MetaActionType::TEXTARRAY ): + case MetaActionType::TEXT: nSizeBytes += static_cast<MetaTextAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; + case MetaActionType::STRETCHTEXT: nSizeBytes += static_cast<MetaStretchTextAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; + case MetaActionType::TEXTRECT: nSizeBytes += static_cast<MetaTextRectAction*>( pAction )->GetText().getLength() * sizeof( sal_Unicode ); break; + case MetaActionType::TEXTARRAY: { MetaTextArrayAction* pTextArrayAction = static_cast<MetaTextArrayAction*>(pAction); diff --git a/vcl/source/gdi/pdfwriter_impl2.cxx b/vcl/source/gdi/pdfwriter_impl2.cxx index 94a3772a00c7..b7ce3650f65f 100644 --- a/vcl/source/gdi/pdfwriter_impl2.cxx +++ b/vcl/source/gdi/pdfwriter_impl2.cxx @@ -273,21 +273,21 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa switch( nType ) { - case( MetaActionType::PIXEL ): + case MetaActionType::PIXEL: { const MetaPixelAction* pA = static_cast<const MetaPixelAction*>(pAction); m_rOuterFace.DrawPixel( pA->GetPoint(), pA->GetColor() ); } break; - case( MetaActionType::POINT ): + case MetaActionType::POINT: { const MetaPointAction* pA = static_cast<const MetaPointAction*>(pAction); m_rOuterFace.DrawPixel( pA->GetPoint() ); } break; - case( MetaActionType::LINE ): + case MetaActionType::LINE: { const MetaLineAction* pA = static_cast<const MetaLineAction*>(pAction); if ( pA->GetLineInfo().IsDefault() ) @@ -297,56 +297,56 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::RECT ): + case MetaActionType::RECT: { const MetaRectAction* pA = static_cast<const MetaRectAction*>(pAction); m_rOuterFace.DrawRect( pA->GetRect() ); } break; - case( MetaActionType::ROUNDRECT ): + case MetaActionType::ROUNDRECT: { const MetaRoundRectAction* pA = static_cast<const MetaRoundRectAction*>(pAction); m_rOuterFace.DrawRect( pA->GetRect(), pA->GetHorzRound(), pA->GetVertRound() ); } break; - case( MetaActionType::ELLIPSE ): + case MetaActionType::ELLIPSE: { const MetaEllipseAction* pA = static_cast<const MetaEllipseAction*>(pAction); m_rOuterFace.DrawEllipse( pA->GetRect() ); } break; - case( MetaActionType::ARC ): + case MetaActionType::ARC: { const MetaArcAction* pA = static_cast<const MetaArcAction*>(pAction); m_rOuterFace.DrawArc( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint() ); } break; - case( MetaActionType::PIE ): + case MetaActionType::PIE: { const MetaArcAction* pA = static_cast<const MetaArcAction*>(pAction); m_rOuterFace.DrawPie( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint() ); } break; - case( MetaActionType::CHORD ): + case MetaActionType::CHORD: { const MetaChordAction* pA = static_cast<const MetaChordAction*>(pAction); m_rOuterFace.DrawChord( pA->GetRect(), pA->GetStartPoint(), pA->GetEndPoint() ); } break; - case( MetaActionType::POLYGON ): + case MetaActionType::POLYGON: { const MetaPolygonAction* pA = static_cast<const MetaPolygonAction*>(pAction); m_rOuterFace.DrawPolygon( pA->GetPolygon() ); } break; - case( MetaActionType::POLYLINE ): + case MetaActionType::POLYLINE: { const MetaPolyLineAction* pA = static_cast<const MetaPolyLineAction*>(pAction); if ( pA->GetLineInfo().IsDefault() ) @@ -356,14 +356,14 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::POLYPOLYGON ): + case MetaActionType::POLYPOLYGON: { const MetaPolyPolygonAction* pA = static_cast<const MetaPolyPolygonAction*>(pAction); m_rOuterFace.DrawPolyPolygon( pA->GetPolyPolygon() ); } break; - case( MetaActionType::GRADIENT ): + case MetaActionType::GRADIENT: { const MetaGradientAction* pA = static_cast<const MetaGradientAction*>(pAction); const Gradient& rGradient = pA->GetGradient(); @@ -379,7 +379,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::GRADIENTEX ): + case MetaActionType::GRADIENTEX: { const MetaGradientExAction* pA = static_cast<const MetaGradientExAction*>(pAction); const Gradient& rGradient = pA->GetGradient(); @@ -398,14 +398,14 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::Transparent ): + case MetaActionType::Transparent: { const MetaTransparentAction* pA = static_cast<const MetaTransparentAction*>(pAction); m_rOuterFace.DrawTransparent( pA->GetPolyPolygon(), pA->GetTransparence() ); } break; - case( MetaActionType::FLOATTRANSPARENT ): + case MetaActionType::FLOATTRANSPARENT: { const MetaFloatTransparentAction* pA = static_cast<const MetaFloatTransparentAction*>(pAction); @@ -500,7 +500,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::EPS ): + case MetaActionType::EPS: { const MetaEPSAction* pA = static_cast<const MetaEPSAction*>(pAction); const GDIMetaFile aSubstitute( pA->GetSubstitute() ); @@ -522,7 +522,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::COMMENT ): + case MetaActionType::COMMENT: if( ! i_rContext.m_bTransparenciesWereRemoved ) { const MetaCommentAction* pA = static_cast<const MetaCommentAction*>(pAction); @@ -784,7 +784,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMP ): + case MetaActionType::BMP: { const MetaBmpAction* pA = static_cast<const MetaBmpAction*>(pAction); BitmapEx aBitmapEx( pA->GetBitmap() ); @@ -798,7 +798,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMPSCALE ): + case MetaActionType::BMPSCALE: { const MetaBmpScaleAction* pA = static_cast<const MetaBmpScaleAction*>(pAction); Graphic aGraphic = i_pOutDevData ? i_pOutDevData->GetCurrentGraphic() : Graphic(); @@ -806,7 +806,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMPSCALEPART ): + case MetaActionType::BMPSCALEPART: { const MetaBmpScalePartAction* pA = static_cast<const MetaBmpScalePartAction*>(pAction); BitmapEx aBitmapEx( pA->GetBitmap() ); @@ -816,7 +816,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMPEX ): + case MetaActionType::BMPEX: { const MetaBmpExAction* pA = static_cast<const MetaBmpExAction*>(pAction); BitmapEx aBitmapEx( pA->GetBitmapEx() ); @@ -827,7 +827,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMPEXSCALE ): + case MetaActionType::BMPEXSCALE: { const MetaBmpExScaleAction* pA = static_cast<const MetaBmpExScaleAction*>(pAction); Graphic aGraphic = i_pOutDevData ? i_pOutDevData->GetCurrentGraphic() : Graphic(); @@ -835,7 +835,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::BMPEXSCALEPART ): + case MetaActionType::BMPEXSCALEPART: { const MetaBmpExScalePartAction* pA = static_cast<const MetaBmpExScalePartAction*>(pAction); BitmapEx aBitmapEx( pA->GetBitmapEx() ); @@ -845,43 +845,43 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::MASK ): - case( MetaActionType::MASKSCALE ): - case( MetaActionType::MASKSCALEPART ): + case MetaActionType::MASK: + case MetaActionType::MASKSCALE: + case MetaActionType::MASKSCALEPART: { SAL_WARN( "vcl", "MetaMask...Action not supported yet" ); } break; - case( MetaActionType::TEXT ): + case MetaActionType::TEXT: { const MetaTextAction* pA = static_cast<const MetaTextAction*>(pAction); m_rOuterFace.DrawText( pA->GetPoint(), pA->GetText().copy( pA->GetIndex(), std::min<sal_Int32>(pA->GetText().getLength() - pA->GetIndex(), pA->GetLen()) ) ); } break; - case( MetaActionType::TEXTRECT ): + case MetaActionType::TEXTRECT: { const MetaTextRectAction* pA = static_cast<const MetaTextRectAction*>(pAction); m_rOuterFace.DrawText( pA->GetRect(), pA->GetText(), pA->GetStyle() ); } break; - case( MetaActionType::TEXTARRAY ): + case MetaActionType::TEXTARRAY: { const MetaTextArrayAction* pA = static_cast<const MetaTextArrayAction*>(pAction); m_rOuterFace.DrawTextArray( pA->GetPoint(), pA->GetText(), pA->GetDXArray(), pA->GetIndex(), pA->GetLen() ); } break; - case( MetaActionType::STRETCHTEXT ): + case MetaActionType::STRETCHTEXT: { const MetaStretchTextAction* pA = static_cast<const MetaStretchTextAction*>(pAction); m_rOuterFace.DrawStretchText( pA->GetPoint(), pA->GetWidth(), pA->GetText(), pA->GetIndex(), pA->GetLen() ); } break; - case( MetaActionType::TEXTLINE ): + case MetaActionType::TEXTLINE: { const MetaTextLineAction* pA = static_cast<const MetaTextLineAction*>(pAction); m_rOuterFace.DrawTextLine( pA->GetStartPoint(), pA->GetWidth(), pA->GetStrikeout(), pA->GetUnderline(), pA->GetOverline() ); @@ -889,7 +889,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::CLIPREGION ): + case MetaActionType::CLIPREGION: { const MetaClipRegionAction* pA = static_cast<const MetaClipRegionAction*>(pAction); @@ -908,14 +908,14 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::ISECTRECTCLIPREGION ): + case MetaActionType::ISECTRECTCLIPREGION: { const MetaISectRectClipRegionAction* pA = static_cast<const MetaISectRectClipRegionAction*>(pAction); m_rOuterFace.IntersectClipRegion( pA->GetRect() ); } break; - case( MetaActionType::ISECTREGIONCLIPREGION ): + case MetaActionType::ISECTREGIONCLIPREGION: { const MetaISectRegionClipRegionAction* pA = static_cast<const MetaISectRegionClipRegionAction*>(pAction); vcl::Region aReg( pA->GetRegion() ); @@ -923,21 +923,21 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::MOVECLIPREGION ): + case MetaActionType::MOVECLIPREGION: { const MetaMoveClipRegionAction* pA = static_cast<const MetaMoveClipRegionAction*>(pAction); m_rOuterFace.MoveClipRegion( pA->GetHorzMove(), pA->GetVertMove() ); } break; - case( MetaActionType::MAPMODE ): + case MetaActionType::MAPMODE: { const_cast< MetaAction* >( pAction )->Execute( pDummyVDev ); m_rOuterFace.SetMapMode( pDummyVDev->GetMapMode() ); } break; - case( MetaActionType::LINECOLOR ): + case MetaActionType::LINECOLOR: { const MetaLineColorAction* pA = static_cast<const MetaLineColorAction*>(pAction); @@ -948,7 +948,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::FILLCOLOR ): + case MetaActionType::FILLCOLOR: { const MetaFillColorAction* pA = static_cast<const MetaFillColorAction*>(pAction); @@ -959,7 +959,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::TEXTLINECOLOR ): + case MetaActionType::TEXTLINECOLOR: { const MetaTextLineColorAction* pA = static_cast<const MetaTextLineColorAction*>(pAction); @@ -970,7 +970,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::OVERLINECOLOR ): + case MetaActionType::OVERLINECOLOR: { const MetaOverlineColorAction* pA = static_cast<const MetaOverlineColorAction*>(pAction); @@ -981,7 +981,7 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::TEXTFILLCOLOR ): + case MetaActionType::TEXTFILLCOLOR: { const MetaTextFillColorAction* pA = static_cast<const MetaTextFillColorAction*>(pAction); @@ -992,28 +992,28 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::TEXTCOLOR ): + case MetaActionType::TEXTCOLOR: { const MetaTextColorAction* pA = static_cast<const MetaTextColorAction*>(pAction); m_rOuterFace.SetTextColor( pA->GetColor() ); } break; - case( MetaActionType::TEXTALIGN ): + case MetaActionType::TEXTALIGN: { const MetaTextAlignAction* pA = static_cast<const MetaTextAlignAction*>(pAction); m_rOuterFace.SetTextAlign( pA->GetTextAlign() ); } break; - case( MetaActionType::FONT ): + case MetaActionType::FONT: { const MetaFontAction* pA = static_cast<const MetaFontAction*>(pAction); m_rOuterFace.SetFont( pA->GetFont() ); } break; - case( MetaActionType::PUSH ): + case MetaActionType::PUSH: { const MetaPushAction* pA = static_cast<const MetaPushAction*>(pAction); @@ -1022,14 +1022,14 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::POP ): + case MetaActionType::POP: { pDummyVDev->Pop(); m_rOuterFace.Pop(); } break; - case( MetaActionType::LAYOUTMODE ): + case MetaActionType::LAYOUTMODE: { const MetaLayoutModeAction* pA = static_cast<const MetaLayoutModeAction*>(pAction); m_rOuterFace.SetLayoutMode( pA->GetLayoutMode() ); @@ -1043,20 +1043,20 @@ void PDFWriterImpl::playMetafile( const GDIMetaFile& i_rMtf, vcl::PDFExtOutDevDa } break; - case( MetaActionType::WALLPAPER ): + case MetaActionType::WALLPAPER: { const MetaWallpaperAction* pA = static_cast<const MetaWallpaperAction*>(pAction); m_rOuterFace.DrawWallpaper( pA->GetRect(), pA->GetWallpaper() ); } break; - case( MetaActionType::RASTEROP ): + case MetaActionType::RASTEROP: { // !!! >>> we don't want to support this actions } break; - case( MetaActionType::REFPOINT ): + case MetaActionType::REFPOINT: { // !!! >>> we don't want to support this actions } diff --git a/vcl/source/outdev/mask.cxx b/vcl/source/outdev/mask.cxx index 5ce47c676e84..17cd06e4ba68 100644 --- a/vcl/source/outdev/mask.cxx +++ b/vcl/source/outdev/mask.cxx @@ -64,17 +64,17 @@ void OutputDevice::DrawMask( const Point& rDestPt, const Size& rDestSize, { switch( nAction ) { - case( MetaActionType::MASK ): + case MetaActionType::MASK: mpMetaFile->AddAction( new MetaMaskAction( rDestPt, rBitmap, rMaskColor ) ); break; - case( MetaActionType::MASKSCALE ): + case MetaActionType::MASKSCALE: mpMetaFile->AddAction( new MetaMaskScaleAction( rDestPt, rDestSize, rBitmap, rMaskColor ) ); break; - case( MetaActionType::MASKSCALEPART ): + case MetaActionType::MASKSCALEPART: mpMetaFile->AddAction( new MetaMaskScalePartAction( rDestPt, rDestSize, rSrcPtPixel, rSrcSizePixel, rBitmap, rMaskColor ) ); break; diff --git a/vcl/source/outdev/wallpaper.cxx b/vcl/source/outdev/wallpaper.cxx index bb22f2be95ea..e6aaf70e23cd 100644 --- a/vcl/source/outdev/wallpaper.cxx +++ b/vcl/source/outdev/wallpaper.cxx @@ -187,7 +187,7 @@ void OutputDevice::DrawBitmapWallpaper( long nX, long nY, switch( eStyle ) { - case( WallpaperStyle::Scale ): + case WallpaperStyle::Scale: if( !pCached || ( pCached->GetSizePixel() != aSize ) ) { if( pCached ) @@ -199,41 +199,41 @@ void OutputDevice::DrawBitmapWallpaper( long nX, long nY, } break; - case( WallpaperStyle::TopLeft ): + case WallpaperStyle::TopLeft: break; - case( WallpaperStyle::Top ): + case WallpaperStyle::Top: aPos.X() += ( aSize.Width() - nBmpWidth ) >> 1; break; - case( WallpaperStyle::TopRight ): + case WallpaperStyle::TopRight: aPos.X() += ( aSize.Width() - nBmpWidth ); break; - case( WallpaperStyle::Left ): + case WallpaperStyle::Left: aPos.Y() += ( aSize.Height() - nBmpHeight ) >> 1; break; - case( WallpaperStyle::Center ): + case WallpaperStyle::Center: aPos.X() += ( aSize.Width() - nBmpWidth ) >> 1; aPos.Y() += ( aSize.Height() - nBmpHeight ) >> 1; break; - case( WallpaperStyle::Right ): + case WallpaperStyle::Right: aPos.X() += ( aSize.Width() - nBmpWidth ); aPos.Y() += ( aSize.Height() - nBmpHeight ) >> 1; break; - case( WallpaperStyle::BottomLeft ): + case WallpaperStyle::BottomLeft: aPos.Y() += ( aSize.Height() - nBmpHeight ); break; - case( WallpaperStyle::Bottom ): + case WallpaperStyle::Bottom: aPos.X() += ( aSize.Width() - nBmpWidth ) >> 1; aPos.Y() += ( aSize.Height() - nBmpHeight ); break; - case( WallpaperStyle::BottomRight ): + case WallpaperStyle::BottomRight: aPos.X() += ( aSize.Width() - nBmpWidth ); aPos.Y() += ( aSize.Height() - nBmpHeight ); break; diff --git a/vcl/source/window/scrwnd.cxx b/vcl/source/window/scrwnd.cxx index 7127f2e7c22b..5e88bef81649 100644 --- a/vcl/source/window/scrwnd.cxx +++ b/vcl/source/window/scrwnd.cxx @@ -324,14 +324,14 @@ void ImplWheelWindow::MouseMove( const MouseEvent& rMEvt ) { switch( eActStyle ) { - case( PointerStyle::AutoScrollN ): mnActDeltaX = +0; mnActDeltaY = +1; break; - case( PointerStyle::AutoScrollS ): mnActDeltaX = +0; mnActDeltaY = -1; break; - case( PointerStyle::AutoScrollW ): mnActDeltaX = +1; mnActDeltaY = +0; break; - case( PointerStyle::AutoScrollE ): mnActDeltaX = -1; mnActDeltaY = +0; break; - case( PointerStyle::AutoScrollNW ): mnActDeltaX = +1; mnActDeltaY = +1; break; - case( PointerStyle::AutoScrollNE ): mnActDeltaX = -1; mnActDeltaY = +1; break; - case( PointerStyle::AutoScrollSW ): mnActDeltaX = +1; mnActDeltaY = -1; break; - case( PointerStyle::AutoScrollSE ): mnActDeltaX = -1; mnActDeltaY = -1; break; + case PointerStyle::AutoScrollN: mnActDeltaX = +0; mnActDeltaY = +1; break; + case PointerStyle::AutoScrollS: mnActDeltaX = +0; mnActDeltaY = -1; break; + case PointerStyle::AutoScrollW: mnActDeltaX = +1; mnActDeltaY = +0; break; + case PointerStyle::AutoScrollE: mnActDeltaX = -1; mnActDeltaY = +0; break; + case PointerStyle::AutoScrollNW: mnActDeltaX = +1; mnActDeltaY = +1; break; + case PointerStyle::AutoScrollNE: mnActDeltaX = -1; mnActDeltaY = +1; break; + case PointerStyle::AutoScrollSW: mnActDeltaX = +1; mnActDeltaY = -1; break; + case PointerStyle::AutoScrollSE: mnActDeltaX = -1; mnActDeltaY = -1; break; default: break; |