diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-06-23 16:52:37 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-06-23 21:37:42 +0200 |
commit | d4eee72ea39f02ad8a63a592feb3553771bf9bbe (patch) | |
tree | 00e38e5dea152ffda4e8c8c1d39a406d7d9131e1 | |
parent | 4eeb12bb83d5d90eadd14ab5e57950613fcc5fc3 (diff) |
ofz#48264 Timeout
Change-Id: I5028fd192cda7741a51d5d4ff8913214e8c56a18
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/136348
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | svx/source/customshapes/EnhancedCustomShapeFontWork.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx index 9a5aff5bea6a..7b53511f6cfb 100644 --- a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx +++ b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx @@ -273,6 +273,11 @@ static void CalculateHorizontalScalingFactor( nFontSize = std::max<int>(16, std::ceil(5 * nEstimatedFinalFontSize)); SAL_WARN("svx", "CalculateHorizontalScalingFactor skipping direct to: " << nFontSize << " from " << rFontHeight.GetHeight()); } + else if (nEstimatedFinalFontSize < nOnePercentFontSize * 10) + { + nFontSize = std::max<int>(16, std::ceil(2 * nEstimatedFinalFontSize)); + SAL_WARN("svx", "CalculateHorizontalScalingFactor skipping direct to: " << nFontSize << " from " << rFontHeight.GetHeight()); + } } } nFontSize--; |