diff --git a/editeng/source/items/paraitem.cxx b/editeng/source/items/paraitem.cxx index 625db860123d..338c9b51e161 100644 --- a/editeng/source/items/paraitem.cxx +++ b/editeng/source/items/paraitem.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include #include #include @@ -692,6 +693,15 @@ void SvxTabStop::fillDecimal() const m_cDecimal = SvtSysLocale().GetLocaleData().getNumDecimalSep()[0]; } +void SvxTabStop::dumpAsXml(xmlTextWriterPtr pWriter) const +{ + xmlTextWriterStartElement(pWriter, BAD_CAST("SvxTabStop")); + xmlTextWriterWriteAttribute(pWriter, BAD_CAST("nTabPos"), + BAD_CAST(OString::number(nTabPos).getStr())); + xmlTextWriterWriteAttribute(pWriter, BAD_CAST("eAdjustment"), + BAD_CAST(OString::number(static_cast(eAdjustment)).getStr())); + xmlTextWriterEndElement(pWriter); +} // class SvxTabStopItem -------------------------------------------------- @@ -958,6 +968,13 @@ void SvxTabStopItem::Insert( const SvxTabStopItem* pTabs ) } } +void SvxTabStopItem::dumpAsXml(xmlTextWriterPtr pWriter) const +{ + xmlTextWriterStartElement(pWriter, BAD_CAST("SvxTabStopItem")); + for (const auto& rTabStop : maTabStops) + rTabStop.dumpAsXml(pWriter); + xmlTextWriterEndElement(pWriter); +} // class SvxFormatSplitItem ------------------------------------------------- SvxFormatSplitItem::~SvxFormatSplitItem() diff --git a/include/editeng/tstpitem.hxx b/include/editeng/tstpitem.hxx index 291e1c72e9fc..35032596883e 100644 --- a/include/editeng/tstpitem.hxx +++ b/include/editeng/tstpitem.hxx @@ -85,6 +85,7 @@ public: cFill = rTS.cFill; return *this; } + void dumpAsXml(struct _xmlTextWriter* pWriter) const; }; // class SvxTabStopItem -------------------------------------------------- @@ -149,6 +150,7 @@ public: virtual SfxPoolItem* Clone( SfxItemPool *pPool = nullptr ) const override; + void dumpAsXml(struct _xmlTextWriter* pWriter) const override; }; #endif