diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2019-09-20 11:55:21 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2019-09-20 12:42:17 +0200 |
commit | f8c7a2284b88c149addc8a30abb0cad8a10dad77 (patch) | |
tree | 546b535ce46c8a9f3f10fd165eee82c2d402000a /writerfilter | |
parent | ea4f3099d6e0cf30d80caa8b2121c7a358f80fdd (diff) |
Related: tdf#124600 sw anchored object allow overlap: add DOCX filter
Which also made it necessary to support allow-overlap=no for not only
shapes, but for shapes-with-text in the layout.
Change-Id: Ibd229d21995c0a1053db6bbab0a6ccbbf75f36d3
Reviewed-on: https://gerrit.libreoffice.org/79277
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'writerfilter')
-rw-r--r-- | writerfilter/source/dmapper/GraphicImport.cxx | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/writerfilter/source/dmapper/GraphicImport.cxx b/writerfilter/source/dmapper/GraphicImport.cxx index c148d7989e0d..269a4e290ecb 100644 --- a/writerfilter/source/dmapper/GraphicImport.cxx +++ b/writerfilter/source/dmapper/GraphicImport.cxx @@ -197,6 +197,7 @@ public: sal_Int16 nVertRelation; text::WrapTextMode nWrap; bool bLayoutInCell; + bool bAllowOverlap = true; bool bOpaque; bool bContour; bool bContourOutside; @@ -596,9 +597,9 @@ void GraphicImport::lcl_attribute(Id nName, Value& rValue) break; case NS_ooxml::LN_CT_Anchor_hidden: // 90992; - ignored break; - case NS_ooxml::LN_CT_Anchor_allowOverlap: // 90993; - //enable overlapping - ignored - break; + case NS_ooxml::LN_CT_Anchor_allowOverlap: + m_pImpl->bAllowOverlap = nIntValue != 0; + break; case NS_ooxml::LN_CT_Anchor_wp14_anchorId: case NS_ooxml::LN_CT_Inline_wp14_anchorId: { @@ -866,6 +867,8 @@ void GraphicImport::lcl_attribute(Id nName, Value& rValue) xShapeProps->setPropertyValue("Surround", uno::makeAny(static_cast<sal_Int32>(m_pImpl->nWrap))); m_pImpl->applyZOrder(xShapeProps); m_pImpl->applyName(xShapeProps); + xShapeProps->setPropertyValue("AllowOverlap", + uno::makeAny(m_pImpl->bAllowOverlap)); // Get the grab-bag set by oox, merge with our one and then put it back. comphelper::SequenceAsHashMap aInteropGrabBag(xShapeProps->getPropertyValue("InteropGrabBag")); |