sw/source/core/docnode/nodedump.cxx | 11 +++++++++++ 1 file changed, 11 insertions(+)
New commits: commit 08280034197b577abf994cc05322c010fd1f9895 Author: Miklos Vajna <vmik...@collabora.co.uk> Date: Fri Oct 17 12:38:35 2014 +0200 SwTxtNode::dumpAsXml: handle RES_TXTATR_CHARFMT Change-Id: I29d8eb9ab6d6428f699a92b6cd9d58ed8b3b7e48 diff --git a/sw/source/core/docnode/nodedump.cxx b/sw/source/core/docnode/nodedump.cxx index 4dcfb40..b195aa9 100644 --- a/sw/source/core/docnode/nodedump.cxx +++ b/sw/source/core/docnode/nodedump.cxx @@ -35,6 +35,7 @@ #include "fmtclds.hxx" #include "fmtpdsc.hxx" #include "pagedesc.hxx" +#include "fchrfmt.hxx" #include <swmodule.hxx> #include <svl/itemiter.hxx> #include <svl/intitem.hxx> @@ -766,6 +767,7 @@ void SwTxtNode::dumpAsXml( xmlTextWriterPtr w ) const writer.writeFormatAttribute("whichId", TMP_FORMAT, pHint->Which()); const char* pWhich = 0; + boost::optional<OString> oValue; switch (pHint->Which()) { case RES_TXTATR_AUTOFMT: @@ -777,11 +779,20 @@ void SwTxtNode::dumpAsXml( xmlTextWriterPtr w ) const case RES_TXTATR_FLYCNT: pWhich = "fly content"; break; + case RES_TXTATR_CHARFMT: + { + pWhich = "character format"; + if (SwCharFmt* pCharFmt = pHint->GetCharFmt().GetCharFmt()) + oValue = "name: " + OUStringToOString(pCharFmt->GetName(), RTL_TEXTENCODING_UTF8); + break; + } default: break; } if (pWhich) writer.writeFormatAttribute("which", "%s", BAD_CAST(pWhich)); + if (oValue) + writer.writeFormatAttribute("value", "%s", BAD_CAST(oValue->getStr())); if (pHint->Which() == RES_TXTATR_AUTOFMT) { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits