summaryrefslogtreecommitdiff
path: root/vcl/source
diff options
context:
space:
mode:
Diffstat (limited to 'vcl/source')
-rw-r--r--vcl/source/bitmap/bitmappaint.cxx12
-rw-r--r--vcl/source/control/fixed.cxx2
-rw-r--r--vcl/source/filter/GraphicNativeTransform.cxx7
-rw-r--r--vcl/source/filter/jpeg/Exif.cxx10
-rw-r--r--vcl/source/font/PhysicalFontFace.cxx2
-rw-r--r--vcl/source/font/fontselect.cxx8
-rw-r--r--vcl/source/gdi/gdimtf.cxx4
-rw-r--r--vcl/source/gdi/gradient.cxx2
-rw-r--r--vcl/source/gdi/pdfwriter_impl.cxx10
-rw-r--r--vcl/source/gdi/sallayout.cxx2
-rw-r--r--vcl/source/gdi/wall.cxx2
-rw-r--r--vcl/source/graphic/GraphicObject.cxx4
-rw-r--r--vcl/source/graphic/GraphicObject2.cxx2
-rw-r--r--vcl/source/outdev/gradient.cxx8
-rw-r--r--vcl/source/outdev/hatch.cxx20
-rw-r--r--vcl/source/outdev/text.cxx12
-rw-r--r--vcl/source/window/cursor.cxx2
-rw-r--r--vcl/source/window/printdlg.cxx2
-rw-r--r--vcl/source/window/toolbox.cxx4
-rw-r--r--vcl/source/window/toolbox2.cxx8
20 files changed, 61 insertions, 62 deletions
diff --git a/vcl/source/bitmap/bitmappaint.cxx b/vcl/source/bitmap/bitmappaint.cxx
index 98c4a37a435a..98d50d5f87bc 100644
--- a/vcl/source/bitmap/bitmappaint.cxx
+++ b/vcl/source/bitmap/bitmappaint.cxx
@@ -212,12 +212,12 @@ bool Bitmap::Rotate(Degree10 nAngle10, const Color& rFillColor)
{
bool bRet = false;
- nAngle10 %= Degree10(3600);
- nAngle10 = (nAngle10 < Degree10(0)) ? (Degree10(3599) + nAngle10) : nAngle10;
+ nAngle10 %= 3600_deg10;
+ nAngle10 = (nAngle10 < 0_deg10) ? (Degree10(3599) + nAngle10) : nAngle10;
if (!nAngle10)
bRet = true;
- else if (nAngle10 == Degree10(1800))
+ else if (nAngle10 == 1800_deg10)
bRet = Mirror(BmpMirrorFlags::Horizontal | BmpMirrorFlags::Vertical);
else
{
@@ -228,7 +228,7 @@ bool Bitmap::Rotate(Degree10 nAngle10, const Color& rFillColor)
{
const Size aSizePix(GetSizePixel());
- if (nAngle10 == Degree10(900) || nAngle10 == Degree10(2700))
+ if (nAngle10 == 900_deg10 || nAngle10 == 2700_deg10)
{
const Size aNewSizePix(aSizePix.Height(), aSizePix.Width());
Bitmap aNewBmp(aNewSizePix, GetBitCount(), &pReadAcc->GetPalette());
@@ -243,7 +243,7 @@ bool Bitmap::Rotate(Degree10 nAngle10, const Color& rFillColor)
const tools::Long nNewWidth = aNewSizePix.Width();
const tools::Long nNewHeight = aNewSizePix.Height();
- if (nAngle10 == Degree10(900))
+ if (nAngle10 == 900_deg10)
{
for (tools::Long nY = 0, nOtherX = nWidth1; nY < nNewHeight;
nY++, nOtherX--)
@@ -256,7 +256,7 @@ bool Bitmap::Rotate(Degree10 nAngle10, const Color& rFillColor)
}
}
}
- else if (nAngle10 == Degree10(2700))
+ else if (nAngle10 == 2700_deg10)
{
for (tools::Long nY = 0, nOtherX = 0; nY < nNewHeight; nY++, nOtherX++)
{
diff --git a/vcl/source/control/fixed.cxx b/vcl/source/control/fixed.cxx
index bb9831dcf425..9b8e6242e296 100644
--- a/vcl/source/control/fixed.cxx
+++ b/vcl/source/control/fixed.cxx
@@ -507,7 +507,7 @@ void FixedLine::ImplDraw(vcl::RenderContext& rRenderContext)
tools::Long nWidth = rRenderContext.GetTextWidth(aText);
rRenderContext.Push(PushFlags::FONT);
vcl::Font aFont(rRenderContext.GetFont());
- aFont.SetOrientation(Degree10(900));
+ aFont.SetOrientation(900_deg10);
SetFont(aFont);
Point aStartPt(aOutSize.Width() / 2, aOutSize.Height() - 1);
if (nWinStyle & WB_VCENTER)
diff --git a/vcl/source/filter/GraphicNativeTransform.cxx b/vcl/source/filter/GraphicNativeTransform.cxx
index d1bb5abb547b..b591217edd91 100644
--- a/vcl/source/filter/GraphicNativeTransform.cxx
+++ b/vcl/source/filter/GraphicNativeTransform.cxx
@@ -38,14 +38,13 @@ GraphicNativeTransform::~GraphicNativeTransform() {}
void GraphicNativeTransform::rotate(Degree10 aInputRotation)
{
// Rotation can be between 0 and 3600
- Degree10 aRotation = aInputRotation % Degree10(3600);
+ Degree10 aRotation = aInputRotation % 3600_deg10;
- if (aRotation == Degree10(0))
+ if (aRotation == 0_deg10)
{
return; // No rotation is needed
}
- else if (aRotation != Degree10(900) && aRotation != Degree10(1800)
- && aRotation != Degree10(2700))
+ else if (aRotation != 900_deg10 && aRotation != 1800_deg10 && aRotation != 2700_deg10)
{
return;
}
diff --git a/vcl/source/filter/jpeg/Exif.cxx b/vcl/source/filter/jpeg/Exif.cxx
index b8760b63aef7..d23c6025185c 100644
--- a/vcl/source/filter/jpeg/Exif.cxx
+++ b/vcl/source/filter/jpeg/Exif.cxx
@@ -53,17 +53,17 @@ Degree10 Exif::getRotation() const
{
switch(maOrientation) {
case exif::TOP_LEFT:
- return Degree10(0);
+ return 0_deg10;
case exif::BOTTOM_RIGHT:
- return Degree10(1800);
+ return 1800_deg10;
case exif::RIGHT_TOP:
- return Degree10(2700);
+ return 2700_deg10;
case exif::LEFT_BOTTOM:
- return Degree10(900);
+ return 900_deg10;
default:
break;
}
- return Degree10(0);
+ return 0_deg10;
}
bool Exif::read(SvStream& rStream)
diff --git a/vcl/source/font/PhysicalFontFace.cxx b/vcl/source/font/PhysicalFontFace.cxx
index 9610c1268057..876d6dfbb924 100644
--- a/vcl/source/font/PhysicalFontFace.cxx
+++ b/vcl/source/font/PhysicalFontFace.cxx
@@ -161,7 +161,7 @@ bool PhysicalFontFace::IsBetterMatch( const FontSelectPattern& rFSD, FontMatchSt
int nHeightMatch = 0;
int nWidthMatch = 0;
- if( rFSD.mnOrientation != Degree10(0) )
+ if( rFSD.mnOrientation != 0_deg10 )
nMatch += 80;
else if( rFSD.mnWidth != 0 )
nMatch += 25;
diff --git a/vcl/source/font/fontselect.cxx b/vcl/source/font/fontselect.cxx
index 09fb90e8b15f..b592c71670a2 100644
--- a/vcl/source/font/fontselect.cxx
+++ b/vcl/source/font/fontselect.cxx
@@ -46,12 +46,12 @@ FontSelectPattern::FontSelectPattern( const vcl::Font& rFont,
rFont.GetFontAttributes( *this );
// normalize orientation between 0 and 3600
- if( mnOrientation < Degree10(0) || mnOrientation >= Degree10(3600) )
+ if( mnOrientation < 0_deg10 || mnOrientation >= 3600_deg10 )
{
- if( mnOrientation >= Degree10(0) )
- mnOrientation %= Degree10(3600);
+ if( mnOrientation >= 0_deg10 )
+ mnOrientation %= 3600_deg10;
else
- mnOrientation = Degree10(3600) - (-mnOrientation % Degree10(3600));
+ mnOrientation = 3600_deg10 - (-mnOrientation % 3600_deg10);
}
// normalize width and height
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index 89390752d185..43cfa3070c1e 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -819,8 +819,8 @@ void GDIMetaFile::ImplAddGradientEx( GDIMetaFile& rMtf,
void GDIMetaFile::Rotate( Degree10 nAngle10 )
{
- nAngle10 %= Degree10(3600);
- nAngle10 = ( nAngle10 < Degree10(0) ) ? ( Degree10(3599) + nAngle10 ) : nAngle10;
+ nAngle10 %= 3600_deg10;
+ nAngle10 = ( nAngle10 < 0_deg10 ) ? ( Degree10(3599) + nAngle10 ) : nAngle10;
if( !nAngle10 )
return;
diff --git a/vcl/source/gdi/gradient.cxx b/vcl/source/gdi/gradient.cxx
index b5c331e6953c..a3014abda46d 100644
--- a/vcl/source/gdi/gradient.cxx
+++ b/vcl/source/gdi/gradient.cxx
@@ -198,7 +198,7 @@ void Gradient::SetSteps( sal_uInt16 nSteps )
void Gradient::GetBoundRect( const tools::Rectangle& rRect, tools::Rectangle& rBoundRect, Point& rCenter ) const
{
tools::Rectangle aRect( rRect );
- Degree10 nAngle = GetAngle() % Degree10(3600);
+ Degree10 nAngle = GetAngle() % 3600_deg10;
if( GetStyle() == GradientStyle::Linear || GetStyle() == GradientStyle::Axial )
{
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( " " );
diff --git a/vcl/source/gdi/sallayout.cxx b/vcl/source/gdi/sallayout.cxx
index eaa03d22e5f0..fc3338929ec5 100644
--- a/vcl/source/gdi/sallayout.cxx
+++ b/vcl/source/gdi/sallayout.cxx
@@ -562,7 +562,7 @@ Point SalLayout::GetDrawPosition( const Point& rRelative ) const
Point aPos = maDrawBase;
Point aOfs = rRelative + maDrawOffset;
- if( mnOrientation == Degree10(0) )
+ if( mnOrientation == 0_deg10 )
aPos += aOfs;
else
{
diff --git a/vcl/source/gdi/wall.cxx b/vcl/source/gdi/wall.cxx
index 6b332e5c74fe..444b5441b202 100644
--- a/vcl/source/gdi/wall.cxx
+++ b/vcl/source/gdi/wall.cxx
@@ -282,7 +282,7 @@ bool Wallpaper::IsGradient() const
Gradient Wallpaper::ImplGetApplicationGradient()
{
Gradient g;
- g.SetAngle( Degree10(900) );
+ g.SetAngle( 900_deg10 );
g.SetStyle( GradientStyle::Linear );
g.SetStartColor( Application::GetSettings().GetStyleSettings().GetFaceColor() );
// no 'extreme' gradient when high contrast
diff --git a/vcl/source/graphic/GraphicObject.cxx b/vcl/source/graphic/GraphicObject.cxx
index aa5435d3ad50..ffb2cc776bc5 100644
--- a/vcl/source/graphic/GraphicObject.cxx
+++ b/vcl/source/graphic/GraphicObject.cxx
@@ -110,7 +110,7 @@ bool lclDrawObj( OutputDevice* pOut, const Point& rPt, const Size& rSz,
if( aGraphic.IsSupportedGraphic() )
{
- const Degree10 nRot10 = rAttr.GetRotation() % Degree10(3600);
+ const Degree10 nRot10 = rAttr.GetRotation() % 3600_deg10;
if( nRot10 )
{
@@ -353,7 +353,7 @@ bool GraphicObject::ImplGetCropParams( OutputDevice const * pOut, Point& rPt, Si
if( GetType() != GraphicType::NONE )
{
tools::Polygon aClipPoly( tools::Rectangle( rPt, rSz ) );
- const Degree10 nRot10 = pAttr->GetRotation() % Degree10(3600);
+ const Degree10 nRot10 = pAttr->GetRotation() % 3600_deg10;
const Point aOldOrigin( rPt );
const MapMode aMap100( MapUnit::Map100thMM );
Size aSize100;
diff --git a/vcl/source/graphic/GraphicObject2.cxx b/vcl/source/graphic/GraphicObject2.cxx
index 4153ff47a6ea..82ce4dd07fcf 100644
--- a/vcl/source/graphic/GraphicObject2.cxx
+++ b/vcl/source/graphic/GraphicObject2.cxx
@@ -484,7 +484,7 @@ void GraphicObject::ImplTransformBitmap( BitmapEx& rBmpEx,
const Size aSizePixel( rBmpEx.GetSizePixel() );
- if( rAttr.GetRotation() == Degree10(0) || IsAnimated() )
+ if( rAttr.GetRotation() == 0_deg10 || IsAnimated() )
return;
if( !(aSizePixel.Width() && aSizePixel.Height() && rDstSize.Width() && rDstSize.Height()) )
diff --git a/vcl/source/outdev/gradient.cxx b/vcl/source/outdev/gradient.cxx
index ea8e8b1ca703..5e562c259d96 100644
--- a/vcl/source/outdev/gradient.cxx
+++ b/vcl/source/outdev/gradient.cxx
@@ -265,7 +265,7 @@ void OutputDevice::DrawLinearGradient( const tools::Rectangle& rRect,
// get BoundRect of rotated rectangle
tools::Rectangle aRect;
Point aCenter;
- Degree10 nAngle = rGradient.GetAngle() % Degree10(3600);
+ Degree10 nAngle = rGradient.GetAngle() % 3600_deg10;
rGradient.GetBoundRect( rRect, aRect, aCenter );
@@ -470,7 +470,7 @@ void OutputDevice::DrawComplexGradient( const tools::Rectangle& rRect,
tools::Long nRedSteps = nEndRed - nStartRed;
tools::Long nGreenSteps = nEndGreen - nStartGreen;
tools::Long nBlueSteps = nEndBlue - nStartBlue;
- Degree10 nAngle = rGradient.GetAngle() % Degree10(3600);
+ Degree10 nAngle = rGradient.GetAngle() % 3600_deg10;
rGradient.GetBoundRect( rRect, aRect, aCenter );
@@ -623,7 +623,7 @@ void OutputDevice::DrawLinearGradientToMetafile( const tools::Rectangle& rRect,
// get BoundRect of rotated rectangle
tools::Rectangle aRect;
Point aCenter;
- Degree10 nAngle = rGradient.GetAngle() % Degree10(3600);
+ Degree10 nAngle = rGradient.GetAngle() % 3600_deg10;
rGradient.GetBoundRect( rRect, aRect, aCenter );
@@ -820,7 +820,7 @@ void OutputDevice::DrawComplexGradientToMetafile( const tools::Rectangle& rRect,
tools::Long nRedSteps = nEndRed - nStartRed;
tools::Long nGreenSteps = nEndGreen - nStartGreen;
tools::Long nBlueSteps = nEndBlue - nStartBlue;
- Degree10 nAngle = rGradient.GetAngle() % Degree10(3600);
+ Degree10 nAngle = rGradient.GetAngle() % 3600_deg10;
rGradient.GetBoundRect( rRect, aRect, aCenter );
diff --git a/vcl/source/outdev/hatch.cxx b/vcl/source/outdev/hatch.cxx
index f2d234677331..775253bbba9a 100644
--- a/vcl/source/outdev/hatch.cxx
+++ b/vcl/source/outdev/hatch.cxx
@@ -187,7 +187,7 @@ void OutputDevice::DrawHatch( const tools::PolyPolygon& rPolyPoly, const Hatch&
if( ( rHatch.GetStyle() == HatchStyle::Double ) || ( rHatch.GetStyle() == HatchStyle::Triple ) )
{
// Double hatch
- CalcHatchValues( aRect, nWidth, rHatch.GetAngle() + Degree10(900), aPt1, aPt2, aInc, aEndPt1 );
+ CalcHatchValues( aRect, nWidth, rHatch.GetAngle() + 900_deg10, aPt1, aPt2, aInc, aEndPt1 );
do
{
DrawHatchLine( tools::Line( aPt1, aPt2 ), rPolyPoly, pPtBuffer.get(), bMtf );
@@ -199,7 +199,7 @@ void OutputDevice::DrawHatch( const tools::PolyPolygon& rPolyPoly, const Hatch&
if( rHatch.GetStyle() == HatchStyle::Triple )
{
// Triple hatch
- CalcHatchValues( aRect, nWidth, rHatch.GetAngle() + Degree10(450), aPt1, aPt2, aInc, aEndPt1 );
+ CalcHatchValues( aRect, nWidth, rHatch.GetAngle() + 450_deg10, aPt1, aPt2, aInc, aEndPt1 );
do
{
DrawHatchLine( tools::Line( aPt1, aPt2 ), rPolyPoly, pPtBuffer.get(), bMtf );
@@ -216,15 +216,15 @@ void OutputDevice::CalcHatchValues( const tools::Rectangle& rRect, tools::Long n
Point& rPt1, Point& rPt2, Size& rInc, Point& rEndPt1 )
{
Point aRef;
- Degree10 nAngle = nAngle10 % Degree10(1800);
+ Degree10 nAngle = nAngle10 % 1800_deg10;
tools::Long nOffset = 0;
- if( nAngle > Degree10(900) )
- nAngle -= Degree10(1800);
+ if( nAngle > 900_deg10 )
+ nAngle -= 1800_deg10;
aRef = ( !IsRefPoint() ? rRect.TopLeft() : GetRefPoint() );
- if( Degree10(0) == nAngle )
+ if( 0_deg10 == nAngle )
{
rInc = Size( 0, nDist );
rPt1 = rRect.TopLeft();
@@ -239,7 +239,7 @@ void OutputDevice::CalcHatchValues( const tools::Rectangle& rRect, tools::Long n
rPt1.AdjustY( -nOffset );
rPt2.AdjustY( -nOffset );
}
- else if( Degree10(900) == nAngle )
+ else if( 900_deg10 == nAngle )
{
rInc = Size( nDist, 0 );
rPt1 = rRect.TopLeft();
@@ -254,7 +254,7 @@ void OutputDevice::CalcHatchValues( const tools::Rectangle& rRect, tools::Long n
rPt1.AdjustX( -nOffset );
rPt2.AdjustX( -nOffset );
}
- else if( nAngle >= Degree10(-450) && nAngle <= Degree10(450) )
+ else if( nAngle >= Degree10(-450) && nAngle <= 450_deg10 )
{
const double fAngle = F_PI1800 * std::abs( nAngle.get() );
const double fTan = tan( fAngle );
@@ -264,7 +264,7 @@ void OutputDevice::CalcHatchValues( const tools::Rectangle& rRect, tools::Long n
nDist = FRound( nDist / cos( fAngle ) );
rInc = Size( 0, nDist );
- if( nAngle > Degree10(0) )
+ if( nAngle > 0_deg10 )
{
rPt1 = rRect.TopLeft();
rPt2 = Point( rRect.Right(), rRect.Top() - nYOff );
@@ -297,7 +297,7 @@ void OutputDevice::CalcHatchValues( const tools::Rectangle& rRect, tools::Long n
nDist = FRound( nDist / sin( fAngle ) );
rInc = Size( nDist, 0 );
- if( nAngle > Degree10(0) )
+ if( nAngle > 0_deg10 )
{
rPt1 = rRect.TopLeft();
rPt2 = Point( rRect.Left() - nXOff, rRect.Bottom() );
diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index 42a753f29e3f..c23f93b5ddfb 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -90,9 +90,9 @@ void OutputDevice::ImplDrawTextRect( tools::Long nBaseX, tools::Long nBaseY,
if ( nOrientation )
{
// Rotate rect without rounding problems for 90 degree rotations
- if ( !(nOrientation % Degree10(900)) )
+ if ( !(nOrientation % 900_deg10) )
{
- if ( nOrientation == Degree10(900) )
+ if ( nOrientation == 900_deg10 )
{
tools::Long nTemp = nX;
nX = nY;
@@ -102,7 +102,7 @@ void OutputDevice::ImplDrawTextRect( tools::Long nBaseX, tools::Long nBaseY,
nHeight = nTemp;
nY -= nHeight;
}
- else if ( nOrientation == Degree10(1800) )
+ else if ( nOrientation == 1800_deg10 )
{
nX = -nX;
nY = -nY;
@@ -173,7 +173,7 @@ tools::Rectangle OutputDevice::ImplGetTextBoundRect( const SalLayout& rSalLayout
if ( mpFontInstance->mnOrientation )
{
tools::Long nBaseX = nX, nBaseY = nY;
- if ( !(mpFontInstance->mnOrientation % Degree10(900)) )
+ if ( !(mpFontInstance->mnOrientation % 900_deg10) )
{
tools::Long nX2 = nX+nWidth;
tools::Long nY2 = nY+nHeight;
@@ -225,7 +225,7 @@ bool OutputDevice::ImplDrawRotateText( SalLayout& rSalLayout )
const FontSelectPattern& rPattern = mpFontInstance->GetFontSelectPattern();
vcl::Font aFont( GetFont() );
- aFont.SetOrientation( Degree10(0) );
+ aFont.SetOrientation( 0_deg10 );
aFont.SetFontSize( Size( rPattern.mnWidth, rPattern.mnHeight ) );
pVDev->SetFont( aFont );
pVDev->SetTextColor( COL_BLACK );
@@ -1230,7 +1230,7 @@ ImplLayoutArgs OutputDevice::ImplPrepareLayoutArgs( OUString& rStr,
// set layout options
ImplLayoutArgs aLayoutArgs(rStr, nMinIndex, nEndIndex, nLayoutFlags, maFont.GetLanguageTag(), pLayoutCache);
- Degree10 nOrientation = mpFontInstance ? mpFontInstance->mnOrientation : Degree10(0);
+ Degree10 nOrientation = mpFontInstance ? mpFontInstance->mnOrientation : 0_deg10;
aLayoutArgs.SetOrientation( nOrientation );
aLayoutArgs.SetLayoutWidth( nPixelWidth );
diff --git a/vcl/source/window/cursor.cxx b/vcl/source/window/cursor.cxx
index 18773be22698..c8e9b5ab14ed 100644
--- a/vcl/source/window/cursor.cxx
+++ b/vcl/source/window/cursor.cxx
@@ -332,7 +332,7 @@ vcl::Cursor::Cursor()
{
mpData = nullptr;
mpWindow = nullptr;
- mnOrientation = Degree10(0);
+ mnOrientation = 0_deg10;
mnDirection = CursorDirection::NONE;
mnStyle = 0;
mbVisible = false;
diff --git a/vcl/source/window/printdlg.cxx b/vcl/source/window/printdlg.cxx
index 6ea1182f2b7e..45ac01862829 100644
--- a/vcl/source/window/printdlg.cxx
+++ b/vcl/source/window/printdlg.cxx
@@ -158,7 +158,7 @@ void PrintDialog::PrintPreviewWindow::Paint(vcl::RenderContext& rRenderContext,
{
rRenderContext.Push(PushFlags::FONT);
vcl::Font aFont(rRenderContext.GetFont());
- aFont.SetOrientation(Degree10(900));
+ aFont.SetOrientation(900_deg10);
rRenderContext.SetFont(aFont);
auto nLeft = aOffset.X() - nTextHeight;
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index 289f9e522954..5f8df0453a20 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -1146,7 +1146,7 @@ void ToolBox::ImplInitToolBoxData()
meTextPosition = ToolBoxTextPosition::Right;
mnLastFocusItemId = 0;
mnActivateCount = 0;
- mnImagesRotationAngle = Degree10(0);
+ mnImagesRotationAngle = 0_deg10;
mpStatusListener = new VclStatusListener<ToolBox>(this, ".uno:ImageOrientation");
mpStatusListener->startListening();
@@ -2700,7 +2700,7 @@ void ToolBox::ImplDrawItem(vcl::RenderContext& rRenderContext, ImplToolItems::si
bRotate = true;
vcl::Font aRotateFont = aOldFont;
- aRotateFont.SetOrientation( Degree10(2700) );
+ aRotateFont.SetOrientation( 2700_deg10 );
// center horizontally
nTextOffX += aTxtSize.Height();
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx
index 360fa312640d..18cd1481d014 100644
--- a/vcl/source/window/toolbox2.cxx
+++ b/vcl/source/window/toolbox2.cxx
@@ -94,7 +94,7 @@ void ImplToolItem::init(sal_uInt16 nItemId, ToolBoxItemBits nItemBits,
mbBreak = false;
mnSepSize = TB_SEP_SIZE;
mnDropDownArrowWidth = TB_DROPDOWNARROWWIDTH;
- mnImageAngle = Degree10(0);
+ mnImageAngle = 0_deg10;
mbMirrorMode = false;
mbVisibleText = false;
mbExpand = false;
@@ -978,9 +978,9 @@ void ToolBox::SetItemImageAngle( sal_uInt16 nItemId, Degree10 nAngle10 )
ImplToolItem* pItem = &mpData->m_aItems[nPos];
Size aOldSize = pItem->maImage.GetSizePixel();
- Degree10 nDeltaAngle = (nAngle10 - pItem->mnImageAngle) % Degree10(3600);
- while( nDeltaAngle < Degree10(0) )
- nDeltaAngle += Degree10(3600);
+ Degree10 nDeltaAngle = (nAngle10 - pItem->mnImageAngle) % 3600_deg10;
+ while( nDeltaAngle < 0_deg10 )
+ nDeltaAngle += 3600_deg10;
pItem->mnImageAngle = nAngle10;
if( nDeltaAngle && !!pItem->maImage )