[Libreoffice-commits] core.git: basctl/source basic/source compilerplugins/clang cppuhelper/source cui/source desktop/source emfio/source extensions/source filter/source framework/source package/source reportdesign/source sccomp/source sc/source sd/source sfx2/source slideshow/source starmath/source svtools/source svx/source sw/source vcl/source vcl/unx vcl/workben

Noel Grandin noel.grandin at collabora.co.uk
Mon Feb 26 06:21:46 UTC 2018


 basctl/source/dlged/dlged.cxx                                |    3 --
 basic/source/classes/sbunoobj.cxx                            |    3 --
 compilerplugins/clang/oncevar.cxx                            |    9 +++++-
 cppuhelper/source/servicemanager.cxx                         |    2 -
 cui/source/dialogs/hlmarkwn.cxx                              |    3 --
 cui/source/options/optcolor.cxx                              |    3 --
 cui/source/tabpages/tptrans.cxx                              |    3 --
 desktop/source/lib/init.cxx                                  |    2 -
 emfio/source/reader/mtftools.cxx                             |    3 --
 extensions/source/bibliography/toolbar.cxx                   |    3 --
 filter/source/graphicfilter/ipsd/ipsd.cxx                    |    3 --
 filter/source/msfilter/eschesdo.cxx                          |    4 --
 filter/source/msfilter/msdffimp.cxx                          |    3 --
 filter/source/pdf/pdfexport.cxx                              |    3 --
 filter/source/svg/svgwriter.cxx                              |    3 --
 framework/source/uielement/menubarmanager.cxx                |    3 --
 package/source/zippackage/ZipPackage.cxx                     |    4 --
 reportdesign/source/ui/dlg/Condition.cxx                     |    3 --
 sc/source/core/data/stlpool.cxx                              |    3 --
 sc/source/core/tool/autoform.cxx                             |    3 --
 sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx |    9 ++----
 sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx   |    3 --
 sc/source/ui/Accessibility/AccessiblePreviewTable.cxx        |    3 --
 sc/source/ui/Accessibility/AccessibleText.cxx                |   12 ++------
 sc/source/ui/app/drwtrans.cxx                                |    3 --
 sc/source/ui/app/transobj.cxx                                |    3 --
 sc/source/ui/dbgui/csvgrid.cxx                               |    3 --
 sc/source/ui/dbgui/csvruler.cxx                              |    3 --
 sc/source/ui/miscdlgs/autofmt.cxx                            |    3 --
 sc/source/ui/sidebar/CellLineStyleValueSet.cxx               |    3 --
 sc/source/ui/unoobj/docuno.cxx                               |    6 +---
 sc/source/ui/vba/vbavalidation.cxx                           |    3 --
 sc/source/ui/view/drawview.cxx                               |    3 --
 sc/source/ui/view/hdrcont.cxx                                |    6 +---
 sc/source/ui/view/preview.cxx                                |    3 --
 sccomp/source/solver/SwarmSolver.cxx                         |    3 --
 sd/source/core/drawdoc4.cxx                                  |    6 +---
 sd/source/filter/eppt/epptso.cxx                             |    6 +---
 sd/source/ui/annotations/annotationtag.cxx                   |    3 --
 sd/source/ui/dlg/inspagob.cxx                                |    3 --
 sd/source/ui/table/tablefunction.cxx                         |    3 --
 sd/source/ui/unoidl/unopage.cxx                              |    3 --
 sd/source/ui/view/drviews9.cxx                               |    3 --
 sd/source/ui/view/outlview.cxx                               |    3 --
 sfx2/source/appl/sfxhelp.cxx                                 |    2 -
 sfx2/source/appl/workwin.cxx                                 |    3 --
 sfx2/source/control/thumbnailviewacc.cxx                     |    3 --
 sfx2/source/doc/docfilt.cxx                                  |    4 +-
 sfx2/source/doc/new.cxx                                      |    9 ++----
 sfx2/source/view/frame.cxx                                   |    3 --
 sfx2/source/view/viewfrm.cxx                                 |    3 --
 slideshow/source/engine/shapes/gdimtftools.cxx               |    3 --
 starmath/source/edit.cxx                                     |    3 --
 starmath/source/rect.cxx                                     |    5 +--
 starmath/source/unomodel.cxx                                 |    3 --
 starmath/source/view.cxx                                     |    6 +---
 svtools/source/contnr/ivctrl.cxx                             |    3 --
 svtools/source/contnr/svtabbx.cxx                            |    3 --
 svtools/source/contnr/treelistbox.cxx                        |    3 --
 svtools/source/control/calendar.cxx                          |    4 +-
 svtools/source/control/toolbarmenuacc.cxx                    |    3 --
 svtools/source/control/valueacc.cxx                          |    3 --
 svtools/source/graphic/grfmgr2.cxx                           |    3 --
 svtools/source/hatchwindow/ipwin.cxx                         |    6 +---
 svtools/source/misc/langhelp.cxx                             |    2 -
 svx/source/accessibility/charmapacc.cxx                      |    3 --
 svx/source/dialog/connctrl.cxx                               |    3 --
 svx/source/dialog/contwnd.cxx                                |    3 --
 svx/source/dialog/imapwnd.cxx                                |    3 --
 svx/source/sidebar/line/LineWidthValueSet.cxx                |    3 --
 svx/source/svdraw/svdhdl.cxx                                 |    3 --
 svx/source/svdraw/svdoashp.cxx                               |    3 --
 svx/source/svdraw/svdotext.cxx                               |    3 --
 svx/source/svdraw/svdoutl.cxx                                |    3 --
 svx/source/table/svdotable.cxx                               |    3 --
 svx/source/uitest/sdrobject.cxx                              |    7 +---
 svx/source/xml/xmlgrhlp.cxx                                  |    3 --
 svx/source/xoutdev/_xoutbmp.cxx                              |    3 --
 sw/source/core/access/acccontext.cxx                         |    3 --
 sw/source/core/doc/DocumentStylePoolManager.cxx              |    9 ++----
 sw/source/core/frmedt/fefly1.cxx                             |    3 --
 sw/source/core/text/inftxt.cxx                               |    4 --
 sw/source/core/txtnode/fntcap.cxx                            |    6 +---
 sw/source/filter/writer/wrtswtbl.cxx                         |    3 --
 sw/source/filter/ww8/wrtw8sty.cxx                            |    2 -
 sw/source/filter/ww8/wrtww8gr.cxx                            |    6 +---
 sw/source/filter/ww8/ww8graf.cxx                             |    3 --
 sw/source/filter/ww8/ww8graf2.cxx                            |    3 --
 sw/source/uibase/dialog/SignatureLineDialog.cxx              |    2 -
 sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx         |    3 --
 sw/source/uibase/docvw/edtdd.cxx                             |    3 --
 sw/source/uibase/shells/annotsh.cxx                          |    3 --
 sw/source/uibase/shells/drwtxtsh.cxx                         |    3 --
 sw/source/uibase/uiview/view.cxx                             |    2 -
 sw/source/uibase/utlui/content.cxx                           |    3 --
 sw/source/uibase/utlui/glbltree.cxx                          |    3 --
 vcl/source/app/help.cxx                                      |    3 --
 vcl/source/control/button.cxx                                |    9 ++----
 vcl/source/control/combobox.cxx                              |    3 --
 vcl/source/control/edit.cxx                                  |    6 +---
 vcl/source/control/imp_listbox.cxx                           |    6 +---
 vcl/source/control/listbox.cxx                               |    3 --
 vcl/source/control/spinbtn.cxx                               |    3 --
 vcl/source/filter/jpeg/JpegReader.cxx                        |    3 --
 vcl/source/gdi/animate.cxx                                   |    6 +---
 vcl/source/gdi/bitmap.cxx                                    |    6 +---
 vcl/source/gdi/bmpacc3.cxx                                   |    3 --
 vcl/source/gdi/gdimtf.cxx                                    |    3 --
 vcl/source/gdi/print.cxx                                     |    3 --
 vcl/source/gdi/salgdilayout.cxx                              |    3 --
 vcl/source/outdev/bitmap.cxx                                 |    3 --
 vcl/source/outdev/transparent.cxx                            |    3 --
 vcl/source/window/brdwin.cxx                                 |    3 --
 vcl/source/window/floatwin.cxx                               |    4 +-
 vcl/source/window/menubarwindow.cxx                          |    6 +---
 vcl/source/window/menufloatingwindow.cxx                     |    3 --
 vcl/source/window/scrwnd.cxx                                 |    3 --
 vcl/source/window/toolbox.cxx                                |    9 ++----
 vcl/unx/gtk/salprn-gtk.cxx                                   |    3 --
 vcl/workben/svptest.cxx                                      |   16 +++++------
 120 files changed, 165 insertions(+), 297 deletions(-)

New commits:
commit 08ab1f46b192a188935fdffbefdc9f3973583cdf
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Sat Feb 24 13:47:25 2018 +0200

    loplugin:oncevar extend to tools/gen.hxx types
    
    Change-Id: I5c75875da44334569c02e2ff039b33c38397a0a2
    Reviewed-on: https://gerrit.libreoffice.org/50283
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/basctl/source/dlged/dlged.cxx b/basctl/source/dlged/dlged.cxx
index 0e36883665c0..b82b5915c43e 100644
--- a/basctl/source/dlged/dlged.cxx
+++ b/basctl/source/dlged/dlged.cxx
@@ -472,8 +472,7 @@ void DlgEditor::Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle
     aPaintRect = rRect;
     mnPaintGuard++;
 
-    Size aMacSize;
-    if (bFirstDraw && rWindow.IsVisible() && (rRenderContext.GetOutputSize() != aMacSize))
+    if (bFirstDraw && rWindow.IsVisible() && (rRenderContext.GetOutputSize() != Size()))
     {
         bFirstDraw = false;
 
diff --git a/basic/source/classes/sbunoobj.cxx b/basic/source/classes/sbunoobj.cxx
index ac4b8d4b3ea9..5eda97d08856 100644
--- a/basic/source/classes/sbunoobj.cxx
+++ b/basic/source/classes/sbunoobj.cxx
@@ -647,8 +647,7 @@ void unoToSbxValue( SbxVariable* pVar, const Any& aValue )
                     SbxDimArray* pArray = nullptr;
                     Sequence< sal_Int32 > indices;
                     Sequence< sal_Int32 > sizes;
-                    sal_Int32 dimension = 0;
-                    implSequenceToMultiDimArray( pArray, indices, sizes, aWrap.Array, dimension, aWrap.IsZeroIndex, nullptr );
+                    implSequenceToMultiDimArray( pArray, indices, sizes, aWrap.Array, /*dimension*/0, aWrap.IsZeroIndex, nullptr );
                     if ( pArray )
                     {
                         SbxDimArrayRef xArray = pArray;
diff --git a/compilerplugins/clang/oncevar.cxx b/compilerplugins/clang/oncevar.cxx
index 79f5a80db0d0..a8a56f5a7e33 100644
--- a/compilerplugins/clang/oncevar.cxx
+++ b/compilerplugins/clang/oncevar.cxx
@@ -334,7 +334,14 @@ bool OnceVar::VisitVarDecl( const VarDecl* varDecl )
         && !tc.Class("OString").Namespace("rtl").GlobalNamespace()
         && !tc.Class("OUString").Namespace("rtl").GlobalNamespace()
         && !tc.Class("OStringBuffer").Namespace("rtl").GlobalNamespace()
-        && !tc.Class("OUStringBuffer").Namespace("rtl").GlobalNamespace())
+        && !tc.Class("OUStringBuffer").Namespace("rtl").GlobalNamespace()
+        && !tc.Class("Color").GlobalNamespace()
+        && !tc.Class("Pair").GlobalNamespace()
+        && !tc.Class("Point").GlobalNamespace()
+        && !tc.Class("Size").GlobalNamespace()
+        && !tc.Class("Range").GlobalNamespace()
+        && !tc.Class("Selection").GlobalNamespace()
+        && !tc.Class("Rectangle").Namespace("tools").GlobalNamespace())
     {
         return true;
     }
diff --git a/cppuhelper/source/servicemanager.cxx b/cppuhelper/source/servicemanager.cxx
index 420316c2a5a3..dd7139af252f 100644
--- a/cppuhelper/source/servicemanager.cxx
+++ b/cppuhelper/source/servicemanager.cxx
@@ -1999,7 +1999,7 @@ void cppuhelper::ServiceManager::preloadImplementations() {
         const char *mpFrom;
         const char *mpTo;
         const char *mpPurpose;
-    } aMappingLoad[] = {
+    } const aMappingLoad[] = {
         { "gcc3", "uno",  "" },
         { "uno",  "gcc3", "" },
     };
diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx
index ee011732a24f..d05d4fb5efe0 100644
--- a/cui/source/dialogs/hlmarkwn.cxx
+++ b/cui/source/dialogs/hlmarkwn.cxx
@@ -359,7 +359,6 @@ int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess >
     const sal_uLong nLinks = aNames.getLength();
     const OUString* pNames = aNames.getConstArray();
 
-    Color aMaskColor( COL_LIGHTMAGENTA );
     const OUString aProp_LinkDisplayName( "LinkDisplayName" );
     const OUString aProp_LinkTarget( "com.sun.star.document.LinkTarget" );
     const OUString aProp_LinkDisplayBitmap( "LinkDisplayBitmap" );
@@ -410,7 +409,7 @@ int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess >
                         aXBitmap( xTarget->getPropertyValue( aProp_LinkDisplayBitmap ), uno::UNO_QUERY );
                     if( aXBitmap.is() )
                     {
-                        Image aBmp(BitmapEx(VCLUnoHelper::GetBitmap(aXBitmap).GetBitmap(), aMaskColor));
+                        Image aBmp(BitmapEx(VCLUnoHelper::GetBitmap(aXBitmap).GetBitmap(), /*mask*/COL_LIGHTMAGENTA));
                         // insert Displayname into treelist with bitmaps
                         pEntry = mpLbTree->InsertEntry ( aStrDisplayname,
                                                         aBmp, aBmp,
diff --git a/cui/source/options/optcolor.cxx b/cui/source/options/optcolor.cxx
index 1e8e4c5b2dc3..49d0d3dc79af 100644
--- a/cui/source/options/optcolor.cxx
+++ b/cui/source/options/optcolor.cxx
@@ -547,8 +547,7 @@ void ColorConfigWindow_Impl::CreateEntries()
 
 void ColorConfigWindow_Impl::SetAppearance ()
 {
-    Color TempColor(COL_TRANSPARENT);
-    Wallpaper const aTransparentWall(TempColor);
+    Wallpaper const aTransparentWall(COL_TRANSPARENT);
     StyleSettings const& rStyleSettings = GetSettings().GetStyleSettings();
     Color const aBackColor = rStyleSettings.GetHighContrastMode() ?
         rStyleSettings.GetShadowColor() : Color(COL_LIGHTGRAY);
diff --git a/cui/source/tabpages/tptrans.cxx b/cui/source/tabpages/tptrans.cxx
index bf8ce4d9ff02..553e94d232f3 100644
--- a/cui/source/tabpages/tptrans.cxx
+++ b/cui/source/tabpages/tptrans.cxx
@@ -374,8 +374,7 @@ bool SvxTransparenceTabPage::FillItemSet(SfxItemSet* rAttrs)
     // disable unused XFillFloatTransparenceItem
     if(bSwitchOffGradient && (bGradActive || bGradUsed))
     {
-        Color aColor(COL_BLACK);
-        XGradient aGrad(aColor, Color(COL_WHITE));
+        XGradient aGrad(COL_BLACK, Color(COL_WHITE));
         aGrad.SetStartIntens(100);
         aGrad.SetEndIntens(100);
         XFillFloatTransparenceItem aItem(aGrad);
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index a741d09f7a3b..b6d4f6eb5951 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -3406,7 +3406,7 @@ unsigned char* doc_renderFont(SAL_UNUSED_PARAMETER LibreOfficeKitDocument* /*pTh
 
             if (*pFontWidth > 0 && *pFontHeight > 0)
             {
-                DrawTextFlags nStyle =
+                DrawTextFlags const nStyle =
                         DrawTextFlags::Center
                         | DrawTextFlags::VCenter
                         | DrawTextFlags::MultiLine
diff --git a/emfio/source/reader/mtftools.cxx b/emfio/source/reader/mtftools.cxx
index 81aa50e2bf04..b0cef5242839 100644
--- a/emfio/source/reader/mtftools.cxx
+++ b/emfio/source/reader/mtftools.cxx
@@ -984,8 +984,7 @@ namespace emfio
 
     void MtfTools::ImplSetNonPersistentLineColorTransparenz()
     {
-        Color aColor(  COL_TRANSPARENT);
-        WinMtfLineStyle aTransparentLine( aColor, true );
+        WinMtfLineStyle aTransparentLine( COL_TRANSPARENT, true );
         if ( ! ( maLatestLineStyle == aTransparentLine ) )
         {
             maLatestLineStyle = aTransparentLine;
diff --git a/extensions/source/bibliography/toolbar.cxx b/extensions/source/bibliography/toolbar.cxx
index feac99a016e5..e0e57846e16c 100644
--- a/extensions/source/bibliography/toolbar.cxx
+++ b/extensions/source/bibliography/toolbar.cxx
@@ -508,8 +508,7 @@ IMPL_LINK_NOARG( BibToolBar, MenuHdl, ToolBox*, void)
             SendDispatch(nTBC_BT_AUTOFILTER, aPropVal);
         }
 
-        Point aPoint;
-        MouseEvent aLeave( aPoint, 0, MouseEventModifiers::LEAVEWINDOW | MouseEventModifiers::SYNTHETIC );
+        MouseEvent aLeave( Point(), 0, MouseEventModifiers::LEAVEWINDOW | MouseEventModifiers::SYNTHETIC );
         MouseMove( aLeave );
         SetItemDown(nTBC_BT_AUTOFILTER, false);
 
diff --git a/filter/source/graphicfilter/ipsd/ipsd.cxx b/filter/source/graphicfilter/ipsd/ipsd.cxx
index d962f603c50d..8510ee9b583e 100644
--- a/filter/source/graphicfilter/ipsd/ipsd.cxx
+++ b/filter/source/graphicfilter/ipsd/ipsd.cxx
@@ -138,10 +138,9 @@ bool PSDReader::ReadPSD(Graphic & rGraphic )
 
         if ( mnXResFixed && mnYResFixed )
         {
-            Point       aEmptyPoint;
             Fraction    aFractX( 1, mnXResFixed >> 16 );
             Fraction    aFractY( 1, mnYResFixed >> 16 );
-            MapMode     aMapMode( MapUnit::MapInch, aEmptyPoint, aFractX, aFractY );
+            MapMode     aMapMode( MapUnit::MapInch, Point(), aFractX, aFractY );
             Size        aPrefSize = OutputDevice::LogicToLogic(aBitmapSize, aMapMode, MapMode(MapUnit::Map100thMM));
             rGraphic.SetPrefSize( aPrefSize );
             rGraphic.SetPrefMapMode( MapMode( MapUnit::Map100thMM ) );
diff --git a/filter/source/msfilter/eschesdo.cxx b/filter/source/msfilter/eschesdo.cxx
index 1fb1f5a91472..35e72efc6725 100644
--- a/filter/source/msfilter/eschesdo.cxx
+++ b/filter/source/msfilter/eschesdo.cxx
@@ -196,8 +196,6 @@ sal_uInt32 ImplEESdrWriter::ImplWriteShape( ImplEESdrObject& rObj,
             }
         }
 
-        Point aTextRefPoint;
-
         if( rObj.GetType() == "drawing.Group" )
         {
             Reference< XIndexAccess > xXIndexAccess( rObj.GetShapeRef(), UNO_QUERY );
@@ -700,7 +698,7 @@ sal_uInt32 ImplEESdrWriter::ImplWriteShape( ImplEESdrObject& rObj,
         if( bAdditionalText )
         {
             mpEscherEx->EndShape( nShapeType, nShapeID );
-            ImplWriteAdditionalText( rObj, aTextRefPoint );
+            ImplWriteAdditionalText( rObj, Point() );
         }
 
     } while ( false );
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index da4b6d4258ac..3ffae20be7dc 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -2558,9 +2558,8 @@ void DffPropertyReader::ApplyCustomShapeGeometryAttributes( SvStream& rIn, SfxIt
 
 void DffPropertyReader::ApplyAttributes( SvStream& rIn, SfxItemSet& rSet ) const
 {
-    tools::Rectangle aEmptyRect;
     DffRecordHeader aHdTemp;
-    DffObjData aDffObjTemp( aHdTemp, aEmptyRect, 0 );
+    DffObjData aDffObjTemp( aHdTemp, tools::Rectangle(), 0 );
     ApplyAttributes( rIn, rSet, aDffObjTemp );
 }
 
diff --git a/filter/source/pdf/pdfexport.cxx b/filter/source/pdf/pdfexport.cxx
index ca454bbd65f7..ab7457350f85 100644
--- a/filter/source/pdf/pdfexport.cxx
+++ b/filter/source/pdf/pdfexport.cxx
@@ -1007,8 +1007,7 @@ bool PDFExport::ImplExportPage( vcl::PDFWriter& rWriter, vcl::PDFExtOutDevData&
     basegfx::B2DPolygon aSize(tools::Polygon(tools::Rectangle(Point(0, 0), rMtf.GetPrefSize())).getB2DPolygon());
     basegfx::B2DPolygon aSizePDF(OutputDevice::LogicToLogic(aSize, rMtf.GetPrefMapMode(), MapMode(MapUnit::MapPoint)));
     basegfx::B2DRange aRangePDF(aSizePDF.getB2DRange());
-    Point           aOrigin;
-    tools::Rectangle       aPageRect( aOrigin, rMtf.GetPrefSize() );
+    tools::Rectangle       aPageRect( Point(), rMtf.GetPrefSize() );
 
     rWriter.NewPage( aRangePDF.getWidth(), aRangePDF.getHeight() );
     rWriter.SetMapMode( rMtf.GetPrefMapMode() );
diff --git a/filter/source/svg/svgwriter.cxx b/filter/source/svg/svgwriter.cxx
index a080e1c6a1f6..b22910df87c1 100644
--- a/filter/source/svg/svgwriter.cxx
+++ b/filter/source/svg/svgwriter.cxx
@@ -2714,8 +2714,7 @@ void SVGActionWriter::ImplWriteBmp( const BitmapEx& rBmpEx,
     if( !!rBmpEx )
     {
         BitmapEx aBmpEx( rBmpEx );
-        Point    aPoint;
-        const tools::Rectangle aBmpRect( aPoint, rBmpEx.GetSizePixel() );
+        const tools::Rectangle aBmpRect( Point(), rBmpEx.GetSizePixel() );
         const tools::Rectangle aSrcRect( rSrcPt, rSrcSz );
 
         if( aSrcRect != aBmpRect )
diff --git a/framework/source/uielement/menubarmanager.cxx b/framework/source/uielement/menubarmanager.cxx
index f32d54bba2b4..018518931cd4 100644
--- a/framework/source/uielement/menubarmanager.cxx
+++ b/framework/source/uielement/menubarmanager.cxx
@@ -252,9 +252,8 @@ void SAL_CALL MenuBarManager::elementInserted( const css::ui::ConfigurationEvent
         return;
 
     sal_Int16 nImageType = sal_Int16();
-    sal_Int16 nCurrentImageType = css::ui::ImageType::SIZE_LARGE;
     if (( Event.aInfo >>= nImageType ) &&
-        ( nImageType == nCurrentImageType ))
+        ( nImageType == css::ui::ImageType::SIZE_LARGE ))
         RequestImages();
 }
 
diff --git a/package/source/zippackage/ZipPackage.cxx b/package/source/zippackage/ZipPackage.cxx
index aea7d14048dd..cddda58e68a5 100644
--- a/package/source/zippackage/ZipPackage.cxx
+++ b/package/source/zippackage/ZipPackage.cxx
@@ -1088,11 +1088,10 @@ void ZipPackage::WriteContentTypes( ZipOutputStream& aZipOut, const vector< uno:
 
     // Convert vector into a uno::Sequence
     // TODO/LATER: use Default entries in future
-    uno::Sequence< beans::StringPair > aDefaultsSequence(aManList.size());
+    uno::Sequence< beans::StringPair > aDefaultsSequence(1);
     // Add at least the application/xml default entry.
     aDefaultsSequence[0].First = "xml";
     aDefaultsSequence[0].Second= "application/xml";
-    sal_Int32 nDefSeqLength = 1;
 
     uno::Sequence< beans::StringPair > aOverridesSequence(aManList.size());
     sal_Int32 nOverSeqLength = 0;
@@ -1117,7 +1116,6 @@ void ZipPackage::WriteContentTypes( ZipOutputStream& aZipOut, const vector< uno:
         }
     }
     aOverridesSequence.realloc(nOverSeqLength);
-    aDefaultsSequence.realloc(nDefSeqLength);
 
     ::comphelper::OFOPXMLHelper::WriteContentSequence(
             xConTypeOutStream, aDefaultsSequence, aOverridesSequence, m_xContext );
diff --git a/reportdesign/source/ui/dlg/Condition.cxx b/reportdesign/source/ui/dlg/Condition.cxx
index b88df9b21ba7..1110e9aef21a 100644
--- a/reportdesign/source/ui/dlg/Condition.cxx
+++ b/reportdesign/source/ui/dlg/Condition.cxx
@@ -239,8 +239,7 @@ IMPL_LINK(Condition, DropdownClick, ToolBox*, pToolBox, void)
 
 IMPL_LINK_NOARG( Condition, OnFormatAction, ToolBox*, void )
 {
-    Color aCol(COL_AUTO);
-    ApplyCommand(mapToolbarItemToSlotId(m_pActions->GetCurItemId()),aCol);
+    ApplyCommand(mapToolbarItemToSlotId(m_pActions->GetCurItemId()),COL_AUTO);
 }
 
 IMPL_LINK( Condition, OnConditionAction, Button*, _pClickedButton, void )
diff --git a/sc/source/core/data/stlpool.cxx b/sc/source/core/data/stlpool.cxx
index 571969b71e4a..e82566b8d6b5 100644
--- a/sc/source/core/data/stlpool.cxx
+++ b/sc/source/core/data/stlpool.cxx
@@ -214,7 +214,6 @@ void ScStyleSheetPool::CreateStandardStyles()
     //  Add new entries even for CopyStdStylesFrom
 
     Color           aColBlack   ( COL_BLACK );
-    Color           aColGrey    ( COL_LIGHTGRAY );
     OUString        aStr;
     sal_Int32       nStrLen;
     OUString        aHelpFile;//which text???
@@ -338,7 +337,7 @@ void ScStyleSheetPool::CreateStandardStyles()
     pHFSetItem = new SvxSetItem( pSet->Get( ATTR_PAGE_HEADERSET ) );
     pHFSet = &(pHFSetItem->GetItemSet());
 
-    pHFSet->Put( SvxBrushItem( aColGrey, ATTR_BACKGROUND ) );
+    pHFSet->Put( SvxBrushItem( COL_LIGHTGRAY, ATTR_BACKGROUND ) );
     pHFSet->Put( aBoxItem );
     pHFSet->Put( aBoxInfoItem );
     pHFSetItem->SetWhich(ATTR_PAGE_HEADERSET);
diff --git a/sc/source/core/tool/autoform.cxx b/sc/source/core/tool/autoform.cxx
index fa9f20ff229f..e0a331f8ff76 100644
--- a/sc/source/core/tool/autoform.cxx
+++ b/sc/source/core/tool/autoform.cxx
@@ -885,10 +885,9 @@ ScAutoFormat::ScAutoFormat() :
     aBox.SetLine(&aLine, SvxBoxItemLine::BOTTOM);
 
     Color aWhite(COL_WHITE);
-    Color aBlue(COL_BLUE);
     SvxColorItem aWhiteText( aWhite, ATTR_FONT_COLOR );
     SvxColorItem aBlackText( aBlack, ATTR_FONT_COLOR );
-    SvxBrushItem aBlueBack( aBlue, ATTR_BACKGROUND );
+    SvxBrushItem aBlueBack( COL_BLUE, ATTR_BACKGROUND );
     SvxBrushItem aWhiteBack( aWhite, ATTR_BACKGROUND );
     SvxBrushItem aGray70Back( Color(0x4d, 0x4d, 0x4d), ATTR_BACKGROUND );
     SvxBrushItem aGray20Back( Color(0xcc, 0xcc, 0xcc), ATTR_BACKGROUND );
diff --git a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
index b9f0d3188209..4b7d699ce46e 100644
--- a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
+++ b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx
@@ -1127,8 +1127,7 @@ ScPagePreviewCountData::ScPagePreviewCountData( const ScPreviewLocationData& rDa
     Size aOutputSize;
     if ( pSizeWindow )
         aOutputSize = pSizeWindow->GetOutputSizePixel();
-    Point aPoint;
-    aVisRect = tools::Rectangle( aPoint, aOutputSize );
+    aVisRect = tools::Rectangle( Point(), aOutputSize );
 
     tools::Rectangle aObjRect;
 
@@ -1236,8 +1235,7 @@ void ScAccessibleDocumentPagePreview::Notify( SfxBroadcaster& rBC, const SfxHint
             vcl::Window* pSizeWindow = mpViewShell->GetWindow();
             if ( pSizeWindow )
                 aOutputSize = pSizeWindow->GetOutputSizePixel();
-            Point aPoint;
-            tools::Rectangle aVisRect( aPoint, aOutputSize );
+            tools::Rectangle aVisRect( Point(), aOutputSize );
             GetNotesChildren()->DataChanged(aVisRect);
 
             GetShapeChildren()->DataChanged();
@@ -1273,8 +1271,7 @@ void ScAccessibleDocumentPagePreview::Notify( SfxBroadcaster& rBC, const SfxHint
             vcl::Window* pSizeWindow = mpViewShell->GetWindow();
             if ( pSizeWindow )
                 aOutputSize = pSizeWindow->GetOutputSizePixel();
-            Point aPoint;
-            tools::Rectangle aVisRect( aPoint, aOutputSize );
+            tools::Rectangle aVisRect( Point(), aOutputSize );
             GetNotesChildren()->DataChanged(aVisRect);
 
             GetShapeChildren()->VisAreaChanged();
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
index 6f7a84ae8034..6ba7b9e1e527 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx
@@ -405,8 +405,7 @@ void ScAccessiblePreviewHeaderCell::FillTableInfo() const
         vcl::Window* pWindow = mpViewShell->GetWindow();
         if ( pWindow )
             aOutputSize = pWindow->GetOutputSizePixel();
-        Point aPoint;
-        tools::Rectangle aVisRect( aPoint, aOutputSize );
+        tools::Rectangle aVisRect( Point(), aOutputSize );
 
         mpTableInfo = new ScPreviewTableInfo;
         mpViewShell->GetLocationData().GetTableInfo( aVisRect, *mpTableInfo );
diff --git a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
index 912d15af153d..080f2c9c49a8 100644
--- a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
+++ b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx
@@ -636,8 +636,7 @@ void ScAccessiblePreviewTable::FillTableInfo() const
         vcl::Window* pWindow = mpViewShell->GetWindow();
         if ( pWindow )
             aOutputSize = pWindow->GetOutputSizePixel();
-        Point aPoint;
-        tools::Rectangle aVisRect( aPoint, aOutputSize );
+        tools::Rectangle aVisRect( Point(), aOutputSize );
 
         mpTableInfo = new ScPreviewTableInfo;
         mpViewShell->GetLocationData().GetTableInfo( aVisRect, *mpTableInfo );
diff --git a/sc/source/ui/Accessibility/AccessibleText.cxx b/sc/source/ui/Accessibility/AccessibleText.cxx
index e904086483fc..4842d7b211c6 100644
--- a/sc/source/ui/Accessibility/AccessibleText.cxx
+++ b/sc/source/ui/Accessibility/AccessibleText.cxx
@@ -265,9 +265,8 @@ bool ScPreviewViewForwarder::IsValid() const
 
 tools::Rectangle ScPreviewViewForwarder::GetVisArea() const
 {
-    tools::Rectangle aVisArea;
     OSL_FAIL("should be implemented in an abrevated class");
-    return aVisArea;
+    return tools::Rectangle();
 }
 
 Point ScPreviewViewForwarder::LogicToPixel( const Point& rPoint, const MapMode& rMapMode ) const
@@ -325,8 +324,7 @@ tools::Rectangle ScPreviewViewForwarder::GetVisRect() const
         vcl::Window* pWindow = mpViewShell->GetWindow();
         if ( pWindow )
             aOutputSize = pWindow->GetOutputSizePixel();
-        Point aPoint;
-        tools::Rectangle aVisRect( aPoint, aOutputSize );
+        tools::Rectangle aVisRect( Point(), aOutputSize );
         return aVisRect;
     }
     return tools::Rectangle();
@@ -1274,8 +1272,7 @@ SvxTextForwarder* ScAccessiblePreviewHeaderCellTextData::GetTextForwarder()
             vcl::Window* pWindow = mpViewShell->GetWindow();
             if ( pWindow )
                 aOutputSize = pWindow->GetOutputSizePixel();
-            Point aPoint;
-            tools::Rectangle aVisRect( aPoint, aOutputSize );
+            tools::Rectangle aVisRect( Point(), aOutputSize );
             Size aSize(mpViewShell->GetLocationData().GetHeaderCellOutputRect(aVisRect, aCellPos, mbColHeader).GetSize());
             if (pWindow)
                 aSize = pWindow->PixelToLogic(aSize, pEditEngine->GetRefMapMode());
@@ -1501,8 +1498,7 @@ SvxTextForwarder* ScAccessibleNoteTextData::GetTextForwarder()
             vcl::Window* pWindow = mpViewShell->GetWindow();
             if ( pWindow )
                 aOutputSize = pWindow->GetOutputSizePixel();
-            Point aPoint;
-            tools::Rectangle aVisRect( aPoint, aOutputSize );
+            tools::Rectangle aVisRect( Point(), aOutputSize );
             Size aSize(mpViewShell->GetLocationData().GetNoteInRangeOutputRect(aVisRect, mbMarkNote, maCellPos).GetSize());
             if (pWindow)
                 aSize = pWindow->PixelToLogic(aSize, mpEditEngine->GetRefMapMode());
diff --git a/sc/source/ui/app/drwtrans.cxx b/sc/source/ui/app/drwtrans.cxx
index 6c8863562f66..f379f963fc7f 100644
--- a/sc/source/ui/app/drwtrans.cxx
+++ b/sc/source/ui/app/drwtrans.cxx
@@ -744,8 +744,7 @@ void ScDrawTransferObj::InitDocShell()
             }
         }
 
-        Point aTmpPoint;
-        tools::Rectangle aDestArea( aTmpPoint, aSrcSize );
+        tools::Rectangle aDestArea( Point(), aSrcSize );
         pDocSh->SetVisArea( aDestArea );
 
         ScViewOptions aViewOpt( rDestDoc.GetViewOptions() );
diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx
index 0ebf47ef3e7d..0e581e8f10c6 100644
--- a/sc/source/ui/app/transobj.cxx
+++ b/sc/source/ui/app/transobj.cxx
@@ -102,8 +102,7 @@ void ScTransferObj::PaintToDev( OutputDevice* pDev, ScDocument* pDoc, double nPr
     if (!pDoc)
         return;
 
-    Point aPoint;
-    tools::Rectangle aBound( aPoint, pDev->GetOutputSize() );      //! use size from clip area?
+    tools::Rectangle aBound( Point(), pDev->GetOutputSize() );      //! use size from clip area?
 
     ScViewData aViewData(nullptr,nullptr);
     aViewData.InitData( pDoc );
diff --git a/sc/source/ui/dbgui/csvgrid.cxx b/sc/source/ui/dbgui/csvgrid.cxx
index 4b7ffb4aabe6..3852ca0f0728 100644
--- a/sc/source/ui/dbgui/csvgrid.cxx
+++ b/sc/source/ui/dbgui/csvgrid.cxx
@@ -988,8 +988,7 @@ void ScCsvGrid::Command( const CommandEvent& rCEvt )
         break;
         case CommandEventId::Wheel:
         {
-            Point aPoint;
-            tools::Rectangle aRect( aPoint, maWinSize );
+            tools::Rectangle aRect( Point(), maWinSize );
             if( aRect.IsInside( rCEvt.GetMousePosPixel() ) )
             {
                 const CommandWheelData* pData = rCEvt.GetWheelData();
diff --git a/sc/source/ui/dbgui/csvruler.cxx b/sc/source/ui/dbgui/csvruler.cxx
index 6087719ab139..6233c6795c03 100644
--- a/sc/source/ui/dbgui/csvruler.cxx
+++ b/sc/source/ui/dbgui/csvruler.cxx
@@ -410,8 +410,7 @@ void ScCsvRuler::MouseMove( const MouseEvent& rMEvt )
         }
         else
         {
-            Point aPoint;
-            tools::Rectangle aRect( aPoint, maWinSize );
+            tools::Rectangle aRect( Point(), maWinSize );
             if( !IsVisibleSplitPos( nPos ) || !aRect.IsInside( rMEvt.GetPosPixel() ) )
                 // if focused, keep old cursor position for key input
                 nPos = HasFocus() ? GetRulerCursorPos() : CSV_POS_INVALID;
diff --git a/sc/source/ui/miscdlgs/autofmt.cxx b/sc/source/ui/miscdlgs/autofmt.cxx
index 43a4d0edc146..129cf1df71ce 100644
--- a/sc/source/ui/miscdlgs/autofmt.cxx
+++ b/sc/source/ui/miscdlgs/autofmt.cxx
@@ -507,8 +507,7 @@ void ScAutoFmtPreview::DoPaint(vcl::RenderContext& rRenderContext)
     Size aWndSize(GetSizePixel());
     vcl::Font aFont(aVD->GetFont());
     Color aBackCol(rRenderContext.GetSettings().GetStyleSettings().GetWindowColor());
-    Point aTmpPoint;
-    tools::Rectangle aRect(aTmpPoint, aWndSize);
+    tools::Rectangle aRect(Point(), aWndSize);
 
     aFont.SetTransparent( true );
     aVD->SetFont(aFont);
diff --git a/sc/source/ui/sidebar/CellLineStyleValueSet.cxx b/sc/source/ui/sidebar/CellLineStyleValueSet.cxx
index 27c876e7e7a6..3123a60b3541 100644
--- a/sc/source/ui/sidebar/CellLineStyleValueSet.cxx
+++ b/sc/source/ui/sidebar/CellLineStyleValueSet.cxx
@@ -92,11 +92,10 @@ void CellLineStyleValueSet::UserDraw( const UserDrawEvent& rUDEvt )
 
     if( nSelItem ==  nItemId )
     {
-        Color aBackColor(50,107,197);
         tools::Rectangle aBackRect = aRect;
         aBackRect.AdjustTop(3 );
         aBackRect.AdjustBottom( -2 );
-        pDev->SetFillColor(aBackColor);
+        pDev->SetFillColor(Color(50,107,197));
         pDev->DrawRect(aBackRect);
     }
     else
diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx
index cd56f7c5872e..a42a0ea3b70c 100644
--- a/sc/source/ui/unoobj/docuno.cxx
+++ b/sc/source/ui/unoobj/docuno.cxx
@@ -1905,8 +1905,7 @@ void SAL_CALL ScModelObj::render( sal_Int32 nSelRenderer, const uno::Any& aSelec
     {
         // Similar to as in and when calling ScTransferObj::PaintToDev()
 
-        Point aPoint;
-        tools::Rectangle aBound( aPoint, pDev->GetOutputSize());
+        tools::Rectangle aBound( Point(), pDev->GetOutputSize());
 
         ScViewData aViewData(nullptr,nullptr);
         aViewData.InitData( &rDoc );
@@ -4496,11 +4495,10 @@ void SAL_CALL ScScenariosObj::addNewByName( const OUString& aName,
             }
         }
 
-        Color aColor( COL_LIGHTGRAY );  // Default
         ScScenarioFlags const nFlags = ScScenarioFlags::ShowFrame | ScScenarioFlags::PrintFrame
                                      | ScScenarioFlags::TwoWay    | ScScenarioFlags::Protected;
 
-        pDocShell->MakeScenario( nTab, aName, aComment, aColor, nFlags, aMarkData );
+        pDocShell->MakeScenario( nTab, aName, aComment, COL_LIGHTGRAY, nFlags, aMarkData );
     }
 }
 
diff --git a/sc/source/ui/vba/vbavalidation.cxx b/sc/source/ui/vba/vbavalidation.cxx
index 1be125034e17..a7abaa6921eb 100644
--- a/sc/source/ui/vba/vbavalidation.cxx
+++ b/sc/source/ui/vba/vbavalidation.cxx
@@ -301,7 +301,6 @@ ScVbaValidation::getFormula1()
 
     ScRefFlags nFlags = ScRefFlags::ZERO;
     ScRangeList aCellRanges;
-    formula::FormulaGrammar::AddressConvention eConv = formula::FormulaGrammar::CONV_XL_A1;
 
     ScDocShell* pDocSh = excel::GetDocShellFromRange( m_xRange );
     // in calc validation formula is either a range or formula
@@ -309,7 +308,7 @@ ScVbaValidation::getFormula1()
     // In VBA both formula and address can have a leading '='
     // in result of getFormula1, however it *seems* that a named range or
     // real formula has to (or is expected to) have the '='
-    if ( pDocSh && !ScVbaRange::getCellRangesForAddress(  nFlags, sString, pDocSh, aCellRanges, eConv, 0 ) )
+    if ( pDocSh && !ScVbaRange::getCellRangesForAddress(  nFlags, sString, pDocSh, aCellRanges, formula::FormulaGrammar::CONV_XL_A1, 0 ) )
         sString = "=" + sString;
     return sString;
 }
diff --git a/sc/source/ui/view/drawview.cxx b/sc/source/ui/view/drawview.cxx
index 30c934de4951..47e262ec83f3 100644
--- a/sc/source/ui/view/drawview.cxx
+++ b/sc/source/ui/view/drawview.cxx
@@ -264,9 +264,8 @@ void ScDrawView::UpdateWorkArea()
     SdrPage* pPage = GetModel()->GetPage(static_cast<sal_uInt16>(nTab));
     if (pPage)
     {
-        Point aPos;
         Size aPageSize( pPage->GetSize() );
-        tools::Rectangle aNewArea( aPos, aPageSize );
+        tools::Rectangle aNewArea( Point(), aPageSize );
         if ( aPageSize.Width() < 0 )
         {
             //  RTL: from max.negative (left) to zero (right)
diff --git a/sc/source/ui/view/hdrcont.cxx b/sc/source/ui/view/hdrcont.cxx
index 7c0eae5c4306..6a46c87e47a5 100644
--- a/sc/source/ui/view/hdrcont.cxx
+++ b/sc/source/ui/view/hdrcont.cxx
@@ -258,9 +258,8 @@ void ScHeaderControl::Paint( vcl::RenderContext& /*rRenderContext*/, const tools
         aBoldFont.SetColor( aSelTextColor );
     SetTextColor( ( bBoldSet && !bHighContrast ) ? aSelTextColor : aTextColor );
 
-    Color aBlack( COL_BLACK );
     Color aSelLineColor = rStyleSettings.GetHighlightColor();
-    aSelLineColor.Merge( aBlack, 0xe0 );        // darken just a little bit
+    aSelLineColor.Merge( COL_BLACK, 0xe0 );        // darken just a little bit
 
     bool bLayoutRTL = IsLayoutRTL();
     long nLayoutSign = bLayoutRTL ? -1 : 1;
@@ -707,8 +706,7 @@ void ScHeaderControl::MouseButtonDown( const MouseEvent& rMEvt )
     else
     {
         pSelEngine->SetWindow( this );
-        Point aPoint;
-        tools::Rectangle aVis( aPoint,GetOutputSizePixel() );
+        tools::Rectangle aVis( Point(), GetOutputSizePixel() );
         if (bVertical)
         {
             aVis.SetLeft( LONG_MIN );
diff --git a/sc/source/ui/view/preview.cxx b/sc/source/ui/view/preview.cxx
index f8dc39195800..b3bf1aa0db7e 100644
--- a/sc/source/ui/view/preview.cxx
+++ b/sc/source/ui/view/preview.cxx
@@ -514,8 +514,7 @@ void ScPreview::DoPrint( ScPreviewLocationData* pFillLocation )
             rDefPattern.FillEditItemSet(pEditDefaults);
             pEditEng->SetDefaults(pEditDefaults);
 
-            Color aTextColor(COL_LIGHTGRAY);
-            pEditDefaults->Put(SvxColorItem(aTextColor, EE_CHAR_COLOR));
+            pEditDefaults->Put(SvxColorItem(COL_LIGHTGRAY, EE_CHAR_COLOR));
 
             OUString aEmptyMsg;
             if (mbHasEmptyRangeTable)
diff --git a/sccomp/source/solver/SwarmSolver.cxx b/sccomp/source/solver/SwarmSolver.cxx
index ba89367db54b..dab7b648b8c0 100644
--- a/sccomp/source/solver/SwarmSolver.cxx
+++ b/sccomp/source/solver/SwarmSolver.cxx
@@ -279,9 +279,8 @@ public:
 
 OUString SwarmSolver::getResourceString(const char* pId)
 {
-    OUString sString;
     if (!pId)
-        return sString;
+        return OUString();
 
     return Translate::get(pId, Translate::Create("scc"));
 }
diff --git a/sd/source/core/drawdoc4.cxx b/sd/source/core/drawdoc4.cxx
index 9fec6a7b947b..efb52fefbd4c 100644
--- a/sd/source/core/drawdoc4.cxx
+++ b/sd/source/core/drawdoc4.cxx
@@ -167,9 +167,8 @@ void SdDrawDocument::CreateLayoutTemplates()
     rISet.Put( XFillGradientItem( aNullGrad) );
     rISet.Put(XFillHatchItem(aNullHatch));
     Size    aNullSize( 32, 32 );
-    Color   aNullColor( COL_WHITE );
     Bitmap  aNullBmp( aNullSize, 8 );
-    aNullBmp.Erase( aNullColor );
+    aNullBmp.Erase( COL_WHITE );
     rISet.Put(XFillBitmapItem(Graphic(aNullBmp)));
 
                     // Shadow attributes (Drawing Engine)
@@ -401,8 +400,7 @@ void SdDrawDocument::CreateLayoutTemplates()
 
     // Don't get color from the color table, because the color might have been
     // deleted or changed there
-    Color aOrange4(255, 204, 153);
-    pISet->Put(XFillColorItem(OUString(), aOrange4));
+    pISet->Put(XFillColorItem(OUString(), Color(255, 204, 153))); // orange
 
     pISet->Put(makeSdrShadowItem(true));
     pISet->Put(makeSdrShadowColorItem(COL_GRAY));
diff --git a/sd/source/filter/eppt/epptso.cxx b/sd/source/filter/eppt/epptso.cxx
index de02cd1eb5c4..a6394aa458d8 100644
--- a/sd/source/filter/eppt/epptso.cxx
+++ b/sd/source/filter/eppt/epptso.cxx
@@ -828,8 +828,7 @@ void PPTWriter::ImplWritePortions( SvStream& rOut, TextObj& rTextObj )
                 {
                     case css::drawing::FillStyle_GRADIENT :
                     {
-                        Point aEmptyPoint;
-                        ::tools::Rectangle aRect( aEmptyPoint, Size( 28000, 21000 ) );
+                        ::tools::Rectangle aRect( Point(), Size( 28000, 21000 ) );
                         EscherPropertyContainer aPropOpt( mpPptEscherEx->GetGraphicProvider(), mpPicStrm, aRect );
                         aPropOpt.CreateGradientProperties( mXPropSet );
                         aPropOpt.GetOpt( ESCHER_Prop_fillColor, nBackgroundColor );
@@ -851,8 +850,7 @@ void PPTWriter::ImplWritePortions( SvStream& rOut, TextObj& rTextObj )
                         {
                             case css::drawing::FillStyle_GRADIENT :
                             {
-                                Point aEmptyPoint;
-                                ::tools::Rectangle aRect( aEmptyPoint, Size( 28000, 21000 ) );
+                                ::tools::Rectangle aRect( Point(), Size( 28000, 21000 ) );
                                 EscherPropertyContainer aPropOpt( mpPptEscherEx->GetGraphicProvider(), mpPicStrm, aRect );
                                 aPropOpt.CreateGradientProperties( mXBackgroundPropSet );
                                 aPropOpt.GetOpt( ESCHER_Prop_fillColor, nBackgroundColor );
diff --git a/sd/source/ui/annotations/annotationtag.cxx b/sd/source/ui/annotations/annotationtag.cxx
index b69984bf76a0..4c6a53b3c1a2 100644
--- a/sd/source/ui/annotations/annotationtag.cxx
+++ b/sd/source/ui/annotations/annotationtag.cxx
@@ -450,8 +450,7 @@ void AnnotationTag::addCustomHandles( SdrHdlList& rHandlerList )
     if( mxAnnotation.is() )
     {
         SmartTagReference xThis( this );
-        Point aPoint;
-        AnnotationHdl* pHdl = new AnnotationHdl( xThis, mxAnnotation, aPoint );
+        AnnotationHdl* pHdl = new AnnotationHdl( xThis, mxAnnotation, Point() );
         pHdl->SetObjHdlNum( SMART_TAG_HDL_NUM );
         pHdl->SetPageView( mrView.GetSdrPageView() );
 
diff --git a/sd/source/ui/dlg/inspagob.cxx b/sd/source/ui/dlg/inspagob.cxx
index a7e674006195..9f2dcc7ca7d9 100644
--- a/sd/source/ui/dlg/inspagob.cxx
+++ b/sd/source/ui/dlg/inspagob.cxx
@@ -82,10 +82,9 @@ void SdInsertPagesObjsDlg::Reset()
     }
     else
     {
-        Color aColor( COL_WHITE );
         BitmapEx aBmpText(BMP_DOC_TEXT);
         //to-do, check if this is already transparent and remove intermedia bitmapex if it is
-        Image aImgText(BitmapEx(aBmpText.GetBitmap(), aColor));
+        Image aImgText(BitmapEx(aBmpText.GetBitmap(), COL_WHITE));
         m_pLbTree->InsertEntry( rName, aImgText, aImgText );
     }
 
diff --git a/sd/source/ui/table/tablefunction.cxx b/sd/source/ui/table/tablefunction.cxx
index 5b737f1d764a..ce518259d9e0 100644
--- a/sd/source/ui/table/tablefunction.cxx
+++ b/sd/source/ui/table/tablefunction.cxx
@@ -273,8 +273,7 @@ void CreateTableFromRTF( SvStream& rStream, SdDrawDocument* pModel )
         if( pPage )
         {
             Size aSize( 200, 200 );
-            Point aPos;
-            ::tools::Rectangle aRect (aPos, aSize);
+            ::tools::Rectangle aRect (Point(), aSize);
             sdr::table::SdrTableObj* pObj = new sdr::table::SdrTableObj( pModel, aRect, 1, 1 );
             pObj->NbcSetStyleSheet( pModel->GetDefaultStyleSheet(), true );
             apply_table_style( pObj, pModel, OUString() );
diff --git a/sd/source/ui/unoidl/unopage.cxx b/sd/source/ui/unoidl/unopage.cxx
index 2263860bfa02..3ac7872fd6b3 100644
--- a/sd/source/ui/unoidl/unopage.cxx
+++ b/sd/source/ui/unoidl/unopage.cxx
@@ -1118,10 +1118,9 @@ Any SAL_CALL SdGenericDrawPage::getPropertyValue( const OUString& PropertyName )
                     std::shared_ptr<GDIMetaFile> xMetaFile = pDocShell->GetPreviewMetaFile();
                     if (xMetaFile)
                     {
-                        Point   aPoint;
                         Size    aSize( GetPage()->GetSize() );
                         xMetaFile->AddAction( static_cast<MetaAction*>(new MetaFillColorAction( COL_WHITE, true )), 0 );
-                        xMetaFile->AddAction( static_cast<MetaAction*>(new MetaRectAction( ::tools::Rectangle( aPoint, aSize ) )), 1 );
+                        xMetaFile->AddAction( static_cast<MetaAction*>(new MetaRectAction( ::tools::Rectangle( Point(), aSize ) )), 1 );
                         xMetaFile->SetPrefMapMode(MapMode(MapUnit::Map100thMM));
                         xMetaFile->SetPrefSize( aSize );
 
diff --git a/sd/source/ui/view/drviews9.cxx b/sd/source/ui/view/drviews9.cxx
index d2ea8c5565fd..4c2e6b1c3203 100644
--- a/sd/source/ui/view/drviews9.cxx
+++ b/sd/source/ui/view/drviews9.cxx
@@ -647,8 +647,7 @@ void DrawViewShell::AttrExec (SfxRequest &rReq)
 
                         if (i >= nCounts)
                         {
-                            Color  aBlack (0, 0, 0);
-                            XHatch aHatch (aBlack, static_cast<css::drawing::HatchStyle>(pStyle->GetValue ()), pDistance->GetValue (),
+                            XHatch aHatch (Color(0), static_cast<css::drawing::HatchStyle>(pStyle->GetValue ()), pDistance->GetValue (),
                                            pAngle->GetValue () * 10);
 
                             pHatchList->Insert(o3tl::make_unique<XHatchEntry>(aHatch, pName->GetValue()));
diff --git a/sd/source/ui/view/outlview.cxx b/sd/source/ui/view/outlview.cxx
index 48ce3459d989..cd63ec9f63c6 100644
--- a/sd/source/ui/view/outlview.cxx
+++ b/sd/source/ui/view/outlview.cxx
@@ -113,8 +113,7 @@ OutlineView::OutlineView( DrawDocShell& rDocSh, vcl::Window* pWindow, OutlineVie
     }
 
     mpOutlinerView[0] = new OutlinerView(&mrOutliner, pWindow);
-    ::tools::Rectangle aNullRect;
-    mpOutlinerView[0]->SetOutputArea(aNullRect);
+    mpOutlinerView[0]->SetOutputArea(::tools::Rectangle());
     mrOutliner.SetUpdateMode(false);
     mrOutliner.InsertView(mpOutlinerView[0], EE_APPEND);
 
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index 7fe8d968dbe7..fcf8c320397c 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -689,7 +689,7 @@ static bool impl_showOnlineHelp( const OUString& rURL )
 static bool impl_showOfflineHelp( const OUString& rURL )
 {
     OUString aBaseInstallPath = getHelpRootURL();
-    OUString aInternal( "vnd.sun.star.help://"  );
+    OUString const aInternal( "vnd.sun.star.help://"  );
 
     OUString aHelpLink( aBaseInstallPath + "/" + utl::ConfigManager::getProductVersion() + "/index.html?" );
     aHelpLink += rURL.copy( aInternal.getLength() );
diff --git a/sfx2/source/appl/workwin.cxx b/sfx2/source/appl/workwin.cxx
index 48554dd8284d..f18c271cdeb8 100644
--- a/sfx2/source/appl/workwin.cxx
+++ b/sfx2/source/appl/workwin.cxx
@@ -2317,8 +2317,7 @@ void SfxWorkWindow::EndAutoShow_Impl( Point aPos )
         if ( p && p->IsAutoHide(false) )
         {
             Point aLocalPos = p->ScreenToOutputPixel( aPos );
-            Point aEmptyPoint;
-            tools::Rectangle aRect( aEmptyPoint, p->GetSizePixel() );
+            tools::Rectangle aRect( Point(), p->GetSizePixel() );
             if ( !aRect.IsInside( aLocalPos ) )
                 p->FadeOut();
         }
diff --git a/sfx2/source/control/thumbnailviewacc.cxx b/sfx2/source/control/thumbnailviewacc.cxx
index 4029b6792ce0..600e8d705e21 100644
--- a/sfx2/source/control/thumbnailviewacc.cxx
+++ b/sfx2/source/control/thumbnailviewacc.cxx
@@ -825,8 +825,7 @@ awt::Rectangle SAL_CALL ThumbnailViewItemAcc::getBounds()
     if( mpParent )
     {
         tools::Rectangle   aRect( mpParent->getDrawArea() );
-        Point       aOrigin;
-        tools::Rectangle   aParentRect( aOrigin, mpParent->mrParent.GetOutputSizePixel() );
+        tools::Rectangle   aParentRect( Point(), mpParent->mrParent.GetOutputSizePixel() );
 
         aRect.Intersection( aParentRect );
 
diff --git a/sfx2/source/doc/docfilt.cxx b/sfx2/source/doc/docfilt.cxx
index b3d931124f4c..0bfefd65a59b 100644
--- a/sfx2/source/doc/docfilt.cxx
+++ b/sfx2/source/doc/docfilt.cxx
@@ -175,9 +175,9 @@ OUString SfxFilter::GetTypeFromStorage(
             SotClipboardFormatId nClipId = SotExchange::GetFormat( aDataFlavor );
             if ( nClipId != SotClipboardFormatId::NONE )
             {
-                SfxFilterFlags nMust = SfxFilterFlags::IMPORT;
+                SfxFilterFlags const nMust = SfxFilterFlags::IMPORT;
                 // template filters shouldn't be detected if not explicitly asked for
-                SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED | SfxFilterFlags::TEMPLATEPATH;
+                SfxFilterFlags const nDont = SFX_FILTER_NOTINSTALLED | SfxFilterFlags::TEMPLATEPATH;
 
                 // get filter from storage MediaType
                 std::shared_ptr<const SfxFilter> pFilter = aMatcher.GetFilter4ClipBoardId( nClipId, nMust, nDont );
diff --git a/sfx2/source/doc/new.cxx b/sfx2/source/doc/new.cxx
index cd78f4b524ca..9c363b02e17b 100644
--- a/sfx2/source/doc/new.cxx
+++ b/sfx2/source/doc/new.cxx
@@ -69,8 +69,7 @@ Size SfxPreviewBase_Impl::GetOptimalSize() const
 void SfxPreviewWin_Impl::ImpPaint(vcl::RenderContext& rRenderContext, GDIMetaFile* pFile)
 {
     rRenderContext.SetLineColor();
-    Color aLightGrayCol(COL_LIGHTGRAY);
-    rRenderContext.SetFillColor(aLightGrayCol);
+    rRenderContext.SetFillColor(COL_LIGHTGRAY);
     rRenderContext.DrawRect(tools::Rectangle(Point(0,0), rRenderContext.GetOutputSize()));
 
     Size aTmpSize = pFile ? pFile->GetPrefSize() : Size(1, 1);
@@ -101,10 +100,8 @@ void SfxPreviewWin_Impl::ImpPaint(vcl::RenderContext& rRenderContext, GDIMetaFil
 
     if (pFile)
     {
-        Color aBlackCol(COL_BLACK);
-        Color aWhiteCol(COL_WHITE);
-        rRenderContext.SetLineColor(aBlackCol);
-        rRenderContext.SetFillColor(aWhiteCol);
+        rRenderContext.SetLineColor(COL_BLACK);
+        rRenderContext.SetFillColor(COL_WHITE);
         rRenderContext.DrawRect(tools::Rectangle(aPoint + Point(FRAME, FRAME), bPoint + Point(FRAME, FRAME)));
         pFile->WindStart();
         pFile->Play(&rRenderContext, aPoint + Point(FRAME, FRAME), aSize);
diff --git a/sfx2/source/view/frame.cxx b/sfx2/source/view/frame.cxx
index 82facc714be5..08c404f6fb04 100644
--- a/sfx2/source/view/frame.cxx
+++ b/sfx2/source/view/frame.cxx
@@ -599,8 +599,7 @@ void SfxFrame::SetToolSpaceBorderPixel_Impl( const SvBorder& rBorder )
 tools::Rectangle SfxFrame::GetTopOuterRectPixel_Impl() const
 {
     Size aSize( GetWindow().GetOutputSizePixel() );
-    Point aPoint;
-    return ( tools::Rectangle ( aPoint, aSize ) );
+    return tools::Rectangle( Point(), aSize );
 }
 
 SfxWorkWindow* SfxFrame::GetWorkWindow_Impl() const
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index a7874e1934b0..33978818fa44 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -1168,8 +1168,7 @@ void SfxViewFrame::SetBorderPixelImpl
     }
     else
     {
-        Point aPoint;
-        tools::Rectangle aEditArea( aPoint, GetWindow().GetOutputSizePixel() );
+        tools::Rectangle aEditArea( Point(), GetWindow().GetOutputSizePixel() );
         aEditArea.AdjustLeft(rBorder.Left() );
         aEditArea.AdjustRight( -(rBorder.Right()) );
         aEditArea.AdjustTop(rBorder.Top() );
diff --git a/slideshow/source/engine/shapes/gdimtftools.cxx b/slideshow/source/engine/shapes/gdimtftools.cxx
index 86ebae1a6358..de099219e11b 100644
--- a/slideshow/source/engine/shapes/gdimtftools.cxx
+++ b/slideshow/source/engine/shapes/gdimtftools.cxx
@@ -140,11 +140,10 @@ public:
         {
             // wrap bitmap into GDIMetafile
             GDIMetaFileSharedPtr xMtf(new GDIMetaFile);
-            ::Point         aEmptyPoint;
 
             ::BitmapEx      aBmpEx( aGraphic.GetBitmapEx() );
 
-            xMtf->AddAction( new MetaBmpExAction( aEmptyPoint,
+            xMtf->AddAction( new MetaBmpExAction( Point(),
                                                  aBmpEx ) );
             xMtf->SetPrefSize( aBmpEx.GetPrefSize() );
             xMtf->SetPrefMapMode( aBmpEx.GetPrefMapMode() );
diff --git a/starmath/source/edit.cxx b/starmath/source/edit.cxx
index edd7db345037..cc77f688eefc 100644
--- a/starmath/source/edit.cxx
+++ b/starmath/source/edit.cxx
@@ -554,8 +554,7 @@ IMPL_LINK( SmEditWindow, ScrollHdl, ScrollBar *, /*pScrollBar*/, void )
 tools::Rectangle SmEditWindow::AdjustScrollBars()
 {
     const Size aOut( GetOutputSizePixel() );
-    Point aPoint;
-    tools::Rectangle aRect( aPoint, aOut );
+    tools::Rectangle aRect( Point(), aOut );
 
     if (pVScrollBar && pHScrollBar && pScrollBox)
     {
diff --git a/starmath/source/rect.cxx b/starmath/source/rect.cxx
index c67c1a2b72f0..1ec45fbeb10d 100644
--- a/starmath/source/rect.cxx
+++ b/starmath/source/rect.cxx
@@ -73,9 +73,8 @@ bool SmGetGlyphBoundRect(const vcl::RenderContext &rDev,
     pGlyphDev->SetFont(aFnt);
 
     long nTextWidth = rDev.GetTextWidth(rText);
-    Point aPoint;
-    tools::Rectangle   aResult (aPoint, Size(nTextWidth, rDev.GetTextHeight())),
-                aTmp;
+    tools::Rectangle   aResult (Point(), Size(nTextWidth, rDev.GetTextHeight())),
+                       aTmp;
 
     bool bSuccess = pGlyphDev->GetTextBoundRect(aTmp, rText);
     OSL_ENSURE( bSuccess, "GetTextBoundRect failed" );
diff --git a/starmath/source/unomodel.cxx b/starmath/source/unomodel.cxx
index 768071767962..63816bd3c525 100644
--- a/starmath/source/unomodel.cxx
+++ b/starmath/source/unomodel.cxx
@@ -1015,8 +1015,7 @@ void SAL_CALL SmModel::render(
                     aPrtPageOffset = Point( static_cast<long>(aPrtPaperSize.Width()  * 0.0250),
                                             static_cast<long>(aPrtPaperSize.Height() * 0.0214));
                 }
-                Point   aZeroPoint;
-                tools::Rectangle OutputRect( aZeroPoint, aOutputSize );
+                tools::Rectangle OutputRect( Point(), aOutputSize );
 
 
                 // set minimum top and bottom border
diff --git a/starmath/source/view.cxx b/starmath/source/view.cxx
index fbd977d07ff2..353d3658d90d 100644
--- a/starmath/source/view.cxx
+++ b/starmath/source/view.cxx
@@ -809,8 +809,7 @@ IMPL_LINK_NOARG( SmCmdBoxWindow, InitialFocusTimerHdl, Timer *, void )
 
 void SmCmdBoxWindow::AdjustPosition()
 {
-    Point aPt;
-    const tools::Rectangle aRect( aPt, GetParent()->GetOutputSizePixel() );
+    const tools::Rectangle aRect( Point(), GetParent()->GetOutputSizePixel() );
     Point aTopLeft( Point( aRect.Left(),
                            aRect.Bottom() - GetSizePixel().Height() ) );
     Point aPos( GetParent()->OutputToScreenPixel( aTopLeft ) );
@@ -2021,8 +2020,7 @@ void SmViewShell::ZoomByItemSet(const SfxItemSet *pSet)
         {
             const MapMode aMap( MapUnit::Map100thMM );
             SfxPrinter *pPrinter = GetPrinter( true );
-            Point aPoint;
-            tools::Rectangle  OutputRect(aPoint, pPrinter->GetOutputSize());
+            tools::Rectangle  OutputRect(Point(), pPrinter->GetOutputSize());
             Size       OutputSize(pPrinter->LogicToPixel(Size(OutputRect.GetWidth(),
                                                               OutputRect.GetHeight()), aMap));
             Size       GraphicSize(pPrinter->LogicToPixel(GetDoc()->GetSize(), aMap));
diff --git a/svtools/source/contnr/ivctrl.cxx b/svtools/source/contnr/ivctrl.cxx
index 16dfe2749f72..796579b0a838 100644
--- a/svtools/source/contnr/ivctrl.cxx
+++ b/svtools/source/contnr/ivctrl.cxx
@@ -349,8 +349,7 @@ void SvtIconChoiceCtrl::SetBackground( const Wallpaper& rPaper )
 
         WallpaperStyle eStyle = aBackground.GetStyle();
         Color aBack( aBackground.GetColor());
-        Color aTrans( COL_TRANSPARENT );
-        if( aBack == aTrans &&
+        if( aBack == COL_TRANSPARENT &&
             (!aBackground.IsBitmap() ||
              aBackground.GetBitmap().IsTransparent() ||
              (eStyle != WallpaperStyle::Tile && eStyle != WallpaperStyle::Scale)) )
diff --git a/svtools/source/contnr/svtabbx.cxx b/svtools/source/contnr/svtabbx.cxx
index 21b458212319..9a804adb162b 100644
--- a/svtools/source/contnr/svtabbx.cxx
+++ b/svtools/source/contnr/svtabbx.cxx
@@ -1143,8 +1143,7 @@ Reference< XAccessible > SvHeaderTabListBox::CreateAccessible()
 
 tools::Rectangle SvHeaderTabListBox::GetFieldCharacterBounds(sal_Int32,sal_Int32,sal_Int32)
 {
-    tools::Rectangle aRect;
-    return aRect;
+    return tools::Rectangle();
 }
 
 sal_Int32 SvHeaderTabListBox::GetFieldIndexAtPoint(sal_Int32 _nRow,sal_Int32 _nColumnPos,const Point& _rPoint)
diff --git a/svtools/source/contnr/treelistbox.cxx b/svtools/source/contnr/treelistbox.cxx
index 0a68c3405e18..aa070ff36a88 100644
--- a/svtools/source/contnr/treelistbox.cxx
+++ b/svtools/source/contnr/treelistbox.cxx
@@ -3472,8 +3472,7 @@ void SvTreeListBox::EnableAsyncDrag( bool b )
 
 SvTreeListEntry* SvTreeListBox::GetFirstEntryInView() const
 {
-    Point aPos;
-    return GetEntry( aPos );
+    return GetEntry( Point() );
 }
 
 SvTreeListEntry* SvTreeListBox::GetNextEntryInView(SvTreeListEntry* pEntry ) const
diff --git a/svtools/source/control/calendar.cxx b/svtools/source/control/calendar.cxx
index efd07162ce05..e89605313e54 100644
--- a/svtools/source/control/calendar.cxx
+++ b/svtools/source/control/calendar.cxx
@@ -220,7 +220,7 @@ void Calendar::ImplFormat()
         if ( (aOutSize.Width() <= 1) || (aOutSize.Height() <= 1) )
             return;
 
-        OUString a99Text("99");
+        OUString const a99Text("99");
 
         vcl::Font aOldFont = GetFont();
 
@@ -1577,7 +1577,7 @@ void Calendar::EndSelection()
 
 Size Calendar::CalcWindowSizePixel() const
 {
-    OUString  a99Text("99");
+    OUString  const a99Text("99");
     vcl::Font aOldFont = GetFont();
 
     Size    aSize;
diff --git a/svtools/source/control/toolbarmenuacc.cxx b/svtools/source/control/toolbarmenuacc.cxx
index eca17d9a53ca..74d91e584b29 100644
--- a/svtools/source/control/toolbarmenuacc.cxx
+++ b/svtools/source/control/toolbarmenuacc.cxx
@@ -762,8 +762,7 @@ awt::Rectangle SAL_CALL ToolbarMenuEntryAcc::getBounds()
     if( mpParent )
     {
         tools::Rectangle   aRect( mpParent->maRect );
-        Point       aOrigin;
-        tools::Rectangle   aParentRect( aOrigin, mpParent->mrMenu.GetOutputSizePixel() );
+        tools::Rectangle   aParentRect( Point(), mpParent->mrMenu.GetOutputSizePixel() );
 
         aRect.Intersection( aParentRect );
 
diff --git a/svtools/source/control/valueacc.cxx b/svtools/source/control/valueacc.cxx
index e6e8e6b909e0..4abbb3a4c645 100644
--- a/svtools/source/control/valueacc.cxx
+++ b/svtools/source/control/valueacc.cxx
@@ -951,8 +951,7 @@ awt::Rectangle SAL_CALL ValueItemAcc::getBounds()
     if( mpParent )
     {
         tools::Rectangle   aRect( mpParent->mrParent.GetItemRect(mpParent->mnId) );
-        Point       aOrigin;
-        tools::Rectangle   aParentRect( aOrigin, mpParent->mrParent.GetOutputSizePixel() );
+        tools::Rectangle   aParentRect( Point(), mpParent->mrParent.GetOutputSizePixel() );
 
         aRect.Intersection( aParentRect );
 
diff --git a/svtools/source/graphic/grfmgr2.cxx b/svtools/source/graphic/grfmgr2.cxx
index bc3dab23f454..2c9429f01be6 100644
--- a/svtools/source/graphic/grfmgr2.cxx
+++ b/svtools/source/graphic/grfmgr2.cxx
@@ -921,8 +921,7 @@ bool GraphicManager::ImplCreateOutput( OutputDevice* pOutputDevice,
         // calculate output sizes
         if( !pBmpEx )
         {
-            Point       aPt;
-            tools::Rectangle   aOutRect( aPt, pOutputDevice->GetOutputSizePixel() );
+            tools::Rectangle   aOutRect( Point(), pOutputDevice->GetOutputSizePixel() );
             tools::Rectangle   aBmpRect( aOutputPointPix, aOutputSizePix );
 
             if( pOutputDevice->GetOutDevType() == OUTDEV_WINDOW )
diff --git a/svtools/source/hatchwindow/ipwin.cxx b/svtools/source/hatchwindow/ipwin.cxx
index 9da230d76dbf..20d49a243516 100644
--- a/svtools/source/hatchwindow/ipwin.cxx
+++ b/svtools/source/hatchwindow/ipwin.cxx
@@ -109,10 +109,8 @@ void SvResizeHelper::Draw(vcl::RenderContext& rRenderContext)
 {
     rRenderContext.Push();
     rRenderContext.SetMapMode( MapMode() );
-    Color aColBlack;
-    Color aFillColor( COL_LIGHTGRAY );
 
-    rRenderContext.SetFillColor( aFillColor );
+    rRenderContext.SetFillColor( COL_LIGHTGRAY );
     rRenderContext.SetLineColor();
 
     tools::Rectangle aMoveRects[ 4 ];
@@ -121,7 +119,7 @@ void SvResizeHelper::Draw(vcl::RenderContext& rRenderContext)
     for (i = 0; i < 4; i++)
         rRenderContext.DrawRect(aMoveRects[i]);
     // draw handles
-    rRenderContext.SetFillColor(aColBlack);
+    rRenderContext.SetFillColor(Color()); // black
     tools::Rectangle aRects[ 8 ];
     FillHandleRectsPixel(aRects);
     for (i = 0; i < 8; i++)
diff --git a/svtools/source/misc/langhelp.cxx b/svtools/source/misc/langhelp.cxx
index 55643af50621..75ce24b589a3 100644
--- a/svtools/source/misc/langhelp.cxx
+++ b/svtools/source/misc/langhelp.cxx
@@ -115,7 +115,7 @@ OUString getInstalledLocaleForSystemUILanguage(const css::uno::Sequence<OUString
         {
             // Get the list of langpacks that this build was configured to include
             std::vector<OUString> aPackages;
-            OUString sAvailableLocales(WITH_LANG);
+            OUString const sAvailableLocales(WITH_LANG);
             std::vector<OUString> aAvailable;
             sal_Int32 nIndex = 0;
             do
diff --git a/svx/source/accessibility/charmapacc.cxx b/svx/source/accessibility/charmapacc.cxx
index c8b820939565..02b67240f626 100644
--- a/svx/source/accessibility/charmapacc.cxx
+++ b/svx/source/accessibility/charmapacc.cxx
@@ -738,8 +738,7 @@ awt::Rectangle SvxShowCharSetItemAcc::implGetBounds(  )
     if( mpParent )
     {
         tools::Rectangle   aRect( mpParent->maRect );
-        Point       aOrigin;
-        tools::Rectangle   aParentRect( aOrigin, mpParent->mrParent.GetOutputSizePixel() );
+        tools::Rectangle   aParentRect( Point(), mpParent->mrParent.GetOutputSizePixel() );
 
         aRect.Intersection( aParentRect );
 
diff --git a/svx/source/dialog/connctrl.cxx b/svx/source/dialog/connctrl.cxx
index f9eebf9f8a70..b9a8ea76b1bd 100644
--- a/svx/source/dialog/connctrl.cxx
+++ b/svx/source/dialog/connctrl.cxx
@@ -134,8 +134,7 @@ void SvxXConnectionPreview::AdaptSize()
     aDisplayMap.SetOrigin( aNewPos );
     SetMapMode( aDisplayMap );
 
-    Point aPos;
-    MouseEvent aMEvt( aPos, 1, MouseEventModifiers::NONE, MOUSE_RIGHT );
+    MouseEvent aMEvt( Point(), 1, MouseEventModifiers::NONE, MOUSE_RIGHT );
     MouseButtonDown( aMEvt );
 }
 
diff --git a/svx/source/dialog/contwnd.cxx b/svx/source/dialog/contwnd.cxx
index 4f9f14e88064..b25c123f27b6 100644
--- a/svx/source/dialog/contwnd.cxx
+++ b/svx/source/dialog/contwnd.cxx
@@ -174,8 +174,7 @@ void ContourWindow::MouseMove( const MouseEvent& rMEvt )
 
 void ContourWindow::MouseButtonUp(const MouseEvent& rMEvt)
 {
-    Point aTmpPoint;
-    const tools::Rectangle aGraphRect( aTmpPoint, GetGraphicSize() );
+    const tools::Rectangle aGraphRect( Point(), GetGraphicSize() );
     const Point     aLogPt( PixelToLogic( rMEvt.GetPosPixel() ) );
 
     bClickValid = aGraphRect.IsInside( aLogPt );
diff --git a/svx/source/dialog/imapwnd.cxx b/svx/source/dialog/imapwnd.cxx
index 392467718611..69686edce864 100644
--- a/svx/source/dialog/imapwnd.cxx
+++ b/svx/source/dialog/imapwnd.cxx
@@ -182,8 +182,7 @@ void IMapWindow::SetTargetList( TargetList& rTargetList )
 
 SdrObject* IMapWindow::CreateObj( const IMapObject* pIMapObj )
 {
-    Point       aPoint;
-    tools::Rectangle   aClipRect( aPoint, GetGraphicSize() );
+    tools::Rectangle   aClipRect( Point(), GetGraphicSize() );
     SdrObject*  pSdrObj = nullptr;
     IMapObjectPtr pCloneIMapObj;
 
diff --git a/svx/source/sidebar/line/LineWidthValueSet.cxx b/svx/source/sidebar/line/LineWidthValueSet.cxx
index 8aaeb8005cfb..9e497c6ca1d4 100644
--- a/svx/source/sidebar/line/LineWidthValueSet.cxx
+++ b/svx/source/sidebar/line/LineWidthValueSet.cxx
@@ -129,11 +129,10 @@ void  LineWidthValueSet::UserDraw( const UserDrawEvent& rUDEvt )
     {
         if( nSelItem ==  nItemId )
         {
-            Color aBackColor(50,107,197);
             tools::Rectangle aBackRect = aRect;
             aBackRect.AdjustTop(3 );
             aBackRect.AdjustBottom( -2 );
-            pDev->SetFillColor(aBackColor);
+            pDev->SetFillColor(Color(50,107,197));
             pDev->DrawRect(aBackRect);
         }
         else
diff --git a/svx/source/svdraw/svdhdl.cxx b/svx/source/svdraw/svdhdl.cxx
index cd3bc2f5fcb6..63b42083fe4b 100644
--- a/svx/source/svdraw/svdhdl.cxx
+++ b/svx/source/svdraw/svdhdl.cxx
@@ -585,7 +585,6 @@ void SdrHdl::CreateB2dIAObject()
                             float fScalingFactor = rOutDev.GetDPIScaleFactor();
                             basegfx::B2DSize aB2DSize(fSize * fScalingFactor, fSize * fScalingFactor);
 
-                            Color aHandleStrokeColor(COL_BLACK);
                             Color aHandleFillColor(COL_LIGHTGREEN);
                             switch (eColIndex)
                             {
@@ -607,7 +606,7 @@ void SdrHdl::CreateB2dIAObject()
                                 default:
                                     break;
                             }
-                            pNewOverlayObject = new sdr::overlay::OverlayHandle(aPosition, aB2DSize, aHandleStrokeColor, aHandleFillColor);
+                            pNewOverlayObject = new sdr::overlay::OverlayHandle(aPosition, aB2DSize, /*HandleStrokeColor*/COL_BLACK, aHandleFillColor);
                         }
                         else
                         {
diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx
index 7b6dddf2fabd..70c9faf7978b 100644
--- a/svx/source/svdraw/svdoashp.cxx
+++ b/svx/source/svdraw/svdoashp.cxx
@@ -2957,13 +2957,12 @@ void SdrObjCustomShape::TRSetBaseGeometry(const basegfx::B2DHomMatrix& rMatrix,
     }
 
     // build and set BaseRect (use scale)
-    Point aPoint;
     Size aSize(FRound(aScale.getX()), FRound(aScale.getY()));
     // fdo#47434 We need a valid rectangle here
     if( !aSize.Height() ) aSize.setHeight( 1 );
     if( !aSize.Width() ) aSize.setWidth( 1 );
 
-    tools::Rectangle aBaseRect(aPoint, aSize);
+    tools::Rectangle aBaseRect(Point(), aSize);
     SetSnapRect(aBaseRect);
 
     // shear?
diff --git a/svx/source/svdraw/svdotext.cxx b/svx/source/svdraw/svdotext.cxx
index 5449c5f8c877..cf4448fac249 100644
--- a/svx/source/svdraw/svdotext.cxx
+++ b/svx/source/svdraw/svdotext.cxx
@@ -1204,9 +1204,8 @@ void SdrTextObj::ImpInitDrawOutliner( SdrOutliner& rOutl ) const
     EEControlBits nStat=rOutl.GetControlWord();
     nStat &= ~EEControlBits(EEControlBits::STRETCHING|EEControlBits::AUTOPAGESIZE);
     rOutl.SetControlWord(nStat);
-    Size aNullSize;
     Size aMaxSize(100000,100000);
-    rOutl.SetMinAutoPaperSize(aNullSize);
+    rOutl.SetMinAutoPaperSize(Size());
     rOutl.SetMaxAutoPaperSize(aMaxSize);
     rOutl.SetPaperSize(aMaxSize);
     rOutl.ClearPolygon();
diff --git a/svx/source/svdraw/svdoutl.cxx b/svx/source/svdraw/svdoutl.cxx
index 5ed3a5d0a761..bebb82b76c54 100644
--- a/svx/source/svdraw/svdoutl.cxx
+++ b/svx/source/svdraw/svdoutl.cxx
@@ -56,9 +56,8 @@ void SdrOutliner::SetTextObj( const SdrTextObj* pObj )
         nStat &= ~EEControlBits( EEControlBits::STRETCHING | EEControlBits::AUTOPAGESIZE );
         SetControlWord(nStat);
 
-        Size aNullSize;
         Size aMaxSize( 100000,100000 );
-        SetMinAutoPaperSize( aNullSize );
+        SetMinAutoPaperSize( Size() );
         SetMaxAutoPaperSize( aMaxSize );
         SetPaperSize( aMaxSize );
         ClearPolygon();
diff --git a/svx/source/table/svdotable.cxx b/svx/source/table/svdotable.cxx
index 14f9896e9259..dab61a948e33 100644
--- a/svx/source/table/svdotable.cxx
+++ b/svx/source/table/svdotable.cxx
@@ -1393,10 +1393,9 @@ void SdrTableObj::TakeTextRect( const CellPos& rPos, SdrOutliner& rOutliner, too
     SdrTextVertAdjust eVAdj=xCell->GetTextVerticalAdjust();
 
     EEControlBits nStat0=rOutliner.GetControlWord();
-    Size aNullSize;
     nStat0 |= EEControlBits::AUTOPAGESIZE;
     rOutliner.SetControlWord(nStat0);
-    rOutliner.SetMinAutoPaperSize(aNullSize);
+    rOutliner.SetMinAutoPaperSize(Size());
     rOutliner.SetMaxAutoPaperSize(aAnkRect.GetSize());
     rOutliner.SetPaperSize(aAnkRect.GetSize());
 
diff --git a/svx/source/uitest/sdrobject.cxx b/svx/source/uitest/sdrobject.cxx
index 4fdd4c315764..2f0b05096a04 100644
--- a/svx/source/uitest/sdrobject.cxx
+++ b/svx/source/uitest/sdrobject.cxx
@@ -148,14 +148,11 @@ void SdrUIObject::execute(const OUString& rAction,
     }
     else if (rAction == "Mirror")
     {
-        Point aPos;
-        Point aPos2;
-        pObj->Mirror(aPos, aPos2);
+        pObj->Mirror(Point(), Point());
     }
     else if (rAction == "SHEAR")
     {
-        Point aPos;
-        pObj->Shear(aPos, 0.0/*nAngle*/, 0, false);
+        pObj->Shear(Point(), 0.0/*nAngle*/, 0, false);
     }
 }
 
diff --git a/svx/source/xml/xmlgrhlp.cxx b/svx/source/xml/xmlgrhlp.cxx
index ffdf60a21972..ddac8dbbe812 100644
--- a/svx/source/xml/xmlgrhlp.cxx
+++ b/svx/source/xml/xmlgrhlp.cxx
@@ -1060,9 +1060,8 @@ OUString SAL_CALL SvXMLGraphicHelper::saveGraphicByName(css::uno::Reference<css:
 
 OUString SAL_CALL SvXMLGraphicHelper::saveGraphic(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic)
 {
-    OUString aEmpty;
     OUString aOutMimeType;
-    return implSaveGraphic(rxGraphic, aOutMimeType, aEmpty);
+    return implSaveGraphic(rxGraphic, aOutMimeType, OUString());
 }
 
 OUString SvXMLGraphicHelper::implSaveGraphic(css::uno::Reference<css::graphic::XGraphic> const & rxGraphic,
diff --git a/svx/source/xoutdev/_xoutbmp.cxx b/svx/source/xoutdev/_xoutbmp.cxx
index 6b8b2211f693..3700b3618f7d 100644
--- a/svx/source/xoutdev/_xoutbmp.cxx
+++ b/svx/source/xoutdev/_xoutbmp.cxx
@@ -532,8 +532,7 @@ tools::Polygon XOutBitmap::GetContour( const Bitmap& rBmp, const XOutFlags nFlag
 {
     Bitmap      aWorkBmp;
     tools::Polygon aRetPoly;
-    Point       aTmpPoint;
-    tools::Rectangle   aWorkRect( aTmpPoint, rBmp.GetSizePixel() );
+    tools::Rectangle   aWorkRect( Point(), rBmp.GetSizePixel() );
 
     if( pWorkRectPixel )
         aWorkRect.Intersection( *pWorkRectPixel );
diff --git a/sw/source/core/access/acccontext.cxx b/sw/source/core/access/acccontext.cxx
index c0ee49f316a3..9a4c36659c20 100644
--- a/sw/source/core/access/acccontext.cxx
+++ b/sw/source/core/access/acccontext.cxx
@@ -1369,9 +1369,8 @@ bool SwAccessibleContext::Select( SwPaM *pPaM, SdrObject *pObj,
     {
         if( pFEShell )
         {
-            Point aDummy;
             sal_uInt8 nFlags = bAdd ? SW_ADD_SELECT : 0;
-            pFEShell->SelectObj( aDummy, nFlags, pObj );
+            pFEShell->SelectObj( Point(), nFlags, pObj );
             bRet = true;
         }
     }
diff --git a/sw/source/core/doc/DocumentStylePoolManager.cxx b/sw/source/core/doc/DocumentStylePoolManager.cxx
index 660e1067e918..aa8d08f6cf3e 100644
--- a/sw/source/core/doc/DocumentStylePoolManager.cxx
+++ b/sw/source/core/doc/DocumentStylePoolManager.cxx
@@ -1504,8 +1504,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
 
     case RES_POOLCHR_INET_NORMAL:
         {
-            Color aCol( COL_BLUE );
-            aSet.Put( SvxColorItem( aCol, RES_CHRATR_COLOR ) );
+            aSet.Put( SvxColorItem( COL_BLUE, RES_CHRATR_COLOR ) );
             aSet.Put( SvxUnderlineItem( LINESTYLE_SINGLE, RES_CHRATR_UNDERLINE ) );
             // i40133: patch submitted by rail: set language to 'none' to prevent spell checking:
             aSet.Put( SvxLanguageItem( LANGUAGE_NONE, RES_CHRATR_LANGUAGE ) );
@@ -1515,8 +1514,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
         break;
     case RES_POOLCHR_INET_VISIT:
         {
-            Color aCol( COL_RED );
-            aSet.Put( SvxColorItem( aCol, RES_CHRATR_COLOR ) );
+            aSet.Put( SvxColorItem( COL_RED, RES_CHRATR_COLOR ) );
             aSet.Put( SvxUnderlineItem( LINESTYLE_SINGLE, RES_CHRATR_UNDERLINE ) );
             aSet.Put( SvxLanguageItem( LANGUAGE_NONE, RES_CHRATR_LANGUAGE ) );
             aSet.Put( SvxLanguageItem( LANGUAGE_NONE, RES_CHRATR_CJK_LANGUAGE ) );
@@ -1525,8 +1523,7 @@ SwFormat* DocumentStylePoolManager::GetFormatFromPool( sal_uInt16 nId )
         break;
     case RES_POOLCHR_JUMPEDIT:
         {
-            Color aCol( COL_CYAN );
-            aSet.Put( SvxColorItem( aCol, RES_CHRATR_COLOR ) );
+            aSet.Put( SvxColorItem( COL_CYAN, RES_CHRATR_COLOR ) );
             aSet.Put( SvxUnderlineItem( LINESTYLE_DOTTED, RES_CHRATR_UNDERLINE ) );
             aSet.Put( SvxCaseMapItem( SvxCaseMap::SmallCaps, RES_CHRATR_CASEMAP ) );
         }
diff --git a/sw/source/core/frmedt/fefly1.cxx b/sw/source/core/frmedt/fefly1.cxx
index ebd55b4c2da7..92b630350d09 100644
--- a/sw/source/core/frmedt/fefly1.cxx
+++ b/sw/source/core/frmedt/fefly1.cxx
@@ -1116,8 +1116,7 @@ bool SwFEShell::SetDrawingAttr( SfxItemSet& rSet )
     if( GetDoc()->SetFlyFrameAttr( *pFormat, rSet ))
     {
         bRet = true;
-        Point aTmp;
-        SelectObj( aTmp, 0, pObj );
+        SelectObj( Point(), 0, pObj );
     }
     EndAllActionAndCall();
     EndUndo();
diff --git a/sw/source/core/text/inftxt.cxx b/sw/source/core/text/inftxt.cxx
index d4cb80f1e17e..ef5e6be5086e 100644
--- a/sw/source/core/text/inftxt.cxx
+++ b/sw/source/core/text/inftxt.cxx
@@ -993,12 +993,10 @@ void SwTextPaintInfo::DrawRedArrow( const SwLinePortion &rPor ) const
     if ( GetTextFrame()->IsVertical() )
         GetTextFrame()->SwitchHorizontalToVertical( aRect );
 
-    Color aCol( COL_LIGHTRED );
-
     if( aRect.HasArea() )
     {
         const sal_uInt8 nOptions = 0;
-        lcl_DrawSpecial( *this, rPor, aRect, aCol, cChar, nOptions );
+        lcl_DrawSpecial( *this, rPor, aRect, COL_LIGHTRED, cChar, nOptions );
     }
 }
 
diff --git a/sw/source/core/txtnode/fntcap.cxx b/sw/source/core/txtnode/fntcap.cxx
index d536051b752a..36aaf7d0f8c6 100644
--- a/sw/source/core/txtnode/fntcap.cxx
+++ b/sw/source/core/txtnode/fntcap.cxx
@@ -134,8 +134,7 @@ Size SwSubFont::GetCapitalSize( SwDrawTextInfo& rInf )
     // Start:
     const long nOldKern = rInf.GetKern();
     rInf.SetKern( CheckKerning() );
-    Point aPos;
-    rInf.SetPos( aPos );
+    rInf.SetPos( Point() );
     rInf.SetSpace( 0 );
     rInf.SetDrawSpace( false );
     SwDoGetCapitalSize aDo( rInf );
@@ -377,8 +376,7 @@ sal_Int32 SwSubFont::GetCapitalCursorOfst( SwDrawTextInfo& rInf )
     const long nOldKern = rInf.GetKern();
     rInf.SetKern( CheckKerning() );
     SwDoCapitalCursorOfst aDo( rInf, rInf.GetOfst() );
-    Point aPos;
-    rInf.SetPos( aPos );
+    rInf.SetPos( Point() );
     rInf.SetDrawSpace( false );
     DoOnCapitals( aDo );
     rInf.SetKern( nOldKern );
diff --git a/sw/source/filter/writer/wrtswtbl.cxx b/sw/source/filter/writer/wrtswtbl.cxx
index c92803aa5b30..98bc37956fc3 100644
--- a/sw/source/filter/writer/wrtswtbl.cxx
+++ b/sw/source/filter/writer/wrtswtbl.cxx
@@ -193,8 +193,7 @@ void SwWriteTable::MergeBorders( const SvxBorderLine* pBorderLine,
 {
     if( sal_uInt32(-1) == m_nBorderColor )
     {
-        Color aGrayColor( COL_GRAY );
-        if( !pBorderLine->GetColor().IsRGBEqual( aGrayColor ) )
+        if( !pBorderLine->GetColor().IsRGBEqual( COL_GRAY ) )
             m_nBorderColor = pBorderLine->GetColor().GetColor();
     }
 
diff --git a/sw/source/filter/ww8/wrtw8sty.cxx b/sw/source/filter/ww8/wrtw8sty.cxx
index ccfc366f7843..1b0aefe49c4d 100644
--- a/sw/source/filter/ww8/wrtw8sty.cxx
+++ b/sw/source/filter/ww8/wrtw8sty.cxx
@@ -674,7 +674,7 @@ void MSWordStyles::OutputStylesTable()
     // and refuses to load .docx with more, even though the spec seems to allow that;
     // so simply if there are more styles, don't export those
     // Implementing check for all exports DOCX, DOC, RTF
-    sal_uInt16 nLimit = MSWORD_MAX_STYLES_LIMIT;
+    sal_uInt16 const nLimit = MSWORD_MAX_STYLES_LIMIT;
     m_nUsedSlots = std::min(nLimit, m_nUsedSlots);
 
     for ( n = 0; n < m_nUsedSlots; n++ )
diff --git a/sw/source/filter/ww8/wrtww8gr.cxx b/sw/source/filter/ww8/wrtww8gr.cxx
index d51630f76816..4d9ceaa9c00f 100644
--- a/sw/source/filter/ww8/wrtww8gr.cxx
+++ b/sw/source/filter/ww8/wrtww8gr.cxx
@@ -131,17 +131,15 @@ bool WW8Export::TestOleNeedsGraphic(const SwAttrSet& rSet,
     {
         // bGraphicNeeded set to true is right / fixes #i51670#.
         bGraphicNeeded = true;
-        Point aTmpPoint;
-        tools::Rectangle aRect( aTmpPoint, Size( nX, nY ) );
+        tools::Rectangle aRect( Point(), Size( nX, nY ) );
         Graphic aGraph(aWMF);
 
         ErrCode nErr = ERRCODE_NONE;
-        tools::Rectangle aVisArea;
         sal_Int64 nAspect = embed::Aspects::MSOLE_CONTENT;
         if ( pOLENd )
             nAspect = pOLENd->GetAspect();
         SdrOle2Obj *pRet = SvxMSDffManager::CreateSdrOLEFromStorage(
-            rStorageName,xObjStg,m_pDoc->GetDocStorage(),aGraph,aRect,aVisArea,nullptr,nErr,0,nAspect, m_pWriter->GetBaseURL());
+            rStorageName,xObjStg,m_pDoc->GetDocStorage(),aGraph,aRect,tools::Rectangle(),nullptr,nErr,0,nAspect, m_pWriter->GetBaseURL());
 
         if (pRet)
         {
diff --git a/sw/source/filter/ww8/ww8graf.cxx b/sw/source/filter/ww8/ww8graf.cxx
index 8f7cf453a6c1..037dd4f450a9 100644
--- a/sw/source/filter/ww8/ww8graf.cxx
+++ b/sw/source/filter/ww8/ww8graf.cxx
@@ -1783,8 +1783,7 @@ void SwWW8ImplReader::MatchSdrItemsIntoFlySet( SdrObject const * pSdrObj,
 
         rFlySet.Put( aShadow );
     }
-    Color Temp(COL_WHITE);
-    SvxBrushItem aBrushItem(Temp, RES_BACKGROUND);
+    SvxBrushItem aBrushItem(COL_WHITE, RES_BACKGROUND);
     bool bBrushItemOk = false;
     sal_uInt8 nTrans = 0;
 
diff --git a/sw/source/filter/ww8/ww8graf2.cxx b/sw/source/filter/ww8/ww8graf2.cxx
index a1dbe9fc17e8..023aaabf173f 100644
--- a/sw/source/filter/ww8/ww8graf2.cxx
+++ b/sw/source/filter/ww8/ww8graf2.cxx
@@ -561,10 +561,9 @@ SwFrameFormat* SwWW8ImplReader::ImportGraf(SdrTextObj const * pTextObj,
                 m_pDataStream->SeekRel( nNameLen );
             }
 
-            tools::Rectangle aChildRect;
             tools::Rectangle aClientRect( 0,0, aPD.nWidth,  aPD.nHeight);
             SvxMSDffImportData aData( aClientRect );
-            pObject = m_xMSDffManager->ImportObj(*m_pDataStream, &aData, aClientRect, aChildRect, /*nCalledByGroup*/0, /*pShapeId*/nullptr );
+            pObject = m_xMSDffManager->ImportObj(*m_pDataStream, &aData, aClientRect, tools::Rectangle(), /*nCalledByGroup*/0, /*pShapeId*/nullptr );
             if (pObject)
             {
                 // for the frame
diff --git a/sw/source/uibase/dialog/SignatureLineDialog.cxx b/sw/source/uibase/dialog/SignatureLineDialog.cxx
index b574a7b455e4..c7832e4078e9 100644
--- a/sw/source/uibase/dialog/SignatureLineDialog.cxx
+++ b/sw/source/uibase/dialog/SignatureLineDialog.cxx
@@ -179,7 +179,7 @@ void SignatureLineDialog::Apply()
 
 OUString SignatureLineDialog::getSignatureImage()
 {
-    OUString svg(
+    OUString const svg(
         "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?><svg "
         "xmlns:dc=\"http://purl.org/dc/elements/1.1/\" xmlns:cc=\"http://creativecommons.org/ns#\" "
         "xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\" "
diff --git a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx
index dd2ee979dad6..0b7daa49b5d7 100644
--- a/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx
+++ b/sw/source/uibase/dialog/SwSpellDialogChildWindow.cxx
@@ -774,9 +774,8 @@ bool SwSpellDialogChildWindow::FindNextDrawTextError_Impl(SwWrtShell& rSh)
                     std::unique_ptr<OutlinerView> pOutlView( new OutlinerView( &aTmpOutliner, &(rView.GetEditWin()) ) );
                     pOutlView->GetOutliner()->SetRefDevice( rSh.getIDocumentDeviceAccess().getPrinter( false ) );
                     aTmpOutliner.InsertView( pOutlView.get() );
-                    Point aPt;
                     Size aSize(1,1);
-                    tools::Rectangle aRect( aPt, aSize );
+                    tools::Rectangle aRect( Point(), aSize );
                     pOutlView->SetOutputArea( aRect );
                     aTmpOutliner.SetText( *pParaObj );
                     aTmpOutliner.ClearModifyFlag();
diff --git a/sw/source/uibase/docvw/edtdd.cxx b/sw/source/uibase/docvw/edtdd.cxx
index e45561269217..ed773db4b658 100644
--- a/sw/source/uibase/docvw/edtdd.cxx
+++ b/sw/source/uibase/docvw/edtdd.cxx
@@ -338,8 +338,7 @@ sal_Int8 SwEditWin::AcceptDrop( const AcceptDropEvent& rEvt )
 
     // If the cursor is near the inner boundary
     // we attempt to scroll towards the desired direction.
-    Point aPoint;
-    tools::Rectangle aWin(aPoint,GetOutputSizePixel());
+    tools::Rectangle aWin(Point(), GetOutputSizePixel());
     const int nMargin = 10;
     aWin.AdjustLeft(nMargin );
     aWin.AdjustTop(nMargin );
diff --git a/sw/source/uibase/shells/annotsh.cxx b/sw/source/uibase/shells/annotsh.cxx
index da1f9880e303..bc526cb1afb5 100644
--- a/sw/source/uibase/shells/annotsh.cxx
+++ b/sw/source/uibase/shells/annotsh.cxx
@@ -602,9 +602,8 @@ void SwAnnotationShell::Exec( SfxRequest &rReq )
         aNewAttr.Put(*pNewItem);
     }
 
-    tools::Rectangle aNullRect;
     tools::Rectangle aOutRect = pOLV->GetOutputArea();
-    if (aNullRect != aOutRect)
+    if (tools::Rectangle() != aOutRect)
         pOLV->SetAttribs(aNewAttr);
 
     rView.GetViewFrame()->GetBindings().InvalidateAll(false);
diff --git a/sw/source/uibase/shells/drwtxtsh.cxx b/sw/source/uibase/shells/drwtxtsh.cxx
index 603b66ecddba..ef4054229160 100644
--- a/sw/source/uibase/shells/drwtxtsh.cxx
+++ b/sw/source/uibase/shells/drwtxtsh.cxx
@@ -160,11 +160,10 @@ void SwDrawTextShell::StateDisableItems( SfxItemSet &rSet )
 
 void SwDrawTextShell::SetAttrToMarked(const SfxItemSet& rAttr)
 {
-    tools::Rectangle aNullRect;
     OutlinerView* pOLV = pSdrView->GetTextEditOutlinerView();
     tools::Rectangle aOutRect = pOLV->GetOutputArea();
 
-    if (aNullRect != aOutRect)
+    if (tools::Rectangle() != aOutRect)
     {
         GetShell().GetDrawView()->SetAttributes(rAttr);
     }
diff --git a/sw/source/uibase/uiview/view.cxx b/sw/source/uibase/uiview/view.cxx
index 2dec6c0c5054..338c4aa8da83 100644
--- a/sw/source/uibase/uiview/view.cxx
+++ b/sw/source/uibase/uiview/view.cxx
@@ -1648,7 +1648,7 @@ void SwView::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
                 break;
             case SfxHintId::RedlineChanged:
                 {
-                    sal_uInt16 aSlotRedLine[] = {
+                    static sal_uInt16 const aSlotRedLine[] = {
                         FN_REDLINE_NEXT_CHANGE,
                         FN_REDLINE_PREV_CHANGE,
                         FN_REDLINE_ACCEPT_DIRECT,
diff --git a/sw/source/uibase/utlui/content.cxx b/sw/source/uibase/utlui/content.cxx
index 264cb7245b27..8c451e3a9a97 100644
--- a/sw/source/uibase/utlui/content.cxx
+++ b/sw/source/uibase/utlui/content.cxx
@@ -3575,8 +3575,7 @@ void SwContentLBoxString::Paint(const Point& rPos, SvTreeListBox& rDev, vcl::Ren
     {
         vcl::Font aOldFont(rRenderContext.GetFont());
         vcl::Font aFont(aOldFont);
-        Color aCol(COL_LIGHTGRAY);
-        aFont.SetColor(aCol);
+        aFont.SetColor(COL_LIGHTGRAY);
         rRenderContext.SetFont(aFont );
         rRenderContext.DrawText(rPos, GetText());
         rRenderContext.SetFont(aOldFont);
diff --git a/sw/source/uibase/utlui/glbltree.cxx b/sw/source/uibase/utlui/glbltree.cxx
index a4aeaf143853..d29d3eb49762 100644
--- a/sw/source/uibase/utlui/glbltree.cxx
+++ b/sw/source/uibase/utlui/glbltree.cxx
@@ -1258,8 +1258,7 @@ void SwLBoxString::Paint(const Point& rPos, SvTreeListBox& rDev, vcl::RenderCont
         rRenderContext.Push(PushFlags::FONT);
         vcl::Font aOldFont(rRenderContext.GetFont());
         vcl::Font aFont(rRenderContext.GetFont());
-        Color aCol(COL_LIGHTRED);
-        aFont.SetColor(aCol);
+        aFont.SetColor(COL_LIGHTRED);
         rRenderContext.SetFont(aFont);
         rRenderContext.DrawText(rPos, GetText());
         rRenderContext.Pop();
diff --git a/vcl/source/app/help.cxx b/vcl/source/app/help.cxx
index da6ad774d57d..86bf084df4e2 100644
--- a/vcl/source/app/help.cxx
+++ b/vcl/source/app/help.cxx
@@ -340,7 +340,6 @@ void HelpTextWindow::SetHelpText( const OUString& rHelpText )
     }
     else // HELPWINSTYLE_BALLOON
     {
-        Point       aTmpPoint;
         sal_Int32 nCharsInLine = 35 + ((maHelpText.getLength()/100)*5);
         // average width to have all windows consistent
         OUStringBuffer aBuf;
@@ -348,7 +347,7 @@ void HelpTextWindow::SetHelpText( const OUString& rHelpText )
         OUString aXXX = aBuf.makeStringAndClear();
         long nWidth = GetTextWidth( aXXX );
         Size aTmpSize( nWidth, 0x7FFFFFFF );
-        tools::Rectangle aTry1( aTmpPoint, aTmpSize );
+        tools::Rectangle aTry1( Point(), aTmpSize );
         DrawTextFlags nDrawFlags = DrawTextFlags::MultiLine | DrawTextFlags::WordBreak |
                             DrawTextFlags::Left | DrawTextFlags::Top;
         if ( mnStyle & QuickHelpFlags::CtrlText )
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index 4b6ff1ddc3a5..dc437fbca9d3 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -750,8 +750,7 @@ void PushButton::ImplDrawPushButtonFrame(vcl::RenderContext& rRenderContext,
 bool PushButton::ImplHitTestPushButton( vcl::Window const * pDev,
                                         const Point& rPos )
 {
-    Point       aTempPoint;
-    tools::Rectangle   aTestRect( aTempPoint, pDev->GetOutputSizePixel() );
+    tools::Rectangle   aTestRect( Point(), pDev->GetOutputSizePixel() );
 
     return aTestRect.IsInside( rPos );
 }
@@ -934,9 +933,8 @@ void PushButton::ImplDrawPushButton(vcl::RenderContext& rRenderContext)
     HideFocus();
 
     DrawButtonFlags nButtonStyle = ImplGetButtonState();
-    Point aPoint;
     Size aOutSz(GetOutputSizePixel());
-    tools::Rectangle aRect(aPoint, aOutSz);
+    tools::Rectangle aRect(Point(), aOutSz);
     tools::Rectangle aInRect = aRect;
     bool bNativeOK = false;
 
@@ -1517,8 +1515,7 @@ bool PushButton::PreNotify( NotifyEvent& rNEvt )
                 if(aCtrlType == ControlType::Combobox)
                 {
                     // only paint the button part to avoid flickering of the combobox text
-                    Point aPt;
-                    tools::Rectangle aClipRect( aPt, GetOutputSizePixel() );
+                    tools::Rectangle aClipRect( Point(), GetOutputSizePixel() );
                     aClipRect.SetPos(pBorder->ScreenToOutputPixel(OutputToScreenPixel(aClipRect.TopLeft())));
                     pBorder->Invalidate( aClipRect );
                 }
diff --git a/vcl/source/control/combobox.cxx b/vcl/source/control/combobox.cxx
index 990e24454a4c..2db27dfe8d7a 100644
--- a/vcl/source/control/combobox.cxx
+++ b/vcl/source/control/combobox.cxx
@@ -1002,11 +1002,10 @@ long ComboBox::getMaxWidthScrollBarAndDownButton() const
 
     vcl::Window *pBorder = GetWindow( GetWindowType::Border );
     ImplControlValue aControlValue;
-    Point aPoint;
     tools::Rectangle aContent, aBound;
 
     // use the full extent of the control
-    tools::Rectangle aArea( aPoint, pBorder->GetOutputSizePixel() );
+    tools::Rectangle aArea( Point(), pBorder->GetOutputSizePixel() );
 
     if ( GetNativeControlRegion(ControlType::Combobox, ControlPart::ButtonDown,
         aArea, ControlState::NONE, aControlValue, aBound, aContent) )
diff --git a/vcl/source/control/edit.cxx b/vcl/source/control/edit.cxx
index c11b78ff6bf8..a7cb9b6a4a34 100644
--- a/vcl/source/control/edit.cxx
+++ b/vcl/source/control/edit.cxx
@@ -985,8 +985,7 @@ void Edit::ImplClearBackground(vcl::RenderContext& rRenderContext, const tools::
     /*
     * note: at this point the cursor must be switched off already
     */
-    Point aTmpPoint;
-    tools::Rectangle aRect(aTmpPoint, GetOutputSizePixel());
+    tools::Rectangle aRect(Point(), GetOutputSizePixel());
     aRect.SetLeft( nXStart );
     aRect.SetRight( nXEnd );
 
@@ -1007,8 +1006,7 @@ void Edit::ImplPaintBorder(vcl::RenderContext const & rRenderContext, long nXSta
     if (SupportsDoubleBuffering())
         return;
 
-    Point aTmpPoint;
-    tools::Rectangle aRect(aTmpPoint, GetOutputSizePixel());
+    tools::Rectangle aRect(Point(), GetOutputSizePixel());
     aRect.SetLeft( nXStart );
     aRect.SetRight( nXEnd );
 
diff --git a/vcl/source/control/imp_listbox.cxx b/vcl/source/control/imp_listbox.cxx
index f13df3bcd46f..171b75afd151 100644
--- a/vcl/source/control/imp_listbox.cxx
+++ b/vcl/source/control/imp_listbox.cxx
@@ -887,8 +887,7 @@ void ImplListBoxWindow::MouseMove( const MouseEvent& rMEvt )
     }
     else if ( ( ( !mbMulti && IsMouseMoveSelect() ) || mbStackMode ) && mpEntryList->GetEntryCount() )
     {
-        Point aPoint;
-        tools::Rectangle aRect( aPoint, GetOutputSizePixel() );
+        tools::Rectangle aRect( Point(), GetOutputSizePixel() );
         if( aRect.IsInside( rMEvt.GetPosPixel() ) )
         {
             if ( IsMouseMoveSelect() )
@@ -1158,8 +1157,7 @@ bool ImplListBoxWindow::SelectEntries( sal_Int32 nSelect, LB_EVENT_TYPE eLET, bo
 
 void ImplListBoxWindow::Tracking( const TrackingEvent& rTEvt )
 {
-    Point aPoint;
-    tools::Rectangle aRect( aPoint, GetOutputSizePixel() );
+    tools::Rectangle aRect( Point(), GetOutputSizePixel() );
     bool bInside = aRect.IsInside( rTEvt.GetMouseEvent().GetPosPixel() );
 
     if( rTEvt.IsTrackingCanceled() || rTEvt.IsTrackingEnded() ) // MouseButtonUp
diff --git a/vcl/source/control/listbox.cxx b/vcl/source/control/listbox.cxx
index 514d86b94a3d..36ea3202c7d8 100644
--- a/vcl/source/control/listbox.cxx
+++ b/vcl/source/control/listbox.cxx
@@ -1181,10 +1181,9 @@ Size ListBox::CalcMinimumSize() const
         // Try native borders; scrollbar size may not be a good indicator
         // See how large the edit area inside is to estimate what is needed for the dropdown
         ImplControlValue aControlValue;
-        Point aPoint;
         tools::Rectangle aContent, aBound;
         Size aTestSize( 100, 20 );
-        tools::Rectangle aArea( aPoint, aTestSize );
+        tools::Rectangle aArea( Point(), aTestSize );
         if( GetNativeControlRegion( ControlType::Listbox, ControlPart::SubEdit, aArea, ControlState::NONE,
                     aControlValue, aBound, aContent) )
         {
diff --git a/vcl/source/control/spinbtn.cxx b/vcl/source/control/spinbtn.cxx
index b5c388ce54c6..14d9fea61e2c 100644
--- a/vcl/source/control/spinbtn.cxx
+++ b/vcl/source/control/spinbtn.cxx
@@ -102,8 +102,7 @@ void SpinButton::Resize()
     Control::Resize();
 
     Size aSize(GetOutputSizePixel());
-    Point aTmpPoint;
-    tools::Rectangle aRect(aTmpPoint, aSize);
+    tools::Rectangle aRect(Point(), aSize);
     if (mbHorz)
     {
         maLowerRect = tools::Rectangle(0, 0, aSize.Width() / 2, aSize.Height() - 1);
diff --git a/vcl/source/filter/jpeg/JpegReader.cxx b/vcl/source/filter/jpeg/JpegReader.cxx
index 8606491462fd..46c8ef365071 100644
--- a/vcl/source/filter/jpeg/JpegReader.cxx
+++ b/vcl/source/filter/jpeg/JpegReader.cxx
@@ -221,10 +221,9 @@ bool JPEGReader::CreateBitmap(JPEGCreateBitmapParam const & rParam)
 
         if (((1 == nUnit) || (2 == nUnit)) && rParam.X_density && rParam.Y_density )
         {
-            Point       aEmptyPoint;
             Fraction    aFractX( 1, rParam.X_density );
             Fraction    aFractY( 1, rParam.Y_density );
-            MapMode     aMapMode( nUnit == 1 ? MapUnit::MapInch : MapUnit::MapCM, aEmptyPoint, aFractX, aFractY );
+            MapMode     aMapMode( nUnit == 1 ? MapUnit::MapInch : MapUnit::MapCM, Point(), aFractX, aFractY );
             Size        aPrefSize = OutputDevice::LogicToLogic(aSize, aMapMode, MapMode(MapUnit::Map100thMM));
 
             mpBitmap->SetPrefSize(aPrefSize);
diff --git a/vcl/source/gdi/animate.cxx b/vcl/source/gdi/animate.cxx
index 6e1102a5ac49..e1a96c7434a0 100644
--- a/vcl/source/gdi/animate.cxx
+++ b/vcl/source/gdi/animate.cxx
@@ -146,8 +146,7 @@ void Animation::Clear()
 
 bool Animation::IsTransparent() const
 {
-    Point       aPoint;
-    tools::Rectangle   aRect( aPoint, maGlobalSize );
+    tools::Rectangle   aRect( Point(), maGlobalSize );
     bool        bRet = false;
 
     // If some small bitmap needs to be replaced by the background,
@@ -446,8 +445,7 @@ bool Animation::Insert( const AnimationBitmap& rStepBmp )
 
     if( !IsInAnimation() )
     {
-        Point       aPoint;
-        tools::Rectangle   aGlobalRect( aPoint, maGlobalSize );
+        tools::Rectangle   aGlobalRect( Point(), maGlobalSize );
 
         maGlobalSize = aGlobalRect.Union( tools::Rectangle( rStepBmp.aPosPix, rStepBmp.aSizePix ) ).GetSize();
         maList.emplace_back( new AnimationBitmap( rStepBmp ) );
diff --git a/vcl/source/gdi/bitmap.cxx b/vcl/source/gdi/bitmap.cxx
index 8ca224a1c789..27088cc5465c 100644
--- a/vcl/source/gdi/bitmap.cxx
+++ b/vcl/source/gdi/bitmap.cxx
@@ -444,8 +444,7 @@ bool Bitmap::Erase(const Color& rFillColor)
         }
         else
         {
-            Point aTmpPoint;
-            const tools::Rectangle aRect( aTmpPoint, Size( pWriteAcc->Width(), pWriteAcc->Height() ) );
+            const tools::Rectangle aRect( Point(), Size( pWriteAcc->Width(), pWriteAcc->Height() ) );
             pWriteAcc->SetFillColor( rFillColor );
             pWriteAcc->FillRect( aRect );
         }
@@ -752,8 +751,7 @@ bool Bitmap::Crop( const tools::Rectangle& rRectPixel )
 
         if( pReadAcc )
         {
-            Point               aTmpPoint;
-            const tools::Rectangle     aNewRect( aTmpPoint, aRect.GetSize() );
+            const tools::Rectangle     aNewRect( Point(), aRect.GetSize() );
             Bitmap              aNewBmp( aNewRect.GetSize(), GetBitCount(), &pReadAcc->GetPalette() );
             ScopedWriteAccess   pWriteAcc(aNewBmp);
 
diff --git a/vcl/source/gdi/bmpacc3.cxx b/vcl/source/gdi/bmpacc3.cxx
index 6196fd7e6435..3e665746481b 100644
--- a/vcl/source/gdi/bmpacc3.cxx
+++ b/vcl/source/gdi/bmpacc3.cxx
@@ -234,8 +234,7 @@ void BitmapWriteAccess::FillRect( const tools::Rectangle& rRect )
     if (mpFillColor)
     {
         const BitmapColor& rFillColor = *mpFillColor.get();
-        Point aPoint;
-        tools::Rectangle aRect(aPoint, maBitmap.GetSizePixel());
+        tools::Rectangle aRect(Point(), maBitmap.GetSizePixel());
 
         aRect.Intersection(rRect);
 
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index eb73aa2b6349..c38bfe4e4f5d 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -2828,9 +2828,8 @@ bool GDIMetaFile::CreateThumbnail(BitmapEx& rBitmapEx, BmpConversion eColorConve
         Size aAntialias(aDrawSize.Width() * 4, aDrawSize.Height() * 4);
 
         // draw metafile into VDev
-        Point aBackPosPix;
         const_cast<GDIMetaFile *>(this)->WindStart();
-        const_cast<GDIMetaFile *>(this)->Play(aVDev.get(), aBackPosPix, aAntialias);
+        const_cast<GDIMetaFile *>(this)->Play(aVDev.get(), Point(), aAntialias);
 
         // get paint bitmap
         Bitmap aBitmap( aVDev->GetBitmap( aNullPt, aVDev->GetOutputSizePixel() ) );
diff --git a/vcl/source/gdi/print.cxx b/vcl/source/gdi/print.cxx
index 66a15d0e257b..60d3649baf0b 100644
--- a/vcl/source/gdi/print.cxx
+++ b/vcl/source/gdi/print.cxx
@@ -733,7 +733,6 @@ void Printer::DrawDeviceMask( const Bitmap& rMask, const Color& rMaskColor,
                          const Point& rDestPt, const Size& rDestSize,
                          const Point& rSrcPtPixel, const Size& rSrcSizePixel )
 {
-    Point       aPt;
     Point       aDestPt( LogicToPixel( rDestPt ) );
     Size        aDestSz( LogicToPixel( rDestSize ) );
     tools::Rectangle   aSrcRect( rSrcPtPixel, rSrcSizePixel );
@@ -766,7 +765,7 @@ void Printer::DrawDeviceMask( const Bitmap& rMask, const Color& rMaskColor,
     }
 
     // source cropped?
-    if( aSrcRect != tools::Rectangle( aPt, aMask.GetSizePixel() ) )
+    if( aSrcRect != tools::Rectangle( Point(), aMask.GetSizePixel() ) )
         aMask.Crop( aSrcRect );
 
     // destination mirrored
diff --git a/vcl/source/gdi/salgdilayout.cxx b/vcl/source/gdi/salgdilayout.cxx
index 1c6e6f72ac1e..4efc812a0fce 100644
--- a/vcl/source/gdi/salgdilayout.cxx
+++ b/vcl/source/gdi/salgdilayout.cxx
@@ -698,8 +698,7 @@ bool SalGraphics::DrawNativeControl( ControlType nType, ControlPart nPart, const
     if( (m_nLayout & SalLayoutFlags::BiDiRtl) || (pOutDev && pOutDev->IsRTLEnabled()) )
     {
         tools::Rectangle rgn( rControlRegion );
-        tools::Rectangle aNull;
-        if (rgn != aNull)
+        if (rgn != tools::Rectangle())
             mirror(rgn, pOutDev);
         std::unique_ptr< ImplControlValue > mirrorValue( aValue.clone());
         mirror( *mirrorValue, pOutDev );
diff --git a/vcl/source/outdev/bitmap.cxx b/vcl/source/outdev/bitmap.cxx
index 353cc4fb7e92..c8a52cac435d 100644
--- a/vcl/source/outdev/bitmap.cxx
+++ b/vcl/source/outdev/bitmap.cxx
@@ -182,8 +182,7 @@ Bitmap OutputDevice::GetDownsampledBitmap( const Size& rDstSz,
 
     if( !aBmp.IsEmpty() )
     {
-        Point           aPoint;
-        const tools::Rectangle aBmpRect( aPoint, aBmp.GetSizePixel() );
+        const tools::Rectangle aBmpRect( Point(), aBmp.GetSizePixel() );
         tools::Rectangle       aSrcRect( rSrcPt, rSrcSz );
 
         // do cropping if necessary
diff --git a/vcl/source/outdev/transparent.cxx b/vcl/source/outdev/transparent.cxx
index 506159a50812..b88b6ceb0b61 100644
--- a/vcl/source/outdev/transparent.cxx
+++ b/vcl/source/outdev/transparent.cxx
@@ -393,8 +393,7 @@ void OutputDevice::EmulateDrawTransparent ( const tools::PolyPolygon& rPolyPoly,
 
     tools::PolyPolygon aPolyPoly( LogicToPixel( rPolyPoly ) );
     tools::Rectangle aPolyRect( aPolyPoly.GetBoundRect() );
-    Point aPoint;
-    tools::Rectangle aDstRect( aPoint, GetOutputSizePixel() );
+    tools::Rectangle aDstRect( Point(), GetOutputSizePixel() );
 
     aDstRect.Intersection( aPolyRect );
 
diff --git a/vcl/source/window/brdwin.cxx b/vcl/source/window/brdwin.cxx
index 282ff6ef47d1..0b027196db8f 100644
--- a/vcl/source/window/brdwin.cxx
+++ b/vcl/source/window/brdwin.cxx
@@ -739,8 +739,7 @@ void ImplSmallBorderWindowView::DrawWindow(vcl::RenderContext& rRenderContext, c
         nFlags |= DrawFrameFlags::WindowBorder;
 
     DecorationView aDecoView(&rRenderContext);
-    Point aTmpPoint;
-    tools::Rectangle aInRect(aTmpPoint, Size(mnWidth, mnHeight));
+    tools::Rectangle aInRect(Point(), Size(mnWidth, mnHeight));
     aDecoView.DrawFrame(aInRect, nStyle, nFlags);
 }
 
diff --git a/vcl/source/window/floatwin.cxx b/vcl/source/window/floatwin.cxx
index e337c7c5c341..53f88865c2cd 100644
--- a/vcl/source/window/floatwin.cxx
+++ b/vcl/source/window/floatwin.cxx
@@ -494,8 +494,8 @@ FloatingWindow* FloatingWindow::ImplFloatHitTest( vcl::Window* pReference, const
         // use the border window to have the exact position
         vcl::Window *pBorderWin = pWin->GetWindow( GetWindowType::Border );
 
-        Point aPt;  // the top-left corner in output coordinates ie (0,0)
-        tools::Rectangle devRect( pBorderWin->ImplOutputToUnmirroredAbsoluteScreenPixel( tools::Rectangle( aPt, pBorderWin->GetSizePixel()) ) ) ;
+        // the top-left corner in output coordinates ie (0,0)
+        tools::Rectangle devRect( pBorderWin->ImplOutputToUnmirroredAbsoluteScreenPixel( tools::Rectangle( Point(), pBorderWin->GetSizePixel()) ) ) ;
         if ( devRect.IsInside( aAbsolute ) )
         {
             rHitTest = HITTEST_WINDOW;
diff --git a/vcl/source/window/menubarwindow.cxx b/vcl/source/window/menubarwindow.cxx
index 56b1ad8fd6eb..18339eec8c11 100644
--- a/vcl/source/window/menubarwindow.cxx
+++ b/vcl/source/window/menubarwindow.cxx
@@ -602,8 +602,7 @@ static void ImplAddNWFSeparator(vcl::RenderContext& rRenderContext, const Size&
         // note: the menubar only provides the upper (dark) half of it, the rest (bright part) is drawn by the docking area
 
         rRenderContext.SetLineColor(rRenderContext.GetSettings().GetStyleSettings().GetSeparatorColor());
-        Point aPt;
-        tools::Rectangle aRect(aPt, rSize);
+        tools::Rectangle aRect(Point(), rSize);
         rRenderContext.DrawLine(aRect.BottomLeft(), aRect.BottomRight());
     }
 }
@@ -920,8 +919,7 @@ void MenuBarWindow::Paint(vcl::RenderContext& rRenderContext, const tools::Recta
             Erase(rRenderContext);
         else
         {
-            Point aPt;
-            tools::Rectangle aCtrlRegion( aPt, aOutputSize );
+            tools::Rectangle aCtrlRegion( Point(), aOutputSize );
 
             rRenderContext.DrawNativeControl(ControlType::Menubar, ControlPart::Entire, aCtrlRegion,
                                              ControlState::ENABLED, aMenubarValue, OUString());
diff --git a/vcl/source/window/menufloatingwindow.cxx b/vcl/source/window/menufloatingwindow.cxx
index 972300f8536e..a2bc5473fb2c 100644
--- a/vcl/source/window/menufloatingwindow.cxx
+++ b/vcl/source/window/menufloatingwindow.cxx
@@ -173,8 +173,7 @@ long MenuFloatingWindow::ImplGetStartY() const
 vcl::Region MenuFloatingWindow::ImplCalcClipRegion() const
 {
     Size aOutSz = GetOutputSizePixel();
-    Point aPos;
-    tools::Rectangle aRect( aPos, aOutSz );
+    tools::Rectangle aRect( Point(), aOutSz );
     aRect.AdjustTop(nScrollerHeight );
     aRect.AdjustBottom( -(nScrollerHeight) );
 
diff --git a/vcl/source/window/scrwnd.cxx b/vcl/source/window/scrwnd.cxx
index de15943f9e77..5650e8462074 100644
--- a/vcl/source/window/scrwnd.cxx
+++ b/vcl/source/window/scrwnd.cxx
@@ -104,8 +104,7 @@ void ImplWheelWindow::ImplSetRegion( const Bitmap& rRegionBmp )
 {
     Point           aPos( GetPointerPosPixel() );
     const Size      aSize( rRegionBmp.GetSizePixel() );
-    Point           aPoint;
-    const tools::Rectangle aRect( aPoint, aSize );
+    const tools::Rectangle aRect( Point(), aSize );
 
     maCenter = maLastMousePos = aPos;
     aPos.AdjustX( -(aSize.Width() >> 1) );
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index e46fd4a0cee8..ee75679c9ded 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -122,9 +122,8 @@ int ToolBox::ImplGetDragWidth( const vcl::RenderContext& rRenderContext, bool bH
     {
 
         ImplControlValue aControlValue;
-        Point aPoint;
         tools::Rectangle aContent, aBound;
-        tools::Rectangle aArea( aPoint, rRenderContext.GetOutputSizePixel() );
+        tools::Rectangle aArea( Point(), rRenderContext.GetOutputSizePixel() );
 
         if ( rRenderContext.GetNativeControlRegion(ControlType::Toolbar,
                 bHorz ? ControlPart::ThumbVert : ControlPart::ThumbHorz,
@@ -248,8 +247,7 @@ void ToolBox::ImplDrawGrip(vcl::RenderContext& rRenderContext,
         ToolbarValue aToolbarValue;
         aToolbarValue.maGripRect = aDragArea;
 
-        Point aPt;
-        tools::Rectangle aCtrlRegion(aPt, aSz);
+        tools::Rectangle aCtrlRegion(Point(), aSz);
 
         bNativeOk = rRenderContext.DrawNativeControl( ControlType::Toolbar, ePart,
                                         aCtrlRegion, ControlState::ENABLED, aToolbarValue, OUString() );
@@ -430,8 +428,7 @@ void ToolBox::ImplDrawGradientBackground(vcl::RenderContext& rRenderContext)
 bool ToolBox::ImplDrawNativeBackground(vcl::RenderContext& rRenderContext)
 {
     // use NWF
-    Point aPt;
-    tools::Rectangle aCtrlRegion(aPt, GetOutputSizePixel());
+    tools::Rectangle aCtrlRegion(Point(), GetOutputSizePixel());
 
     return rRenderContext.DrawNativeControl( ControlType::Toolbar, mbHorz ? ControlPart::DrawBackgroundHorz : ControlPart::DrawBackgroundVert,
                                     aCtrlRegion, ControlState::ENABLED, ImplControlValue(), OUString() );
diff --git a/vcl/unx/gtk/salprn-gtk.cxx b/vcl/unx/gtk/salprn-gtk.cxx
index 9d7abcc7db75..d77a6b69d98d 100644
--- a/vcl/unx/gtk/salprn-gtk.cxx
+++ b/vcl/unx/gtk/salprn-gtk.cxx
@@ -242,7 +242,6 @@ GtkSalPrinter::StartJob(
     if (!bDoJob)
         return false;
 #endif
-    bool bCollate = false;
 
     //To-Do proper name, watch for encodings
     sFileName = OString("/tmp/hacking.ps");
@@ -252,7 +251,7 @@ GtkSalPrinter::StartJob(
 
     //To-Do, swap ps/pdf for gtk_printer_accepts_ps()/gtk_printer_accepts_pdf() ?
 
-    return impl_doJob(&aFileName, i_rJobName, i_rAppName, io_pSetupData, bCollate, io_rController);
+    return impl_doJob(&aFileName, i_rJobName, i_rAppName, io_pSetupData, /*bCollate*/false, io_rController);
 }
 
 bool
diff --git a/vcl/workben/svptest.cxx b/vcl/workben/svptest.cxx
index 4d33ff7934a9..30aa4e0e5d14 100644
--- a/vcl/workben/svptest.cxx
+++ b/vcl/workben/svptest.cxx
@@ -252,14 +252,14 @@ void MyWin::Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle& rR
                               Size( 3000,3000 ),
                               m_aBitmap);
 
-    Color aWhite(0xff, 0xff, 0xff);
-    Color aBlack(0, 0, 0);
-    Color aLightRed(0xff, 0, 0);
-    Color aDarkRed(0x40, 0, 0);
-    Color aLightBlue(0, 0, 0xff);
-    Color aDarkBlue(0,0,0x40);
-    Color aLightGreen(0, 0xff, 0);
-    Color aDarkGreen(0, 0x40, 0);
+    Color const aWhite(0xff, 0xff, 0xff);
+    Color const aBlack(0, 0, 0);
+    Color const aLightRed(0xff, 0, 0);
+    Color const aDarkRed(0x40, 0, 0);
+    Color const aLightBlue(0, 0, 0xff);
+    Color const aDarkBlue(0,0,0x40);
+    Color const aLightGreen(0, 0xff, 0);
+    Color const aDarkGreen(0, 0x40, 0);
 
     Gradient aGradient(GradientStyle::Linear, aBlack, aWhite);
     aGradient.SetAngle(900);


More information about the Libreoffice-commits mailing list