diff options
author | Andrzej Hunt <andrzej.hunt@collabora.com> | 2014-08-11 21:21:32 +0200 |
---|---|---|
committer | Andrzej Hunt <andrzej.hunt@collabora.com> | 2014-08-11 21:21:32 +0200 |
commit | 3413e93dae1a915596c9621a49c73ba9c005a9b6 (patch) | |
tree | aebe16f06c809476679872d4378bc50eaaceb244 | |
parent | 4fbdd7b3f789b9cb74f1f23ab11a198d9848d023 (diff) |
Return logic units for GetMergeSizePixel too.
This is used for some cell drawing etc.
This commit by itself isn't so useful as the clients also need
to be updated to work with logic units rather than pixels. We should
probably also rename the method at some point.
Change-Id: I7e563d21885261b0dabe55e6e535b066b68a07a3
-rw-r--r-- | sc/source/ui/view/viewdata.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sc/source/ui/view/viewdata.cxx b/sc/source/ui/view/viewdata.cxx index a89b31ce4f9a..cbf19e976062 100644 --- a/sc/source/ui/view/viewdata.cxx +++ b/sc/source/ui/view/viewdata.cxx @@ -1716,7 +1716,7 @@ bool ScViewData::GetMergeSizePixel( SCCOL nX, SCROW nY, long& rSizeXPix, long& r long nOutHeight = 0; SCCOL nCountX = pMerge->GetColMerge(); for (SCCOL i=0; i<nCountX; i++) - nOutWidth += ToPixel( pDoc->GetColWidth(nX+i,nTabNo), nPPTX ); + nOutWidth += pDoc->GetColWidth(nX+i,nTabNo); SCROW nCountY = pMerge->GetRowMerge(); for (SCROW nRow = nY; nRow <= nY+nCountY-1; ++nRow) @@ -1730,6 +1730,7 @@ bool ScViewData::GetMergeSizePixel( SCCOL nX, SCROW nY, long& rSizeXPix, long& r sal_uInt16 nHeight = pDoc->GetRowHeight(nRow, nTabNo); nOutHeight += ToPixel(nHeight, nPPTY); + nOutHeight += nHeight; } rSizeXPix = nOutWidth; @@ -1738,8 +1739,8 @@ bool ScViewData::GetMergeSizePixel( SCCOL nX, SCROW nY, long& rSizeXPix, long& r } else { - rSizeXPix = ToPixel( pDoc->GetColWidth( nX, nTabNo ), nPPTX ); - rSizeYPix = ToPixel( pDoc->GetRowHeight( nY, nTabNo ), nPPTY ); + rSizeXPix = pDoc->GetColWidth( nX, nTabNo ); + rSizeYPix = pDoc->GetRowHeight( nY, nTabNo ); return false; } } |