[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - oox/qa oox/source
oox/qa/unit/data/tdf156902_GlowOnGroup.docx |binary oox/qa/unit/shape.cxx | 12 oox/source/drawingml/shape.cxx |3 ++- 3 files changed, 14 insertions(+), 1 deletion(-) New commits: commit 18beb9a0bb64ba79f65eb67637b0f3750299d705 Author: Regina Henschel AuthorDate: Sat Oct 7 17:37:46 2023 +0200 Commit: Xisco Fauli CommitDate: Mon Oct 9 13:55:57 2023 +0200 tdf#156902 Do not set glow on group shape in import Currently a group is not able to use glow. But in MS Office it is possible. When we try to set glow at the group, we produce an exception and no children are imported. So for now the patch prevents setting glow. Change-Id: Ifa7245ebf3c38f8685239c2b62eefccd35aab870 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157679 Tested-by: Jenkins Reviewed-by: Regina Henschel (cherry picked from commit e84ae94270f0f0037fa2662a5f2765b37a50c33e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/157711 Reviewed-by: Michael Stahl diff --git a/oox/qa/unit/data/tdf156902_GlowOnGroup.docx b/oox/qa/unit/data/tdf156902_GlowOnGroup.docx new file mode 100644 index ..0c176eefa025 Binary files /dev/null and b/oox/qa/unit/data/tdf156902_GlowOnGroup.docx differ diff --git a/oox/qa/unit/shape.cxx b/oox/qa/unit/shape.cxx index 54c19b7aeee5..4db45f7451be 100644 --- a/oox/qa/unit/shape.cxx +++ b/oox/qa/unit/shape.cxx @@ -819,6 +819,18 @@ CPPUNIT_TEST_FIXTURE(OoxShapeTest, testWordArtDefaultColor) CPPUNIT_ASSERT_EQUAL(uno::Any(Color(3, 74, 144)), xShapeProps->getPropertyValue(u"FillColor")); } + +CPPUNIT_TEST_FIXTURE(OoxShapeTest, testGlowOnGroup) +{ +// The document contains a group of two shapes. A glow-effect is set on the group. +// Without the fix, the children of the group were not imported at all. +loadFromURL(u"tdf156902_GlowOnGroup.docx"); +uno::Reference xDrawPagesSupplier(mxComponent, uno::UNO_QUERY); +uno::Reference xDrawPage(xDrawPagesSupplier->getDrawPages()->getByIndex(0), + uno::UNO_QUERY); +uno::Reference xGroup(xDrawPage->getByIndex(0), uno::UNO_QUERY); +CPPUNIT_ASSERT_EQUAL(sal_Int32(2), xGroup->getCount()); +} CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx index bf87841a2c9b..78b50294d356 100644 --- a/oox/source/drawingml/shape.cxx +++ b/oox/source/drawingml/shape.cxx @@ -1914,7 +1914,8 @@ Reference< XShape > const & Shape::createAndInsert( } // Set glow effect properties -if ( aEffectProperties.maGlow.moGlowRad.has_value() ) +if (aEffectProperties.maGlow.moGlowRad.has_value() +&& aServiceName != "com.sun.star.drawing.GroupShape") { uno::Reference propertySet (mxShape, uno::UNO_QUERY); propertySet->setPropertyValue("GlowEffectRadius", Any(convertEmuToHmm(aEffectProperties.maGlow.moGlowRad.value(;
[Libreoffice-commits] core.git: Branch 'libreoffice-7-6' - oox/qa oox/source
oox/qa/unit/data/tdf155827_MCGR_AxialColorLinearTrans.fodp | 644 + oox/qa/unit/mcgr.cxx | 27 oox/source/export/drawingml.cxx| 75 - 3 files changed, 702 insertions(+), 44 deletions(-) New commits: commit 211ba7dd49ef52820cfd11dab33d9767497fa3c4 Author: Regina Henschel AuthorDate: Fri Jun 16 22:12:39 2023 +0200 Commit: Xisco Fauli CommitDate: Tue Jun 20 23:12:26 2023 +0200 tdf#155827 MCGR: Axial to linear in oox export, apply... ... separately for color and transparency gradient. The current solution had the change from axial to linear applied to color and transparency gradient at the same time. That resulted in wrong gradient if only one of them was axial. Because changing axial to linear changes the number of stops, it has to be applied before color and transparency gradients are synchronized. As now color and transparency are both linear already after they are synchronized, the switch can be replaced with a simple if. Change-Id: I75e6b495782bc8a9fe94504426efadec2f60b61f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153197 Tested-by: Jenkins Reviewed-by: Regina Henschel (cherry picked from commit b08ceed6e82e58089e58d15e5ac694b8517349be) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153331 Reviewed-by: Xisco Fauli diff --git a/oox/qa/unit/data/tdf155827_MCGR_AxialColorLinearTrans.fodp b/oox/qa/unit/data/tdf155827_MCGR_AxialColorLinearTrans.fodp new file mode 100644 index ..f55669998068 --- /dev/null +++ b/oox/qa/unit/data/tdf155827_MCGR_AxialColorLinearTrans.fodp @@ -0,0 +1,644 @@ + + +http://openoffice.org/2004/office; xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" xmlns:xlink="http://www.w3.org/1999/xlink; xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" xmlns:dc="http://purl.org/dc/elements/1.1/; xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" xmlns:rpt="http://openoffice.org/2005/report; xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" xmlns:ooow="http://openoffice.org/200 4/writer" xmlns:oooc="http://openoffice.org/2004/calc; xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" xmlns:xforms="http://www.w3.org/2002/xforms; xmlns:tableooo="http://openoffice.org/2009/table; xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0" xmlns:drawooo="http://openoffice.org/2010/draw; xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0" xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" xmlns:math="http://www.w3.org/1998/Math/MathML; xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" xmlns:dom="http://www.w3.org/2001/xml-events; xmlns:xsd="http://www.w3.org/2001/XMLSchema; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance; xmlns:xhtml="http://www.w3.org/1999/xhtml; xmlns:grddl="http://www.w3.org/2003/g/data-view#; xmlns :css3t="http://www.w3.org/TR/css3-text/; xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" xmlns:smil="urn:oasis:names:tc:opendocument:xmlns:smil-compatible:1.0" xmlns:anim="urn:oasis:names:tc:opendocument:xmlns:animation:1.0" xmlns:officeooo="http://openoffice.org/2009/office; office:version="1.3" office:mimetype="application/vnd.oasis.opendocument.presentation"> + 2023-06-16T14:29:43.2850024x16impressPT33M34S4LODev_13_Jun/24.2.0.0.alpha0$Windows_X86_64 LibreOffice_project/d4ee93a54e790acab470667591d61d424831e665Regina Henschel2023-06-16T15:25:09.01600Regina Henschel + + + -235 + -6182 + 36454 + 16497 + + + view1 + false + false + true + true + true + true + false + false + true + 1500 + false + Hw== + Hw== + + false + true + false + 0 + 0 + false + true + true + 4 + 0 + -235 + -6182 + 36455 + 16498 + 2000 + 2000 + 500 + 500 + 2000 + 4 + 2000 + 4 + false + 1500 + true + false + true + false + false + + + + + true + 1250 + EPSON6FC99C (WP-4025 Series) + + + de + DE + + + + + +