cppcanvas/source/mtfrenderer/implrenderer.cxx | 2 +- vcl/source/gdi/pdfwriter_impl.cxx | 2 +- vcl/source/gdi/sallayout.cxx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
New commits: commit 388c0893a2defa4296fbad31c2add980079b4fee Author: Noel Grandin <noelgran...@gmail.com> AuthorDate: Mon Dec 28 21:09:22 2020 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Tue Dec 29 19:10:41 2020 +0100 use new toRadians function in more places Change-Id: Id9da8dadab277b62053071a59813d7a4bd38f345 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108432 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/cppcanvas/source/mtfrenderer/implrenderer.cxx b/cppcanvas/source/mtfrenderer/implrenderer.cxx index eea91a021e6b..bf93f6bf2e3e 100644 --- a/cppcanvas/source/mtfrenderer/implrenderer.cxx +++ b/cppcanvas/source/mtfrenderer/implrenderer.cxx @@ -574,7 +574,7 @@ namespace cppcanvas::internal const ::basegfx::B2DVector aOffset( rGradient.GetOfsX() / 100.0, rGradient.GetOfsY() / 100.0); - double fRotation( rGradient.GetAngle().get() * M_PI / 1800.0 ); + double fRotation = toRadians( rGradient.GetAngle() ); const double fBorder( rGradient.GetBorder() / 100.0 ); basegfx::B2DHomMatrix aRot90; diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx index 3ba778e09d49..cb1efa987c60 100644 --- a/vcl/source/gdi/pdfwriter_impl.cxx +++ b/vcl/source/gdi/pdfwriter_impl.cxx @@ -6065,7 +6065,7 @@ void PDFWriterImpl::drawLayout( SalLayout& rLayout, const OUString& rText, bool while( nAngle < 0_deg10 ) nAngle += 3600_deg10; nAngle = nAngle % 3600_deg10; - double fAngle = static_cast<double>(nAngle.get()) * M_PI / 1800.0; + double fAngle = toRadians(nAngle); Matrix3 aRotScale; aRotScale.scale( fXScale, 1.0 ); diff --git a/vcl/source/gdi/sallayout.cxx b/vcl/source/gdi/sallayout.cxx index fc3338929ec5..067672dc5366 100644 --- a/vcl/source/gdi/sallayout.cxx +++ b/vcl/source/gdi/sallayout.cxx @@ -572,7 +572,7 @@ Point SalLayout::GetDrawPosition( const Point& rRelative ) const if( nOldOrientation != mnOrientation ) { nOldOrientation = mnOrientation; - double fRad = mnOrientation.get() * (M_PI / 1800.0); + double fRad = toRadians(mnOrientation); fCos = cos( fRad ); fSin = sin( fRad ); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits