diff options
author | Leonid Ryzhov <leoryzhov@gmail.com> | 2022-11-21 21:26:49 +0300 |
---|---|---|
committer | Hossein <hossein@libreoffice.org> | 2022-11-24 19:23:29 +0100 |
commit | 6379414ca34527fbe69df2035d49d651655317cd (patch) | |
tree | e48f1123bba47b7bf0e009310cd0a79f169dff35 /vcl | |
parent | 493a714d4a62f78a4726d09d3258c425939c94c3 (diff) |
tdf#146479 Use basegfx fTools for converting the angle unit
Change-Id: I6128262cb0572b267e232f7a647e1c68f5144e68
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143047
Tested-by: Jenkins
Reviewed-by: Hossein <hossein@libreoffice.org>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/filter/ipict/ipict.cxx | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/vcl/source/filter/ipict/ipict.cxx b/vcl/source/filter/ipict/ipict.cxx index 447d1c153625..fcdef08e3592 100644 --- a/vcl/source/filter/ipict/ipict.cxx +++ b/vcl/source/filter/ipict/ipict.cxx @@ -597,9 +597,8 @@ sal_uInt8 PictReader::ReadAndDrawSameArc(PictDrawingMethod eMethod) nstartAngle = nstartAngle + narcAngle; narcAngle=-narcAngle; } - const double pi = 2 * acos(0.0); - double fAng1 = static_cast<double>(nstartAngle) * pi / 180.0; - double fAng2 = static_cast<double>(nstartAngle + narcAngle) * pi / 180.0; + double fAng1 = basegfx::deg2rad(nstartAngle); + double fAng2 = basegfx::deg2rad(nstartAngle + narcAngle); PictReaderShape::drawArc( pVirDev, eMethod == PictDrawingMethod::FRAME, aLastArcRect, fAng1, fAng2, nActPenSize ); return 4; } |