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/window | |
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/window')
-rw-r--r-- | vcl/source/window/cursor.cxx | 2 | ||||
-rw-r--r-- | vcl/source/window/printdlg.cxx | 2 | ||||
-rw-r--r-- | vcl/source/window/toolbox.cxx | 4 | ||||
-rw-r--r-- | vcl/source/window/toolbox2.cxx | 8 |
4 files changed, 8 insertions, 8 deletions
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 ) |