diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-11 14:34:46 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-09-11 20:29:04 +0200 |
commit | aaa3c31ba79b1b3d335dcf55d72837a13411b45e (patch) | |
tree | ccc18b3eb1be45cfdeb9c3d5b8fb56455a06f7cf | |
parent | 6d79c2f56d3548d8ea767dfe69626759e6cf6f34 (diff) |
tdf#119305 Chart created from fully selected sheet only targets header row
regression from
commit 3acc5a2383f5b0458e3caf1505fe6b8ad7dc3fb0
tdf#69977 improve creation of large charts
Change-Id: I09d02447b0e4691e98a44222608a3dc5edc95b0b
Reviewed-on: https://gerrit.libreoffice.org/60318
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | sc/source/core/data/table1.cxx | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sc/source/core/data/table1.cxx b/sc/source/core/data/table1.cxx index 4c5be3efcda9..8457035c784a 100644 --- a/sc/source/core/data/table1.cxx +++ b/sc/source/core/data/table1.cxx @@ -1123,8 +1123,10 @@ void ScTable::LimitChartArea( SCCOL& rStartCol, SCROW& rStartRow, SCCOL& rEndCol // Optimised loop for finding the bottom of the area, can be costly in large // spreadsheets. + SCROW lastDataPos = 0; for (SCCOL i=rStartCol; i<=rEndCol; i++) - rEndRow = std::min(rEndRow, aCol[i].GetLastDataPos()); + lastDataPos = std::max(lastDataPos, aCol[i].GetLastDataPos()); + rEndRow = std::min(rEndRow, lastDataPos); } SCCOL ScTable::FindNextVisibleCol( SCCOL nCol, bool bRight ) const |