diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2023-12-30 18:37:58 +0600 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2023-12-30 17:45:12 +0100 |
commit | 46b06663ae767d3423f2135fa91800cfa304877b (patch) | |
tree | 86360d116905d7f5509cd041ea90e2d8cbd8317b /forms/source | |
parent | 427d8f61d7bc4087a9408ba7f0b8a718943f4240 (diff) |
tdf#158254: don't shrink to data area when applying to entire sheet
Commit ac859a4c6a7fce4efee9cdd45821a0c9e40e9e9a (tdf#147842 shrink
selection to data area when applying to entire sheet, 2022-10-18)
tried to workaround the problem of applying to the massive amount
of columns. This caused regressions, where it was impossible to pre-
format entire rows.
This change removes the call to ShrinkToDataArea from
ScViewFunc::ApplySelectionPattern (it is used elsewhere, so the
commit is not reverted completely).
Instead, it addresses the bottleneck in the bugdoc in tdf#147842,
which is ScAttrArray::RemoveCellCharAttribs: since the document
had hidden rows, selecting all made multi-selection split into
separate stripes, and the fulction was called repeatedly, and
itself called ScEditUtil::RemoveCharAttribs for every cell in
~ 1000 columns * 1000000 rows, even though most of the cells in
that range were empty - so no char attribs could exist. Asking
for the last used row (the same as done in ShrinkToDataArea)
makes the operation fast again, and keeps assigning the format
to the entire range.
Change-Id: I9635ea1a392b3a1e048c0888f4786a3628675fc9
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/161442
Tested-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'forms/source')
0 files changed, 0 insertions, 0 deletions