diff options
author | Balazs Varga <balazs.varga.extern@allotropia.de> | 2023-04-11 20:38:15 +0200 |
---|---|---|
committer | Balazs Varga <balazs.varga.extern@allotropia.de> | 2023-04-12 12:37:32 +0200 |
commit | 9cb9c54748ec586695780778b3f4d94cf74392ad (patch) | |
tree | b6b7b6915dad6ee267acdf6767937bb7d09834bf /sc/source/filter | |
parent | bac8f52748e43a9aa5b19b4010efbadf975c4748 (diff) |
Revert "Improve 'resize with cell' handling"
This reverts commit f43ac75e8e3d8520aef8a5baeda4543bdae44b10.
Except adding GetObjectsAnchoredToCols to drwlayer.hxx
and using ScTable::SetRowHidden and ScTable::SetColHidden
modifications from the original commit.
Change-Id: I1fcc724ed49ca0d2faedaae02009ec006106672f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150267
Tested-by: Balazs Varga <balazs.varga.extern@allotropia.de>
Reviewed-by: Balazs Varga <balazs.varga.extern@allotropia.de>
Diffstat (limited to 'sc/source/filter')
-rw-r--r-- | sc/source/filter/xml/xmlexprt.cxx | 4 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlimprt.cxx | 32 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlimprt.hxx | 3 |
3 files changed, 2 insertions, 37 deletions
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx index bdda79626f5c..5a93a64cda43 100644 --- a/sc/source/filter/xml/xmlexprt.cxx +++ b/sc/source/filter/xml/xmlexprt.cxx @@ -3474,10 +3474,8 @@ void ScXMLExport::WriteShapes(const ScMyCell& rMyCell) if( rMyCell.bHasShape && !rMyCell.aShapeList.empty() && pDoc ) { awt::Point aPoint; - // Hiding row or col does not change the shape geometry. tools::Rectangle aRect = pDoc->GetMMRect(rMyCell.maCellAddress.Col(), rMyCell.maCellAddress.Row(), - rMyCell.maCellAddress.Col(), rMyCell.maCellAddress.Row(), rMyCell.maCellAddress.Tab(), - false /*bHiddenAsZero*/); + rMyCell.maCellAddress.Col(), rMyCell.maCellAddress.Row(), rMyCell.maCellAddress.Tab()); bool bNegativePage = pDoc->IsNegativePage(rMyCell.maCellAddress.Tab()); if (bNegativePage) aPoint.X = aRect.Right(); diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx index 061172f4d82f..f97b06884261 100644 --- a/sc/source/filter/xml/xmlimprt.cxx +++ b/sc/source/filter/xml/xmlimprt.cxx @@ -38,7 +38,6 @@ #include <xmloff/xmltoken.hxx> #include <xmloff/xmlerror.hxx> #include <xmloff/ProgressBarHelper.hxx> -#include <svx/svdpage.hxx> #include <svl/languageoptions.hxx> #include <editeng/editstat.hxx> @@ -54,7 +53,6 @@ #include "xmlbodyi.hxx" #include "xmlstyli.hxx" #include <ViewSettingsSequenceDefines.hxx> -#include <userdat.hxx> #include <compiler.hxx> @@ -1789,36 +1787,6 @@ void SAL_CALL ScXMLImport::endDocument() } } - // Initialize and set position and size of objects - if (pDoc && pDoc->GetDrawLayer()) - { - ScDrawLayer* pDrawLayer = pDoc->GetDrawLayer(); - SCTAB nTabCount = pDoc->GetTableCount(); - for (SCTAB nTab = 0; nTab < nTabCount; ++nTab) - { - const SdrPage* pPage = pDrawLayer->GetPage(nTab); - if (!pPage) - continue; - bool bNegativePage = pDoc->IsNegativePage(nTab); - const size_t nCount = pPage->GetObjCount(); - for (size_t i = 0; i < nCount; ++i) - { - SdrObject* pObj = pPage->GetObj(i); - ScDrawObjData* pData - = ScDrawLayer::GetObjDataTab(pObj, nTab); - // Existance of pData means, that it is a cell anchored object - if (pData) - { - // Finish and correct import based on full size (no hidden row/col) and LTR - pDrawLayer->InitializeCellAnchoredObj(pObj, *pData); - // Adapt object to hidden row/col and RTL - pDrawLayer->RecalcPos(pObj, *pData, bNegativePage, - true /*bUpdateNoteCaptionPos*/); - } - } - } - } - aTables.FixupOLEs(); } if (GetModel().is()) diff --git a/sc/source/filter/xml/xmlimprt.hxx b/sc/source/filter/xml/xmlimprt.hxx index e8e369355e4a..5dc661cae26b 100644 --- a/sc/source/filter/xml/xmlimprt.hxx +++ b/sc/source/filter/xml/xmlimprt.hxx @@ -49,13 +49,12 @@ class XMLNumberFormatAttributesExportHelper; class ScEditEngineDefaulter; class ScDocumentImport; class ScMyImpDetectiveOpArray; -class SdrPage; namespace sc { struct ImportPostProcessData; struct PivotTableSources; -class ScDrawObjData; + } enum ScXMLDocTokens |