summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/svx/unoshprp.hxx4
-rw-r--r--sw/CppunitTest_sw_ooxmlimport2.mk1
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf133473.docxbin0 -> 83030 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport15.cxx17
4 files changed, 20 insertions, 2 deletions
diff --git a/include/svx/unoshprp.hxx b/include/svx/unoshprp.hxx
index cf263ea8cadd..af63b426d500 100644
--- a/include/svx/unoshprp.hxx
+++ b/include/svx/unoshprp.hxx
@@ -216,8 +216,8 @@
{ OUString(UNO_NAME_SHADOWTRANSPARENCE),SDRATTR_SHADOWTRANSPARENCE, ::cppu::UnoType<sal_Int16>::get(), 0, 0}, \
{ OUString(UNO_NAME_SHADOWXDIST), SDRATTR_SHADOWXDIST, ::cppu::UnoType<sal_Int32>::get(), 0, 0, PropertyMoreFlags::METRIC_ITEM}, \
{ OUString(UNO_NAME_SHADOWYDIST), SDRATTR_SHADOWYDIST, ::cppu::UnoType<sal_Int32>::get(), 0, 0, PropertyMoreFlags::METRIC_ITEM}, \
- { OUString(UNO_NAME_SHADOWSIZEX), SDRATTR_SHADOWSIZEX, ::cppu::UnoType<sal_Int32>::get(), 0, 0, PropertyMoreFlags::METRIC_ITEM}, \
- { OUString(UNO_NAME_SHADOWSIZEY), SDRATTR_SHADOWSIZEY, ::cppu::UnoType<sal_Int32>::get(), 0, 0, PropertyMoreFlags::METRIC_ITEM},
+ { OUString(UNO_NAME_SHADOWSIZEX), SDRATTR_SHADOWSIZEX, ::cppu::UnoType<sal_Int32>::get(), 0, 0}, \
+ { OUString(UNO_NAME_SHADOWSIZEY), SDRATTR_SHADOWSIZEY, ::cppu::UnoType<sal_Int32>::get(), 0, 0},
#define LINE_PROPERTIES_DEFAULTS\
{ OUString(UNO_NAME_LINECAP), XATTR_LINECAP, ::cppu::UnoType<css::drawing::LineCap>::get(), 0, 0}, \
diff --git a/sw/CppunitTest_sw_ooxmlimport2.mk b/sw/CppunitTest_sw_ooxmlimport2.mk
index dd0267663455..d5f387af2614 100644
--- a/sw/CppunitTest_sw_ooxmlimport2.mk
+++ b/sw/CppunitTest_sw_ooxmlimport2.mk
@@ -31,6 +31,7 @@ $(eval $(call gb_CppunitTest_use_libraries,sw_ooxmlimport2, \
tl \
vcl \
svxcore \
+ svl\
))
$(eval $(call gb_CppunitTest_use_externals,sw_ooxmlimport2,\
diff --git a/sw/qa/extras/ooxmlexport/data/tdf133473.docx b/sw/qa/extras/ooxmlexport/data/tdf133473.docx
new file mode 100644
index 000000000000..c351db950231
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/tdf133473.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
index 6859ac0d1c6b..6dbef482ef25 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport15.cxx
@@ -8,6 +8,10 @@
*/
#include <swmodeltestbase.hxx>
+#include <svx/svddef.hxx>
+#include <svx/unoapi.hxx>
+#include <svx/sdmetitm.hxx>
+#include <svx/svdobj.hxx>
#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
@@ -181,6 +185,19 @@ DECLARE_OOXMLEXPORT_EXPORTONLY_TEST(testGutterTop, "gutter-top.docx")
assertXPath(pXmlSettings, "/w:settings/w:gutterAtTop", 1);
}
+DECLARE_OOXMLEXPORT_TEST(testTdf133473_shadowSize, "tdf133473.docx")
+{
+ uno::Reference<drawing::XShape> xShape = getShape(1);
+ SdrObject* pObj(GetSdrObjectFromXShape(xShape));
+ const SfxItemSet& rSet = pObj->GetMergedItemSet();
+ sal_Int32 nSize1 = rSet.Get(SDRATTR_SHADOWSIZEX).GetValue();
+ // Without the accompanying fix in place, this test would have failed with:
+ // - Expected: 200000
+ // - Actual : 113386
+ // I.e. Shadow size will be smaller than actual.
+ CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(200000), nSize1);
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */