summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolan.mcnamara@collabora.com>2024-11-29 14:16:19 +0000
committerCaolán McNamara <caolan.mcnamara@collabora.com>2024-11-29 16:39:01 +0100
commit8aea35ec4f19419b714879eb09fc6658fd3eeb1f (patch)
tree0c08f4a3c6e0f9f740e93202ba3bb0c7103cea23 /sc/source
parentc585b697b583fa0f8cdadeab594c31d270367ba7 (diff)
crashtesting: failure to export forum-mso-en4-491312.xlsx to ods
probably since: commit 65129e0bc5abfe7afc612eb46f1434e627265a7d CommitDate: Tue Feb 2 22:06:18 2021 +0100 tdf#137081, tdf137082 fixes shape handling in RTL sheets Change-Id: Ife720a0ccbff0029ace822d246dc227e01846734 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177537 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/filter/xml/xmlexprt.cxx13
1 files changed, 12 insertions, 1 deletions
diff --git a/sc/source/filter/xml/xmlexprt.cxx b/sc/source/filter/xml/xmlexprt.cxx
index 8bb83786c7a2..e13a3880a637 100644
--- a/sc/source/filter/xml/xmlexprt.cxx
+++ b/sc/source/filter/xml/xmlexprt.cxx
@@ -3692,7 +3692,18 @@ void ScXMLExport::WriteTableShapes()
// GetSnapRect() from associated SdrObject.
uno::Reference<beans::XPropertySet> xShapeProp(rxShape, uno::UNO_QUERY);
awt::Rectangle aFrameRect;
- if (xShapeProp.is() && (xShapeProp->getPropertyValue(u"FrameRect"_ustr) >>= aFrameRect))
+ if (!xShapeProp.is())
+ {
+ SAL_WARN("sc", "no shape propertyset");
+ continue;
+ }
+ uno::Reference<beans::XPropertySetInfo> xPropSetInfo = xShapeProp->getPropertySetInfo();
+ if (!xPropSetInfo->hasPropertyByName(u"FrameRect"_ustr))
+ {
+ SAL_WARN("sc", "shape doesn't support FrameRect property");
+ continue;
+ }
+ if (xShapeProp->getPropertyValue(u"FrameRect"_ustr) >>= aFrameRect)
{
// file format uses shape in LTR mode. newLeft = - oldRight = - (oldLeft + width).
// newTranslate = oldTranslate - refPoint, oldTranslate from transformation matrix,