summaryrefslogtreecommitdiff
path: root/sw/source/core/txtnode/fntcache.cxx
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2023-10-12 10:48:38 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2023-10-12 14:16:46 +0200
commita0b003257aa87d34a4403531798d0074e19a18ac (patch)
tree499acf3d492eacd139a9cd1d3f030e8cd4b8ff0d /sw/source/core/txtnode/fntcache.cxx
parent3d97d220c912c2e45e97489e55c8d2a2b0b3516d (diff)
Fix Windows x64 build
...after 6f45c0cf86b21772740bb0cafb3d462b058523f3 "cool#7318 Calc rendering acceleration" caused > sw/source/core/txtnode/fntcache.cxx(540): error C2672: 'std::min': no matching overloaded function found > C:\PROGRA~1\MICROS~3\2022\Preview\VC\Tools\MSVC\1438~1.331\Include\utility(108): note: could be '_Ty std::min(std::initializer_list<_Elem>)' > sw/source/core/txtnode/fntcache.cxx(540): note: '_Ty std::min(std::initializer_list<_Elem>)': expects 1 arguments - 2 provided > C:\PROGRA~1\MICROS~3\2022\Preview\VC\Tools\MSVC\1438~1.331\Include\utility(105): note: or '_Ty std::min(std::initializer_list<_Elem>,_Pr)' > sw/source/core/txtnode/fntcache.cxx(540): note: '_Ty std::min(std::initializer_list<_Elem>,_Pr)': could not deduce template argument for 'std::initializer_list<_Elem>' from 'sal_Int32' > C:\PROGRA~1\MICROS~3\2022\Preview\VC\Tools\MSVC\1438~1.331\Include\utility(98): note: or 'const _Ty &std::min(const _Ty &,const _Ty &) noexcept(<expr>)' > sw/source/core/txtnode/fntcache.cxx(540): note: 'const _Ty &std::min(const _Ty &,const _Ty &) noexcept(<expr>)': template parameter '_Ty' is ambiguous > sw/source/core/txtnode/fntcache.cxx(540): note: could be 'tools::Long' > sw/source/core/txtnode/fntcache.cxx(540): note: or 'sal_Int32' > sw/source/core/txtnode/fntcache.cxx(540): note: 'const _Ty &std::min(const _Ty &,const _Ty &) noexcept(<expr>)': could not deduce template argument for 'const _Ty &' from 'tools::Long' > C:\PROGRA~1\MICROS~3\2022\Preview\VC\Tools\MSVC\1438~1.331\Include\utility(88): note: or 'const _Ty &std::min(const _Ty &,const _Ty &,_Pr) noexcept(<expr>)' > sw/source/core/txtnode/fntcache.cxx(540): note: 'const _Ty &std::min(const _Ty &,const _Ty &,_Pr) noexcept(<expr>)': expects 3 arguments - 2 provided Change-Id: I9af33041a81190998303aec2795fe03da7e2f119 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157858 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'sw/source/core/txtnode/fntcache.cxx')
-rw-r--r--sw/source/core/txtnode/fntcache.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index bc5dd603a433..4e9f2a1c1dc7 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -516,7 +516,7 @@ void SwFntObj::GuessLeading( const SwViewShell&
{
// If the Leading on the Window is also 0, then it has to stay
// that way (see also StarMath).
- tools::Long nTmpLeading = aWinMet.GetInternalLeading();
+ sal_Int32 nTmpLeading = aWinMet.GetInternalLeading();
if( nTmpLeading <= 0 )
{
pWin->SetFont( rMet );
@@ -537,7 +537,7 @@ void SwFntObj::GuessLeading( const SwViewShell&
// Those who lie about their Leading, may lie about their
// Ascent/Descent as well, hence the Font will be lowered a
// little without changing its height.
- tools::Long nDiff = std::min( rMet.GetDescent() - aWinMet.GetDescent(),
+ sal_Int32 nDiff = std::min( rMet.GetDescent() - aWinMet.GetDescent(),
aWinMet.GetAscent() - rMet.GetAscent() - nTmpLeading );
if( nDiff > 0 )
{