make tools::Long 64-bit on Windows platform

This is only for the 64-bit windows platform.
I don't see the point in messing with the 32-bit platforms, they are
(a) become more and more rare
(b) unlikely to even have enough available process memory to load extremely large calc spreadsheets

The primary problem we are addressing here is bringing
Windows-64bit up to same capability as Linux-64bit when it
comes to handling very large spreadsheets,
which is caused by things like tools::Rectangle using "long",
which means that all the work done to make Libreoffice on 64-bit
Linux capable of loading large spreadsheets is useless on Windows,
where long is 32-bit.

The operator<< for tools::Rectangle needs to be inside
the tools namespace because of an interaction with the cppunit
printing template stuff that I don't understand.

SalPoint changed to use sal_Int32, since it needs to be
the same definition as the Windows POINT structure.

Change-Id: Iab6f1af88847b6c8d46995e8ceda3f82b6722ff7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104913
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Noel Grandin
2020-11-11 06:34:17 +01:00
committed by Noel Grandin
parent 3de38e9556
commit 3d90997fb6
134 changed files with 450 additions and 423 deletions
@@ -995,7 +995,7 @@ namespace cppcanvas::internal
{
::tools::Long nInterval = ( nWidth - nStrikeoutWidth * nLen ) / nLen;
nStrikeoutWidth += nInterval;
::tools::Long* pStrikeoutCharWidths = new long[nLen];
::tools::Long* pStrikeoutCharWidths = new ::tools::Long[nLen];
for ( int i = 0;i<nLen; i++)
{
@@ -1589,8 +1589,8 @@ namespace cppcanvas::internal
// least one dimension
// Remark the 1L cannot be replaced, that would cause max to compare long/int
const Size aMtfSizePix( std::max( aMtfSizePixPre.Width(), 1L ),
std::max( aMtfSizePixPre.Height(), 1L ) );
const Size aMtfSizePix( std::max( aMtfSizePixPre.Width(), ::tools::Long(1) ),
std::max( aMtfSizePixPre.Height(), ::tools::Long(1) ) );
// Setup local transform, such that the
// metafile renders itself into the given
@@ -2885,8 +2885,8 @@ namespace cppcanvas::internal
// #i44110# correct null-sized output - there are shapes
// which have zero size in at least one dimension
// Remark the 1L cannot be replaced, that would cause max to compare long/int
const Size aMtfSizePix( std::max( aMtfSizePixPre.Width(), 1L ),
std::max( aMtfSizePixPre.Height(), 1L ) );
const Size aMtfSizePix( std::max( aMtfSizePixPre.Width(), ::tools::Long(1) ),
std::max( aMtfSizePixPre.Height(), ::tools::Long(1) ) );
sal_Int32 nCurrActions(0);
ActionFactoryParameters aParms(aStateStack,