diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2020-12-23 14:09:52 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2020-12-24 12:00:07 +0100 |
commit | 88c0e46e139fe44f7f2a6f9fbaa6b3fd7a827a8d (patch) | |
tree | f41e0a3e856a8dd9dba6bbac7d08e62518b53420 /vcl/source/gdi/pdfwriter_impl.cxx | |
parent | 17aea7c41c95186c03c173a8c6f26cd2ebce4c54 (diff) |
custom literal for Degree10
Change-Id: Id13869138a622e62d9ffebf2c89bddccda6aff01
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108238
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source/gdi/pdfwriter_impl.cxx')
-rw-r--r-- | vcl/source/gdi/pdfwriter_impl.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx index 87b33685cc51..9b70300e5cc7 100644 --- a/vcl/source/gdi/pdfwriter_impl.cxx +++ b/vcl/source/gdi/pdfwriter_impl.cxx @@ -6062,9 +6062,9 @@ void PDFWriterImpl::drawLayout( SalLayout& rLayout, const OUString& rText, bool Degree10 nAngle = m_aCurrentPDFState.m_aFont.GetOrientation(); // normalize angles - while( nAngle < Degree10(0) ) - nAngle += Degree10(3600); - nAngle = nAngle % Degree10(3600); + while( nAngle < 0_deg10 ) + nAngle += 3600_deg10; + nAngle = nAngle % 3600_deg10; double fAngle = static_cast<double>(nAngle.get()) * M_PI / 1800.0; Matrix3 aRotScale; @@ -8300,7 +8300,7 @@ bool PDFWriterImpl::writeGradientFunction( GradientEmit const & rObject ) tools::Rectangle aBoundRect; Point aCenter; - Degree10 nAngle = rObject.m_aGradient.GetAngle() % Degree10(3600); + Degree10 nAngle = rObject.m_aGradient.GetAngle() % 3600_deg10; rObject.m_aGradient.GetBoundRect( aRect, aBoundRect, aCenter ); const bool bLinear = (rObject.m_aGradient.GetStyle() == GradientStyle::Linear); @@ -8326,7 +8326,7 @@ bool PDFWriterImpl::writeGradientFunction( GradientEmit const & rObject ) tools::Polygon aPoly( 2 ); aPoly[0] = aBoundRect.BottomCenter(); aPoly[1] = aBoundRect.TopCenter(); - aPoly.Rotate( aCenter, Degree10(3600) - nAngle ); + aPoly.Rotate( aCenter, 3600_deg10 - nAngle ); aLine.append( static_cast<sal_Int32>(aPoly[0].X()) ); aLine.append( " " ); |