drawinglayer/source/processor2d/helperwrongspellrenderer.cxx | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-)
New commits: commit 029194643d0ba7d76df28bc21eec4a27492eea99 Author: Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk> AuthorDate: Sun May 3 11:34:51 2020 +0200 Commit: Tomaž Vajngerl <qui...@gmail.com> CommitDate: Mon May 4 08:43:35 2020 +0200 drawinglayer: extract constant in renderWrongSpellPrimitive2D Change-Id: I131e2d5620d027f32dc2929cd12fedb168e30e9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93390 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <qui...@gmail.com> diff --git a/drawinglayer/source/processor2d/helperwrongspellrenderer.cxx b/drawinglayer/source/processor2d/helperwrongspellrenderer.cxx index 27df21201efe..9f838a7e1b61 100644 --- a/drawinglayer/source/processor2d/helperwrongspellrenderer.cxx +++ b/drawinglayer/source/processor2d/helperwrongspellrenderer.cxx @@ -28,6 +28,11 @@ using namespace css; namespace drawinglayer { +namespace +{ +constexpr sal_uInt32 constMinimumFontHeight = 5; // #define WRONG_SHOW_MIN 5 +} + bool renderWrongSpellPrimitive2D(const primitive2d::WrongSpellPrimitive2D& rWrongSpellCandidate, OutputDevice& rOutputDevice, const basegfx::B2DHomMatrix& rObjectToViewTransformation, @@ -38,9 +43,7 @@ bool renderWrongSpellPrimitive2D(const primitive2d::WrongSpellPrimitive2D& rWron const basegfx::B2DVector aFontVectorPixel(aLocalTransform * basegfx::B2DVector(0.0, 1.0)); const sal_uInt32 nFontPixelHeight(basegfx::fround(aFontVectorPixel.getLength())); - static const sal_uInt32 nMinimumFontHeight(5); // #define WRONG_SHOW_MIN 5 - - if (nFontPixelHeight <= nMinimumFontHeight) + if (nFontPixelHeight <= constMinimumFontHeight) return true; const basegfx::B2DPoint aStart(aLocalTransform _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits