diff options
Diffstat (limited to 'sw/source')
-rw-r--r-- | sw/source/core/text/porlay.cxx | 7 | ||||
-rw-r--r-- | sw/source/core/text/porlay.hxx | 4 | ||||
-rw-r--r-- | sw/source/core/text/xmldump.cxx | 6 |
3 files changed, 17 insertions, 0 deletions
diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx index 2aeced43f463..1af44ae369e3 100644 --- a/sw/source/core/text/porlay.cxx +++ b/sw/source/core/text/porlay.cxx @@ -2505,6 +2505,13 @@ const SwDropPortion *SwParaPortion::FindDropPortion() const return nullptr; } +void SwParaPortion::dumpAsXml(xmlTextWriterPtr pWriter) const +{ + (void)xmlTextWriterStartElement(pWriter, BAD_CAST("SwParaPortion")); + (void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST("ptr"), "%p", this); + (void)xmlTextWriterEndElement(pWriter); +} + void SwLineLayout::Init( SwLinePortion* pNextPortion ) { Height( 0, false ); diff --git a/sw/source/core/text/porlay.hxx b/sw/source/core/text/porlay.hxx index 5234a537fa4c..3a3d458f2cf8 100644 --- a/sw/source/core/text/porlay.hxx +++ b/sw/source/core/text/porlay.hxx @@ -18,6 +18,8 @@ */ #pragma once +#include <libxml/xmlwriter.h> + #include <scriptinfo.hxx> #include <swrect.hxx> @@ -321,6 +323,8 @@ public: void SetErgoSumNum( const OUString &rErgo ); const SwDropPortion *FindDropPortion() const; + + void dumpAsXml(xmlTextWriterPtr pWriter) const; }; inline void SwParaPortion::ResetPreps() diff --git a/sw/source/core/text/xmldump.cxx b/sw/source/core/text/xmldump.cxx index 03cf10e86b80..d188a0698373 100644 --- a/sw/source/core/text/xmldump.cxx +++ b/sw/source/core/text/xmldump.cxx @@ -28,6 +28,8 @@ #include <view.hxx> #include <svx/svdobj.hxx> +#include "porlay.hxx" + namespace { class XmlPortionDumper:public SwPortionHandler @@ -481,6 +483,10 @@ void SwFrame::dumpAsXml( xmlTextWriterPtr writer ) const reinterpret_cast<const xmlChar *>(aText8.getStr( )) ); XmlPortionDumper pdumper( writer, aText ); pTextFrame->VisitPortions( pdumper ); + if (const SwParaPortion* pPara = pTextFrame->GetPara()) + { + pPara->dumpAsXml(writer); + } } else |