From 5ee52d401e2086f79f794a4ec1a1d7beec8aa582 Mon Sep 17 00:00:00 2001 From: Tünde Tóth Date: Tue, 18 Apr 2023 12:01:18 +0200 Subject: tdf#119565 XLSX export: fix lost line properties inherited from theme MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Line properties (LineWidth and LineJoint) of shape inherited from theme lost after export. Perhaps regression from commit 5391d4872e71d1edba7acc4ad2d2e3b5b97e1723 "ooxml: Preserve shape style and theme attributes for line". Change-Id: I9977bb20f16245f3c95ccbe2c5c8033b5b0c9cc4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/150547 Tested-by: László Németh Reviewed-by: László Németh --- oox/source/export/drawingml.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'oox/source/export') diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx index aaad66b4d083..60a5cdd62d7e 100644 --- a/oox/source/export/drawingml.cxx +++ b/oox/source/export/drawingml.cxx @@ -1263,7 +1263,8 @@ void DrawingML::WriteOutline( const Reference& rXPropSet, Referenc mpFS->startElementNS( XML_a, XML_ln, XML_cap, cap, XML_w, sax_fastparser::UseIf(OString::number(nEmuLineWidth), - nLineWidth == 0 || (nLineWidth > 1 && nStyleLineWidth != nLineWidth)) ); + nLineWidth == 0 || GetDocumentType() == DOCUMENT_XLSX // tdf#119565 LO doesn't export the actual theme.xml in XLSX. + || (nLineWidth > 1 && nStyleLineWidth != nLineWidth))); if( bColorSet ) { @@ -1431,7 +1432,9 @@ void DrawingML::WriteOutline( const Reference& rXPropSet, Referenc { LineJoint eLineJoint = mAny.get(); - if( aStyleLineJoint == LineJoint_NONE || aStyleLineJoint != eLineJoint ) + // tdf#119565 LO doesn't export the actual theme.xml in XLSX. + if (aStyleLineJoint == LineJoint_NONE || GetDocumentType() == DOCUMENT_XLSX + || aStyleLineJoint != eLineJoint) { // style-defined line joint does not exist, or is different from the shape's joint switch( eLineJoint ) -- cgit