summaryrefslogtreecommitdiff
path: root/vcl/source/gdi/gradient.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source/gdi/gradient.cxx')
-rw-r--r--vcl/source/gdi/gradient.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/vcl/source/gdi/gradient.cxx b/vcl/source/gdi/gradient.cxx
index 899861cfc222..b94223a427c4 100644
--- a/vcl/source/gdi/gradient.cxx
+++ b/vcl/source/gdi/gradient.cxx
@@ -201,7 +201,7 @@ void Gradient::GetBoundRect( const tools::Rectangle& rRect, tools::Rectangle& rB
if( GetStyle() == GradientStyle::Linear || GetStyle() == GradientStyle::Axial )
{
- const double fAngle = nAngle.get() * F_PI1800;
+ const double fAngle = toRadians(nAngle);
const double fWidth = aRect.GetWidth();
const double fHeight = aRect.GetHeight();
double fDX = fWidth * fabs( cos( fAngle ) ) +
@@ -222,7 +222,7 @@ void Gradient::GetBoundRect( const tools::Rectangle& rRect, tools::Rectangle& rB
{
if( GetStyle() == GradientStyle::Square || GetStyle() == GradientStyle::Rect )
{
- const double fAngle = nAngle.get() * F_PI1800;
+ const double fAngle = toRadians(nAngle);
const double fWidth = aRect.GetWidth();
const double fHeight = aRect.GetHeight();
double fDX = fWidth * fabs( cos( fAngle ) ) + fHeight * fabs( sin( fAngle ) );