diff options
-rwxr-xr-x | sw/qa/extras/ooxmlimport/data/tdf113182.docx | bin | 0 -> 12561 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlimport/ooxmlimport.cxx | 8 | ||||
-rw-r--r-- | writerfilter/source/dmapper/DomainMapper.cxx | 7 |
3 files changed, 14 insertions, 1 deletions
diff --git a/sw/qa/extras/ooxmlimport/data/tdf113182.docx b/sw/qa/extras/ooxmlimport/data/tdf113182.docx Binary files differnew file mode 100755 index 000000000000..9f35ec3d4ebc --- /dev/null +++ b/sw/qa/extras/ooxmlimport/data/tdf113182.docx diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index 6e181a87a9b9..5563ce56dc1f 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -1558,6 +1558,14 @@ DECLARE_OOXMLIMPORT_TEST(testTdf112443, "tdf112443.docx") } +// DOCX: Textbox wrap differs in MSO and LO +// Both should layout text regardless of existing text box +// and as result only one page should be generated. +DECLARE_OOXMLIMPORT_TEST(testTdf113182, "tdf113182.docx") +{ + CPPUNIT_ASSERT_EQUAL(getPages(), 1); +} + DECLARE_OOXMLIMPORT_TEST(testTdf113946, "tdf113946.docx") { OUString aTop = parseDump("/root/page/body/txt/anchored/SwAnchoredDrawObject/bounds", "top"); diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 310bf761f3b7..6219b7c672e1 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -868,11 +868,16 @@ void DomainMapper::lcl_attribute(Id nName, Value & val) //should be either LN_Value_doc_ST_Wrap_notBeside or LN_Value_doc_ST_Wrap_around or LN_Value_doc_ST_Wrap_auto OSL_ENSURE( sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_around || sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_notBeside || + sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_through || + sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_none || sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_auto, - "wrap not around, not_Beside or auto?"); + "wrap not around, not_Beside, through, none or auto?"); if( sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_around || + sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_through || sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_auto ) pParaProperties->SetWrap ( text::WrapTextMode_DYNAMIC ) ; + else if (sal::static_int_cast<Id>(nIntValue) == NS_ooxml::LN_Value_doc_ST_Wrap_none) + pParaProperties->SetWrap ( text::WrapTextMode_THROUGH ) ; else pParaProperties->SetWrap ( text::WrapTextMode_NONE ) ; } |