diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-10-23 07:46:34 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-10-23 09:44:09 +0200 |
commit | a8a461b2fba27f1a729e2b9b28426286617892a9 (patch) | |
tree | 8e05dfae5ef9b070dc54fcbd344ad591cf6e229c /canvas/source/cairo | |
parent | f806a2832aee62efc0e0404f7c24d53aaaf814d0 (diff) |
clang-tidy performance-unnecessary-copy-init in canvas..cui
Change-Id: I08c137d852b5f1f817c171ee4f1cee7971417dc4
Reviewed-on: https://gerrit.libreoffice.org/62214
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'canvas/source/cairo')
-rw-r--r-- | canvas/source/cairo/cairo_canvashelper.cxx | 4 | ||||
-rw-r--r-- | canvas/source/cairo/cairo_textlayout.cxx | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/canvas/source/cairo/cairo_canvashelper.cxx b/canvas/source/cairo/cairo_canvashelper.cxx index 8a80912886a5..dcd752cf6a52 100644 --- a/canvas/source/cairo/cairo_canvashelper.cxx +++ b/canvas/source/cairo/cairo_canvashelper.cxx @@ -694,7 +694,7 @@ namespace cairocanvas for( sal_uInt32 nPolygonIndex = 0; nPolygonIndex < aPolyPolygon.count(); nPolygonIndex++ ) { - ::basegfx::B2DPolygon aPolygon( aPolyPolygon.getB2DPolygon( nPolygonIndex ) ); + const ::basegfx::B2DPolygon& aPolygon( aPolyPolygon.getB2DPolygon( nPolygonIndex ) ); const sal_uInt32 nPointCount( aPolygon.count() ); // to correctly render closed curves, need to output first // point twice (so output one additional point) @@ -831,7 +831,7 @@ namespace cairocanvas // emulate rendering::PathJoinType::NONE by painting single edges for(sal_uInt32 a(0); a < rPolyPoly.count(); a++) { - const basegfx::B2DPolygon aCandidate(rPolyPoly.getB2DPolygon(a)); + const basegfx::B2DPolygon& aCandidate(rPolyPoly.getB2DPolygon(a)); const sal_uInt32 nPointCount(aCandidate.count()); if(nPointCount) diff --git a/canvas/source/cairo/cairo_textlayout.cxx b/canvas/source/cairo/cairo_textlayout.cxx index bce2469d6b9d..087f0479bf05 100644 --- a/canvas/source/cairo/cairo_textlayout.cxx +++ b/canvas/source/cairo/cairo_textlayout.cxx @@ -399,7 +399,7 @@ namespace cairocanvas if (cairo_glyphs.empty()) continue; - vcl::Font aFont = rOutDev.GetFont(); + const vcl::Font& aFont = rOutDev.GetFont(); long nWidth = aFont.GetAverageFontWidth(); long nHeight = aFont.GetFontHeight(); if (nWidth == 0) |