sw/qa/extras/ooxmlimport/data/tdf95775.docx |binary sw/qa/extras/ooxmlimport/ooxmlimport.cxx | 5 +++++ sw/source/core/doc/textboxhelper.cxx | 6 ++++++ sw/source/core/layout/atrfrm.cxx | 2 +- 4 files changed, 12 insertions(+), 1 deletion(-)
New commits: commit ca80f73c3a330c38493e5e358bfa887adbe21db2 Author: Mike Kaganski <mike.kagan...@collabora.com> Date: Sat Nov 14 14:04:20 2015 +1000 tdf#95775: Allow zero shape width/height; fix setting width/height relation Conflicts: sw/qa/extras/ooxmlimport/ooxmlimport.cxx Reviewed on: https://gerrit.libreoffice.org/19962 Change-Id: Ic91ebf4a18a77704dc1ccd1e1180b42d0bc84c74 diff --git a/sw/qa/extras/ooxmlimport/data/tdf95775.docx b/sw/qa/extras/ooxmlimport/data/tdf95775.docx new file mode 100644 index 0000000..a4c1293 Binary files /dev/null and b/sw/qa/extras/ooxmlimport/data/tdf95775.docx differ diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index 5138377..19dfa31 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -2920,6 +2920,11 @@ DECLARE_OOXMLIMPORT_TEST(testTdf85232, "tdf85232.docx") CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(2267), xShape->getPosition().X); } +DECLARE_OOXMLIMPORT_TEST(testTdf95775, "tdf95775.docx") +{ + // This must not fail in layout +} + CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/doc/textboxhelper.cxx b/sw/source/core/doc/textboxhelper.cxx index d640c96..4c89861 100644 --- a/sw/source/core/doc/textboxhelper.cxx +++ b/sw/source/core/doc/textboxhelper.cxx @@ -486,6 +486,12 @@ void SwTextBoxHelper::syncProperty(SwFrameFormat* pShape, sal_uInt16 nWID, sal_u case MID_FRMSIZE_IS_AUTO_HEIGHT: aPropertyName = UNO_NAME_FRAME_ISAUTOMATIC_HEIGHT; break; + case MID_FRMSIZE_REL_HEIGHT_RELATION: + aPropertyName = UNO_NAME_RELATIVE_HEIGHT_RELATION; + break; + case MID_FRMSIZE_REL_WIDTH_RELATION: + aPropertyName = UNO_NAME_RELATIVE_WIDTH_RELATION; + break; default: aPropertyName = UNO_NAME_SIZE; bAdjustSize = true; diff --git a/sw/source/core/layout/atrfrm.cxx b/sw/source/core/layout/atrfrm.cxx index 129eca5..c8d4ca6 100644 --- a/sw/source/core/layout/atrfrm.cxx +++ b/sw/source/core/layout/atrfrm.cxx @@ -282,7 +282,7 @@ bool SwFormatFrmSize::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) aTmp.Height() = convertMm100ToTwip(aTmp.Height()); aTmp.Width() = convertMm100ToTwip(aTmp.Width()); } - if(aTmp.Height() && aTmp.Width()) + if(aTmp.Height() || aTmp.Width()) m_aSize = aTmp; else bRet = false; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits