diff options
author | Caolán McNamara <caolanm@redhat.com> | 2020-11-11 16:29:05 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2020-11-12 09:47:53 +0100 |
commit | 22ae46a85086ee716dc5c6b727c76bfb9ccb7c0f (patch) | |
tree | d5a562a0ae7e4dd3229e858ad058f36cfb832af8 | |
parent | 0d4ffe9a63422f30752bf886ab23ab1b8d2b10f9 (diff) |
use Point direct and drop a reinterpret_cast
Change-Id: Idd8901225ddb687a2d1b8b5ba4069b40f218191f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105603
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | vcl/source/outdev/font.cxx | 53 |
1 files changed, 26 insertions, 27 deletions
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx index e633781ed040..71dc5e861fcf 100644 --- a/vcl/source/outdev/font.cxx +++ b/vcl/source/outdev/font.cxx @@ -278,32 +278,32 @@ void OutputDevice::ImplGetEmphasisMark( tools::PolyPolygon& rPolyPoly, bool& rPo PolyFlags::Normal, PolyFlags::Control, PolyFlags::Control }; - static const tools::Long aAccentPos[48] = + static const Point aAccentPos[24] = { - 78, 0, - 348, 79, - 599, 235, - 843, 469, - 938, 574, - 990, 669, - 990, 773, - 990, 843, - 964, 895, - 921, 947, - 886, 982, - 860, 999, - 825, 999, - 764, 999, - 721, 964, - 686, 895, - 625, 791, - 556, 660, - 469, 504, - 400, 400, - 261, 252, - 61, 61, - 0, 27, - 9, 0 + { 78, 0 }, + { 348, 79 }, + { 599, 235 }, + { 843, 469 }, + { 938, 574 }, + { 990, 669 }, + { 990, 773 }, + { 990, 843 }, + { 964, 895 }, + { 921, 947 }, + { 886, 982 }, + { 860, 999 }, + { 825, 999 }, + { 764, 999 }, + { 721, 964 }, + { 686, 895 }, + { 625, 791 }, + { 556, 660 }, + { 469, 504 }, + { 400, 400 }, + { 261, 252 }, + { 61, 61 }, + { 0, 27 }, + { 9, 0 } }; rWidth = 0; @@ -396,8 +396,7 @@ void OutputDevice::ImplGetEmphasisMark( tools::PolyPolygon& rPolyPoly, bool& rPo } else { - tools::Polygon aPoly( SAL_N_ELEMENTS( aAccentPos ) / 2, - reinterpret_cast<const Point*>(aAccentPos), + tools::Polygon aPoly( SAL_N_ELEMENTS(aAccentPos), aAccentPos, aAccentPolyFlags ); double dScale = static_cast<double>(nDotSize)/1000.0; aPoly.Scale( dScale, dScale ); |