summaryrefslogtreecommitdiff
path: root/writerfilter/source
diff options
context:
space:
mode:
authorDaniel Rentz [dr] <daniel.rentz@oracle.com>2011-02-28 10:08:33 +0100
committerDaniel Rentz [dr] <daniel.rentz@oracle.com>2011-02-28 10:08:33 +0100
commita1a84343919c08e0d698d40e2bcf5c411ca47f3f (patch)
tree96f4e5c924b79e27e28b5841b8e2adf4e4a32660 /writerfilter/source
parent4f06bfae891d1b7b80e0e17be9623536f31ae9ac (diff)
parent818573bfbce420afedffd45d7bb080f25da32625 (diff)
dr78: rebase to DEV300_m101
Diffstat (limited to 'writerfilter/source')
-rw-r--r--writerfilter/source/dmapper/BorderHandler.cxx33
-rw-r--r--writerfilter/source/dmapper/BorderHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/CellColorHandler.cxx14
-rw-r--r--writerfilter/source/dmapper/CellColorHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/CellMarginHandler.cxx24
-rw-r--r--writerfilter/source/dmapper/CellMarginHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/DomainMapper.cxx141
-rw-r--r--writerfilter/source/dmapper/DomainMapperTableHandler.cxx67
-rw-r--r--writerfilter/source/dmapper/DomainMapper_Impl.cxx8
-rw-r--r--writerfilter/source/dmapper/FFDataHandler.cxx44
-rw-r--r--writerfilter/source/dmapper/FFDataHandler.hxx14
-rw-r--r--writerfilter/source/dmapper/FontTable.cxx43
-rw-r--r--writerfilter/source/dmapper/FontTable.hxx57
-rw-r--r--writerfilter/source/dmapper/GraphicHelpers.cxx26
-rw-r--r--writerfilter/source/dmapper/GraphicHelpers.hxx16
-rw-r--r--writerfilter/source/dmapper/GraphicImport.cxx214
-rw-r--r--writerfilter/source/dmapper/GraphicImport.hxx58
-rw-r--r--writerfilter/source/dmapper/MeasureHandler.cxx12
-rw-r--r--writerfilter/source/dmapper/MeasureHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/NumberingManager.cxx46
-rw-r--r--writerfilter/source/dmapper/NumberingManager.hxx46
-rw-r--r--writerfilter/source/dmapper/OLEHandler.cxx13
-rw-r--r--writerfilter/source/dmapper/OLEHandler.hxx13
-rw-r--r--writerfilter/source/dmapper/PageBordersHandler.cxx11
-rw-r--r--writerfilter/source/dmapper/PageBordersHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/PropertyIds.hxx508
-rw-r--r--writerfilter/source/dmapper/PropertyMap.cxx46
-rw-r--r--writerfilter/source/dmapper/PropertyMap.hxx5
-rw-r--r--writerfilter/source/dmapper/PropertyMapHelper.cxx2
-rw-r--r--writerfilter/source/dmapper/PropertyMapHelper.hxx2
-rw-r--r--writerfilter/source/dmapper/SectionColumnHandler.cxx15
-rw-r--r--writerfilter/source/dmapper/SectionColumnHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/SettingsTable.cxx44
-rw-r--r--[-rwxr-xr-x]writerfilter/source/dmapper/SettingsTable.hxx19
-rw-r--r--writerfilter/source/dmapper/StyleSheetTable.cxx144
-rw-r--r--writerfilter/source/dmapper/StyleSheetTable.hxx39
-rw-r--r--writerfilter/source/dmapper/TDefTableHandler.cxx17
-rw-r--r--writerfilter/source/dmapper/TDefTableHandler.hxx13
-rw-r--r--writerfilter/source/dmapper/TblStylePrHandler.cxx15
-rw-r--r--writerfilter/source/dmapper/TblStylePrHandler.hxx12
-rw-r--r--writerfilter/source/dmapper/ThemeTable.cxx16
-rw-r--r--writerfilter/source/dmapper/ThemeTable.hxx15
-rw-r--r--writerfilter/source/dmapper/WrapPolygonHandler.cxx216
-rw-r--r--writerfilter/source/dmapper/WrapPolygonHandler.hxx91
-rw-r--r--writerfilter/source/dmapper/dmapperLoggers.hxx3
-rw-r--r--writerfilter/source/dmapper/makefile.mk8
-rw-r--r--writerfilter/source/filter/ImportFilter.cxx4
-rw-r--r--writerfilter/source/filter/WriterFilterDetection.cxx2
-rw-r--r--writerfilter/source/ooxml/OOXMLFactory.cxx65
-rw-r--r--[-rwxr-xr-x]writerfilter/source/ooxml/OOXMLFactory.hxx3
-rw-r--r--writerfilter/source/ooxml/OOXMLFastContextHandler.cxx379
-rw-r--r--writerfilter/source/ooxml/OOXMLFastContextHandler.hxx7
-rw-r--r--writerfilter/source/ooxml/OOXMLFastHelper.hxx77
-rw-r--r--writerfilter/source/ooxml/OOXMLParserState.cxx5
-rw-r--r--writerfilter/source/ooxml/OOXMLParserState.hxx5
-rw-r--r--writerfilter/source/ooxml/OOXMLPropertySetImpl.cxx11
-rw-r--r--writerfilter/source/ooxml/analyzemodel.xsl1
-rw-r--r--writerfilter/source/ooxml/effort.xsl59
-rw-r--r--writerfilter/source/ooxml/factory_ns.xsl11
-rw-r--r--writerfilter/source/ooxml/factoryimpl.xsl24
-rw-r--r--writerfilter/source/ooxml/factoryimpl_ns.xsl230
-rw-r--r--writerfilter/source/ooxml/model.xml671
-rw-r--r--writerfilter/source/resourcemodel/Fraction.cxx150
-rw-r--r--writerfilter/source/resourcemodel/LoggedResources.cxx322
-rw-r--r--writerfilter/source/resourcemodel/TagLogger.cxx514
-rw-r--r--writerfilter/source/resourcemodel/XPathLogger.cxx90
-rw-r--r--writerfilter/source/resourcemodel/makefile.mk13
67 files changed, 2876 insertions, 1969 deletions
diff --git a/writerfilter/source/dmapper/BorderHandler.cxx b/writerfilter/source/dmapper/BorderHandler.cxx
index 9fa737f47de2..67f8e65bafb6 100644
--- a/writerfilter/source/dmapper/BorderHandler.cxx
+++ b/writerfilter/source/dmapper/BorderHandler.cxx
@@ -44,12 +44,13 @@ using namespace ::com::sun::star;
-----------------------------------------------------------------------*/
BorderHandler::BorderHandler( bool bOOXML ) :
- m_nCurrentBorderPosition( BORDER_TOP ),
- m_nLineWidth(0),
- m_nLineType(0),
- m_nLineColor(0),
- m_nLineDistance(0),
- m_bOOXML( bOOXML )
+LoggedProperties(dmapper_logger, "BorderHandler"),
+m_nCurrentBorderPosition( BORDER_TOP ),
+m_nLineWidth(0),
+m_nLineType(0),
+m_nLineColor(0),
+m_nLineDistance(0),
+m_bOOXML( bOOXML )
{
const int nBorderCount(BORDER_COUNT);
std::fill_n(m_aFilledLines, nBorderCount, false);
@@ -64,14 +65,8 @@ BorderHandler::~BorderHandler()
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void BorderHandler::attribute(Id rName, Value & rVal)
+void BorderHandler::lcl_attribute(Id rName, Value & rVal)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("BorderHandler.attribute");
- dmapper_logger->attribute("id", (*QNameToString::Instance())(rName));
- dmapper_logger->endElement("BorderHandler.attribute");
-#endif
-
sal_Int32 nIntValue = rVal.getInt();
/* WRITERFILTERSTATUS: table: BorderHandler_attributedata */
switch( rName )
@@ -123,13 +118,8 @@ void BorderHandler::attribute(Id rName, Value & rVal)
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void BorderHandler::sprm(Sprm & rSprm)
+void BorderHandler::lcl_sprm(Sprm & rSprm)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("BorderHandler.sprm");
- dmapper_logger->attribute("sprm", rSprm.toString());
-#endif
-
/* WRITERFILTERSTATUS: table: BorderHandler_sprm */
switch( rSprm.getId())
{
@@ -157,11 +147,6 @@ void BorderHandler::sprm(Sprm & rSprm)
break;
default:;
}
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("BorderHandler.sprm");
-#endif
-
}
/*-- 24.04.2007 09:09:01---------------------------------------------------
diff --git a/writerfilter/source/dmapper/BorderHandler.hxx b/writerfilter/source/dmapper/BorderHandler.hxx
index 0fc722227191..fe6e3549feba 100644
--- a/writerfilter/source/dmapper/BorderHandler.hxx
+++ b/writerfilter/source/dmapper/BorderHandler.hxx
@@ -28,7 +28,7 @@
#define INCLUDED_BORDERHANDLER_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
#include <com/sun/star/table/BorderLine.hpp>
@@ -36,7 +36,7 @@ namespace writerfilter {
namespace dmapper
{
class PropertyMap;
-class WRITERFILTER_DLLPRIVATE BorderHandler : public Properties
+class WRITERFILTER_DLLPRIVATE BorderHandler : public LoggedProperties
{
public:
//todo: order is a guess
@@ -63,14 +63,14 @@ private:
bool m_aFilledLines[BORDER_COUNT];
::com::sun::star::table::BorderLine m_aBorderLines[BORDER_COUNT];
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
BorderHandler( bool bOOXML );
virtual ~BorderHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
::boost::shared_ptr<PropertyMap> getProperties();
::com::sun::star::table::BorderLine getBorderLine();
sal_Int32 getLineDistance() const { return m_nLineDistance;}
diff --git a/writerfilter/source/dmapper/CellColorHandler.cxx b/writerfilter/source/dmapper/CellColorHandler.cxx
index 2de4554e06dc..f72d4dd0d66b 100644
--- a/writerfilter/source/dmapper/CellColorHandler.cxx
+++ b/writerfilter/source/dmapper/CellColorHandler.cxx
@@ -29,6 +29,7 @@
#include <doctok/resourceids.hxx>
#include <ConversionHelper.hxx>
#include <ooxml/resourceids.hxx>
+#include "dmapperLoggers.hxx"
#define OOXML_COLOR_AUTO 0x0a //todo: AutoColor needs symbol
@@ -43,10 +44,11 @@ using namespace ::writerfilter;
-----------------------------------------------------------------------*/
CellColorHandler::CellColorHandler() :
- m_nShadowType( 0 ),
- m_nColor( 0xffffffff ),
- m_nFillColor( 0xffffffff ),
- m_bParagraph( false )
+LoggedProperties(dmapper_logger, "CellColorHandler"),
+m_nShadowType( 0 ),
+m_nColor( 0xffffffff ),
+m_nFillColor( 0xffffffff ),
+m_bParagraph( false )
{
}
/*-- 24.04.2007 09:06:35---------------------------------------------------
@@ -58,7 +60,7 @@ CellColorHandler::~CellColorHandler()
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void CellColorHandler::attribute(Id rName, Value & rVal)
+void CellColorHandler::lcl_attribute(Id rName, Value & rVal)
{
sal_Int32 nIntValue = rVal.getInt();
(void)nIntValue;
@@ -119,7 +121,7 @@ void CellColorHandler::attribute(Id rName, Value & rVal)
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void CellColorHandler::sprm(Sprm & rSprm)
+void CellColorHandler::lcl_sprm(Sprm & rSprm)
{
(void)rSprm;
}
diff --git a/writerfilter/source/dmapper/CellColorHandler.hxx b/writerfilter/source/dmapper/CellColorHandler.hxx
index 3e6b1bb2db70..102449258550 100644
--- a/writerfilter/source/dmapper/CellColorHandler.hxx
+++ b/writerfilter/source/dmapper/CellColorHandler.hxx
@@ -28,7 +28,7 @@
#define INCLUDED_CELLCOLORHANDLER_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
//#include <com/sun/star/table/TableBorder.hpp>
#include <com/sun/star/table/BorderLine.hpp>
@@ -37,23 +37,23 @@ namespace writerfilter {
namespace dmapper
{
class TablePropertyMap;
-class WRITERFILTER_DLLPRIVATE CellColorHandler : public Properties
+class WRITERFILTER_DLLPRIVATE CellColorHandler : public LoggedProperties
{
public:
sal_Int32 m_nShadowType;
sal_Int32 m_nColor;
sal_Int32 m_nFillColor;
bool m_bParagraph;
+
private:
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
public:
CellColorHandler( );
virtual ~CellColorHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
::boost::shared_ptr<TablePropertyMap> getProperties();
void setParagraph() { m_bParagraph = true; }
diff --git a/writerfilter/source/dmapper/CellMarginHandler.cxx b/writerfilter/source/dmapper/CellMarginHandler.cxx
index bfea8a6b25f9..645755cc4c63 100644
--- a/writerfilter/source/dmapper/CellMarginHandler.cxx
+++ b/writerfilter/source/dmapper/CellMarginHandler.cxx
@@ -29,6 +29,7 @@
#include <doctok/resourceids.hxx>
#include <ConversionHelper.hxx>
#include <ooxml/resourceids.hxx>
+#include "dmapperLoggers.hxx"
namespace writerfilter {
namespace dmapper {
@@ -41,15 +42,16 @@ using namespace ::writerfilter;
-----------------------------------------------------------------------*/
CellMarginHandler::CellMarginHandler() :
- m_nValue( 0 ),
- m_nLeftMargin( 0 ),
- m_bLeftMarginValid( false ),
- m_nRightMargin( 0 ),
- m_bRightMarginValid( false ),
- m_nTopMargin( 0 ),
- m_bTopMarginValid( false ),
- m_nBottomMargin( 0 ),
- m_bBottomMarginValid( false )
+LoggedProperties(dmapper_logger, "CellMarginHandler"),
+m_nValue( 0 ),
+m_nLeftMargin( 0 ),
+m_bLeftMarginValid( false ),
+m_nRightMargin( 0 ),
+m_bRightMarginValid( false ),
+m_nTopMargin( 0 ),
+m_bTopMarginValid( false ),
+m_nBottomMargin( 0 ),
+m_bBottomMarginValid( false )
{
}
/*-- 18.02.2008 12:36:51---------------------------------------------------
@@ -61,7 +63,7 @@ CellMarginHandler::~CellMarginHandler()
/*-- 18.02.2008 12:36:51---------------------------------------------------
-----------------------------------------------------------------------*/
-void CellMarginHandler::attribute(Id rName, Value & rVal)
+void CellMarginHandler::lcl_attribute(Id rName, Value & rVal)
{
sal_Int32 nIntValue = rVal.getInt();
(void)nIntValue;
@@ -82,7 +84,7 @@ void CellMarginHandler::attribute(Id rName, Value & rVal)
/*-- 18.02.2008 12:36:51---------------------------------------------------
-----------------------------------------------------------------------*/
-void CellMarginHandler::sprm(Sprm & rSprm)
+void CellMarginHandler::lcl_sprm(Sprm & rSprm)
{
writerfilter::Reference<Properties>::Pointer_t pProperties = rSprm.getProps();
if( pProperties.get())
diff --git a/writerfilter/source/dmapper/CellMarginHandler.hxx b/writerfilter/source/dmapper/CellMarginHandler.hxx
index 5f01df47a347..3d2512675683 100644
--- a/writerfilter/source/dmapper/CellMarginHandler.hxx
+++ b/writerfilter/source/dmapper/CellMarginHandler.hxx
@@ -30,18 +30,22 @@
#ifndef INCLUDED_WRITERFILTERDLLAPI_H
#include <WriterFilterDllApi.hxx>
#endif
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
namespace writerfilter {
namespace dmapper
{
class TablePropertyMap;
-class WRITERFILTER_DLLPRIVATE CellMarginHandler : public Properties
+class WRITERFILTER_DLLPRIVATE CellMarginHandler : public LoggedProperties
{
private:
sal_Int32 m_nValue;
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
sal_Int32 m_nLeftMargin;
bool m_bLeftMarginValid;
@@ -56,10 +60,6 @@ public:
CellMarginHandler( );
virtual ~CellMarginHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
::boost::shared_ptr<TablePropertyMap> getProperties();
};
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx
index 65dfb4c5fcec..fb36455fcd97 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -86,15 +86,11 @@
#include <vector>
#include <iostream>
-#ifdef DEBUG_DOMAINMAPPER
-#include <resourcemodel/QNameToString.hxx>
-#include <resourcemodel/util.hxx>
-#include <resourcemodel/TagLogger.hxx>
-#endif
#if OSL_DEBUG_LEVEL > 0
#include <resourcemodel/QNameToString.hxx>
#endif
+#include <resourcemodel/TagLogger.hxx>
using namespace ::com::sun::star;
using namespace ::rtl;
@@ -106,9 +102,7 @@ using resourcemodel::resolveAttributeProperties;
namespace dmapper{
-#ifdef DEBUG_DOMAINMAPPER
TagLogger::Pointer_t dmapper_logger(TagLogger::getInstance("DOMAINMAPPER"));
-#endif
/* ---- Fridrich's mess begins here ---- */
struct _PageSz
@@ -129,6 +123,9 @@ DomainMapper::DomainMapper( const uno::Reference< uno::XComponentContext >& xCon
uno::Reference< io::XInputStream > xInputStream,
uno::Reference< lang::XComponent > xModel,
SourceDocumentType eDocumentType) :
+LoggedProperties(dmapper_logger, "DomainMapper"),
+LoggedTable(dmapper_logger, "DomainMapper"),
+LoggedStream(dmapper_logger, "DomainMapper"),
m_pImpl( new DomainMapper_Impl( *this, xContext, xModel, eDocumentType )),
mnBackgroundColor(0), mbIsHighlightSet(false)
{
@@ -193,14 +190,8 @@ DomainMapper::~DomainMapper()
/*-- 09.06.2006 09:52:12---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::attribute(Id nName, Value & val)
+void DomainMapper::lcl_attribute(Id nName, Value & val)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("attribute");
- dmapper_logger->attribute("name", (*QNameToString::Instance())(nName));
- dmapper_logger->attribute("value", val.toString());
- dmapper_logger->endElement("attribute");
-#endif
static ::rtl::OUString sLocalBookmarkName;
sal_Int32 nIntValue = val.getInt();
rtl::OUString sStringValue = val.getString();
@@ -2195,20 +2186,16 @@ void DomainMapper::attribute(Id nName, Value & val)
/*-- 09.06.2006 09:52:12---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::sprm(Sprm & rSprm)
+void DomainMapper::lcl_sprm(Sprm & rSprm)
{
if( !m_pImpl->getTableManager().sprm(rSprm))
- DomainMapper::sprm( rSprm, m_pImpl->GetTopContext() );
+ sprmWithProps( rSprm, m_pImpl->GetTopContext() );
}
/*-- 20.06.2006 09:58:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::sprm( Sprm& rSprm, PropertyMapPtr rContext, SprmType eSprmType )
+void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType eSprmType )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("DomainMapper.sprm");
- dmapper_logger->chars(rSprm.toString());
-#endif
OSL_ENSURE(rContext.get(), "PropertyMap has to be valid!");
if(!rContext.get())
return ;
@@ -2885,12 +2872,6 @@ void DomainMapper::sprm( Sprm& rSprm, PropertyMapPtr rContext, SprmType eSprmTyp
{
uno::Any aBold( uno::makeAny( nIntValue ? awt::FontWeight::BOLD : awt::FontWeight::NORMAL ) );
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("charWeight");
- dmapper_logger->attribute("weight", nIntValue ? awt::FontWeight::BOLD : awt::FontWeight::NORMAL);
- dmapper_logger->endElement("charWeight");
-#endif
-
rContext->Insert(ePropertyId, true, aBold );
if( nSprmId != NS_sprm::LN_CFBoldBi ) // sprmCFBoldBi
rContext->Insert(PROP_CHAR_WEIGHT_ASIAN, true, aBold );
@@ -4246,27 +4227,14 @@ void DomainMapper::sprm( Sprm& rSprm, PropertyMapPtr rContext, SprmType eSprmTyp
#endif
}
}
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->addTag(rContext->toTag());
- dmapper_logger->endElement("DomainMapper.sprm");
-#endif
}
/*-- 09.06.2006 09:52:13---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::entry(int /*pos*/,
+void DomainMapper::lcl_entry(int /*pos*/,
writerfilter::Reference<Properties>::Pointer_t ref)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("DomainMapper.entry");
-#endif
-
ref->resolve(*this);
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("DomainMapper.entry");
-#endif
}
/*-- 09.06.2006 09:52:13---------------------------------------------------
@@ -4278,17 +4246,14 @@ void DomainMapper::data(const sal_uInt8* /*buf*/, size_t /*len*/,
/*-- 09.06.2006 09:52:13---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::startSectionGroup()
+void DomainMapper::lcl_startSectionGroup()
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("section");
-#endif
m_pImpl->PushProperties(CONTEXT_SECTION);
}
/*-- 09.06.2006 09:52:13---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::endSectionGroup()
+void DomainMapper::lcl_endSectionGroup()
{
PropertyMapPtr pContext = m_pImpl->GetTopContextOfType(CONTEXT_SECTION);
SectionPropertyMap* pSectionContext = dynamic_cast< SectionPropertyMap* >( pContext.get() );
@@ -4296,20 +4261,12 @@ void DomainMapper::endSectionGroup()
if(pSectionContext)
pSectionContext->CloseSectionGroup( *m_pImpl );
m_pImpl->PopProperties(CONTEXT_SECTION);
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("section");
-#endif
}
/*-- 09.06.2006 09:52:13---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::startParagraphGroup()
+void DomainMapper::lcl_startParagraphGroup()
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("paragraph");
-#endif
-
m_pImpl->getTableManager().startParagraphGroup();
m_pImpl->PushProperties(CONTEXT_PARAGRAPH);
static ::rtl::OUString sDefault( ::rtl::OUString::createFromAscii("Standard") );
@@ -4326,40 +4283,27 @@ void DomainMapper::startParagraphGroup()
/*-- 09.06.2006 09:52:14---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::endParagraphGroup()
+void DomainMapper::lcl_endParagraphGroup()
{
m_pImpl->PopProperties(CONTEXT_PARAGRAPH);
m_pImpl->getTableManager().endParagraphGroup();
//frame conversion has to be executed after table conversion
m_pImpl->ExecuteFrameConversion();
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("paragraph");
-#endif
}
void DomainMapper::markLastParagraphInSection( )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->element( "markLastParagraphInSection" );
-#endif
m_pImpl->SetIsLastParagraphInSection( true );
}
-void DomainMapper::startShape( uno::Reference< drawing::XShape > xShape )
+void DomainMapper::lcl_startShape( uno::Reference< drawing::XShape > xShape )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("shape");
-#endif
m_pImpl->PushShapeContext( xShape );
}
-void DomainMapper::endShape( )
+void DomainMapper::lcl_endShape( )
{
m_pImpl->PopShapeContext( );
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("shape");
-#endif
}
/*-- 13.06.2007 16:15:55---------------------------------------------------
@@ -4401,12 +4345,8 @@ void DomainMapper::PopListProperties()
-----------------------------------------------------------------------*/
-void DomainMapper::startCharacterGroup()
+void DomainMapper::lcl_startCharacterGroup()
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("charactergroup");
-#endif
-
m_pImpl->PushProperties(CONTEXT_CHARACTER);
DomainMapperTableManager& rTableManager = m_pImpl->getTableManager();
if( rTableManager.getTableStyleName().getLength() )
@@ -4418,18 +4358,14 @@ void DomainMapper::startCharacterGroup()
/*-- 09.06.2006 09:52:14---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::endCharacterGroup()
+void DomainMapper::lcl_endCharacterGroup()
{
m_pImpl->PopProperties(CONTEXT_CHARACTER);
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("charactergroup");
-#endif
}
/*-- 09.06.2006 09:52:14---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::text(const sal_uInt8 * data_, size_t len)
+void DomainMapper::lcl_text(const sal_uInt8 * data_, size_t len)
{
//TODO: Determine the right text encoding (FIB?)
::rtl::OUString sText( (const sal_Char*) data_, len, RTL_TEXTENCODING_MS_1252 );
@@ -4515,19 +4451,13 @@ void DomainMapper::text(const sal_uInt8 * data_, size_t len)
/*-- 09.06.2006 09:52:15---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::utext(const sal_uInt8 * data_, size_t len)
+void DomainMapper::lcl_utext(const sal_uInt8 * data_, size_t len)
{
OUString sText;
OUStringBuffer aBuffer = OUStringBuffer(len);
aBuffer.append( (const sal_Unicode *) data_, len);
sText = aBuffer.makeStringAndClear();
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("utext");
- dmapper_logger->chars(sText);
- dmapper_logger->endElement("utext");
-#endif
-
try
{
m_pImpl->getTableManager().utext(data_, len);
@@ -4585,12 +4515,8 @@ void DomainMapper::utext(const sal_uInt8 * data_, size_t len)
/*-- 09.06.2006 09:52:15---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::props(writerfilter::Reference<Properties>::Pointer_t ref)
+void DomainMapper::lcl_props(writerfilter::Reference<Properties>::Pointer_t ref)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("props");
-#endif
-
string sType = ref->getType();
if( sType == "PICF" )
{
@@ -4602,21 +4528,12 @@ void DomainMapper::props(writerfilter::Reference<Properties>::Pointer_t ref)
}
else
ref->resolve(*this);
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("props");
-#endif
}
/*-- 09.06.2006 09:52:15---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::table(Id name, writerfilter::Reference<Table>::Pointer_t ref)
+void DomainMapper::lcl_table(Id name, writerfilter::Reference<Table>::Pointer_t ref)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("table");
- dmapper_logger->attribute("id", (*QNameToString::Instance())(name));
-#endif
-
// printf ( "DomainMapper::table(0x%.4x)\n", (unsigned int)name);
m_pImpl->SetAnyTableImport(true);
/* WRITERFILTERSTATUS: table: attributedata */
@@ -4666,20 +4583,12 @@ void DomainMapper::table(Id name, writerfilter::Reference<Table>::Pointer_t ref)
OSL_ENSURE( false, "which table is to be filled here?");
}
m_pImpl->SetAnyTableImport(false);
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("table");
-#endif
}
/*-- 09.06.2006 09:52:16---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::substream(Id rName, ::writerfilter::Reference<Stream>::Pointer_t ref)
+void DomainMapper::lcl_substream(Id rName, ::writerfilter::Reference<Stream>::Pointer_t ref)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("substream");
-#endif
-
m_pImpl->appendTableManager( );
m_pImpl->getTableManager().startLevel();
@@ -4751,15 +4660,11 @@ void DomainMapper::substream(Id rName, ::writerfilter::Reference<Stream>::Pointe
m_pImpl->getTableManager().endLevel();
m_pImpl->popTableManager( );
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("substream");
-#endif
}
/*-- 09.06.2006 09:52:16---------------------------------------------------
-----------------------------------------------------------------------*/
-void DomainMapper::info(const string & /*info_*/)
+void DomainMapper::lcl_info(const string & /*info_*/)
{
}
diff --git a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
index 958a96fbff7d..c6869aca5f2b 100644
--- a/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
+++ b/writerfilter/source/dmapper/DomainMapperTableHandler.cxx
@@ -32,7 +32,7 @@
#include <com/sun/star/text/HoriOrientation.hpp>
#include <dmapperLoggers.hxx>
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
#include <PropertyMapHelper.hxx>
#endif
@@ -45,7 +45,7 @@ using namespace ::std;
#define DEF_BORDER_DIST 190 //0,19cm
#define DEFAULT_CELL_MARGIN 108 //default cell margin, not documented
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
static void lcl_printProperties( PropertyMapPtr pProps )
{
if( pProps.get() )
@@ -104,7 +104,7 @@ void DomainMapperTableHandler::startTable(unsigned int nRows,
m_pTableSeq = TableSequencePointer_t(new TableSequence_t(nRows));
m_nRowIndex = 0;
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("tablehandler.table");
dmapper_logger->attribute("rows", nRows);
@@ -118,11 +118,6 @@ void DomainMapperTableHandler::startTable(unsigned int nRows,
-----------------------------------------------------------------------*/
PropertyMapPtr lcl_SearchParentStyleSheetAndMergeProperties(const StyleSheetEntryPtr pStyleSheet, StyleSheetTablePtr pStyleSheetTable)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("lcl_SearchParentStyleSheetAndMergeProperties");
- dmapper_logger->addTag(pStyleSheet->toTag());
-#endif
-
PropertyMapPtr pRet;
if( pStyleSheet->sBaseStyleIdentifier.getLength())
{
@@ -136,10 +131,6 @@ PropertyMapPtr lcl_SearchParentStyleSheetAndMergeProperties(const StyleSheetEntr
pRet->insert( pStyleSheet->pProperties, true );
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("lcl_SearchParentStyleSheetAndMergeProperties");
-#endif
-
return pRet;
}
@@ -241,7 +232,7 @@ void lcl_computeCellBorders( PropertyMapPtr pTableBorders, PropertyMapPtr pCellP
}
}
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
void lcl_debug_BorderLine(table::BorderLine & rLine)
{
@@ -334,7 +325,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
PropertyMapPtr pMergedProperties = lcl_SearchParentStyleSheetAndMergeProperties(pStyleSheet, pStyleSheetTable);
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("mergedProps");
dmapper_logger->addTag(pMergedProperties->toTag());
dmapper_logger->endElement("mergedProps");
@@ -343,7 +334,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
m_aTableProperties->insert( pMergedProperties );
m_aTableProperties->insert( pTableProps );
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("TableProperties");
dmapper_logger->addTag(m_aTableProperties->toTag());
dmapper_logger->endElement("TableProperties");
@@ -354,7 +345,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
// Set the table default attributes for the cells
rInfo.pTableDefaults->insert( m_aTableProperties );
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("TableDefaults");
dmapper_logger->addTag(rInfo.pTableDefaults->toTag());
dmapper_logger->endElement("TableDefaults");
@@ -472,7 +463,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
m_aTableProperties->Insert( PROP_TABLE_BORDER, false, uno::makeAny( aTableBorder ) );
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
lcl_debug_TableBorder(aTableBorder);
#endif
@@ -501,7 +492,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
rInfo.aTableProperties = m_aTableProperties->GetPropertyValues();
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("debug.tableprops");
dmapper_logger->addTag(m_aTableProperties->toTag());
dmapper_logger->endElement("debug.tableprops");
@@ -514,7 +505,7 @@ TableStyleSheetEntry * DomainMapperTableHandler::endTableGetTableStyle(TableInfo
CellPropertyValuesSeq_t DomainMapperTableHandler::endTableGetCellProperties(TableInfo & rInfo)
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("getCellProperties");
#endif
@@ -593,7 +584,7 @@ CellPropertyValuesSeq_t DomainMapperTableHandler::endTableGetCellProperties(Tabl
pAllCellProps->insert( *aCellIterator );
aCellIterator->get( )->swap( *pAllCellProps.get( ) );
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("cell");
dmapper_logger->attribute("cell", nCell);
dmapper_logger->attribute("row", nRow);
@@ -626,14 +617,14 @@ CellPropertyValuesSeq_t DomainMapperTableHandler::endTableGetCellProperties(Tabl
uno::makeAny((sal_Int32) rInfo.nBottomBorderDistance ) );
pSingleCellProperties[nCell] = aCellIterator->get()->GetPropertyValues();
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("cell");
#endif
}
++nCell;
++aCellIterator;
}
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
//-->debug cell properties
{
::rtl::OUString sNames;
@@ -660,7 +651,7 @@ CellPropertyValuesSeq_t DomainMapperTableHandler::endTableGetCellProperties(Tabl
++aRowOfCellsIterator;
}
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("getCellProperties");
#endif
@@ -669,7 +660,7 @@ CellPropertyValuesSeq_t DomainMapperTableHandler::endTableGetCellProperties(Tabl
RowPropertyValuesSeq_t DomainMapperTableHandler::endTableGetRowProperties()
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("getRowProperties");
#endif
@@ -679,7 +670,7 @@ RowPropertyValuesSeq_t DomainMapperTableHandler::endTableGetRowProperties()
sal_Int32 nRow = 0;
while( aRowIter != aRowIterEnd )
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("rowProps.row");
#endif
if( aRowIter->get() )
@@ -689,19 +680,19 @@ RowPropertyValuesSeq_t DomainMapperTableHandler::endTableGetRowProperties()
aRowIter->get()->Insert( PROP_IS_SPLIT_ALLOWED, false, uno::makeAny(sal_True ) );
aRowProperties[nRow] = (*aRowIter)->GetPropertyValues();
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->addTag((*aRowIter)->toTag());
dmapper_logger->addTag(lcl_PropertyValuesToTag(aRowProperties[nRow]));
#endif
}
++nRow;
++aRowIter;
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("rowProps.row");
#endif
}
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("getRowProperties");
#endif
@@ -710,7 +701,7 @@ RowPropertyValuesSeq_t DomainMapperTableHandler::endTableGetRowProperties()
void DomainMapperTableHandler::endTable()
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("tablehandler.endTable");
#endif
@@ -722,7 +713,7 @@ void DomainMapperTableHandler::endTable()
RowPropertyValuesSeq_t aRowProperties = endTableGetRowProperties();
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->addTag(lcl_PropertyValueSeqToTag(aRowProperties));
#endif
@@ -739,25 +730,25 @@ void DomainMapperTableHandler::endTable()
}
catch (lang::IllegalArgumentException e)
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->chars("failed to import table!");
#endif
}
-#ifdef DEBUG_DOMAINMAPPER
catch ( uno::Exception e )
{
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("exception");
dmapper_logger->chars(rtl::OUStringToOString( e.Message, RTL_TEXTENCODING_UTF8 ).getStr( ));
dmapper_logger->endElement("exeception");
- }
#endif
+ }
}
m_aTableProperties.reset();
m_aCellProperties.clear();
m_aRowProperties.clear();
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("tablehandler.endTable");
dmapper_logger->endElement("tablehandler.table");
#endif
@@ -769,7 +760,7 @@ void DomainMapperTableHandler::startRow(unsigned int nCells,
m_aRowProperties.push_back( pProps );
m_aCellProperties.push_back( PropertyMapVector1() );
-#if DEBUG_DOMAINMAPPER
+#if DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("table.row");
dmapper_logger->attribute("cells", nCells);
if (pProps != NULL)
@@ -785,7 +776,7 @@ void DomainMapperTableHandler::endRow()
(*m_pTableSeq)[m_nRowIndex] = *m_pRowSeq;
++m_nRowIndex;
m_nCellIndex = 0;
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->endElement("table.row");
#endif
}
@@ -804,7 +795,7 @@ void DomainMapperTableHandler::startCell(const Handle_t & start,
m_aCellProperties[nRow - 1].push_back( pEmptyProps );
}
-#if DEBUG_DOMAINMAPPER
+#if DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("table.cell");
dmapper_logger->startElement("table.cell.start");
dmapper_logger->chars(toString(start));
@@ -824,7 +815,7 @@ void DomainMapperTableHandler::startCell(const Handle_t & start,
void DomainMapperTableHandler::endCell(const Handle_t & end)
{
-#ifdef DEBUG_DOMAINMAPPER
+#ifdef DEBUG_DMAPPER_TABLE_HANDLER
dmapper_logger->startElement("table.cell.end");
dmapper_logger->chars(toString(end));
dmapper_logger->endElement("table.cell.end");
diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index 301774dc2b96..11d03655b5db 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -627,10 +627,9 @@ void DomainMapper_Impl::finishParagraph( PropertyMapPtr pPropertyMap )
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->attribute("isTextAppend", xTextAppend.is());
- dmapper_logger->attribute("isIgnor", getTableManager().isIgnore());
#endif
- if(xTextAppend.is() && ! getTableManager( ).isIgnore())
+ if(xTextAppend.is() && ! getTableManager( ).isIgnore() && pParaContext != NULL)
{
try
{
@@ -649,7 +648,10 @@ void DomainMapper_Impl::finishParagraph( PropertyMapPtr pPropertyMap )
old _and_ new DropCap must not occur
*/
- bool bIsDropCap = pParaContext->IsFrameMode() && sal::static_int_cast<Id>(pParaContext->GetDropCap()) != NS_ooxml::LN_Value_wordprocessingml_ST_DropCap_none;
+ bool bIsDropCap =
+ pParaContext->IsFrameMode() &&
+ sal::static_int_cast<Id>(pParaContext->GetDropCap()) != NS_ooxml::LN_Value_wordprocessingml_ST_DropCap_none;
+
style::DropCapFormat aDrop;
ParagraphPropertiesPtr pToBeSavedProperties;
bool bKeepLastParagraphProperties = false;
diff --git a/writerfilter/source/dmapper/FFDataHandler.cxx b/writerfilter/source/dmapper/FFDataHandler.cxx
index 9f9430401161..6decd84d2786 100644
--- a/writerfilter/source/dmapper/FFDataHandler.cxx
+++ b/writerfilter/source/dmapper/FFDataHandler.cxx
@@ -30,10 +30,8 @@
#include "FFDataHandler.hxx"
#include <ooxml/resourceids.hxx>
-#ifdef DEBUG_DOMAINMAPPER
-#include <resourcemodel/QNameToString.hxx>
#include "dmapperLoggers.hxx"
-#endif
+
namespace writerfilter {
namespace dmapper {
@@ -41,17 +39,18 @@ namespace dmapper {
* class: FFDataHandler *
************************/
-FFDataHandler::FFDataHandler()
-: m_bEnabled(false),
- m_bCalcOnExit(false),
- m_nHelpTextType(0),
- m_nStatusTextType(0),
- m_nCheckboxHeight(0),
- m_bCheckboxAutoHeight(false),
- m_bCheckboxDefault(false),
- m_bCheckboxChecked(false),
- m_nTextType(0),
- m_nTextMaxLength(0)
+FFDataHandler::FFDataHandler() :
+LoggedProperties(dmapper_logger, "FFDataHandler"),
+m_bEnabled(false),
+m_bCalcOnExit(false),
+m_nHelpTextType(0),
+m_nStatusTextType(0),
+m_nCheckboxHeight(0),
+m_bCheckboxAutoHeight(false),
+m_bCheckboxDefault(false),
+m_bCheckboxChecked(false),
+m_nTextType(0),
+m_nTextMaxLength(0)
{
}
@@ -286,12 +285,8 @@ const rtl::OUString & FFDataHandler::getTextFormat() const
}
-void FFDataHandler::sprm(Sprm & r_Sprm)
+void FFDataHandler::lcl_sprm(Sprm & r_Sprm)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("FFDataHandler.sprm");
- dmapper_logger->chars(r_Sprm.toString());
-#endif
switch(r_Sprm.getId())
{
case NS_ooxml::LN_CT_FFData_name:
@@ -426,9 +421,6 @@ void FFDataHandler::sprm(Sprm & r_Sprm)
#endif
break;
}
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("FFDataHandler.sprm");
-#endif
}
void FFDataHandler::resolveSprm(Sprm & r_Sprm)
@@ -438,14 +430,8 @@ void FFDataHandler::resolveSprm(Sprm & r_Sprm)
pProperties->resolve(*this);
}
-void FFDataHandler::attribute(Id name, Value & val)
+void FFDataHandler::lcl_attribute(Id name, Value & val)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("FFDataHandler.attribute");
- dmapper_logger->attribute("name", (*QNameToString::Instance())(name));
- dmapper_logger->attribute("value", val.toString());
- dmapper_logger->endElement("FFDataHandler.attribute");
-#endif
switch (name)
{
case NS_ooxml::LN_CT_FFHelpText_type:
diff --git a/writerfilter/source/dmapper/FFDataHandler.hxx b/writerfilter/source/dmapper/FFDataHandler.hxx
index fb7a4ccee950..b1c7ff2ea7fb 100644
--- a/writerfilter/source/dmapper/FFDataHandler.hxx
+++ b/writerfilter/source/dmapper/FFDataHandler.hxx
@@ -29,11 +29,11 @@
************************************************************************/
#ifndef INCLUDED_FFDataHandler_HXX
#define INCLUDED_FFDataHandler_HXX
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <rtl/ustring.hxx>
namespace writerfilter {
namespace dmapper {
-class FFDataHandler : public Properties
+class FFDataHandler : public LoggedProperties
{
public:
// typedefs
@@ -127,12 +127,8 @@ public:
const rtl::OUString & getTextFormat() const;
// sprm
- void sprm(Sprm & r_sprm);
void resolveSprm(Sprm & r_sprm);
- // attribute
- void attribute(Id name, Value & val);
-
private:
rtl::OUString m_sName;
bool m_bEnabled;
@@ -154,6 +150,12 @@ private:
sal_uInt32 m_nTextMaxLength;
rtl::OUString m_sTextDefault;
rtl::OUString m_sTextFormat;
+
+ // sprm
+ void lcl_sprm(Sprm & r_sprm);
+
+ // attribute
+ void lcl_attribute(Id name, Value & val);
};
diff --git a/writerfilter/source/dmapper/FontTable.cxx b/writerfilter/source/dmapper/FontTable.cxx
index 4bde0ac275b5..fd6f15660557 100644
--- a/writerfilter/source/dmapper/FontTable.cxx
+++ b/writerfilter/source/dmapper/FontTable.cxx
@@ -33,6 +33,8 @@
#include <vector>
#include <stdio.h>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper
{
@@ -46,8 +48,11 @@ struct FontTable_Impl
/*-- 19.06.2006 12:04:32---------------------------------------------------
-----------------------------------------------------------------------*/
-FontTable::FontTable() :
- m_pImpl( new FontTable_Impl )
+FontTable::FontTable()
+: LoggedProperties(dmapper_logger, "FontTable")
+, LoggedTable(dmapper_logger, "FontTable")
+, LoggedStream(dmapper_logger, "FontTable")
+, m_pImpl( new FontTable_Impl )
{
}
/*-- 19.06.2006 12:04:33---------------------------------------------------
@@ -60,7 +65,7 @@ FontTable::~FontTable()
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::attribute(Id Name, Value & val)
+void FontTable::lcl_attribute(Id Name, Value & val)
{
OSL_ENSURE( m_pImpl->pCurrentEntry, "current entry has to be set here");
if(!m_pImpl->pCurrentEntry)
@@ -533,7 +538,7 @@ void FontTable::attribute(Id Name, Value & val)
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::sprm(Sprm& rSprm)
+void FontTable::lcl_sprm(Sprm& rSprm)
{
OSL_ENSURE( m_pImpl->pCurrentEntry, "current entry has to be set here");
if(!m_pImpl->pCurrentEntry)
@@ -561,7 +566,7 @@ void FontTable::sprm(Sprm& rSprm)
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
+void FontTable::lcl_entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
{
//create a new font entry
OSL_ENSURE( !m_pImpl->pCurrentEntry, "current entry has to be NULL here");
@@ -574,81 +579,81 @@ void FontTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_
/*-- 19.06.2006 12:04:34---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::startSectionGroup()
+void FontTable::lcl_startSectionGroup()
{
}
/*-- 19.06.2006 12:04:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::endSectionGroup()
+void FontTable::lcl_endSectionGroup()
{
}
/*-- 19.06.2006 12:04:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::startParagraphGroup()
+void FontTable::lcl_startParagraphGroup()
{
}
/*-- 19.06.2006 12:04:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::endParagraphGroup()
+void FontTable::lcl_endParagraphGroup()
{
}
/*-- 19.06.2006 12:04:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::startCharacterGroup()
+void FontTable::lcl_startCharacterGroup()
{
}
/*-- 19.06.2006 12:04:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::endCharacterGroup()
+void FontTable::lcl_endCharacterGroup()
{
}
/*-- 19.06.2006 12:04:36---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::text(const sal_uInt8*, size_t )
+void FontTable::lcl_text(const sal_uInt8*, size_t )
{
}
/*-- 19.06.2006 12:04:36---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::utext(const sal_uInt8* , size_t)
+void FontTable::lcl_utext(const sal_uInt8* , size_t)
{
}
/*-- 19.06.2006 12:04:37---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::props(writerfilter::Reference<Properties>::Pointer_t)
+void FontTable::lcl_props(writerfilter::Reference<Properties>::Pointer_t)
{
}
/*-- 19.06.2006 12:04:37---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::table(Id, writerfilter::Reference<Table>::Pointer_t)
+void FontTable::lcl_table(Id, writerfilter::Reference<Table>::Pointer_t)
{
}
/*-- 19.06.2006 12:04:38---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::substream(Id, ::writerfilter::Reference<Stream>::Pointer_t)
+void FontTable::lcl_substream(Id, ::writerfilter::Reference<Stream>::Pointer_t)
{
}
/*-- 19.06.2006 12:04:39---------------------------------------------------
-----------------------------------------------------------------------*/
-void FontTable::info(const string& )
+void FontTable::lcl_info(const string& )
{
}
-void FontTable::startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > )
+void FontTable::lcl_startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > )
{
}
-void FontTable::endShape( )
+void FontTable::lcl_endShape( )
{
}
diff --git a/writerfilter/source/dmapper/FontTable.hxx b/writerfilter/source/dmapper/FontTable.hxx
index a2fa967d85fe..cc8e9458f7da 100644
--- a/writerfilter/source/dmapper/FontTable.hxx
+++ b/writerfilter/source/dmapper/FontTable.hxx
@@ -30,7 +30,7 @@
#include <boost/shared_ptr.hpp>
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <com/sun/star/lang/XComponent.hpp>
namespace writerfilter {
@@ -62,46 +62,45 @@ struct FontEntry
nAltFontIndex( 0 )
{}
};
-class WRITERFILTER_DLLPRIVATE FontTable : public Properties, public Table
- /*,public BinaryObj*/, public Stream
+
+class WRITERFILTER_DLLPRIVATE FontTable : public LoggedProperties, public LoggedTable
+ /*,public BinaryObj*/, public LoggedStream
{
FontTable_Impl *m_pImpl;
-public:
+ public:
FontTable();
virtual ~FontTable();
+ sal_uInt32 size();
+ const FontEntry::Pointer_t getFontEntry(sal_uInt32 nIndex);
+
+ private:
// Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
// Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
- // BinaryObj
-// virtual void data(const sal_Int8* buf, size_t len,
-// writerfilter::Reference<Properties>::Pointer_t ref);
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
// Stream
- virtual void startSectionGroup();
- virtual void endSectionGroup();
- virtual void startParagraphGroup();
- virtual void endParagraphGroup();
- virtual void startCharacterGroup();
- virtual void endCharacterGroup();
- virtual void text(const sal_uInt8 * data, size_t len);
- virtual void utext(const sal_uInt8 * data, size_t len);
- virtual void props(writerfilter::Reference<Properties>::Pointer_t ref);
- virtual void table(Id name,
- writerfilter::Reference<Table>::Pointer_t ref);
- virtual void substream(Id name,
- ::writerfilter::Reference<Stream>::Pointer_t ref);
- virtual void info(const string & info);
- virtual void startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape );
- virtual void endShape( );
+ virtual void lcl_startSectionGroup();
+ virtual void lcl_endSectionGroup();
+ virtual void lcl_startParagraphGroup();
+ virtual void lcl_endParagraphGroup();
+ virtual void lcl_startCharacterGroup();
+ virtual void lcl_endCharacterGroup();
+ virtual void lcl_text(const sal_uInt8 * data, size_t len);
+ virtual void lcl_utext(const sal_uInt8 * data, size_t len);
+ virtual void lcl_props(writerfilter::Reference<Properties>::Pointer_t ref);
+ virtual void lcl_table(Id name,
+ writerfilter::Reference<Table>::Pointer_t ref);
+ virtual void lcl_substream(Id name,
+ ::writerfilter::Reference<Stream>::Pointer_t ref);
+ virtual void lcl_info(const string & info);
+ virtual void lcl_startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape );
+ virtual void lcl_endShape( );
- const FontEntry::Pointer_t getFontEntry(sal_uInt32 nIndex);
- sal_uInt32 size();
};
typedef boost::shared_ptr< FontTable > FontTablePtr;
}}
diff --git a/writerfilter/source/dmapper/GraphicHelpers.cxx b/writerfilter/source/dmapper/GraphicHelpers.cxx
index c77f2dd55d3e..76ef4c7257ff 100644
--- a/writerfilter/source/dmapper/GraphicHelpers.cxx
+++ b/writerfilter/source/dmapper/GraphicHelpers.cxx
@@ -8,6 +8,8 @@
#include <com/sun/star/text/RelOrientation.hpp>
#include <com/sun/star/text/WrapTextMode.hpp>
+#include "dmapperLoggers.hxx"
+
#include <iostream>
using namespace std;
@@ -17,7 +19,7 @@ namespace dmapper {
using namespace com::sun::star;
PositionHandler::PositionHandler( ) :
- Properties( )
+LoggedProperties(dmapper_logger, "PositionHandler")
{
m_nOrient = text::VertOrientation::NONE;
m_nRelation = text::RelOrientation::FRAME;
@@ -28,7 +30,7 @@ PositionHandler::~PositionHandler( )
{
}
-void PositionHandler::attribute( Id aName, Value& rVal )
+void PositionHandler::lcl_attribute( Id aName, Value& rVal )
{
sal_Int32 nIntValue = rVal.getInt( );
switch ( aName )
@@ -85,11 +87,15 @@ void PositionHandler::attribute( Id aName, Value& rVal )
}
}
break;
- default:;
+ default:
+#ifdef DEBUG_DOMAINMAPPER
+ dmapper_logger->element("unhandled");
+#endif
+ break;
}
}
-void PositionHandler::sprm( Sprm& rSprm )
+void PositionHandler::lcl_sprm( Sprm& rSprm )
{
Value::Pointer_t pValue = rSprm.getValue();
sal_Int32 nIntValue = pValue->getInt();
@@ -153,12 +159,16 @@ void PositionHandler::sprm( Sprm& rSprm )
case NS_ooxml::LN_CT_PosH_posOffset:
case NS_ooxml::LN_CT_PosV_posOffset:
m_nPosition = ConversionHelper::convertEMUToMM100( nIntValue );
- default:;
+ default:
+#ifdef DEBUG_DOMAINMAPPER
+ dmapper_logger->element("unhandled");
+#endif
+ break;
}
}
WrapHandler::WrapHandler( ) :
- Properties( ),
+LoggedProperties(dmapper_logger, "WrapHandler"),
m_nType( 0 ),
m_nSide( 0 )
{
@@ -168,7 +178,7 @@ WrapHandler::~WrapHandler( )
{
}
-void WrapHandler::attribute( Id aName, Value& rVal )
+void WrapHandler::lcl_attribute( Id aName, Value& rVal )
{
switch ( aName )
{
@@ -182,7 +192,7 @@ void WrapHandler::attribute( Id aName, Value& rVal )
}
}
-void WrapHandler::sprm( Sprm& )
+void WrapHandler::lcl_sprm( Sprm& )
{
}
diff --git a/writerfilter/source/dmapper/GraphicHelpers.hxx b/writerfilter/source/dmapper/GraphicHelpers.hxx
index fb8f8b2455ee..7127ccf22c1f 100644
--- a/writerfilter/source/dmapper/GraphicHelpers.hxx
+++ b/writerfilter/source/dmapper/GraphicHelpers.hxx
@@ -4,7 +4,7 @@
#include "PropertyMap.hxx"
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
@@ -12,7 +12,7 @@ namespace writerfilter {
namespace dmapper
{
-class WRITERFILTER_DLLPRIVATE PositionHandler: public Properties
+class WRITERFILTER_DLLPRIVATE PositionHandler: public LoggedProperties
{
public:
PositionHandler( );
@@ -22,12 +22,13 @@ public:
sal_Int16 m_nRelation;
sal_Int32 m_nPosition;
- virtual void attribute( Id aName, Value& rVal );
- virtual void sprm( Sprm& rSprm );
+ private:
+ virtual void lcl_attribute( Id aName, Value& rVal );
+ virtual void lcl_sprm( Sprm& rSprm );
};
typedef boost::shared_ptr<PositionHandler> PositionHandlerPtr;
-class WRITERFILTER_DLLPRIVATE WrapHandler: public Properties
+class WRITERFILTER_DLLPRIVATE WrapHandler: public LoggedProperties
{
public:
WrapHandler( );
@@ -38,8 +39,9 @@ public:
sal_Int32 getWrapMode( );
- virtual void attribute( Id aName, Value& rVal );
- virtual void sprm( Sprm& rSprm );
+ private:
+ virtual void lcl_attribute( Id aName, Value& rVal );
+ virtual void lcl_sprm( Sprm& rSprm );
};
typedef boost::shared_ptr<WrapHandler> WrapHandlerPtr;
diff --git a/writerfilter/source/dmapper/GraphicImport.cxx b/writerfilter/source/dmapper/GraphicImport.cxx
index 14a54c640626..beae39a68a29 100644
--- a/writerfilter/source/dmapper/GraphicImport.cxx
+++ b/writerfilter/source/dmapper/GraphicImport.cxx
@@ -25,54 +25,51 @@
*
************************************************************************/
-#include "GraphicImport.hxx"
-#include "GraphicHelpers.hxx"
+#include <string.h>
-#include <dmapper/DomainMapper.hxx>
-#include <PropertyMap.hxx>
-#include <doctok/resourceids.hxx>
-#include <ooxml/resourceids.hxx>
-#include <ConversionHelper.hxx>
-#include <com/sun/star/uno/XComponentContext.hpp>
-#include <com/sun/star/io/XInputStream.hpp>
-#include <cppuhelper/implbase1.hxx>
#include <com/sun/star/awt/Size.hpp>
#include <com/sun/star/container/XNamed.hpp>
#include <com/sun/star/drawing/ColorMode.hpp>
-
-#include <com/sun/star/graphic/XGraphicProvider.hpp>
+#include <com/sun/star/drawing/PointSequenceSequence.hpp>
+#include <com/sun/star/drawing/XShape.hpp>
#include <com/sun/star/graphic/XGraphic.hpp>
+#include <com/sun/star/graphic/XGraphicProvider.hpp>
+#include <com/sun/star/io/XInputStream.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/table/BorderLine.hpp>
#include <com/sun/star/text/GraphicCrop.hpp>
-#include <com/sun/star/text/XTextContent.hpp>
-#include <com/sun/star/text/TextContentAnchorType.hpp>
#include <com/sun/star/text/HoriOrientation.hpp>
#include <com/sun/star/text/RelOrientation.hpp>
+#include <com/sun/star/text/TextContentAnchorType.hpp>
#include <com/sun/star/text/VertOrientation.hpp>
#include <com/sun/star/text/WrapTextMode.hpp>
-#include <com/sun/star/drawing/XShape.hpp>
-#include <rtl/ustrbuf.hxx>
+#include <com/sun/star/text/XTextContent.hpp>
+#include <com/sun/star/uno/XComponentContext.hpp>
+#include <cppuhelper/implbase1.hxx>
+#include <rtl/ustrbuf.hxx>
-#include <iostream>
-#include <resourcemodel/QNameToString.hxx>
-#include <string.h>
+#include <dmapper/DomainMapper.hxx>
+#include <doctok/resourceids.hxx>
+#include <ooxml/resourceids.hxx>
+#include <resourcemodel/ResourceModelHelper.hxx>
-#ifdef DEBUG_DOMAINMAPPER
-#include <resourcemodel/TagLogger.hxx>
-#endif
+#include "ConversionHelper.hxx"
+#include "GraphicHelpers.hxx"
+#include "GraphicImport.hxx"
+#include "PropertyMap.hxx"
+#include "WrapPolygonHandler.hxx"
+#include "dmapperLoggers.hxx"
namespace writerfilter {
+
+using resourcemodel::resolveSprmProps;
+
namespace dmapper
{
using namespace ::std;
using namespace ::com::sun::star;
-#ifdef DEBUG_DOMAINMAPPER
-extern TagLogger::Pointer_t dmapper_logger;
-#endif
-
class XInputStreamHelper : public cppu::WeakImplHelper1
< io::XInputStream >
{
@@ -230,6 +227,8 @@ public:
sal_Int32 nWrap;
bool bOpaque;
bool bContour;
+ bool bContourOutside;
+ WrapPolygon::Pointer_t mpWrapPolygon;
bool bIgnoreWRK;
sal_Int32 nLeftMargin;
@@ -292,6 +291,7 @@ public:
,nWrap(0)
,bOpaque( true )
,bContour(false)
+ ,bContourOutside(true)
,bIgnoreWRK(true)
,nLeftMargin(319)
,nRightMargin(319)
@@ -354,9 +354,12 @@ GraphicImport::GraphicImport(uno::Reference < uno::XComponentContext > xCompo
uno::Reference< lang::XMultiServiceFactory > xTextFactory,
DomainMapper& rDMapper,
GraphicImportType eImportType )
-: m_pImpl( new GraphicImport_Impl( eImportType, rDMapper ))
- ,m_xComponentContext( xComponentContext )
- ,m_xTextFactory( xTextFactory)
+: LoggedProperties(dmapper_logger, "GraphicImport")
+, LoggedTable(dmapper_logger, "GraphicImport")
+, LoggedStream(dmapper_logger, "GraphicImport")
+, m_pImpl( new GraphicImport_Impl( eImportType, rDMapper ))
+, m_xComponentContext( xComponentContext )
+, m_xTextFactory( xTextFactory)
{
}
/*-- 01.11.2006 09:42:42---------------------------------------------------
@@ -366,15 +369,32 @@ GraphicImport::~GraphicImport()
{
delete m_pImpl;
}
+
+void GraphicImport::handleWrapTextValue(sal_uInt32 nVal)
+{
+ switch (nVal)
+ {
+ case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_bothSides: // 90920;
+ m_pImpl->nWrap = text::WrapTextMode_PARALLEL;
+ break;
+ case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_left: // 90921;
+ m_pImpl->nWrap = text::WrapTextMode_LEFT;
+ break;
+ case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_right: // 90922;
+ m_pImpl->nWrap = text::WrapTextMode_RIGHT;
+ break;
+ case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_largest: // 90923;
+ m_pImpl->nWrap = text::WrapTextMode_DYNAMIC;
+ break;
+ default:;
+ }
+}
+
/*-- 01.11.2006 09:45:01---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::attribute(Id nName, Value & val)
+void GraphicImport::lcl_attribute(Id nName, Value & val)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("attribute");
- dmapper_logger->attribute("name", (*QNameToString::Instance())(nName));
-#endif
sal_Int32 nIntValue = val.getInt();
/* WRITERFILTERSTATUS: table: PICFattribute */
switch( nName )
@@ -1018,26 +1038,24 @@ void GraphicImport::attribute(Id nName, Value & val)
case NS_ooxml::LN_CT_WrapTight_wrapText: // 90934;
/* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
m_pImpl->bContour = true;
- //no break;
+ m_pImpl->bContourOutside = true;
+
+ handleWrapTextValue(val.getInt());
+
+ break;
+ case NS_ooxml::LN_CT_WrapThrough_wrapText:
+ /* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
+ m_pImpl->bContour = true;
+ m_pImpl->bContourOutside = false;
+
+ handleWrapTextValue(val.getInt());
+
+ break;
case NS_ooxml::LN_CT_WrapSquare_wrapText: //90928;
/* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
- switch ( val.getInt() )
- {
- case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_bothSides: // 90920;
- m_pImpl->nWrap = text::WrapTextMode_PARALLEL;
- break;
- case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_left: // 90921;
- m_pImpl->nWrap = text::WrapTextMode_LEFT;
- break;
- case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_right: // 90922;
- m_pImpl->nWrap = text::WrapTextMode_RIGHT;
- break;
- case NS_ooxml::LN_Value_wordprocessingDrawing_ST_WrapText_largest: // 90923;
- m_pImpl->nWrap = text::WrapTextMode_DYNAMIC;
- break;
- default:;
- }
- break;
+
+ handleWrapTextValue(val.getInt());
+ break;
case NS_ooxml::LN_shape:
/* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
{
@@ -1130,18 +1148,11 @@ void GraphicImport::attribute(Id nName, Value & val)
//TODO: does it need to be handled?
break;
default:
-#if OSL_DEBUG_LEVEL > 0
- ::rtl::OString sMessage( "GraphicImport::attribute() - Id: ");
- sMessage += ::rtl::OString::valueOf( sal_Int32( nName ), 10 );
- sMessage += ::rtl::OString(" / 0x");
- sMessage += ::rtl::OString::valueOf( sal_Int32( nName ), 16 );
- OSL_ENSURE( false, sMessage.getStr())
+#ifdef DEBUG_DMAPPER_GRAPHIC_IMPORT
+ dmapper_logger->element("unhandled");
#endif
;
}
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("attribute");
-#endif
}
uno::Reference<text::XTextContent> GraphicImport::GetGraphicObject()
@@ -1357,13 +1368,8 @@ void GraphicImport::ProcessShapeOptions(Value& val)
/*-- 01.11.2006 09:45:02---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::sprm(Sprm & rSprm)
+void GraphicImport::lcl_sprm(Sprm & rSprm)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("sprm");
- dmapper_logger->chars(rSprm.toString());
-#endif
-
sal_uInt32 nSprmId = rSprm.getId();
Value::Pointer_t pValue = rSprm.getValue();
@@ -1386,12 +1392,12 @@ void GraphicImport::sprm(Sprm & rSprm)
case NS_ooxml::LN_CT_Anchor_effectExtent: // 90979;
case NS_ooxml::LN_EG_WrapType_wrapSquare: // 90945;
case NS_ooxml::LN_EG_WrapType_wrapTight: // 90946;
+ case NS_ooxml::LN_EG_WrapType_wrapThrough:
case NS_ooxml::LN_CT_Anchor_docPr: // 90980;
case NS_ooxml::LN_CT_Anchor_cNvGraphicFramePr: // 90981;
case NS_ooxml::LN_CT_Anchor_a_graphic: // 90982;
case NS_ooxml::LN_CT_WrapPath_start: // 90924;
case NS_ooxml::LN_CT_WrapPath_lineTo: // 90925;
- case NS_ooxml::LN_CT_WrapTight_wrapPolygon: // 90933;
case NS_ooxml::LN_graphic_graphic:
case NS_ooxml::LN_pic_pic:
/* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
@@ -1403,6 +1409,17 @@ void GraphicImport::sprm(Sprm & rSprm)
}
}
break;
+ case NS_ooxml::LN_CT_WrapTight_wrapPolygon:
+ case NS_ooxml::LN_CT_WrapThrough_wrapPolygon:
+ /* WRITERFILTERSTATUS: done: 100, planned: 4, spent: 2 */
+ {
+ WrapPolygonHandler aHandler;
+
+ resolveSprmProps(aHandler, rSprm);
+
+ m_pImpl->mpWrapPolygon = aHandler.getPolygon();
+ }
+ break;
case NS_ooxml::LN_CT_Anchor_positionH: // 90976;
{
// Use a special handler for the positionning
@@ -1453,10 +1470,6 @@ void GraphicImport::sprm(Sprm & rSprm)
/* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
m_pImpl->nWrap = text::WrapTextMode_NONE;
break;
- case NS_ooxml::LN_EG_WrapType_wrapThrough: // 90947;
- /* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
- m_pImpl->nWrap = text::WrapTextMode_THROUGHT;
- break;
case 0xf010:
case 0xf011:
//ignore - doesn't contain useful members
@@ -1481,17 +1494,11 @@ void GraphicImport::sprm(Sprm & rSprm)
#endif
;
}
-
-
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("sprm");
-#endif
}
/*-- 01.11.2006 09:45:02---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t /*ref*/)
+void GraphicImport::lcl_entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t /*ref*/)
{
}
/*-- 16.11.2006 16:14:32---------------------------------------------------
@@ -1640,7 +1647,7 @@ uno::Reference< text::XTextContent > GraphicImport::createGraphicObject( const b
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_SURROUND_CONTOUR ),
uno::makeAny(m_pImpl->bContour));
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_CONTOUR_OUTSIDE ),
- uno::makeAny(true));
+ uno::makeAny(m_pImpl->bContourOutside));
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_LEFT_MARGIN ),
uno::makeAny(m_pImpl->nLeftMargin));
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_RIGHT_MARGIN ),
@@ -1650,8 +1657,6 @@ uno::Reference< text::XTextContent > GraphicImport::createGraphicObject( const b
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_BOTTOM_MARGIN ),
uno::makeAny(m_pImpl->nBottomMargin));
- xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_CONTOUR_POLY_POLYGON),
- uno::Any());
if( m_pImpl->eColorMode == drawing::ColorMode_STANDARD &&
m_pImpl->nContrast == -70 &&
m_pImpl->nBrightness == 70 )
@@ -1679,16 +1684,31 @@ uno::Reference< text::XTextContent > GraphicImport::createGraphicObject( const b
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_HORI_MIRRORED_ON_ODD_PAGES ),
uno::makeAny( m_pImpl->bHoriFlip ));
}
+
if( m_pImpl->bVertFlip )
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_VERT_MIRRORED ),
uno::makeAny( m_pImpl->bVertFlip ));
xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_BACK_COLOR ),
uno::makeAny( m_pImpl->nFillColor ));
+
//there seems to be no way to detect the original size via _real_ API
uno::Reference< beans::XPropertySet > xGraphicProperties( xGraphic, uno::UNO_QUERY_THROW );
awt::Size aGraphicSize, aGraphicSizePixel;
xGraphicProperties->getPropertyValue(rPropNameSupplier.GetName( PROP_SIZE100th_M_M )) >>= aGraphicSize;
xGraphicProperties->getPropertyValue(rPropNameSupplier.GetName( PROP_SIZE_PIXEL )) >>= aGraphicSizePixel;
+
+ uno::Any aContourPolyPolygon;
+ if( aGraphicSize.Width && aGraphicSize.Height &&
+ m_pImpl->mpWrapPolygon.get() != NULL)
+ {
+ awt::Size aDstSize(m_pImpl->getXSize(), m_pImpl->getYSize());
+ WrapPolygon::Pointer_t pCorrected = m_pImpl->mpWrapPolygon->correctWordWrapPolygon(aGraphicSize, aDstSize);
+ aContourPolyPolygon <<= pCorrected->getPointSequenceSequence();
+ }
+
+ xGraphicObjectProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_CONTOUR_POLY_POLYGON),
+ aContourPolyPolygon);
+
if( aGraphicSize.Width && aGraphicSize.Height )
{
//todo: i71651 graphic size is not provided by the GraphicDescriptor
@@ -1697,9 +1717,11 @@ uno::Reference< text::XTextContent > GraphicImport::createGraphicObject( const b
lcl_CalcCrop( m_pImpl->nLeftCrop, aGraphicSize.Width );
lcl_CalcCrop( m_pImpl->nRightCrop, aGraphicSize.Width );
+
xGraphicProperties->setPropertyValue(rPropNameSupplier.GetName( PROP_GRAPHIC_CROP ),
uno::makeAny(text::GraphicCrop(m_pImpl->nTopCrop, m_pImpl->nBottomCrop, m_pImpl->nLeftCrop, m_pImpl->nRightCrop)));
}
+
}
if(m_pImpl->eGraphicImportType == IMPORT_AS_DETECTED_INLINE || m_pImpl->eGraphicImportType == IMPORT_AS_DETECTED_ANCHOR)
@@ -1747,81 +1769,81 @@ void GraphicImport::data(const sal_uInt8* buf, size_t len, writerfilter::Referen
/*-- 01.11.2006 09:45:03---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::startSectionGroup()
+void GraphicImport::lcl_startSectionGroup()
{
}
/*-- 01.11.2006 09:45:03---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::endSectionGroup()
+void GraphicImport::lcl_endSectionGroup()
{
}
/*-- 01.11.2006 09:45:03---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::startParagraphGroup()
+void GraphicImport::lcl_startParagraphGroup()
{
}
/*-- 01.11.2006 09:45:03---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::endParagraphGroup()
+void GraphicImport::lcl_endParagraphGroup()
{
}
/*-- 01.11.2006 09:45:03---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::startCharacterGroup()
+void GraphicImport::lcl_startCharacterGroup()
{
}
/*-- 01.11.2006 09:45:04---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::endCharacterGroup()
+void GraphicImport::lcl_endCharacterGroup()
{
}
/*-- 01.11.2006 09:45:04---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::text(const sal_uInt8 * /*_data*/, size_t /*len*/)
+void GraphicImport::lcl_text(const sal_uInt8 * /*_data*/, size_t /*len*/)
{
}
/*-- 01.11.2006 09:45:05---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::utext(const sal_uInt8 * /*_data*/, size_t /*len*/)
+void GraphicImport::lcl_utext(const sal_uInt8 * /*_data*/, size_t /*len*/)
{
}
/*-- 01.11.2006 09:45:05---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::props(writerfilter::Reference<Properties>::Pointer_t /*ref*/)
+void GraphicImport::lcl_props(writerfilter::Reference<Properties>::Pointer_t /*ref*/)
{
}
/*-- 01.11.2006 09:45:06---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::table(Id /*name*/, writerfilter::Reference<Table>::Pointer_t /*ref*/)
+void GraphicImport::lcl_table(Id /*name*/, writerfilter::Reference<Table>::Pointer_t /*ref*/)
{
}
/*-- 01.11.2006 09:45:07---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::substream(Id /*name*/, ::writerfilter::Reference<Stream>::Pointer_t /*ref*/)
+void GraphicImport::lcl_substream(Id /*name*/, ::writerfilter::Reference<Stream>::Pointer_t /*ref*/)
{
}
/*-- 01.11.2006 09:45:07---------------------------------------------------
-----------------------------------------------------------------------*/
-void GraphicImport::info(const string & /*info*/)
+void GraphicImport::lcl_info(const string & /*info*/)
{
}
-void GraphicImport::startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > /*xShape*/ )
+void GraphicImport::lcl_startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > /*xShape*/ )
{
}
-void GraphicImport::endShape( )
+void GraphicImport::lcl_endShape( )
{
}
diff --git a/writerfilter/source/dmapper/GraphicImport.hxx b/writerfilter/source/dmapper/GraphicImport.hxx
index 14f512a3d4ee..87e99ce975b6 100644
--- a/writerfilter/source/dmapper/GraphicImport.hxx
+++ b/writerfilter/source/dmapper/GraphicImport.hxx
@@ -30,7 +30,7 @@
//#ifndef INCLUDED_WRITERFILTERDLLAPI_H
//#include <WriterFilterDllApi.hxx>
//#endif
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
//#include <com/sun/star/lang/XComponent.hpp>
namespace com{ namespace sun { namespace star {
namespace uno{
@@ -69,8 +69,8 @@ enum GraphicImportType
IMPORT_AS_DETECTED_ANCHOR
};
-class WRITERFILTER_DLLPRIVATE GraphicImport : public Properties, public Table
- ,public BinaryObj, public Stream
+class WRITERFILTER_DLLPRIVATE GraphicImport : public LoggedProperties, public LoggedTable
+ ,public BinaryObj, public LoggedStream
{
GraphicImport_Impl* m_pImpl;
::com::sun::star::uno::Reference < ::com::sun::star::uno::XComponentContext > m_xComponentContext;
@@ -91,37 +91,41 @@ public:
GraphicImportType eGraphicImportType);
virtual ~GraphicImport();
+ // BinaryObj
+ virtual void data(const sal_uInt8* buf, size_t len, writerfilter::Reference<Properties>::Pointer_t ref);
+
+ ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > GetGraphicObject();
+ bool IsGraphic() const;
+
+ private:
// Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
// Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
- // BinaryObj
- virtual void data(const sal_uInt8* buf, size_t len, writerfilter::Reference<Properties>::Pointer_t ref);
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
// Stream
- virtual void startSectionGroup();
- virtual void endSectionGroup();
- virtual void startParagraphGroup();
- virtual void endParagraphGroup();
- virtual void startCharacterGroup();
- virtual void endCharacterGroup();
- virtual void text(const sal_uInt8 * data, size_t len);
- virtual void utext(const sal_uInt8 * data, size_t len);
- virtual void props(writerfilter::Reference<Properties>::Pointer_t ref);
- virtual void table(Id name,
- writerfilter::Reference<Table>::Pointer_t ref);
- virtual void substream(Id name,
- ::writerfilter::Reference<Stream>::Pointer_t ref);
- virtual void info(const string & info);
- virtual void startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape );
- virtual void endShape( );
+ virtual void lcl_startSectionGroup();
+ virtual void lcl_endSectionGroup();
+ virtual void lcl_startParagraphGroup();
+ virtual void lcl_endParagraphGroup();
+ virtual void lcl_startCharacterGroup();
+ virtual void lcl_endCharacterGroup();
+ virtual void lcl_text(const sal_uInt8 * data, size_t len);
+ virtual void lcl_utext(const sal_uInt8 * data, size_t len);
+ virtual void lcl_props(writerfilter::Reference<Properties>::Pointer_t ref);
+ virtual void lcl_table(Id name,
+ writerfilter::Reference<Table>::Pointer_t ref);
+ virtual void lcl_substream(Id name,
+ ::writerfilter::Reference<Stream>::Pointer_t ref);
+ virtual void lcl_info(const string & info);
+ virtual void lcl_startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape );
+ virtual void lcl_endShape( );
- ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent > GetGraphicObject();
- bool IsGraphic() const;
+ void handleWrapTextValue(sal_uInt32 nVal);
};
+
typedef boost::shared_ptr< GraphicImport > GraphicImportPtr;
}}
diff --git a/writerfilter/source/dmapper/MeasureHandler.cxx b/writerfilter/source/dmapper/MeasureHandler.cxx
index 58f3980063ee..e34a6896ea0d 100644
--- a/writerfilter/source/dmapper/MeasureHandler.cxx
+++ b/writerfilter/source/dmapper/MeasureHandler.cxx
@@ -30,6 +30,7 @@
#include <ConversionHelper.hxx>
#include <ooxml/resourceids.hxx>
#include <com/sun/star/text/SizeType.hpp>
+#include "dmapperLoggers.hxx"
namespace writerfilter {
namespace dmapper {
@@ -40,9 +41,10 @@ using namespace ::com::sun::star;
-----------------------------------------------------------------------*/
MeasureHandler::MeasureHandler() :
- m_nMeasureValue( 0 ),
- m_nUnit( -1 ),
- m_nRowHeightSizeType( text::SizeType::MIN )
+LoggedProperties(dmapper_logger, "MeasureHandler"),
+m_nMeasureValue( 0 ),
+m_nUnit( -1 ),
+m_nRowHeightSizeType( text::SizeType::MIN )
{
}
/*-- 24.04.2007 09:06:35---------------------------------------------------
@@ -54,7 +56,7 @@ MeasureHandler::~MeasureHandler()
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void MeasureHandler::attribute(Id rName, Value & rVal)
+void MeasureHandler::lcl_attribute(Id rName, Value & rVal)
{
sal_Int32 nIntValue = rVal.getInt();
(void)rName;
@@ -99,7 +101,7 @@ void MeasureHandler::attribute(Id rName, Value & rVal)
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void MeasureHandler::sprm(Sprm & rSprm)
+void MeasureHandler::lcl_sprm(Sprm & rSprm)
{
(void)rSprm;
}
diff --git a/writerfilter/source/dmapper/MeasureHandler.hxx b/writerfilter/source/dmapper/MeasureHandler.hxx
index 574685f8ed27..25a38a4862f3 100644
--- a/writerfilter/source/dmapper/MeasureHandler.hxx
+++ b/writerfilter/source/dmapper/MeasureHandler.hxx
@@ -28,7 +28,7 @@
#define INCLUDED_MEASUREHANDLER_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
namespace writerfilter {
@@ -39,20 +39,20 @@ class PropertyMap;
- Left indent of tables
- Preferred width of tables
*/
-class WRITERFILTER_DLLPRIVATE MeasureHandler : public Properties
+class WRITERFILTER_DLLPRIVATE MeasureHandler : public LoggedProperties
{
sal_Int32 m_nMeasureValue;
sal_Int32 m_nUnit;
sal_Int16 m_nRowHeightSizeType; //table row height type
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
MeasureHandler();
virtual ~MeasureHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
sal_Int32 getMeasureValue() const;
//at least tables can have automatic width
bool isAutoWidth() const;
diff --git a/writerfilter/source/dmapper/NumberingManager.cxx b/writerfilter/source/dmapper/NumberingManager.cxx
index 8cc031ea1d09..9e66e1a467c3 100644
--- a/writerfilter/source/dmapper/NumberingManager.cxx
+++ b/writerfilter/source/dmapper/NumberingManager.cxx
@@ -1,3 +1,29 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
#include "ConversionHelper.hxx"
#include "NumberingManager.hxx"
#include "StyleSheetTable.hxx"
@@ -19,6 +45,8 @@
#include <stdio.h>
#endif
+#include "dmapperLoggers.hxx"
+
using namespace rtl;
using namespace com::sun::star;
@@ -614,10 +642,12 @@ void ListDef::CreateNumberingRules( DomainMapper& rDMapper,
//------------------------------------- NumberingManager implementation
-ListsManager::ListsManager( DomainMapper& rDMapper,
- const uno::Reference< lang::XMultiServiceFactory > xFactory ) :
- m_rDMapper( rDMapper ),
- m_xFactory( xFactory )
+ListsManager::ListsManager(DomainMapper& rDMapper,
+ const uno::Reference< lang::XMultiServiceFactory > xFactory) :
+LoggedProperties(dmapper_logger, "ListsManager"),
+LoggedTable(dmapper_logger, "ListsManager"),
+m_rDMapper( rDMapper ),
+m_xFactory( xFactory )
{
}
@@ -625,7 +655,7 @@ ListsManager::~ListsManager( )
{
}
-void ListsManager::attribute( Id nName, Value& rVal )
+void ListsManager::lcl_attribute( Id nName, Value& rVal )
{
OSL_ENSURE( m_pCurrentDefinition.get(), "current entry has to be set here");
if(!m_pCurrentDefinition.get())
@@ -764,7 +794,7 @@ void ListsManager::attribute( Id nName, Value& rVal )
}
}
-void ListsManager::sprm( Sprm& rSprm )
+void ListsManager::lcl_sprm( Sprm& rSprm )
{
//fill the attributes of the style sheet
sal_uInt32 nSprmId = rSprm.getId();
@@ -939,8 +969,8 @@ void ListsManager::sprm( Sprm& rSprm )
}
}
-void ListsManager::entry( int /* pos */,
- writerfilter::Reference<Properties>::Pointer_t ref )
+void ListsManager::lcl_entry( int /* pos */,
+ writerfilter::Reference<Properties>::Pointer_t ref )
{
if( m_rDMapper.IsOOXMLImport() )
{
diff --git a/writerfilter/source/dmapper/NumberingManager.hxx b/writerfilter/source/dmapper/NumberingManager.hxx
index a7970fca531c..3285bc85f416 100644
--- a/writerfilter/source/dmapper/NumberingManager.hxx
+++ b/writerfilter/source/dmapper/NumberingManager.hxx
@@ -1,3 +1,29 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
#ifndef INCLUDED_NUMBERINGMANAGER_HXX
#define INCLUDED_NUMBERINGMANAGER_HXX
@@ -5,7 +31,7 @@
#include <WriterFilterDllApi.hxx>
#include <dmapper/DomainMapper.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <com/sun/star/container/XIndexReplace.hpp>
@@ -170,8 +196,8 @@ public:
/** This class provides access to the defined numbering styles.
*/
class ListsManager :
- public Properties,
- public Table
+ public LoggedProperties,
+ public LoggedTable
{
private:
@@ -190,6 +216,13 @@ private:
AbstractListDef::Pointer GetAbstractList( sal_Int32 nId );
+ // Properties
+ virtual void lcl_attribute( Id nName, Value & rVal );
+ virtual void lcl_sprm(Sprm & sprm);
+
+ // Table
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
+
public:
ListsManager(
@@ -199,13 +232,6 @@ public:
typedef boost::shared_ptr< ListsManager > Pointer;
- // Properties
- virtual void attribute( Id nName, Value & rVal );
- virtual void sprm(Sprm & sprm);
-
- // Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
// Config methods
void SetLFOImport( bool bLFOImport ) { m_bIsLFOImport = bLFOImport; };
diff --git a/writerfilter/source/dmapper/OLEHandler.cxx b/writerfilter/source/dmapper/OLEHandler.cxx
index 65f76f11cbfc..89ee01ecb9a0 100644
--- a/writerfilter/source/dmapper/OLEHandler.cxx
+++ b/writerfilter/source/dmapper/OLEHandler.cxx
@@ -44,6 +44,8 @@
#include <com/sun/star/text/XTextDocument.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper {
@@ -52,9 +54,10 @@ using namespace ::com::sun::star;
-----------------------------------------------------------------------*/
OLEHandler::OLEHandler() :
- m_nDxaOrig(0),
- m_nDyaOrig(0),
- m_nWrapMode(0)
+LoggedProperties(dmapper_logger, "OLEHandler"),
+m_nDxaOrig(0),
+m_nDyaOrig(0),
+m_nWrapMode(0)
{
}
/*-- 23.04.2008 10:46:14---------------------------------------------------
@@ -66,7 +69,7 @@ OLEHandler::~OLEHandler()
/*-- 23.04.2008 10:46:14---------------------------------------------------
-----------------------------------------------------------------------*/
-void OLEHandler::attribute(Id rName, Value & rVal)
+void OLEHandler::lcl_attribute(Id rName, Value & rVal)
{
rtl::OUString sStringValue = rVal.getString();
(void)rName;
@@ -141,7 +144,7 @@ void OLEHandler::attribute(Id rName, Value & rVal)
/*-- 23.04.2008 10:46:14---------------------------------------------------
-----------------------------------------------------------------------*/
-void OLEHandler::sprm(Sprm & rSprm)
+void OLEHandler::lcl_sprm(Sprm & rSprm)
{
sal_uInt32 nSprmId = rSprm.getId();
switch( nSprmId )
diff --git a/writerfilter/source/dmapper/OLEHandler.hxx b/writerfilter/source/dmapper/OLEHandler.hxx
index f9059fb6a35a..cddbac5475bc 100644
--- a/writerfilter/source/dmapper/OLEHandler.hxx
+++ b/writerfilter/source/dmapper/OLEHandler.hxx
@@ -30,7 +30,7 @@
#ifndef INCLUDED_WRITERFILTERDLLAPI_H
#include <WriterFilterDllApi.hxx>
#endif
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
#include <com/sun/star/awt/Size.hpp>
#include <com/sun/star/awt/Point.hpp>
@@ -60,7 +60,7 @@ namespace dmapper
//class PropertyMap;
/** Handler for OLE objects
*/
-class WRITERFILTER_DLLPRIVATE OLEHandler : public Properties
+class WRITERFILTER_DLLPRIVATE OLEHandler : public LoggedProperties
{
::rtl::OUString m_sObjectType;
::rtl::OUString m_sProgId;
@@ -81,14 +81,15 @@ class WRITERFILTER_DLLPRIVATE OLEHandler : public Properties
::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > m_xReplacement;
::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > m_xInputStream;
+
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
OLEHandler();
virtual ~OLEHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
inline ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > getShape( ) { return m_xShape; };
inline bool isOLEObject( ) { return m_xInputStream.is( ); };
diff --git a/writerfilter/source/dmapper/PageBordersHandler.cxx b/writerfilter/source/dmapper/PageBordersHandler.cxx
index 725502843982..21798d684b5d 100644
--- a/writerfilter/source/dmapper/PageBordersHandler.cxx
+++ b/writerfilter/source/dmapper/PageBordersHandler.cxx
@@ -2,6 +2,8 @@
#include <ooxml/resourceids.hxx>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper {
@@ -16,8 +18,9 @@ _PgBorder::~_PgBorder( )
}
PageBordersHandler::PageBordersHandler( ) :
- m_nDisplay( 0 ),
- m_nOffset( 0 )
+LoggedProperties(dmapper_logger, "PageBordersHandler"),
+m_nDisplay( 0 ),
+m_nOffset( 0 )
{
}
@@ -25,7 +28,7 @@ PageBordersHandler::~PageBordersHandler( )
{
}
-void PageBordersHandler::attribute( Id eName, Value& rVal )
+void PageBordersHandler::lcl_attribute( Id eName, Value& rVal )
{
int nIntValue = rVal.getInt( );
switch ( eName )
@@ -65,7 +68,7 @@ void PageBordersHandler::attribute( Id eName, Value& rVal )
}
}
-void PageBordersHandler::sprm( Sprm& rSprm )
+void PageBordersHandler::lcl_sprm( Sprm& rSprm )
{
switch ( rSprm.getId( ) )
{
diff --git a/writerfilter/source/dmapper/PageBordersHandler.hxx b/writerfilter/source/dmapper/PageBordersHandler.hxx
index 327ccfc4f8d6..621f239b3038 100644
--- a/writerfilter/source/dmapper/PageBordersHandler.hxx
+++ b/writerfilter/source/dmapper/PageBordersHandler.hxx
@@ -5,7 +5,7 @@
#include "PropertyMap.hxx"
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
#include <com/sun/star/table/BorderLine.hpp>
@@ -27,7 +27,7 @@ public:
~_PgBorder( );
};
-class WRITERFILTER_DLLPRIVATE PageBordersHandler : public Properties
+class WRITERFILTER_DLLPRIVATE PageBordersHandler : public LoggedProperties
{
private:
@@ -36,14 +36,14 @@ private:
sal_Int32 m_nOffset;
vector<_PgBorder> m_aBorders;
+ // Properties
+ virtual void lcl_attribute( Id eName, Value& rVal );
+ virtual void lcl_sprm( Sprm& rSprm );
+
public:
PageBordersHandler( );
~PageBordersHandler( );
- // Properties
- virtual void attribute( Id eName, Value& rVal );
- virtual void sprm( Sprm& rSprm );
-
inline sal_Int32 GetDisplayOffset( )
{
return ( m_nOffset << 5 ) + m_nDisplay;
diff --git a/writerfilter/source/dmapper/PropertyIds.hxx b/writerfilter/source/dmapper/PropertyIds.hxx
index 2066cf58f530..33107e7356d3 100644
--- a/writerfilter/source/dmapper/PropertyIds.hxx
+++ b/writerfilter/source/dmapper/PropertyIds.hxx
@@ -32,261 +32,261 @@ namespace rtl{ class OUString;}
namespace writerfilter {
namespace dmapper{
enum PropertyIds
-{
+ {
PROP_ID_START = 1
- /* 1*/ ,PROP_CHAR_WEIGHT = PROP_ID_START
- /* 2*/ ,PROP_CHAR_POSTURE
- /* 3*/ ,PROP_CHAR_STRIKEOUT
- /* 4*/ ,PROP_CHAR_CONTOURED
- /* 5*/ ,PROP_CHAR_SHADOWED
- /* 6*/ ,PROP_CHAR_CASE_MAP
- /* 7*/ ,PROP_CHAR_COLOR
- /* 8*/ ,PROP_CHAR_RELIEF
- /* 9*/ ,PROP_CHAR_UNDERLINE
- /*10*/ ,PROP_CHAR_WORD_MODE
- /*11*/ ,PROP_CHAR_ESCAPEMENT
- /*12*/ ,PROP_CHAR_ESCAPEMENT_HEIGHT
- /*13*/ ,PROP_CHAR_HEIGHT
- /*14*/ ,PROP_CHAR_HEIGHT_COMPLEX
- /*15*/ ,PROP_CHAR_LOCALE
- /*16*/ ,PROP_CHAR_LOCALE_ASIAN
- /*17*/ ,PROP_CHAR_WEIGHT_COMPLEX
- /*18*/ ,PROP_CHAR_POSTURE_COMPLEX
- /*19*/ ,PROP_CHAR_AUTO_KERNING
- /*20*/ ,PROP_CHAR_CHAR_KERNING
- /*21*/ ,PROP_CHAR_SCALE_WIDTH
- /*22*/ ,PROP_CHAR_LOCALE_COMPLEX
- /*23*/ ,PROP_CHAR_UNDERLINE_COLOR
-/*24*/ , PROP_CHAR_UNDERLINE_HAS_COLOR
-/*25*/ , PROP_CHAR_FONT_NAME
-/*26*/ , PROP_CHAR_FONT_STYLE
-/*27*/ , PROP_CHAR_FONT_FAMILY
-/*28*/ , PROP_CHAR_FONT_CHAR_SET
-/*29*/ , PROP_CHAR_FONT_PITCH
-/*30*/ , PROP_CHAR_FONT_NAME_ASIAN
-/*31*/ , PROP_CHAR_HEIGHT_ASIAN
-/*32*/ , PROP_CHAR_FONT_STYLE_ASIAN
-/*33*/ , PROP_CHAR_FONT_FAMILY_ASIAN
-/*34*/ , PROP_CHAR_FONT_CHAR_SET_ASIAN
-/*35*/ , PROP_CHAR_FONT_PITCH_ASIAN
-/*36*/ , PROP_CHAR_FONT_NAME_COMPLEX
-/*37*/ , PROP_CHAR_FONT_STYLE_COMPLEX
-/*38*/ , PROP_CHAR_FONT_FAMILY_COMPLEX
-/*39*/ , PROP_CHAR_FONT_CHAR_SET_COMPLEX
-/*40*/ , PROP_CHAR_FONT_PITCH_COMPLEX
-/*41*/ , PROP_CHAR_HIDDEN
-/*42*/ , PROP_CHAR_WEIGHT_ASIAN
-/*43*/ , PROP_CHAR_POSTURE_ASIAN
-/*44*/ , PROP_PARA_STYLE_NAME
-/*45*/ , PROP_CHAR_STYLE_NAME
-/*46*/ , PROP_PARA_ADJUST
-/*47*/ , PROP_PARA_LAST_LINE_ADJUST
-/*48*/ , PROP_PARA_RIGHT_MARGIN
-/*49*/ , PROP_PARA_LEFT_MARGIN
-/*50*/ , PROP_PARA_FIRST_LINE_INDENT
-/*51*/ , PROP_PARA_KEEP_TOGETHER
-/*52*/ , PROP_PARA_TOP_MARGIN
-/*53*/ , PROP_PARA_BOTTOM_MARGIN
-/*54*/ , PROP_PARA_IS_HYPHENATION
-/*55*/ , PROP_PARA_LINE_NUMBER_COUNT
-/*56*/ , PROP_PARA_IS_HANGING_PUNCTUATION
-/*57*/ , PROP_PARA_LINE_SPACING
-/*58*/ , PROP_PARA_TAB_STOPS
-/*59*/ , PROP_PARA_WIDOWS
-/*60*/ , PROP_PARA_ORPHANS
-/*61*/ , PROP_PARA_LINE_NUMBER_START_VALUE
-/*62*/ , PROP_NUMBERING_LEVEL
-/*63*/ , PROP_NUMBERING_RULES
-/*64*/ , PROP_NUMBERING_TYPE
-/*65*/ , PROP_START_WITH
-/*66*/ , PROP_ADJUST
-/*67*/ , PROP_PARENT_NUMBERING
-/*68*/ , PROP_LEFT_MARGIN
-/*69*/ , PROP_RIGHT_MARGIN
-/*70*/ , PROP_TOP_MARGIN
-/*71*/ , PROP_BOTTOM_MARGIN
-/*72*/ , PROP_FIRST_LINE_OFFSET
-/*73*/ , PROP_LEFT_BORDER
-/*74*/ , PROP_RIGHT_BORDER
-/*75*/ , PROP_TOP_BORDER
-/*76*/ , PROP_BOTTOM_BORDER
-/*77*/ , PROP_TABLE_BORDER
-/*78*/ , PROP_LEFT_BORDER_DISTANCE
-/*79*/ , PROP_RIGHT_BORDER_DISTANCE
-/*80*/ , PROP_TOP_BORDER_DISTANCE
-/*81*/ , PROP_BOTTOM_BORDER_DISTANCE
-/*82*/ , PROP_CURRENT_PRESENTATION
-/*83*/ , PROP_IS_FIXED
-/*84*/ , PROP_SUB_TYPE
-/*85*/ , PROP_FILE_FORMAT
-/*86*/ , PROP_HYPER_LINK_U_R_L
-/*87*/ , PROP_NUMBER_FORMAT
-/*88*/ , PROP_NAME
-/*89*/ , PROP_IS_INPUT
-/*90*/ , PROP_HINT
-/*91*/ , PROP_FULL_NAME
-/*92*/ , PROP_KEYWORDS
-/*93*/ , PROP_DESCRIPTION
-/*94*/ , PROP_MACRO_NAME
-/*95*/ , PROP_SUBJECT
-/*96*/ , PROP_USER_DATA_TYPE
-/*97*/ , PROP_TITLE
-/*98*/ , PROP_CONTENT
-/*99*/ , PROP_DATA_COLUMN_NAME
-/*100*/, PROP_INPUT_STREAM
-/*101*/, PROP_GRAPHIC
-/*102*/, PROP_ANCHOR_TYPE
-/*103*/ ,PROP_SIZE
-/*104*/ ,PROP_HORI_ORIENT
-/*105*/ ,PROP_HORI_ORIENT_POSITION
-/*106*/ ,PROP_HORI_ORIENT_RELATION
-/*107*/ ,PROP_VERT_ORIENT
-/*108*/ ,PROP_VERT_ORIENT_POSITION
-/*109*/ ,PROP_VERT_ORIENT_RELATION
-/*110*/ ,PROP_GRAPHIC_CROP
-/*111*/ ,PROP_SIZE100th_M_M
-/*112*/ ,PROP_SIZE_PIXEL
-/*113*/ ,PROP_SURROUND
-/*114*/ ,PROP_SURROUND_CONTOUR
-/*115*/ ,PROP_ADJUST_CONTRAST
-/*116*/ ,PROP_ADJUST_LUMINANCE
-/*117*/ ,PROP_GRAPHIC_COLOR_MODE
-/*118*/ ,PROP_GAMMA
-/*119*/ ,PROP_HORI_MIRRORED_ON_EVEN_PAGES
-/*120*/ ,PROP_HORI_MIRRORED_ON_ODD_PAGES
-/*121*/ ,PROP_VERT_MIRRORED
-/*122*/ ,PROP_CONTOUR_OUTSIDE
-/*123*/ ,PROP_CONTOUR_POLY_POLYGON
-/*124*/ ,PROP_PAGE_TOGGLE
-/*125*/ ,PROP_BACK_COLOR
-/*126*/ ,PROP_ALTERNATIVE_TEXT
-/*127*/ ,PROP_HEADER_TEXT_LEFT
-/*128*/ ,PROP_HEADER_TEXT
-/*129*/ ,PROP_HEADER_IS_SHARED
-/*130*/ ,PROP_HEADER_IS_ON
-/*131*/ ,PROP_FOOTER_TEXT_LEFT
-/*132*/ ,PROP_FOOTER_TEXT
-/*133*/ ,PROP_FOOTER_IS_SHARED
-/*134*/ ,PROP_FOOTER_IS_ON
-/*135*/ ,PROP_WIDTH
-/*136*/ ,PROP_HEIGHT
-/*137*/ ,PROP_SEPARATOR_LINE_IS_ON
-/*138*/ ,PROP_TEXT_COLUMNS
-/*139*/ ,PROP_AUTOMATIC_DISTANCE
-/*140*/ ,PROP_IS_LANDSCAPE
-/*141*/ ,PROP_PRINTER_PAPER_TRAY_INDEX
-/*142*/ ,PROP_FIRST_PAGE
-/*143*/ ,PROP_DEFAULT
-/*144*/ ,PROP_PAGE_DESC_NAME
-/*145*/ ,PROP_PAGE_NUMBER_OFFSET
-/*146*/ ,PROP_BREAK_TYPE
-/*147*/ ,PROP_FOOTER_IS_DYNAMIC_HEIGHT
-/*148*/ ,PROP_FOOTER_DYNAMIC_SPACING
-/*149*/ ,PROP_FOOTER_HEIGHT
-/*150*/ ,PROP_FOOTER_BODY_DISTANCE
-/*151*/ ,PROP_HEADER_IS_DYNAMIC_HEIGHT
-/*152*/ ,PROP_HEADER_DYNAMIC_SPACING
-/*153*/ ,PROP_HEADER_HEIGHT
-/*154*/ ,PROP_HEADER_BODY_DISTANCE
-/*155*/ ,PROP_WRITING_MODE
-/*156*/ ,PROP_GRID_MODE
-/*157*/ ,PROP_GRID_DISPLAY
-/*158*/ ,PROP_GRID_PRINT
-/*159*/ ,PROP_ADD_EXTERNAL_LEADING
-/*160*/ ,PROP_GRID_LINES
-/*161*/ ,PROP_GRID_BASE_HEIGHT
-/*162*/ ,PROP_GRID_RUBY_HEIGHT
-/*163*/ ,PROP_IS_ON
-/*164*/ ,PROP_RESTART_AT_EACH_PAGE
-/*165*/ ,PROP_COUNT_EMPTY_LINES
-/*166*/ ,PROP_COUNT_LINES_IN_FRAMES
-/*167*/ ,PROP_INTERVAL
-/*168*/ ,PROP_DISTANCE
-/*169*/ ,PROP_NUMBER_POSITION
-/*170*/ ,PROP_LEVEL
-/*171*/ ,PROP_LEVEL_PARAGRAPH_STYLES
-/*172*/ ,PROP_LEVEL_FORMAT
-/*173*/ ,PROP_TOKEN_TYPE
-/*174*/ ,PROP_TOKEN_HYPERLINK_START
-/*175*/ ,PROP_TOKEN_HYPERLINK_END
-/*176*/ ,PROP_TOKEN_CHAPTER_INFO
-/*177*/ ,PROP_CHAPTER_FORMAT
-/*178*/ ,PROP_TOKEN_TEXT
-/*179*/ ,PROP_TEXT
-/*180*/ ,PROP_CREATE_FROM_OUTLINE
-/*181*/ ,PROP_CREATE_FROM_MARKS
-/*182*/ ,PROP_STANDARD
-/*183*/ ,PROP_CHAR_BACK_COLOR
-/*184*/ ,PROP_CHAR_EMPHASIS
-/*185*/ ,PROP_CHAR_COMBINE_IS_ON
-/*186*/ ,PROP_CHAR_COMBINE_PREFIX
-/*187*/ ,PROP_CHAR_COMBINE_SUFFIX
-/*188*/ ,PROP_CHAR_ROTATION
-/*189*/ ,PROP_CHAR_ROTATION_IS_FIT_TO_LINE
-/*190*/ ,PROP_CHAR_FLASH
-/*191*/ ,PROP_IS_SPLIT_ALLOWED
-/*192*/ ,META_PROP_VERTICAL_BORDER
-/*193*/ ,META_PROP_HORIZONTAL_BORDER
-/*194*/ ,PROP_HEADER_ROW_COUNT
-/*195*/ ,PROP_IS_AUTO_HEIGHT
-/*196*/ ,PROP_SIZE_TYPE
-/*197*/ ,PROP_TABLE_COLUMN_SEPARATORS
-/*198*/ ,META_PROP_TABLE_STYLE_NAME
-/*199*/ ,PROP_REDLINE_AUTHOR
-/*200*/ ,PROP_REDLINE_DATE_TIME
-/*201*/ ,PROP_REDLINE_COMMENT
-/*202*/ ,PROP_REDLINE_TYPE
-/*203*/ ,PROP_REDLINE_SUCCESSOR_DATA
-/*204*/ ,PROP_REDLINE_IDENTIFIER
-/*205*/ ,PROP_SIZE_PROTECTED
-/*206*/ ,PROP_POSITION_PROTECTED
-/*207*/ ,PROP_OPAQUE
-/*208*/ ,PROP_VERTICAL_MERGE
-/*209*/ ,PROP_BULLET_CHAR
-/*210*/ ,PROP_BULLET_FONT_NAME
-/*211*/ ,PROP_PARA_BACK_COLOR
-/*212*/ ,PROP_TABS_RELATIVE_TO_INDENT
-/*213*/ ,PROP_PREFIX
-/*214*/ ,PROP_SUFFIX
-/*215*/ ,PROP_CREATE_FROM_LEVEL_PARAGRAPH_STYLES
-/*216*/ ,PROP_DROP_CAP_FORMAT
-/*217*/ , PROP_REFERENCE_FIELD_PART
-/*218*/ ,PROP_SOURCE_NAME
-/*219*/ ,PROP_REFERENCE_FIELD_SOURCE
-/*220*/ ,PROP_WIDTH_TYPE
-/*221*/ ,PROP_TEXT_RANGE
-/*222*/ ,PROP_SERVICE_CHAR_STYLE
-/*223*/ ,PROP_SERVICE_PARA_STYLE
-/*224*/ ,PROP_CHARACTER_STYLES
-/*225*/ ,PROP_PARAGRAPH_STYLES
-/*226*/ ,PROP_TABLE_BORDER_DISTANCES
-/*227*/ ,META_PROP_CELL_MAR_TOP
-/*228*/ ,META_PROP_CELL_MAR_BOTTOM
-/*229*/ ,META_PROP_CELL_MAR_LEFT
-/*230*/ ,META_PROP_CELL_MAR_RIGHT
-/*231*/ ,PROP_START_AT
-/*232*/ ,PROP_ADD_PARA_TABLE_SPACING
-/*233*/ ,PROP_CHAR_PROP_HEIGHT
-/*234*/ ,PROP_CHAR_PROP_HEIGHT_ASIAN
-/*235*/ ,PROP_CHAR_PROP_HEIGHT_COMPLEX
-/*236*/ ,PROP_FORMAT
-/*237*/ ,PROP_INSERT
-/*238*/ ,PROP_DELETE
-/*239*/ ,PROP_STREAM_NAME
-/*240*/ ,PROP_BITMAP
-/*241*/ ,PROP_IS_DATE
-/*242*/ ,PROP_TAB_STOP_DISTANCE
-/*243*/ ,PROP_CNF_STYLE
-/*244*/ ,PROP_INDENT_AT
-/*245*/ ,PROP_FIRST_LINE_INDENT
-/*246*/ ,PROP_NUMBERING_STYLE_NAME
-/*247*/ ,PROP_OUTLINE_LEVEL
-/*248*/ ,PROP_LISTTAB_STOP_POSITION
-/*249*/ ,PROP_POSITION_AND_SPACE_MODE
-/*250*/ ,PROP_HEADING_STYLE_NAME
-/*251*/ ,PROP_PARA_SPLIT
-/*252*/ ,PROP_HELP
-};
+ ,META_PROP_CELL_MAR_BOTTOM = PROP_ID_START
+ ,META_PROP_CELL_MAR_LEFT
+ ,META_PROP_CELL_MAR_RIGHT
+ ,META_PROP_CELL_MAR_TOP
+ ,META_PROP_HORIZONTAL_BORDER
+ ,META_PROP_TABLE_STYLE_NAME
+ ,META_PROP_VERTICAL_BORDER
+ ,PROP_ADD_EXTERNAL_LEADING
+ ,PROP_ADD_PARA_TABLE_SPACING
+ ,PROP_ADJUST
+ ,PROP_ADJUST_CONTRAST
+ ,PROP_ADJUST_LUMINANCE
+ ,PROP_ALTERNATIVE_TEXT
+ ,PROP_ANCHOR_TYPE
+ ,PROP_AUTOMATIC_DISTANCE
+ ,PROP_BACK_COLOR
+ ,PROP_BITMAP
+ ,PROP_BOTTOM_BORDER
+ ,PROP_BOTTOM_BORDER_DISTANCE
+ ,PROP_BOTTOM_MARGIN
+ ,PROP_BREAK_TYPE
+ ,PROP_BULLET_CHAR
+ ,PROP_BULLET_FONT_NAME
+ ,PROP_CHAPTER_FORMAT
+ ,PROP_CHARACTER_STYLES
+ ,PROP_CHAR_AUTO_KERNING
+ ,PROP_CHAR_BACK_COLOR
+ ,PROP_CHAR_CASE_MAP
+ ,PROP_CHAR_CHAR_KERNING
+ ,PROP_CHAR_COLOR
+ ,PROP_CHAR_COMBINE_IS_ON
+ ,PROP_CHAR_COMBINE_PREFIX
+ ,PROP_CHAR_COMBINE_SUFFIX
+ ,PROP_CHAR_CONTOURED
+ ,PROP_CHAR_EMPHASIS
+ ,PROP_CHAR_ESCAPEMENT
+ ,PROP_CHAR_ESCAPEMENT_HEIGHT
+ ,PROP_CHAR_FLASH
+ ,PROP_CHAR_FONT_CHAR_SET
+ ,PROP_CHAR_FONT_CHAR_SET_ASIAN
+ ,PROP_CHAR_FONT_CHAR_SET_COMPLEX
+ ,PROP_CHAR_FONT_FAMILY
+ ,PROP_CHAR_FONT_FAMILY_ASIAN
+ ,PROP_CHAR_FONT_FAMILY_COMPLEX
+ ,PROP_CHAR_FONT_NAME
+ ,PROP_CHAR_FONT_NAME_ASIAN
+ ,PROP_CHAR_FONT_NAME_COMPLEX
+ ,PROP_CHAR_FONT_PITCH
+ ,PROP_CHAR_FONT_PITCH_ASIAN
+ ,PROP_CHAR_FONT_PITCH_COMPLEX
+ ,PROP_CHAR_FONT_STYLE
+ ,PROP_CHAR_FONT_STYLE_ASIAN
+ ,PROP_CHAR_FONT_STYLE_COMPLEX
+ ,PROP_CHAR_HEIGHT
+ ,PROP_CHAR_HEIGHT_ASIAN
+ ,PROP_CHAR_HEIGHT_COMPLEX
+ ,PROP_CHAR_HIDDEN
+ ,PROP_CHAR_LOCALE
+ ,PROP_CHAR_LOCALE_ASIAN
+ ,PROP_CHAR_LOCALE_COMPLEX
+ ,PROP_CHAR_POSTURE
+ ,PROP_CHAR_POSTURE_ASIAN
+ ,PROP_CHAR_POSTURE_COMPLEX
+ ,PROP_CHAR_PROP_HEIGHT
+ ,PROP_CHAR_PROP_HEIGHT_ASIAN
+ ,PROP_CHAR_PROP_HEIGHT_COMPLEX
+ ,PROP_CHAR_RELIEF
+ ,PROP_CHAR_ROTATION
+ ,PROP_CHAR_ROTATION_IS_FIT_TO_LINE
+ ,PROP_CHAR_SCALE_WIDTH
+ ,PROP_CHAR_SHADOWED
+ ,PROP_CHAR_STRIKEOUT
+ ,PROP_CHAR_STYLE_NAME
+ ,PROP_CHAR_UNDERLINE
+ ,PROP_CHAR_UNDERLINE_COLOR
+ ,PROP_CHAR_UNDERLINE_HAS_COLOR
+ ,PROP_CHAR_WEIGHT
+ ,PROP_CHAR_WEIGHT_ASIAN
+ ,PROP_CHAR_WEIGHT_COMPLEX
+ ,PROP_CHAR_WORD_MODE
+ ,PROP_CNF_STYLE
+ ,PROP_CONTENT
+ ,PROP_CONTOUR_OUTSIDE
+ ,PROP_CONTOUR_POLY_POLYGON
+ ,PROP_COUNT_EMPTY_LINES
+ ,PROP_COUNT_LINES_IN_FRAMES
+ ,PROP_CREATE_FROM_LEVEL_PARAGRAPH_STYLES
+ ,PROP_CREATE_FROM_MARKS
+ ,PROP_CREATE_FROM_OUTLINE
+ ,PROP_CURRENT_PRESENTATION
+ ,PROP_DATA_COLUMN_NAME
+ ,PROP_DEFAULT
+ ,PROP_DELETE
+ ,PROP_DESCRIPTION
+ ,PROP_DISTANCE
+ ,PROP_DROP_CAP_FORMAT
+ ,PROP_FILE_FORMAT
+ ,PROP_FIRST_LINE_INDENT
+ ,PROP_FIRST_LINE_OFFSET
+ ,PROP_FIRST_PAGE
+ ,PROP_FOOTER_BODY_DISTANCE
+ ,PROP_FOOTER_DYNAMIC_SPACING
+ ,PROP_FOOTER_HEIGHT
+ ,PROP_FOOTER_IS_DYNAMIC_HEIGHT
+ ,PROP_FOOTER_IS_ON
+ ,PROP_FOOTER_IS_SHARED
+ ,PROP_FOOTER_TEXT
+ ,PROP_FOOTER_TEXT_LEFT
+ ,PROP_FORMAT
+ ,PROP_FULL_NAME
+ ,PROP_GAMMA
+ ,PROP_GRAPHIC
+ ,PROP_GRAPHIC_COLOR_MODE
+ ,PROP_GRAPHIC_CROP
+ ,PROP_GRID_BASE_HEIGHT
+ ,PROP_GRID_DISPLAY
+ ,PROP_GRID_LINES
+ ,PROP_GRID_MODE
+ ,PROP_GRID_PRINT
+ ,PROP_GRID_RUBY_HEIGHT
+ ,PROP_HEADER_BODY_DISTANCE
+ ,PROP_HEADER_DYNAMIC_SPACING
+ ,PROP_HEADER_HEIGHT
+ ,PROP_HEADER_IS_DYNAMIC_HEIGHT
+ ,PROP_HEADER_IS_ON
+ ,PROP_HEADER_IS_SHARED
+ ,PROP_HEADER_ROW_COUNT
+ ,PROP_HEADER_TEXT
+ ,PROP_HEADER_TEXT_LEFT
+ ,PROP_HEADING_STYLE_NAME
+ ,PROP_HEIGHT
+ ,PROP_HELP
+ ,PROP_HINT
+ ,PROP_HORI_MIRRORED_ON_EVEN_PAGES
+ ,PROP_HORI_MIRRORED_ON_ODD_PAGES
+ ,PROP_HORI_ORIENT
+ ,PROP_HORI_ORIENT_POSITION
+ ,PROP_HORI_ORIENT_RELATION
+ ,PROP_HYPER_LINK_U_R_L
+ ,PROP_INDENT_AT
+ ,PROP_INPUT_STREAM
+ ,PROP_INSERT
+ ,PROP_INTERVAL
+ ,PROP_IS_AUTO_HEIGHT
+ ,PROP_IS_DATE
+ ,PROP_IS_FIXED
+ ,PROP_IS_INPUT
+ ,PROP_IS_LANDSCAPE
+ ,PROP_IS_ON
+ ,PROP_IS_SPLIT_ALLOWED
+ ,PROP_KEYWORDS
+ ,PROP_LEFT_BORDER
+ ,PROP_LEFT_BORDER_DISTANCE
+ ,PROP_LEFT_MARGIN
+ ,PROP_LEVEL
+ ,PROP_LEVEL_FORMAT
+ ,PROP_LEVEL_PARAGRAPH_STYLES
+ ,PROP_LISTTAB_STOP_POSITION
+ ,PROP_MACRO_NAME
+ ,PROP_NAME
+ ,PROP_NUMBERING_LEVEL
+ ,PROP_NUMBERING_RULES
+ ,PROP_NUMBERING_STYLE_NAME
+ ,PROP_NUMBERING_TYPE
+ ,PROP_NUMBER_FORMAT
+ ,PROP_NUMBER_POSITION
+ ,PROP_OPAQUE
+ ,PROP_OUTLINE_LEVEL
+ ,PROP_PAGE_DESC_NAME
+ ,PROP_PAGE_NUMBER_OFFSET
+ ,PROP_PAGE_TOGGLE
+ ,PROP_PARAGRAPH_STYLES
+ ,PROP_PARA_ADJUST
+ ,PROP_PARA_BACK_COLOR
+ ,PROP_PARA_BOTTOM_MARGIN
+ ,PROP_PARA_FIRST_LINE_INDENT
+ ,PROP_PARA_IS_HANGING_PUNCTUATION
+ ,PROP_PARA_IS_HYPHENATION
+ ,PROP_PARA_KEEP_TOGETHER
+ ,PROP_PARA_LAST_LINE_ADJUST
+ ,PROP_PARA_LEFT_MARGIN
+ ,PROP_PARA_LINE_NUMBER_COUNT
+ ,PROP_PARA_LINE_NUMBER_START_VALUE
+ ,PROP_PARA_LINE_SPACING
+ ,PROP_PARA_ORPHANS
+ ,PROP_PARA_RIGHT_MARGIN
+ ,PROP_PARA_SPLIT
+ ,PROP_PARA_STYLE_NAME
+ ,PROP_PARA_TAB_STOPS
+ ,PROP_PARA_TOP_MARGIN
+ ,PROP_PARA_WIDOWS
+ ,PROP_PARENT_NUMBERING
+ ,PROP_POSITION_AND_SPACE_MODE
+ ,PROP_POSITION_PROTECTED
+ ,PROP_PREFIX
+ ,PROP_PRINTER_PAPER_TRAY_INDEX
+ ,PROP_REDLINE_AUTHOR
+ ,PROP_REDLINE_COMMENT
+ ,PROP_REDLINE_DATE_TIME
+ ,PROP_REDLINE_IDENTIFIER
+ ,PROP_REDLINE_SUCCESSOR_DATA
+ ,PROP_REDLINE_TYPE
+ ,PROP_REFERENCE_FIELD_PART
+ ,PROP_REFERENCE_FIELD_SOURCE
+ ,PROP_RESTART_AT_EACH_PAGE
+ ,PROP_RIGHT_BORDER
+ ,PROP_RIGHT_BORDER_DISTANCE
+ ,PROP_RIGHT_MARGIN
+ ,PROP_SEPARATOR_LINE_IS_ON
+ ,PROP_SERVICE_CHAR_STYLE
+ ,PROP_SERVICE_PARA_STYLE
+ ,PROP_SIZE
+ ,PROP_SIZE100th_M_M
+ ,PROP_SIZE_PIXEL
+ ,PROP_SIZE_PROTECTED
+ ,PROP_SIZE_TYPE
+ ,PROP_SOURCE_NAME
+ ,PROP_STANDARD
+ ,PROP_START_AT
+ ,PROP_START_WITH
+ ,PROP_STREAM_NAME
+ ,PROP_SUBJECT
+ ,PROP_SUB_TYPE
+ ,PROP_SUFFIX
+ ,PROP_SURROUND
+ ,PROP_SURROUND_CONTOUR
+ ,PROP_TABLE_BORDER
+ ,PROP_TABLE_BORDER_DISTANCES
+ ,PROP_TABLE_COLUMN_SEPARATORS
+ ,PROP_TABS_RELATIVE_TO_INDENT
+ ,PROP_TAB_STOP_DISTANCE
+ ,PROP_TEXT
+ ,PROP_TEXT_COLUMNS
+ ,PROP_TEXT_RANGE
+ ,PROP_TITLE
+ ,PROP_TOKEN_CHAPTER_INFO
+ ,PROP_TOKEN_HYPERLINK_END
+ ,PROP_TOKEN_HYPERLINK_START
+ ,PROP_TOKEN_TEXT
+ ,PROP_TOKEN_TYPE
+ ,PROP_TOP_BORDER
+ ,PROP_TOP_BORDER_DISTANCE
+ ,PROP_TOP_MARGIN
+ ,PROP_USER_DATA_TYPE
+ ,PROP_VERTICAL_MERGE
+ ,PROP_VERT_MIRRORED
+ ,PROP_VERT_ORIENT
+ ,PROP_VERT_ORIENT_POSITION
+ ,PROP_VERT_ORIENT_RELATION
+ ,PROP_WIDTH
+ ,PROP_WIDTH_TYPE
+ ,PROP_WRITING_MODE
+ };
struct PropertyNameSupplier_Impl;
class PropertyNameSupplier
{
diff --git a/writerfilter/source/dmapper/PropertyMap.cxx b/writerfilter/source/dmapper/PropertyMap.cxx
index 11930fb01972..f8dcb0592cee 100644
--- a/writerfilter/source/dmapper/PropertyMap.cxx
+++ b/writerfilter/source/dmapper/PropertyMap.cxx
@@ -112,13 +112,43 @@ uno::Sequence< beans::PropertyValue > PropertyMap::GetPropertyValues()
}
return m_aValues;
}
-/*-------------------------------------------------------------------------
- -----------------------------------------------------------------------*/
+void lcl_AnyToTag(XMLTag::Pointer_t pTag, const uno::Any & rAny)
+{
+ try {
+ sal_Int32 aInt = 0;
+ rAny >>= aInt;
+ pTag->addAttr("value", aInt);
+
+ sal_uInt32 auInt = 0;
+ rAny >>= auInt;
+ pTag->addAttr("unsignedValue", auInt);
+
+ float aFloat = 0.0f;
+ rAny >>= aFloat;
+ pTag->addAttr("floatValue", aFloat);
+
+ ::rtl::OUString aStr;
+ rAny >>= aStr;
+ pTag->addAttr("stringValue", aStr);
+ }
+ catch (...) {
+ }
+}
+
void PropertyMap::Insert( PropertyIds eId, bool bIsTextProperty, const uno::Any& rAny, bool bOverwrite )
{
-// const ::rtl::OUString& rInsert = PropertyNameSupplier::
-// GetPropertyNameSupplier().GetName(eId);
+#ifdef DEBUG_DMAPPER_PROPERTY_MAP
+ const ::rtl::OUString& rInsert = PropertyNameSupplier::
+ GetPropertyNameSupplier().GetName(eId);
+
+ XMLTag::Pointer_t pTag(new XMLTag("propertyMap.insert"));
+ pTag->addAttr("name", rInsert);
+ lcl_AnyToTag(pTag, rAny);
+
+ dmapper_logger->addTag(pTag);
+#endif
+
PropertyMap::iterator aElement = find(PropertyDefinition( eId, bIsTextProperty ) );
if( aElement != end())
{
@@ -132,7 +162,6 @@ void PropertyMap::Insert( PropertyIds eId, bool bIsTextProperty, const uno::Any&
Invalidate();
}
-#ifdef DEBUG_DOMAINMAPPER
XMLTag::Pointer_t PropertyMap::toTag() const
{
XMLTag::Pointer_t pResult(new XMLTag("PropertyMap"));
@@ -153,15 +182,15 @@ XMLTag::Pointer_t PropertyMap::toTag() const
default:
{
try {
- sal_Int32 aInt;
+ sal_Int32 aInt = 0;
aMapIter->second >>= aInt;
pTag->addAttr("value", aInt);
- sal_uInt32 auInt;
+ sal_uInt32 auInt = 0;
aMapIter->second >>= auInt;
pTag->addAttr("unsignedValue", auInt);
- float aFloat;
+ float aFloat = 0.0;
aMapIter->second >>= aFloat;
pTag->addAttr("floatValue", aFloat);
@@ -182,7 +211,6 @@ XMLTag::Pointer_t PropertyMap::toTag() const
return pResult;
}
-#endif
/*-- 13.12.2006 10:46:42---------------------------------------------------
diff --git a/writerfilter/source/dmapper/PropertyMap.hxx b/writerfilter/source/dmapper/PropertyMap.hxx
index 16886530f324..b6dcad6d63b2 100644
--- a/writerfilter/source/dmapper/PropertyMap.hxx
+++ b/writerfilter/source/dmapper/PropertyMap.hxx
@@ -39,9 +39,7 @@
#include <map>
#include <vector>
-#ifdef DEBUG_DOMAINMAPPER
#include <resourcemodel/TagLogger.hxx>
-#endif
namespace com{namespace sun{namespace star{
namespace beans{
@@ -136,10 +134,7 @@ public:
virtual void insertTableProperties( const PropertyMap* );
-#ifdef DEBUG_DOMAINMAPPER
virtual XMLTag::Pointer_t toTag() const;
-#endif
-
};
typedef boost::shared_ptr<PropertyMap> PropertyMapPtr;
diff --git a/writerfilter/source/dmapper/PropertyMapHelper.cxx b/writerfilter/source/dmapper/PropertyMapHelper.cxx
index 4fb4c759289d..3496c5e04f44 100644
--- a/writerfilter/source/dmapper/PropertyMapHelper.cxx
+++ b/writerfilter/source/dmapper/PropertyMapHelper.cxx
@@ -32,7 +32,6 @@
#include <resourcemodel/TagLogger.hxx>
#include "PropertyMapHelper.hxx"
-#ifdef DEBUG
namespace writerfilter
{
namespace dmapper
@@ -128,4 +127,3 @@ XMLTag::Pointer_t lcl_PropertyValueSeqSeqToTag(PropertyValueSeqSeq_t rPropValSeq
}
}
-#endif // DEBUG
diff --git a/writerfilter/source/dmapper/PropertyMapHelper.hxx b/writerfilter/source/dmapper/PropertyMapHelper.hxx
index 4a528f1736c0..fc9ea0a85bb4 100644
--- a/writerfilter/source/dmapper/PropertyMapHelper.hxx
+++ b/writerfilter/source/dmapper/PropertyMapHelper.hxx
@@ -28,7 +28,6 @@
*
************************************************************************/
-#ifdef DEBUG
#include "PropertyMap.hxx"
#include <com/sun/star/beans/PropertyValues.hpp>
@@ -47,4 +46,3 @@ typedef uno::Sequence<PropertyValueSeq_t> PropertyValueSeqSeq_t;
XMLTag::Pointer_t lcl_PropertyValueSeqSeqToTag(PropertyValueSeqSeq_t & rPropValSeqSeq);
}
}
-#endif // DEBUG
diff --git a/writerfilter/source/dmapper/SectionColumnHandler.cxx b/writerfilter/source/dmapper/SectionColumnHandler.cxx
index 5ad3e51fb8b7..e00b0c7558fa 100644
--- a/writerfilter/source/dmapper/SectionColumnHandler.cxx
+++ b/writerfilter/source/dmapper/SectionColumnHandler.cxx
@@ -30,6 +30,8 @@
#include <ConversionHelper.hxx>
#include <ooxml/resourceids.hxx>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper {
@@ -40,10 +42,11 @@ using namespace ::com::sun::star;
-----------------------------------------------------------------------*/
SectionColumnHandler::SectionColumnHandler() :
- bEqualWidth( false ),
- nSpace( 0 ),
- nNum( 0 ),
- bSep( false )
+LoggedProperties(dmapper_logger, "SectionColumnHandler"),
+bEqualWidth( false ),
+nSpace( 0 ),
+nNum( 0 ),
+bSep( false )
{
}
/*-- 02.06.2008 13:36:24---------------------------------------------------
@@ -55,7 +58,7 @@ SectionColumnHandler::~SectionColumnHandler()
/*-- 02.06.2008 13:36:24---------------------------------------------------
-----------------------------------------------------------------------*/
-void SectionColumnHandler::attribute(Id rName, Value & rVal)
+void SectionColumnHandler::lcl_attribute(Id rName, Value & rVal)
{
sal_Int32 nIntValue = rVal.getInt();
/* WRITERFILTERSTATUS: table: SectionColumnHandler_attributedata */
@@ -93,7 +96,7 @@ void SectionColumnHandler::attribute(Id rName, Value & rVal)
/*-- 02.06.2008 13:36:24---------------------------------------------------
-----------------------------------------------------------------------*/
-void SectionColumnHandler::sprm(Sprm & rSprm)
+void SectionColumnHandler::lcl_sprm(Sprm & rSprm)
{
/* WRITERFILTERSTATUS: table: SectionColumnHandler_sprm */
switch( rSprm.getId())
diff --git a/writerfilter/source/dmapper/SectionColumnHandler.hxx b/writerfilter/source/dmapper/SectionColumnHandler.hxx
index 452895b50194..7742f5d4a22b 100644
--- a/writerfilter/source/dmapper/SectionColumnHandler.hxx
+++ b/writerfilter/source/dmapper/SectionColumnHandler.hxx
@@ -28,7 +28,7 @@
#define INCLUDED_SECTIONCOLUMNHANDLER_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
@@ -44,7 +44,7 @@ struct _Column
};
-class WRITERFILTER_DLLPRIVATE SectionColumnHandler : public Properties
+class WRITERFILTER_DLLPRIVATE SectionColumnHandler : public LoggedProperties
{
bool bEqualWidth;
sal_Int32 nSpace;
@@ -54,14 +54,14 @@ class WRITERFILTER_DLLPRIVATE SectionColumnHandler : public Properties
_Column aTempColumn;
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
SectionColumnHandler();
virtual ~SectionColumnHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
bool IsEqualWidth() const { return bEqualWidth; }
sal_Int32 GetSpace() const { return nSpace; }
sal_Int32 GetNum() const { return nNum; }
diff --git a/writerfilter/source/dmapper/SettingsTable.cxx b/writerfilter/source/dmapper/SettingsTable.cxx
index e711240b65d0..6065d33ddb17 100644
--- a/writerfilter/source/dmapper/SettingsTable.cxx
+++ b/writerfilter/source/dmapper/SettingsTable.cxx
@@ -28,20 +28,17 @@
*
************************************************************************/
+#include <stdio.h>
+#include <rtl/ustring.hxx>
#include <resourcemodel/ResourceModelHelper.hxx>
#include <com/sun/star/beans/XPropertySet.hpp>
-
#include <SettingsTable.hxx>
+#include <resourcemodel/ResourceModelHelper.hxx>
#include <doctok/resourceids.hxx>
#include <ooxml/resourceids.hxx>
-#include <stdio.h>
#include <ConversionHelper.hxx>
-#include <rtl/ustring.hxx>
-#ifdef DEBUG_DOMAINMAPPER
-#include <resourcemodel/QNameToString.hxx>
#include "dmapperLoggers.hxx"
-#endif
namespace writerfilter {
@@ -97,10 +94,13 @@ struct SettingsTable_Impl
, m_nCryptAlgorithmType(NS_ooxml::LN_Value_wordprocessingml_ST_AlgType_typeAny)
, m_nCryptSpinCount(0)
{}
+
};
-SettingsTable::SettingsTable(DomainMapper& rDMapper, const uno::Reference< lang::XMultiServiceFactory > xTextFactory) :
-m_pImpl( new SettingsTable_Impl(rDMapper, xTextFactory) )
+SettingsTable::SettingsTable(DomainMapper& rDMapper, const uno::Reference< lang::XMultiServiceFactory > xTextFactory)
+: LoggedProperties(dmapper_logger, "SettingsTable")
+, LoggedTable(dmapper_logger, "SettingsTable")
+, m_pImpl( new SettingsTable_Impl(rDMapper, xTextFactory) )
{
// printf("SettingsTable::SettingsTable()\n");
}
@@ -110,14 +110,8 @@ SettingsTable::~SettingsTable()
delete m_pImpl;
}
-void SettingsTable::attribute(Id nName, Value & val)
+void SettingsTable::lcl_attribute(Id nName, Value & val)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("SettingsTable.attribute");
- dmapper_logger->attribute("name", (*QNameToString::Instance())(nName));
- dmapper_logger->attribute("value", val.toString());
-#endif
-
(void) nName;
int nIntValue = val.getInt();
(void)nIntValue;
@@ -137,18 +131,10 @@ void SettingsTable::attribute(Id nName, Value & val)
}
}
#endif
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("SettingsTable.attribute");
-#endif
}
-void SettingsTable::sprm(Sprm& rSprm)
+void SettingsTable::lcl_sprm(Sprm& rSprm)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("SettingsTable.sprm");
- dmapper_logger->chars(rSprm.toString());
-#endif
-
sal_uInt32 nSprmId = rSprm.getId();
Value::Pointer_t pValue = rSprm.getValue();
@@ -237,16 +223,14 @@ void SettingsTable::sprm(Sprm& rSprm)
break;
default:
{
- OSL_ENSURE( false, "unknown sprmid in SettingsTable::sprm()");
+#ifdef DEBUG_DMAPPER_SETTINGS_TABLE
+ dmapper_logger->element("unhandled");
+#endif
}
}
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("SettingsTable.sprm");
-#endif
}
-void SettingsTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
+void SettingsTable::lcl_entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
{
// printf ( "SettingsTable::entry\n");
ref->resolve(*this);
diff --git a/writerfilter/source/dmapper/SettingsTable.hxx b/writerfilter/source/dmapper/SettingsTable.hxx
index cb3e7913c5e7..64034c83559b 100755..100644
--- a/writerfilter/source/dmapper/SettingsTable.hxx
+++ b/writerfilter/source/dmapper/SettingsTable.hxx
@@ -32,7 +32,7 @@
#define INCLUDED_SETTINGSTABLE_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <com/sun/star/lang/XComponent.hpp>
#include <com/sun/star/text/XTextDocument.hpp>
#include <map>
@@ -53,7 +53,7 @@ using namespace std;
struct SettingsTable_Impl;
-class WRITERFILTER_DLLPRIVATE SettingsTable : public Properties, public Table
+class WRITERFILTER_DLLPRIVATE SettingsTable : public LoggedProperties, public LoggedTable
{
SettingsTable_Impl *m_pImpl;
@@ -63,18 +63,19 @@ class WRITERFILTER_DLLPRIVATE SettingsTable : public Properties, public Table
);
virtual ~SettingsTable();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
- // Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
//returns default TabStop in 1/100th mm
int GetDefaultTabStop() const;
void ApplyProperties( uno::Reference< text::XTextDocument > xDoc );
+ private:
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
+ // Table
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
+
};
typedef boost::shared_ptr< SettingsTable > SettingsTablePtr;
}}
diff --git a/writerfilter/source/dmapper/StyleSheetTable.cxx b/writerfilter/source/dmapper/StyleSheetTable.cxx
index 5088e8729577..a0d5039a155b 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.cxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.cxx
@@ -47,10 +47,7 @@
#include <stdio.h>
#include <rtl/ustrbuf.hxx>
-#ifdef DEBUG_DOMAINMAPPER
#include <dmapperLoggers.hxx>
-#include <resourcemodel/QNameToString.hxx>
-#endif
using namespace ::com::sun::star;
namespace writerfilter {
@@ -82,32 +79,11 @@ StyleSheetEntry::~StyleSheetEntry()
{
}
-#ifdef DEBUG_DOMAINMAPPER
-XMLTag::Pointer_t StyleSheetEntry::toTag()
-{
- XMLTag::Pointer_t pResult(new XMLTag("StyleSheetEntry"));
-
- pResult->addAttr("identifierI", sStyleIdentifierI);
- pResult->addAttr("identifierD", sStyleIdentifierD);
- pResult->addAttr("default", bIsDefaultStyle ? "true" : "false");
- pResult->addAttr("invalidHeight", bInvalidHeight ? "true" : "false");
- pResult->addAttr("hasUPE", bHasUPE ? "true" : "false");
- pResult->addAttr("styleType", nStyleTypeCode);
- pResult->addAttr("baseStyle", sBaseStyleIdentifier);
- pResult->addAttr("nextStyle", sNextStyleIdentifier);
- pResult->addAttr("styleName", sStyleName);
- pResult->addAttr("styleName1", sStyleName1);
- pResult->addAttr("convertedName", sConvertedStyleName);
- pResult->addTag(pProperties->toTag());
-
- return pResult;
-}
-#endif
-
TableStyleSheetEntry::TableStyleSheetEntry( StyleSheetEntry& rEntry, StyleSheetTable* pStyles ):
StyleSheetEntry( ),
m_pStyleSheet( pStyles )
{
+
bIsDefaultStyle = rEntry.bIsDefaultStyle;
bInvalidHeight = rEntry.bInvalidHeight;
bHasUPE = rEntry.bHasUPE;
@@ -128,13 +104,6 @@ TableStyleSheetEntry::~TableStyleSheetEntry( )
void TableStyleSheetEntry::AddTblStylePr( TblStyleType nType, PropertyMapPtr pProps )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("AddTblStylePr");
- dmapper_logger->attribute("type", nType);
- dmapper_logger->addTag(pProps->toTag());
- dmapper_logger->endElement("AddTblStylePr");
-#endif
-
static TblStyleType pTypesToFix[] =
{
TBL_STYLE_FIRSTROW,
@@ -180,7 +149,7 @@ void TableStyleSheetEntry::AddTblStylePr( TblStyleType nType, PropertyMapPtr pPr
m_aStyles[nType] = pProps;
}
-PropertyMapPtr TableStyleSheetEntry::GetProperties( sal_Int32 nMask )
+PropertyMapPtr TableStyleSheetEntry::GetProperties( sal_Int32 nMask, StyleSheetEntryDequePtr pStack )
{
PropertyMapPtr pProps( new PropertyMap );
@@ -189,8 +158,20 @@ PropertyMapPtr TableStyleSheetEntry::GetProperties( sal_Int32 nMask )
if ( pEntry.get( ) )
{
+ if (pStack.get() == NULL)
+ pStack.reset(new StyleSheetEntryDeque());
+
+ StyleSheetEntryDeque::const_iterator aIt = find(pStack->begin(), pStack->end(), pEntry);
+
+ if (aIt != pStack->end())
+ {
+ pStack->push_back(pEntry);
+
TableStyleSheetEntry* pParent = static_cast<TableStyleSheetEntry *>( pEntry.get( ) );
- pProps->insert( pParent->GetProperties( nMask ) );
+ pProps->insert( pParent->GetProperties( nMask ), pStack );
+
+ pStack->pop_back();
+ }
}
// And finally get the mask ones
@@ -199,24 +180,6 @@ PropertyMapPtr TableStyleSheetEntry::GetProperties( sal_Int32 nMask )
return pProps;
}
-#ifdef DEBUG_DOMAINMAPPER
-XMLTag::Pointer_t TableStyleSheetEntry::toTag()
-{
- XMLTag::Pointer_t pResult(StyleSheetEntry::toTag());
-
- for (sal_Int32 nBit = 0; nBit < 13; ++nBit)
- {
- PropertyMapPtr pMap = GetProperties(1 << nBit);
-
- XMLTag::Pointer_t pTag = pMap->toTag();
- pTag->addAttr("kind", nBit);
- pResult->addTag(pTag);
- }
-
- return pResult;
-}
-#endif
-
void lcl_mergeProps( PropertyMapPtr pToFill, PropertyMapPtr pToAdd, TblStyleType nStyleId )
{
static PropertyIds pPropsToCheck[] =
@@ -398,8 +361,10 @@ StyleSheetTable_Impl::StyleSheetTable_Impl(DomainMapper& rDMapper, uno::Referenc
/*-- 19.06.2006 12:04:32---------------------------------------------------
-----------------------------------------------------------------------*/
-StyleSheetTable::StyleSheetTable(DomainMapper& rDMapper, uno::Reference< text::XTextDocument> xTextDocument) :
- m_pImpl( new StyleSheetTable_Impl(rDMapper, xTextDocument) )
+StyleSheetTable::StyleSheetTable(DomainMapper& rDMapper, uno::Reference< text::XTextDocument> xTextDocument)
+: LoggedProperties(dmapper_logger, "StyleSheetTable")
+, LoggedTable(dmapper_logger, "StyleSheetTable")
+, m_pImpl( new StyleSheetTable_Impl(rDMapper, xTextDocument) )
{
}
/*-- 19.06.2006 12:04:33---------------------------------------------------
@@ -412,14 +377,8 @@ StyleSheetTable::~StyleSheetTable()
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void StyleSheetTable::attribute(Id Name, Value & val)
+void StyleSheetTable::lcl_attribute(Id Name, Value & val)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("StyleSheetTable.attribute");
- dmapper_logger->attribute("name", (*QNameToString::Instance())(Name));
- dmapper_logger->attribute("value", val.toString());
-#endif
-
OSL_ENSURE( m_pImpl->m_pCurrentEntry, "current entry has to be set here");
if(!m_pImpl->m_pCurrentEntry)
return ;
@@ -541,21 +500,12 @@ void StyleSheetTable::attribute(Id Name, Value & val)
}
break;
}
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("StyleSheetTable.attribute");
-#endif
}
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void StyleSheetTable::sprm(Sprm & rSprm)
+void StyleSheetTable::lcl_sprm(Sprm & rSprm)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("StyleSheetTable.sprm");
- dmapper_logger->attribute("sprm", rSprm.toString());
-#endif
-
sal_uInt32 nSprmId = rSprm.getId();
Value::Pointer_t pValue = rSprm.getValue();
sal_Int32 nIntValue = pValue.get() ? pValue->getInt() : 0;
@@ -599,7 +549,7 @@ void StyleSheetTable::sprm(Sprm & rSprm)
break;
case NS_ooxml::LN_CT_Style_tblPr: //contains table properties
case NS_ooxml::LN_CT_Style_tblStylePr: //contains to table properties
- case NS_ooxml::LN_CT_DocDefaults_rPrDefault:
+
case NS_ooxml::LN_CT_TblPrBase_tblInd: //table properties - at least width value and type
case NS_ooxml::LN_EG_RPrBase_rFonts: //table fonts
/* WRITERFILTERSTATUS: done: 100, planned: 0, spent: 0 */
@@ -629,6 +579,7 @@ void StyleSheetTable::sprm(Sprm & rSprm)
break;
}
case NS_ooxml::LN_CT_PPrDefault_pPr:
+ case NS_ooxml::LN_CT_DocDefaults_pPrDefault:
/* WRITERFILTERSTATUS: done: 100, planned: 0, spent: 0 */
m_pImpl->m_rDMapper.PushStyleSheetProperties( m_pImpl->m_pDefaultParaProps );
m_pImpl->m_rDMapper.sprm( rSprm );
@@ -636,6 +587,7 @@ void StyleSheetTable::sprm(Sprm & rSprm)
applyDefaults( true );
break;
case NS_ooxml::LN_CT_RPrDefault_rPr:
+ case NS_ooxml::LN_CT_DocDefaults_rPrDefault:
/* WRITERFILTERSTATUS: done: 100, planned: 0, spent: 0 */
m_pImpl->m_rDMapper.PushStyleSheetProperties( m_pImpl->m_pDefaultCharProps );
m_pImpl->m_rDMapper.sprm( rSprm );
@@ -676,6 +628,7 @@ void StyleSheetTable::sprm(Sprm & rSprm)
pTEntry->m_nColBandSize = nIntValue;
}
}
+ break;
case NS_ooxml::LN_CT_TblPrBase_tblCellMar:
//no cell margins in styles
break;
@@ -697,7 +650,7 @@ void StyleSheetTable::sprm(Sprm & rSprm)
m_pImpl->m_rDMapper.PushStyleSheetProperties( m_pImpl->m_pCurrentEntry->pProperties );
PropertyMapPtr pProps(new PropertyMap());
- m_pImpl->m_rDMapper.sprm( rSprm, pProps );
+ m_pImpl->m_rDMapper.sprmWithProps( rSprm, pProps );
m_pImpl->m_pCurrentEntry->pProperties->insert(pProps);
@@ -705,21 +658,13 @@ void StyleSheetTable::sprm(Sprm & rSprm)
}
}
break;
- }
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("StyleSheetTable.sprm");
-#endif
+}
}
/*-- 19.06.2006 12:04:33---------------------------------------------------
-----------------------------------------------------------------------*/
-void StyleSheetTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
+void StyleSheetTable::lcl_entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("StyleSheetTable.entry");
-#endif
-
//create a new style entry
// printf("StyleSheetTable::entry(...)\n");
OSL_ENSURE( !m_pImpl->m_pCurrentEntry, "current entry has to be NULL here");
@@ -739,16 +684,8 @@ void StyleSheetTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Po
//TODO: this entry contains the default settings - they have to be added to the settings
}
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->addTag(m_pImpl->m_pCurrentEntry->toTag());
-#endif
-
StyleSheetEntryPtr pEmptyEntry;
m_pImpl->m_pCurrentEntry = pEmptyEntry;
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("StyleSheetTable.entry");
-#endif
}
/*-- 21.06.2006 15:34:49---------------------------------------------------
sorting helper
@@ -808,10 +745,6 @@ uno::Sequence< ::rtl::OUString > PropValVector::getNames()
-----------------------------------------------------------------------*/
void StyleSheetTable::ApplyStyleSheets( FontTablePtr rFontTable )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("applyStyleSheets");
-#endif
-
try
{
uno::Reference< style::XStyleFamiliesSupplier > xStylesSupplier( m_pImpl->m_xTextDocument, uno::UNO_QUERY_THROW );
@@ -970,24 +903,13 @@ void StyleSheetTable::ApplyStyleSheets( FontTablePtr rFontTable )
PropValVector aSortedPropVals;
for( sal_Int32 nProp = 0; nProp < aPropValues.getLength(); ++nProp)
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->startElement("propvalue");
- dmapper_logger->attribute("name", aPropValues[nProp].Name);
- dmapper_logger->attribute("value", aPropValues[nProp].Value);
-#endif
// Don't add the style name properties
bool bIsParaStyleName = aPropValues[nProp].Name.equalsAscii( "ParaStyleName" );
bool bIsCharStyleName = aPropValues[nProp].Name.equalsAscii( "CharStyleName" );
if ( !bIsParaStyleName && !bIsCharStyleName )
{
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->element("insert");
-#endif
aSortedPropVals.Insert( aPropValues[nProp] );
}
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("propvalue");
-#endif
}
if(bAddFollowStyle)
{
@@ -1038,12 +960,6 @@ void StyleSheetTable::ApplyStyleSheets( FontTablePtr rFontTable )
if(bInsert)
{
xStyles->insertByName( sConvertedStyleName, uno::makeAny( xStyle) );
-#ifdef DEBUG_DOMAINMAPPER
- uno::Reference<beans::XPropertySet> xProps(xStyle, uno::UNO_QUERY);
- dmapper_logger->startElement("insertStyle");
- dmapper_logger->addTag(unoPropertySetToTag(xProps));
- dmapper_logger->endElement("insertStyle");
-#endif
}
}
++aIt;
@@ -1055,10 +971,6 @@ void StyleSheetTable::ApplyStyleSheets( FontTablePtr rFontTable )
(void)rEx;
OSL_ENSURE( false, "Styles could not be imported completely");
}
-
-#ifdef DEBUG_DOMAINMAPPER
- dmapper_logger->endElement("applyStyleSheets");
-#endif
}
/*-- 22.06.2006 15:56:56---------------------------------------------------
diff --git a/writerfilter/source/dmapper/StyleSheetTable.hxx b/writerfilter/source/dmapper/StyleSheetTable.hxx
index e4441bcb05fe..f6a8b44efa5d 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.hxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.hxx
@@ -34,11 +34,7 @@
#include <com/sun/star/lang/XComponent.hpp>
#include <PropertyMap.hxx>
#include <FontTable.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
-
-#ifdef DEBUG_DOMAINMAPPER
-#include <resourcemodel/TagLogger.hxx>
-#endif
+#include <resourcemodel/LoggedResources.hxx>
namespace com{ namespace sun { namespace star { namespace text{
class XTextDocument;
@@ -76,20 +72,18 @@ public:
PropertyMapPtr pProperties;
::rtl::OUString sConvertedStyleName;
-#ifdef DEBUG_DOMAINMAPPER
- virtual XMLTag::Pointer_t toTag();
-#endif
-
StyleSheetEntry();
virtual ~StyleSheetEntry();
};
typedef boost::shared_ptr<StyleSheetEntry> StyleSheetEntryPtr;
+typedef ::std::deque<StyleSheetEntryPtr> StyleSheetEntryDeque;
+typedef boost::shared_ptr<StyleSheetEntryDeque> StyleSheetEntryDequePtr;
class DomainMapper;
class StyleSheetTable :
- public Properties,
- public Table
+ public LoggedProperties,
+ public LoggedTable
{
StyleSheetTable_Impl *m_pImpl;
@@ -98,13 +92,6 @@ public:
::com::sun::star::uno::Reference< ::com::sun::star::text::XTextDocument> xTextDocument );
virtual ~StyleSheetTable();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
- // Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
void ApplyStyleSheets( FontTablePtr rFontTable );
const StyleSheetEntryPtr FindStyleSheetByISTD(const ::rtl::OUString& sIndex);
const StyleSheetEntryPtr FindStyleSheetByStyleName(const ::rtl::OUString& rIndex);
@@ -118,6 +105,13 @@ public:
::rtl::OUString getOrCreateCharStyle( PropertyValueVector_t& rCharProperties );
private:
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
+ // Table
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
+
void resolveAttributeProperties(Value & val);
void resolveSprmProps(Sprm & sprm_);
void applyDefaults(bool bParaProperties);
@@ -146,11 +140,10 @@ public:
// Gets all the properties
// + corresponding to the mask,
// + from the parent styles
- PropertyMapPtr GetProperties( sal_Int32 nMask );
-
-#ifdef DEBUG_DOMAINMAPPER
- virtual XMLTag::Pointer_t toTag();
-#endif
+ //
+ // @param mask mask describing which properties to return
+ // @param pStack already processed StyleSheetEntries
+ PropertyMapPtr GetProperties( sal_Int32 nMask, StyleSheetEntryDequePtr pStack = StyleSheetEntryDequePtr());
TableStyleSheetEntry( StyleSheetEntry& aEntry, StyleSheetTable* pStyles );
virtual ~TableStyleSheetEntry( );
diff --git a/writerfilter/source/dmapper/TDefTableHandler.cxx b/writerfilter/source/dmapper/TDefTableHandler.cxx
index c65ce2cdb784..fd63fe378c76 100644
--- a/writerfilter/source/dmapper/TDefTableHandler.cxx
+++ b/writerfilter/source/dmapper/TDefTableHandler.cxx
@@ -33,6 +33,8 @@
#include <com/sun/star/text/TableColumnSeparator.hpp>
#include <com/sun/star/text/VertOrientation.hpp>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper {
@@ -42,11 +44,12 @@ using namespace ::com::sun::star;
-----------------------------------------------------------------------*/
TDefTableHandler::TDefTableHandler(bool bOOXML) :
- m_nLineWidth(0),
- m_nLineType(0),
- m_nLineColor(0),
- m_nLineDistance(0),
- m_bOOXML( bOOXML )
+LoggedProperties(dmapper_logger, "TDefTableHandler"),
+m_nLineWidth(0),
+m_nLineType(0),
+m_nLineColor(0),
+m_nLineDistance(0),
+m_bOOXML( bOOXML )
{
}
/*-- 24.04.2007 09:06:35---------------------------------------------------
@@ -58,7 +61,7 @@ TDefTableHandler::~TDefTableHandler()
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void TDefTableHandler::attribute(Id rName, Value & rVal)
+void TDefTableHandler::lcl_attribute(Id rName, Value & rVal)
{
sal_Int32 nIntValue = rVal.getInt();
(void)nIntValue;
@@ -214,7 +217,7 @@ void TDefTableHandler::localResolve(Id rName, writerfilter::Reference<Properties
/*-- 24.04.2007 09:06:35---------------------------------------------------
-----------------------------------------------------------------------*/
-void TDefTableHandler::sprm(Sprm & rSprm)
+void TDefTableHandler::lcl_sprm(Sprm & rSprm)
{
/* WRITERFILTERSTATUS: table: TDefTable_sprm */
switch( rSprm.getId() )
diff --git a/writerfilter/source/dmapper/TDefTableHandler.hxx b/writerfilter/source/dmapper/TDefTableHandler.hxx
index 993b49251a77..3bd25adeb6ea 100644
--- a/writerfilter/source/dmapper/TDefTableHandler.hxx
+++ b/writerfilter/source/dmapper/TDefTableHandler.hxx
@@ -28,7 +28,7 @@
#define INCLUDED_TDEFTABLEHANDLER_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
#include <com/sun/star/table/BorderLine.hpp>
#include <vector>
@@ -41,7 +41,7 @@ namespace dmapper
{
class PropertyMap;
class TablePropertyMap;
-class WRITERFILTER_DLLPRIVATE TDefTableHandler : public Properties
+class WRITERFILTER_DLLPRIVATE TDefTableHandler : public LoggedProperties
{
public:
@@ -67,14 +67,15 @@ private:
bool m_bOOXML;
void localResolve(Id Name, writerfilter::Reference<Properties>::Pointer_t pProperties);
+
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
TDefTableHandler( bool bOOXML );
virtual ~TDefTableHandler();
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
size_t getCellCount() const;
void fillCellProperties( size_t nCell, ::boost::shared_ptr< TablePropertyMap > pCellProperties) const;
::boost::shared_ptr<PropertyMap> getRowProperties() const;
diff --git a/writerfilter/source/dmapper/TblStylePrHandler.cxx b/writerfilter/source/dmapper/TblStylePrHandler.cxx
index 53838353c3b0..02d134786357 100644
--- a/writerfilter/source/dmapper/TblStylePrHandler.cxx
+++ b/writerfilter/source/dmapper/TblStylePrHandler.cxx
@@ -4,14 +4,17 @@
#include <dmapperLoggers.hxx>
#include <resourcemodel/QNameToString.hxx>
+#include "dmapperLoggers.hxx"
+
namespace writerfilter {
namespace dmapper {
TblStylePrHandler::TblStylePrHandler( DomainMapper & rDMapper ) :
- m_rDMapper( rDMapper ),
- m_pTablePropsHandler( new TablePropertiesHandler( true ) ),
- m_nType( TBL_STYLE_UNKNOWN ),
- m_pProperties( new PropertyMap )
+LoggedProperties(dmapper_logger, "TblStylePrHandler"),
+m_rDMapper( rDMapper ),
+m_pTablePropsHandler( new TablePropertiesHandler( true ) ),
+m_nType( TBL_STYLE_UNKNOWN ),
+m_pProperties( new PropertyMap )
{
}
@@ -20,7 +23,7 @@ TblStylePrHandler::~TblStylePrHandler( )
delete m_pTablePropsHandler, m_pTablePropsHandler = NULL;
}
-void TblStylePrHandler::attribute(Id rName, Value & rVal)
+void TblStylePrHandler::lcl_attribute(Id rName, Value & rVal)
{
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->startElement("TblStylePrHandler.attribute");
@@ -41,7 +44,7 @@ void TblStylePrHandler::attribute(Id rName, Value & rVal)
}
}
-void TblStylePrHandler::sprm(Sprm & rSprm)
+void TblStylePrHandler::lcl_sprm(Sprm & rSprm)
{
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->startElement("TblStylePrHandler.sprm");
diff --git a/writerfilter/source/dmapper/TblStylePrHandler.hxx b/writerfilter/source/dmapper/TblStylePrHandler.hxx
index dd8d2da97690..b76782b0edfe 100644
--- a/writerfilter/source/dmapper/TblStylePrHandler.hxx
+++ b/writerfilter/source/dmapper/TblStylePrHandler.hxx
@@ -5,7 +5,7 @@
#include <dmapper/DomainMapper.hxx>
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <boost/shared_ptr.hpp>
namespace writerfilter {
@@ -32,7 +32,7 @@ enum TblStyleType
TBL_STYLE_SWCELL
};
-class WRITERFILTER_DLLPRIVATE TblStylePrHandler : public Properties
+class WRITERFILTER_DLLPRIVATE TblStylePrHandler : public LoggedProperties
{
private:
DomainMapper & m_rDMapper;
@@ -41,14 +41,14 @@ private:
TblStyleType m_nType;
PropertyMapPtr m_pProperties;
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
public:
TblStylePrHandler( DomainMapper & rDMapper );
virtual ~TblStylePrHandler( );
- // Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
-
inline PropertyMapPtr getProperties() { return m_pProperties; };
inline TblStyleType getType() { return m_nType; };
diff --git a/writerfilter/source/dmapper/ThemeTable.cxx b/writerfilter/source/dmapper/ThemeTable.cxx
index 0f0becf06552..74f166dcf313 100644
--- a/writerfilter/source/dmapper/ThemeTable.cxx
+++ b/writerfilter/source/dmapper/ThemeTable.cxx
@@ -30,11 +30,7 @@
#include <doctok/resourceids.hxx>
#include <ooxml/resourceids.hxx>
#endif
-#include <stdio.h>
-#ifdef DEBUG_DOMAINMAPPER
#include "dmapperLoggers.hxx"
-#include <resourcemodel/QNameToString.hxx>
-#endif
namespace writerfilter {
namespace dmapper
@@ -50,8 +46,10 @@ struct ThemeTable_Impl
std::map<sal_uInt32, ::rtl::OUString> m_currentFontThemeEntry;
};
-ThemeTable::ThemeTable() :
- m_pImpl( new ThemeTable_Impl )
+ThemeTable::ThemeTable()
+: LoggedProperties(dmapper_logger, "ThemeTable")
+, LoggedTable(dmapper_logger, "ThemeTable")
+, m_pImpl( new ThemeTable_Impl )
{
// printf("ThemeTable::ThemeTable()\n");
}
@@ -61,7 +59,7 @@ ThemeTable::~ThemeTable()
delete m_pImpl;
}
-void ThemeTable::attribute(Id Name, Value & val)
+void ThemeTable::lcl_attribute(Id Name, Value & val)
{
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->startElement("ThemeTable.attribute");
@@ -91,7 +89,7 @@ void ThemeTable::attribute(Id Name, Value & val)
#endif
}
-void ThemeTable::sprm(Sprm& rSprm)
+void ThemeTable::lcl_sprm(Sprm& rSprm)
{
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->startElement("ThemeTable.sprm");
@@ -156,7 +154,7 @@ void ThemeTable::sprm(Sprm& rSprm)
#endif
}
-void ThemeTable::entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
+void ThemeTable::lcl_entry(int /*pos*/, writerfilter::Reference<Properties>::Pointer_t ref)
{
#ifdef DEBUG_DOMAINMAPPER
dmapper_logger->startElement("ThemeTable.entry");
diff --git a/writerfilter/source/dmapper/ThemeTable.hxx b/writerfilter/source/dmapper/ThemeTable.hxx
index b79877703c58..1396c4cee8c9 100644
--- a/writerfilter/source/dmapper/ThemeTable.hxx
+++ b/writerfilter/source/dmapper/ThemeTable.hxx
@@ -29,7 +29,7 @@
#define INCLUDED_THEMETABLE_HXX
#include <WriterFilterDllApi.hxx>
-#include <resourcemodel/WW8ResourceModel.hxx>
+#include <resourcemodel/LoggedResources.hxx>
#include <com/sun/star/lang/XComponent.hpp>
#include <map>
@@ -39,7 +39,7 @@ namespace dmapper
struct ThemeTable_Impl;
-class WRITERFILTER_DLLPRIVATE ThemeTable : public Properties, public Table
+class WRITERFILTER_DLLPRIVATE ThemeTable : public LoggedProperties, public LoggedTable
{
ThemeTable_Impl *m_pImpl;
@@ -47,14 +47,15 @@ public:
ThemeTable();
virtual ~ThemeTable();
+ const ::rtl::OUString getFontNameForTheme(const Id id) const;
+
+ private:
// Properties
- virtual void attribute(Id Name, Value & val);
- virtual void sprm(Sprm & sprm);
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
// Table
- virtual void entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
-
- const ::rtl::OUString getFontNameForTheme(const Id id) const;
+ virtual void lcl_entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref);
};
typedef boost::shared_ptr< ThemeTable > ThemeTablePtr;
}}
diff --git a/writerfilter/source/dmapper/WrapPolygonHandler.cxx b/writerfilter/source/dmapper/WrapPolygonHandler.cxx
new file mode 100644
index 000000000000..2aabc1a375a9
--- /dev/null
+++ b/writerfilter/source/dmapper/WrapPolygonHandler.cxx
@@ -0,0 +1,216 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <com/sun/star/drawing/PointSequence.hpp>
+
+#include <ooxml/resourceids.hxx>
+#include <resourcemodel/ResourceModelHelper.hxx>
+
+#include "ConversionHelper.hxx"
+#include "WrapPolygonHandler.hxx"
+#include "dmapperLoggers.hxx"
+
+namespace writerfilter {
+
+using resourcemodel::resolveSprmProps;
+
+namespace dmapper {
+
+WrapPolygon::WrapPolygon()
+{
+}
+
+WrapPolygon::~WrapPolygon()
+{
+}
+
+void WrapPolygon::addPoint(const awt::Point & rPoint)
+{
+ mPoints.push_back(rPoint);
+}
+
+WrapPolygon::Points_t::const_iterator WrapPolygon::begin() const
+{
+ return mPoints.begin();
+}
+
+WrapPolygon::Points_t::const_iterator WrapPolygon::end() const
+{
+ return mPoints.end();
+}
+
+WrapPolygon::Points_t::iterator WrapPolygon::begin()
+{
+ return mPoints.begin();
+}
+
+WrapPolygon::Points_t::iterator WrapPolygon::end()
+{
+ return mPoints.end();
+}
+
+size_t WrapPolygon::size() const
+{
+ return mPoints.size();
+}
+
+WrapPolygon::Pointer_t WrapPolygon::move(const awt::Point & rPoint)
+{
+ WrapPolygon::Pointer_t pResult(new WrapPolygon);
+
+ Points_t::iterator aIt = begin();
+ Points_t::iterator aItEnd = end();
+
+ while (aIt != aItEnd)
+ {
+ awt::Point aPoint(aIt->X + rPoint.X, aIt->Y + rPoint.Y);
+ pResult->addPoint(aPoint);
+ aIt++;
+ }
+
+ return pResult;
+}
+
+WrapPolygon::Pointer_t WrapPolygon::scale(const Fraction & rFractionX, const Fraction & rFractionY)
+{
+ WrapPolygon::Pointer_t pResult(new WrapPolygon);
+
+ Points_t::iterator aIt = begin();
+ Points_t::iterator aItEnd = end();
+
+ while (aIt != aItEnd)
+ {
+ awt::Point aPoint(Fraction(aIt->X) * rFractionX, Fraction(aIt->Y) * rFractionY);
+ pResult->addPoint(aPoint);
+ aIt++;
+ }
+
+ return pResult;
+}
+
+WrapPolygon::Pointer_t WrapPolygon::correctWordWrapPolygon(const awt::Size & rSrcSize, const awt::Size & rDstSize)
+{
+ WrapPolygon::Pointer_t pResult;
+
+ const sal_uInt32 nWrap100Percent = 21600;
+
+ Fraction aMove(nWrap100Percent, rSrcSize.Width);
+ aMove = aMove * Fraction(15, 1);
+ awt::Point aMovePoint(aMove, 0);
+ pResult = move(aMovePoint);
+
+ Fraction aScaleX(nWrap100Percent, Fraction(nWrap100Percent) + aMove);
+ Fraction aScaleY(nWrap100Percent, Fraction(nWrap100Percent) - aMove);
+ pResult = pResult->scale(aScaleX, aScaleY);
+
+ Fraction aScaleDestX(rDstSize.Width, nWrap100Percent);
+ Fraction aScaleDestY(rDstSize.Height, nWrap100Percent);
+ pResult = pResult->scale(aScaleDestX, aScaleDestY);
+
+ return pResult;
+}
+
+drawing::PointSequenceSequence WrapPolygon::getPointSequenceSequence() const
+{
+ drawing::PointSequenceSequence aPolyPolygon(1L);
+ drawing::PointSequence * pPolygon = aPolyPolygon.getArray();
+ pPolygon->realloc(size());
+
+ sal_uInt32 n = 0;
+ Points_t::const_iterator aIt = begin();
+ Points_t::const_iterator aItEnd = end();
+
+ while (aIt != aItEnd)
+ {
+ (*pPolygon)[n] = *aIt;
+ ++n;
+ aIt++;
+ }
+
+ return aPolyPolygon;
+}
+
+WrapPolygonHandler::WrapPolygonHandler()
+: LoggedProperties(dmapper_logger, "WrapPolygonHandler")
+, mpPolygon(new WrapPolygon)
+{
+}
+
+WrapPolygonHandler::~WrapPolygonHandler()
+{
+}
+
+void WrapPolygonHandler::lcl_attribute(Id Name, Value & val)
+{
+ sal_Int32 nIntValue = val.getInt();
+
+ switch(Name)
+ {
+ case NS_ooxml::LN_CT_Point2D_x:
+ /* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
+ mnX = nIntValue;
+ break;
+ case NS_ooxml::LN_CT_Point2D_y:
+ /* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
+ mnY = nIntValue;
+ break;
+ default:
+#ifdef DEBUG_WRAP_POLYGON_HANDLER
+ dmapper_logger->element("unhandled");
+#endif
+ break;
+ }
+}
+
+void WrapPolygonHandler::lcl_sprm(Sprm & _sprm)
+{
+ switch (_sprm.getId())
+ {
+ case NS_ooxml::LN_CT_WrapPath_lineTo:
+ case NS_ooxml::LN_CT_WrapPath_start:
+ /* WRITERFILTERSTATUS: done: 100, planned: 0.5, spent: 0 */
+ {
+ resolveSprmProps(*this, _sprm);
+
+ awt::Point aPoint(mnX, mnY);
+ mpPolygon->addPoint(aPoint);
+ }
+ break;
+ default:
+#ifdef DEBUG_WRAP_POLYGON_HANDLER
+ dmapper_logger->element("unhandled");
+#endif
+ break;
+ }
+}
+
+WrapPolygon::Pointer_t WrapPolygonHandler::getPolygon()
+{
+ return mpPolygon;
+}
+
+}}
diff --git a/writerfilter/source/dmapper/WrapPolygonHandler.hxx b/writerfilter/source/dmapper/WrapPolygonHandler.hxx
new file mode 100644
index 000000000000..05161096f81a
--- /dev/null
+++ b/writerfilter/source/dmapper/WrapPolygonHandler.hxx
@@ -0,0 +1,91 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#ifndef WRAP_POLYGON_HANDLER_HXX
+#define WRAP_POLYGON_HANDLER_HXX
+
+#include <com/sun/star/drawing/PointSequenceSequence.hpp>
+#include <resourcemodel/LoggedResources.hxx>
+#include <resourcemodel/Fraction.hxx>
+
+namespace writerfilter {
+namespace dmapper {
+
+using namespace ::com::sun::star;
+using resourcemodel::Fraction;
+
+class WrapPolygon
+{
+public:
+ typedef ::std::deque<awt::Point> Points_t;
+ typedef ::boost::shared_ptr<WrapPolygon> Pointer_t;
+
+private:
+ Points_t mPoints;
+
+public:
+ WrapPolygon();
+ virtual ~WrapPolygon();
+
+ void addPoint(const awt::Point & rPoint);
+
+ Points_t::const_iterator begin() const;
+ Points_t::const_iterator end() const;
+ Points_t::iterator begin();
+ Points_t::iterator end();
+
+ size_t size() const;
+
+ WrapPolygon::Pointer_t move(const awt::Point & rMove);
+ WrapPolygon::Pointer_t scale(const Fraction & rFractionX, const Fraction & rFractionY);
+ WrapPolygon::Pointer_t correctWordWrapPolygon(const awt::Size & rSrcSize, const awt::Size & rDstSize);
+ drawing::PointSequenceSequence getPointSequenceSequence() const;
+};
+
+class WrapPolygonHandler : public LoggedProperties
+{
+public:
+ WrapPolygonHandler();
+ virtual ~WrapPolygonHandler();
+
+ WrapPolygon::Pointer_t getPolygon();
+
+private:
+ WrapPolygon::Pointer_t mpPolygon;
+
+ sal_uInt32 mnX;
+ sal_uInt32 mnY;
+
+ // Properties
+ virtual void lcl_attribute(Id Name, Value & val);
+ virtual void lcl_sprm(Sprm & sprm);
+
+};
+
+}}
+
+#endif // WRAP_POLYGON_HANDLER_HXX
diff --git a/writerfilter/source/dmapper/dmapperLoggers.hxx b/writerfilter/source/dmapper/dmapperLoggers.hxx
index fd9ed722de4a..8b30c491c384 100644
--- a/writerfilter/source/dmapper/dmapperLoggers.hxx
+++ b/writerfilter/source/dmapper/dmapperLoggers.hxx
@@ -31,7 +31,6 @@
#ifndef INCLUDED_DMAPPER_LOGGERS_HXX
#define INCLUDED_DMAPPER_LOGGERS_HXX
-#ifdef DEBUG
#include <resourcemodel/TagLogger.hxx>
namespace writerfilter {
@@ -39,5 +38,5 @@ namespace writerfilter {
extern TagLogger::Pointer_t dmapper_logger;
}
}
-#endif // DEBUG
+
#endif // INCLUDED_DMAPPER_LOGGERS_HXX
diff --git a/writerfilter/source/dmapper/makefile.mk b/writerfilter/source/dmapper/makefile.mk
index 300dfb31d959..a4b000411b4e 100644
--- a/writerfilter/source/dmapper/makefile.mk
+++ b/writerfilter/source/dmapper/makefile.mk
@@ -48,13 +48,13 @@ SLOFILES= \
$(SLO)$/DomainMapperTableManager.obj \
$(SLO)$/DomainMapper_Impl.obj \
$(SLO)$/FFDataHandler.obj \
- $(SLO)$/FormControlHelper.obj \
$(SLO)$/FontTable.obj \
+ $(SLO)$/FormControlHelper.obj \
$(SLO)$/GraphicHelpers.obj \
$(SLO)$/GraphicImport.obj \
- $(SLO)$/NumberingManager.obj \
$(SLO)$/MeasureHandler.obj \
$(SLO)$/ModelEventListener.obj \
+ $(SLO)$/NumberingManager.obj \
$(SLO)$/OLEHandler.obj \
$(SLO)$/PageBordersHandler.obj \
$(SLO)$/PropertyIds.obj \
@@ -66,7 +66,9 @@ SLOFILES= \
$(SLO)$/TDefTableHandler.obj \
$(SLO)$/TablePropertiesHandler.obj \
$(SLO)$/TblStylePrHandler.obj \
- $(SLO)$/ThemeTable.obj
+ $(SLO)$/ThemeTable.obj \
+ $(SLO)$/WrapPolygonHandler.obj \
+
# --- Targets ----------------------------------
diff --git a/writerfilter/source/filter/ImportFilter.cxx b/writerfilter/source/filter/ImportFilter.cxx
index 0f7221552923..199c91f3a48f 100644
--- a/writerfilter/source/filter/ImportFilter.cxx
+++ b/writerfilter/source/filter/ImportFilter.cxx
@@ -85,7 +85,7 @@ sal_Bool WriterFilter::filter( const uno::Sequence< beans::PropertyValue >& aDes
return sal_False;
}
-#ifdef DEBUG_ELEMENT
+#ifdef DEBUG_IMPORT
OUString sURL = aMediaDesc.getUnpackedValueOrDefault( MediaDescriptor::PROP_URL(), OUString() );
::std::string sURLc = OUStringToOString(sURL, RTL_TEXTENCODING_ASCII_US).getStr();
@@ -130,7 +130,7 @@ sal_Bool WriterFilter::filter( const uno::Sequence< beans::PropertyValue >& aDes
pDocument->resolve(*pStream);
}
-#ifdef DEBUG_ELEMENT
+#ifdef DEBUG_IMPORT
writerfilter::TagLogger::dump("DOMAINMAPPER");
dmapperLogger->endDocument();
writerfilter::TagLogger::dump("DEBUG");
diff --git a/writerfilter/source/filter/WriterFilterDetection.cxx b/writerfilter/source/filter/WriterFilterDetection.cxx
index a712cc14fffa..87da1861cbae 100644
--- a/writerfilter/source/filter/WriterFilterDetection.cxx
+++ b/writerfilter/source/filter/WriterFilterDetection.cxx
@@ -97,7 +97,7 @@ OUString WriterFilterDetection::detect( uno::Sequence< beans::PropertyValue >& r
if ( pStream && SotStorage::IsStorageFile(pStream) )
{
- SotStorageRef xStg = new SotStorage( pStream, FALSE );
+ SotStorageRef xStg = new SotStorage( pStream, sal_False );
bool bTable2 = xStg->IsContained( rtl::OUString::createFromAscii("1Table" ));
SotStorageStreamRef xRef =
diff --git a/writerfilter/source/ooxml/OOXMLFactory.cxx b/writerfilter/source/ooxml/OOXMLFactory.cxx
index a277d5928af6..9188bef6e8cb 100644
--- a/writerfilter/source/ooxml/OOXMLFactory.cxx
+++ b/writerfilter/source/ooxml/OOXMLFactory.cxx
@@ -131,8 +131,8 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
if (pFactory.get() != NULL)
{
-#ifdef DEBUG_ATTRIBUTES
- debug_logger->startElement("attributes");
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.attributes");
debug_logger->attribute("define", pFactory->getDefineName(nDefine));
char sBuffer[256];
snprintf(sBuffer, sizeof(sBuffer), "%08" SAL_PRIxUINT32, nDefine);
@@ -148,8 +148,8 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
for (aIt = pMap->begin(); aIt != aEndIt; aIt++)
{
Id nId = (*pTokenToIdMap)[aIt->first];
-#ifdef DEBUG_ATTRIBUTES
- debug_logger->startElement("attribute");
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.attribute");
debug_logger->attribute("name", fastTokenToId(aIt->first));
debug_logger->attribute("tokenid", (*QNameToString::Instance())(nId));
snprintf(sBuffer, sizeof(sBuffer), "%08" SAL_PRIxUINT32, nId);
@@ -161,7 +161,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
{
case RT_Boolean:
{
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->element("boolean");
#endif
::rtl::OUString aValue(Attribs->getValue(aIt->first));
@@ -173,7 +173,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
break;
case RT_String:
{
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->element("string");
#endif
::rtl::OUString aValue(Attribs->getValue(aIt->first));
@@ -186,7 +186,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
break;
case RT_Integer:
{
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->element("integer");
#endif
::rtl::OUString aValue(Attribs->getValue(aIt->first));
@@ -199,7 +199,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
break;
case RT_Hex:
{
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->element("hex");
#endif
::rtl::OUString aValue(Attribs->getValue(aIt->first));
@@ -212,7 +212,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
break;
case RT_List:
{
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->startElement("list");
#endif
ListValueMapPointer pListValueMap =
@@ -223,7 +223,7 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
::rtl::OUString aValue(Attribs->getValue(aIt->first));
sal_uInt32 nValue = (*pListValueMap)[aValue];
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->attribute("value", aValue);
debug_logger->attribute("value-num", nValue);
#endif
@@ -234,25 +234,25 @@ void OOXMLFactory::attributes(OOXMLFastContextHandler * pHandler,
OOXMLValue::Pointer_t pValue(new OOXMLIntegerValue(nValue));
pFactory->attributeAction(pHandler, aIt->first, pValue);
}
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->endElement("list");
#endif
}
break;
default:
-#ifdef DEBUG_ATTRIBUTES
+#ifdef DEBUG_FACTORY
debug_logger->element("unknown-attribute-type");
#endif
break;
}
}
-#ifdef DEBUG_ATTRIBUTES
- debug_logger->endElement("attribute");
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.attribute");
#endif
}
-#ifdef DEBUG_ATTRIBUTES
- debug_logger->endElement("attributes");
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.attributes");
#endif
}
}
@@ -261,6 +261,11 @@ uno::Reference< xml::sax::XFastContextHandler>
OOXMLFactory::createFastChildContext(OOXMLFastContextHandler * pHandler,
Token_t Element)
{
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.createFastChildContext");
+ debug_logger->attribute("token", fastTokenToId(Element));
+#endif
+
Id nDefine = pHandler->getDefine();
OOXMLFactory_ns::Pointer_t pFactory = getFactoryForNamespace(nDefine);
@@ -271,12 +276,21 @@ OOXMLFactory::createFastChildContext(OOXMLFastContextHandler * pHandler,
if ((Element & 0xffff) < OOXML_FAST_TOKENS_END)
ret = createFastChildContextFromFactory(pHandler, pFactory, Element);
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.createFastChildContext");
+#endif
+
return ret;
}
void OOXMLFactory::characters(OOXMLFastContextHandler * pHandler,
const ::rtl::OUString & rString)
{
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.characters");
+ debug_logger->chars(rString);
+#endif
+
Id nDefine = pHandler->getDefine();
OOXMLFactory_ns::Pointer_t pFactory = getFactoryForNamespace(nDefine);
@@ -284,6 +298,10 @@ void OOXMLFactory::characters(OOXMLFastContextHandler * pHandler,
{
pFactory->charactersAction(pHandler, rString);
}
+
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.characters");
+#endif
}
void OOXMLFactory::startAction(OOXMLFastContextHandler * pHandler, Token_t /*nToken*/)
@@ -294,11 +312,11 @@ void OOXMLFactory::startAction(OOXMLFastContextHandler * pHandler, Token_t /*nTo
if (pFactory.get() != NULL)
{
#ifdef DEBUG_ELEMENT
- debug_logger->startElement("factory-startAction");
+ debug_logger->startElement("factory.startAction");
#endif
pFactory->startAction(pHandler);
#ifdef DEBUG_ELEMENT
- debug_logger->endElement("factory-startAction");
+ debug_logger->endElement("factory.startAction");
#endif
}
}
@@ -311,11 +329,11 @@ void OOXMLFactory::endAction(OOXMLFastContextHandler * pHandler, Token_t /*nToke
if (pFactory.get() != NULL)
{
#ifdef DEBUG_ELEMENT
- debug_logger->startElement("factory-endAction");
+ debug_logger->startElement("factory.endAction");
#endif
pFactory->endAction(pHandler);
#ifdef DEBUG_ELEMENT
- debug_logger->endElement("factory-endAction");
+ debug_logger->endElement("factory.endAction");
#endif
}
}
@@ -336,6 +354,13 @@ void OOXMLFactory_ns::attributeAction(OOXMLFastContextHandler *, Token_t, OOXMLV
{
}
+#ifdef DEBUG_FACTORY
+string OOXMLFactory_ns::getName() const
+{
+ return "noname";
+}
+#endif
+
}
}
diff --git a/writerfilter/source/ooxml/OOXMLFactory.hxx b/writerfilter/source/ooxml/OOXMLFactory.hxx
index 0558436ab793..753fb3f658f7 100755..100644
--- a/writerfilter/source/ooxml/OOXMLFactory.hxx
+++ b/writerfilter/source/ooxml/OOXMLFactory.hxx
@@ -114,6 +114,9 @@ public:
virtual void endAction(OOXMLFastContextHandler * pHandler);
virtual void attributeAction(OOXMLFastContextHandler * pHandler, Token_t nToken, OOXMLValue::Pointer_t pValue);
virtual string getDefineName(Id nId) const;
+#ifdef DEBUG_FACTORY
+ virtual string getName() const;
+#endif
AttributeToResourceMapPointer getAttributeToResourceMap(Id nId);
ListValueMapPointer getListValueMap(Id nId);
diff --git a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
index 20ee49258c00..5e4d5604527f 100644
--- a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
+++ b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
@@ -31,6 +31,7 @@
#include <rtl/uuid.h>
#include <com/sun/star/drawing/XShapes.hpp>
#include <resourcemodel/QNameToString.hxx>
+#include <resourcemodel/XPathLogger.hxx>
#include <resourcemodel/util.hxx>
#include <ooxml/resourceids.hxx>
#include <doctok/sprmids.hxx>
@@ -182,52 +183,23 @@ OOXMLFastContextHandler::~OOXMLFastContextHandler()
aSetContexts.erase(this);
}
-#ifdef DEBUG_MEMORY
-void SAL_CALL OOXMLFastContextHandler::acquire()
- throw ()
-{
- mnRefCount++;
-
- static char buffer[256];
- snprintf(buffer, sizeof(buffer), "%ld: %s: aquire(%ld)", mnInstanceNumber,
- getType().c_str(), mnRefCount);
- logger("MEMORY", buffer);
-
- cppu::WeakImplHelper1<com::sun::star::xml::sax::XFastContextHandler>::acquire();
-}
-
-void SAL_CALL OOXMLFastContextHandler::release()
- throw ()
-{
- static char buffer[256];
- snprintf(buffer, sizeof(buffer), "%s: release(%ld)", mnInstanceNumber,
- getType().c_str(), mnRefCount);
- logger("MEMORY", buffer);
-
- cppu::WeakImplHelper1<com::sun::star::xml::sax::XFastContextHandler>::release();
- mnRefCount--;
-}
-#endif
-
// ::com::sun::star::xml::sax::XFastContextHandler:
void SAL_CALL OOXMLFastContextHandler::startFastElement
(Token_t Element,
const uno::Reference< xml::sax::XFastAttributeList > & Attribs)
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("element");
- debug_logger->attribute("token", fastTokenToId(Element));
- debug_logger->attribute("type",getType());
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.element");
+ string sToken = fastTokenToId(Element);
+ mpParserState->getXPathLogger().startElement(sToken);
+ debug_logger->attribute("token", sToken);
+ debug_logger->attribute("type", getType());
+ debug_logger->attribute("xpath", mpParserState->getXPathLogger().getXPath());
debug_logger->startElement("at-start");
debug_logger->addTag(toTag());
debug_logger->endElement("at-start");
#endif
-#ifdef DEBUG_MEMORY
- static char buffer[256];
- snprintf(buffer, sizeof(buffer), "%ld: startFastElement", mnInstanceNumber);
- logger("MEMORY", buffer);
-#endif
attributes(Attribs);
lcl_startFastElement(Element, Attribs);
}
@@ -237,10 +209,11 @@ void SAL_CALL OOXMLFastContextHandler::startUnknownElement
const uno::Reference< xml::sax::XFastAttributeList > & /*Attribs*/)
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_CONTEXT_STACK
- debug_logger->startElement("unknown-element");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.unknown-element");
debug_logger->attribute("namespace", Namespace);
debug_logger->attribute("name", Name);
+ mpParserState->getXPathLogger().startElement("unknown");
#else
(void) Namespace;
(void) Name;
@@ -250,19 +223,19 @@ throw (uno::RuntimeException, xml::sax::SAXException)
void SAL_CALL OOXMLFastContextHandler::endFastElement(Token_t Element)
throw (uno::RuntimeException, xml::sax::SAXException)
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ string sToken = fastTokenToId(Element);
+ (void) sToken;
+#endif
+
lcl_endFastElement(Element);
-#ifdef DEBUG_ELEMENT
+#ifdef DEBUG_CONTEXT_HANDLER
debug_logger->startElement("at-end");
debug_logger->addTag(toTag());
debug_logger->endElement("at-end");
- debug_logger->endElement("element");
-#endif
-#ifdef DEBUG_MEMORY
- static char buffer[256];
- snprintf(buffer, sizeof(buffer), "%ld: %s:endFastElement", mnInstanceNumber,
- getType().c_str());
- logger("MEMORY", buffer);
+ debug_logger->endElement("contexthandler.element");
+ mpParserState->getXPathLogger().endElement();
#endif
}
@@ -278,14 +251,6 @@ void OOXMLFastContextHandler::lcl_endFastElement
(Token_t Element)
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_CONTEXT_STACK
- debug_logger->startElement("endAction");
- debug_logger->endElement("endAction");
- debug_logger->startElement("token");
- debug_logger->chars(fastTokenToId(Element));
- debug_logger->endElement("token");
-#endif
-
OOXMLFactory::getInstance()->endAction(this, Element);
}
@@ -293,9 +258,9 @@ void SAL_CALL OOXMLFastContextHandler::endUnknownElement
(const ::rtl::OUString & , const ::rtl::OUString & )
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("unknown-element");
- debug_logger->endElement("unknown-element");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.unknown-element");
+ mpParserState->getXPathLogger().endElement();
#endif
}
@@ -305,8 +270,8 @@ uno::Reference< xml::sax::XFastContextHandler > SAL_CALL
const uno::Reference< xml::sax::XFastAttributeList > & Attribs)
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_CONTEXT_STACK
- debug_logger->startElement("createFastChildContext");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.createFastChildContext");
debug_logger->attribute("token", fastTokenToId(Element));
debug_logger->attribute("type", getType());
#endif
@@ -314,8 +279,8 @@ uno::Reference< xml::sax::XFastContextHandler > SAL_CALL
uno::Reference< xml::sax::XFastContextHandler > xResult
(lcl_createFastChildContext(Element, Attribs));
-#ifdef DEBUG_CONTEXT_STACK
- debug_logger->endElement("createFastChildContext");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.createFastChildContext");
#endif
return xResult;
@@ -337,11 +302,11 @@ OOXMLFastContextHandler::createUnknownChildContext
const uno::Reference< xml::sax::XFastAttributeList > & /*Attribs*/)
throw (uno::RuntimeException, xml::sax::SAXException)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("createUnknownChildContext");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.createUnknownChildContext");
debug_logger->attribute("namespace", Namespace);
debug_logger->attribute("name", Name);
- debug_logger->endElement("createUnknownChildContext");
+ debug_logger->endElement("contexthandler.createUnknownChildContext");
#else
(void) Namespace;
(void) Name;
@@ -404,12 +369,12 @@ void OOXMLFastContextHandler::attributes
void OOXMLFastContextHandler::startAction(Token_t Element)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("startAction");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.startAction");
#endif
lcl_startAction(Element);
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("startAction");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.startAction");
#endif
}
@@ -420,12 +385,12 @@ void OOXMLFastContextHandler::lcl_startAction(Token_t Element)
void OOXMLFastContextHandler::endAction(Token_t Element)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("endAction");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.endAction");
#endif
lcl_endAction(Element);
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("endAction");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.endAction");
#endif
}
@@ -493,15 +458,15 @@ string OOXMLFastContextHandler::getResourceString() const
void OOXMLFastContextHandler::setId(Id rId)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("setId");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.setId");
static char sBuffer[256];
snprintf(sBuffer, sizeof(sBuffer), "%" SAL_PRIuUINT32, rId);
debug_logger->attribute("id", sBuffer);
- debug_logger->chars((*QNameToString::Instance())(rId));
- debug_logger->endElement("setId");
+ debug_logger->attribute("name", (*QNameToString::Instance())(rId));
+ debug_logger->endElement("contexthandler.setId");
#endif
mId = rId;
@@ -531,7 +496,7 @@ void OOXMLFastContextHandler::setToken(Token_t nToken)
{
mnToken = nToken;
-#ifdef DEBUG_CONTEXT_STACK
+#ifdef DEBUG_CONTEXT_HANDLER
msTokenString = fastTokenToId(mnToken);
#endif
}
@@ -547,11 +512,6 @@ void OOXMLFastContextHandler::mark(const Id & rId, OOXMLValue::Pointer_t pVal)
OOXMLPropertyImpl::Pointer_t pProperty
(new OOXMLPropertyImpl(rId, pVal, OOXMLPropertyImpl::ATTRIBUTE));
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("mark");
- debug_logger->chars(xmlify(pProperty->toString()));
- debug_logger->endElement("mark");
-#endif
pPropSet->add(pProperty);
mpStream->props(pPropSet);
}
@@ -571,8 +531,8 @@ OOXMLPropertySet * OOXMLFastContextHandler::getPicturePropSet
void OOXMLFastContextHandler::sendTableDepth() const
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendTableDepth");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendTableDepth");
#endif
if (mnTableDepth > 0)
@@ -593,15 +553,10 @@ void OOXMLFastContextHandler::sendTableDepth() const
pProps->add(pProp);
}
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("props");
- debug_logger->chars(pProps->toString());
- debug_logger->endElement("props");
-#endif
mpStream->props(writerfilter::Reference<Properties>::Pointer_t(pProps));
}
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendTableDepth");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendTableDepth");
#endif
}
@@ -613,6 +568,10 @@ void OOXMLFastContextHandler::setHandle()
void OOXMLFastContextHandler::startCharacterGroup()
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.startCharacterGroup");
+#endif
+
if (isForwardEvents())
{
if (mpParserState->isInCharacterGroup())
@@ -623,10 +582,6 @@ void OOXMLFastContextHandler::startCharacterGroup()
if (! mpParserState->isInCharacterGroup())
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("startCharacterGroup");
-#endif
-
mpStream->startCharacterGroup();
mpParserState->setInCharacterGroup(true);
mpParserState->resolveCharacterProperties(*mpStream);
@@ -636,12 +591,12 @@ void OOXMLFastContextHandler::startCharacterGroup()
void OOXMLFastContextHandler::endCharacterGroup()
{
- if (isForwardEvents() && mpParserState->isInCharacterGroup())
- {
-#ifdef DEBUG_ELEMENT
- debug_logger->element("endCharacterGroup");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.endCharacterGroup");
#endif
+ if (isForwardEvents() && mpParserState->isInCharacterGroup())
+ {
mpStream->endCharacterGroup();
mpParserState->setInCharacterGroup(false);
}
@@ -649,6 +604,10 @@ void OOXMLFastContextHandler::endCharacterGroup()
void OOXMLFastContextHandler::startParagraphGroup()
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.startParagraphGroup");
+#endif
+
if (isForwardEvents())
{
if (mpParserState->isInParagraphGroup())
@@ -659,10 +618,6 @@ void OOXMLFastContextHandler::startParagraphGroup()
if (! mpParserState->isInParagraphGroup())
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("startParagraphGroup");
-#endif
-
mpStream->startParagraphGroup();
mpParserState->setInParagraphGroup(true);
}
@@ -671,6 +626,10 @@ void OOXMLFastContextHandler::startParagraphGroup()
void OOXMLFastContextHandler::endParagraphGroup()
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.endParagraphGroup");
+#endif
+
if (isForwardEvents())
{
if (mpParserState->isInCharacterGroup())
@@ -678,9 +637,6 @@ void OOXMLFastContextHandler::endParagraphGroup()
if (mpParserState->isInParagraphGroup())
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("endParagraphGroup");
-#endif
mpStream->endParagraphGroup();
mpParserState->setInParagraphGroup(false);
}
@@ -689,6 +645,10 @@ void OOXMLFastContextHandler::endParagraphGroup()
void OOXMLFastContextHandler::startSectionGroup()
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.startSectionGroup");
+#endif
+
if (isForwardEvents())
{
if (mpParserState->isInSectionGroup())
@@ -696,9 +656,6 @@ void OOXMLFastContextHandler::startSectionGroup()
if (! mpParserState->isInSectionGroup())
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("startSectionGroup");
-#endif
mpStream->info(mpParserState->getHandle());
mpStream->startSectionGroup();
mpParserState->setInSectionGroup(true);
@@ -708,6 +665,10 @@ void OOXMLFastContextHandler::startSectionGroup()
void OOXMLFastContextHandler::endSectionGroup()
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.endSectionGroup");
+#endif
+
if (isForwardEvents())
{
if (mpParserState->isInParagraphGroup())
@@ -715,9 +676,6 @@ void OOXMLFastContextHandler::endSectionGroup()
if (mpParserState->isInSectionGroup())
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("endSectionGroup");
-#endif
mpStream->endSectionGroup();
mpParserState->setInSectionGroup(false);
}
@@ -726,10 +684,6 @@ void OOXMLFastContextHandler::endSectionGroup()
void OOXMLFastContextHandler::setLastParagraphInSection()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("setLastParagraphInSection");
-#endif
-
mpParserState->setLastParagraphInSection(true);
mpStream->markLastParagraphInSection( );
}
@@ -751,8 +705,8 @@ OOXMLPropertySet::Pointer_t OOXMLFastContextHandler::getPropertySet() const
void OOXMLFastContextHandler::startField()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("startField");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.startField");
#endif
startCharacterGroup();
if (isForwardEvents())
@@ -762,8 +716,8 @@ void OOXMLFastContextHandler::startField()
void OOXMLFastContextHandler::fieldSeparator()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("fieldSeparator");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.fieldSeparator");
#endif
startCharacterGroup();
if (isForwardEvents())
@@ -773,8 +727,8 @@ void OOXMLFastContextHandler::fieldSeparator()
void OOXMLFastContextHandler::endField()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("endField");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.endField");
#endif
startCharacterGroup();
if (isForwardEvents())
@@ -784,8 +738,8 @@ void OOXMLFastContextHandler::endField()
void OOXMLFastContextHandler::ftnednref()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("ftnednref");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.ftnednref");
#endif
if (isForwardEvents())
mpStream->utext(sFtnEdnRef, 1);
@@ -793,8 +747,8 @@ void OOXMLFastContextHandler::ftnednref()
void OOXMLFastContextHandler::ftnednsep()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("ftnednsep");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.ftnednsep");
#endif
if (isForwardEvents())
mpStream->utext(sFtnEdnSep, 1);
@@ -802,8 +756,8 @@ void OOXMLFastContextHandler::ftnednsep()
void OOXMLFastContextHandler::ftnedncont()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("ftnedncont");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.ftnedncont");
#endif
if (isForwardEvents())
mpStream->text(sFtnEdnCont, 1);
@@ -811,8 +765,8 @@ void OOXMLFastContextHandler::ftnedncont()
void OOXMLFastContextHandler::pgNum()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("pgNum");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.pgNum");
#endif
if (isForwardEvents())
mpStream->utext((const sal_uInt8*)sPgNum, 1);
@@ -820,8 +774,8 @@ void OOXMLFastContextHandler::pgNum()
void OOXMLFastContextHandler::tab()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("tab");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.tab");
#endif
if (isForwardEvents())
mpStream->utext((const sal_uInt8*)sTab, 1);
@@ -829,8 +783,8 @@ void OOXMLFastContextHandler::tab()
void OOXMLFastContextHandler::cr()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("cr");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.cr");
#endif
if (isForwardEvents())
mpStream->utext((const sal_uInt8*)sCR, 1);
@@ -838,8 +792,8 @@ void OOXMLFastContextHandler::cr()
void OOXMLFastContextHandler::noBreakHyphen()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("noBreakHyphen");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.noBreakHyphen");
#endif
if (isForwardEvents())
mpStream->utext((const sal_uInt8*)sNoBreakHyphen, 1);
@@ -847,8 +801,8 @@ void OOXMLFastContextHandler::noBreakHyphen()
void OOXMLFastContextHandler::softHyphen()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("softHyphen");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.softHyphen");
#endif
if (isForwardEvents())
mpStream->utext((const sal_uInt8*)sSoftHyphen, 1);
@@ -856,8 +810,8 @@ void OOXMLFastContextHandler::softHyphen()
void OOXMLFastContextHandler::handleLastParagraphInSection()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("handleLastParagraphInSection");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.handleLastParagraphInSection");
#endif
if (mpParserState->isLastParagraphInSection())
@@ -869,8 +823,8 @@ void OOXMLFastContextHandler::handleLastParagraphInSection()
void OOXMLFastContextHandler::endOfParagraph()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("endOfParagraph");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.endOfParagraph");
#endif
if (! mpParserState->isInCharacterGroup())
startCharacterGroup();
@@ -880,10 +834,10 @@ void OOXMLFastContextHandler::endOfParagraph()
void OOXMLFastContextHandler::text(const ::rtl::OUString & sText)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("text");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.text");
debug_logger->chars(sText);
- debug_logger->endElement("text");
+ debug_logger->endElement("contexthandler.text");
#endif
if (isForwardEvents())
mpStream->utext(reinterpret_cast < const sal_uInt8 * >
@@ -893,10 +847,10 @@ void OOXMLFastContextHandler::text(const ::rtl::OUString & sText)
void OOXMLFastContextHandler::propagateCharacterProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("propagateCharacterProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.propagateCharacterProperties");
debug_logger->addTag(toPropertiesTag(getPropertySet()));
- debug_logger->endElement("propagateCharacterProperties");
+ debug_logger->endElement("contexthandler.propagateCharacterProperties");
#endif
mpParserState->setCharacterProperties(getPropertySet());
@@ -904,10 +858,10 @@ void OOXMLFastContextHandler::propagateCharacterProperties()
void OOXMLFastContextHandler::propagateCharacterPropertiesAsSet(const Id & rId)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("propagateCharacterPropertiesAsSet");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.propagateCharacterPropertiesAsSet");
debug_logger->addTag(toPropertiesTag(getPropertySet()));
- debug_logger->endElement("propagateCharacterPropertiesAsSet");
+ debug_logger->endElement("contexthandler.propagateCharacterPropertiesAsSet");
#endif
OOXMLValue::Pointer_t pValue(new OOXMLPropertySetValue(getPropertySet()));
@@ -927,8 +881,8 @@ bool OOXMLFastContextHandler::propagatesProperties() const
void OOXMLFastContextHandler::propagateCellProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("propagateCellProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.propagateCellProperties");
#endif
mpParserState->setCellProperties(getPropertySet());
@@ -936,8 +890,8 @@ void OOXMLFastContextHandler::propagateCellProperties()
void OOXMLFastContextHandler::propagateRowProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("propagateRowProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.propagateRowProperties");
#endif
mpParserState->setRowProperties(getPropertySet());
@@ -946,10 +900,10 @@ void OOXMLFastContextHandler::propagateRowProperties()
void OOXMLFastContextHandler::propagateTableProperties()
{
OOXMLPropertySet::Pointer_t pProps = getPropertySet();
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("propagateTableProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.propagateTableProperties");
debug_logger->addTag(toPropertiesTag(pProps));
- debug_logger->endElement("propagateTableProperties");
+ debug_logger->endElement("contexthandler.propagateTableProperties");
#endif
mpParserState->setTableProperties(pProps);
@@ -957,47 +911,47 @@ void OOXMLFastContextHandler::propagateTableProperties()
void OOXMLFastContextHandler::sendCellProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendCellProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendCellProperties");
#endif
mpParserState->resolveCellProperties(*mpStream);
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendCellProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendCellProperties");
#endif
}
void OOXMLFastContextHandler::sendRowProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendRowProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendRowProperties");
#endif
mpParserState->resolveRowProperties(*mpStream);
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendRowProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendRowProperties");
#endif
}
void OOXMLFastContextHandler::sendTableProperties()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendTableProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendTableProperties");
#endif
mpParserState->resolveTableProperties(*mpStream);
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendTableProperties");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendTableProperties");
#endif
}
void OOXMLFastContextHandler::clearTableProps()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("clearTableProps");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.clearTableProps");
#endif
mpParserState->setTableProperties(OOXMLPropertySet::Pointer_t
@@ -1006,8 +960,8 @@ void OOXMLFastContextHandler::clearTableProps()
void OOXMLFastContextHandler::sendPropertiesWithId(const Id & rId)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendPropertiesWithId");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendPropertiesWithId");
debug_logger->attribute("id", fastTokenToId(rId));
#endif
@@ -1020,16 +974,16 @@ void OOXMLFastContextHandler::sendPropertiesWithId(const Id & rId)
pPropertySet->add(pProp);
mpStream->props(pPropertySet);
-#ifdef DEBUG_ELEMENT
+#ifdef DEBUG_CONTEXT_HANDLER
debug_logger->addTag(toPropertiesTag(pPropertySet));
- debug_logger->endElement("sendPropertiesWithId");
+ debug_logger->endElement("contexthandler.sendPropertiesWithId");
#endif
}
void OOXMLFastContextHandler::clearProps()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->element("clearProps");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->element("contexthandler.clearProps");
#endif
setPropertySet(OOXMLPropertySet::Pointer_t(new OOXMLPropertySetImpl()));
@@ -1063,15 +1017,15 @@ OOXMLDocument * OOXMLFastContextHandler::getDocument()
void OOXMLFastContextHandler::setForwardEvents(bool bForwardEvents)
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("setForwardEvents");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.setForwardEvents");
if (bForwardEvents)
debug_logger->chars("true");
else
debug_logger->chars("false");
- debug_logger->endElement("setForwardEvents");
+ debug_logger->endElement("contexthandler.setForwardEvents");
#endif
mpParserState->setForwardEvents(bForwardEvents);
@@ -1154,8 +1108,8 @@ void OOXMLFastContextHandler::resolvePropertySetAttrs()
void OOXMLFastContextHandler::sendPropertyToParent()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendPropertyToParent");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendPropertyToParent");
#endif
if (mpParent != NULL)
@@ -1169,21 +1123,21 @@ void OOXMLFastContextHandler::sendPropertyToParent()
OOXMLPropertyImpl::SPRM));
pProps->add(pProp);
-#ifdef DEBUG_ELEMENT
+#ifdef DEBUG_CONTEXT_HANDLER
debug_logger->addTag(toPropertiesTag(pProps));
#endif
}
}
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendPropertyToParent");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendPropertyToParent");
#endif
}
void OOXMLFastContextHandler::sendPropertiesToParent()
{
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("sendPropertiesToParent");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendPropertiesToParent");
#endif
if (mpParent != NULL)
{
@@ -1193,12 +1147,6 @@ void OOXMLFastContextHandler::sendPropertiesToParent()
{
OOXMLPropertySet::Pointer_t pProps(getPropertySet());
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("me");
- debug_logger->addTag(toPropertiesTag(pProps));
- debug_logger->endElement("me");
-#endif
-
if (pProps.get() != NULL)
{
OOXMLValue::Pointer_t pValue
@@ -1207,24 +1155,12 @@ void OOXMLFastContextHandler::sendPropertiesToParent()
OOXMLProperty::Pointer_t pProp
(new OOXMLPropertyImpl(getId(), pValue, OOXMLPropertyImpl::SPRM));
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("propertyForSet");
- debug_logger->chars(pProp->toString());
- debug_logger->endElement("propertyForSet");
-#endif
-
pParentProps->add(pProp);
-
-#ifdef DEBUG_ELEMENT
- debug_logger->startElement("parent");
- debug_logger->addTag(toPropertiesTag(pParentProps));
- debug_logger->endElement("parent");
-#endif
}
}
}
-#ifdef DEBUG_ELEMENT
- debug_logger->endElement("sendPropertiesToParent");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.sendPropertiesToParent");
#endif
}
@@ -1263,11 +1199,11 @@ void OOXMLFastContextHandlerStream::newProperty(const Id & rId,
void OOXMLFastContextHandlerStream::sendProperty(Id nId)
{
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("sendProperty");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.sendProperty");
debug_logger->attribute("id", (*QNameToString::Instance())(nId));
debug_logger->chars(xmlify(getPropertySetAttrs()->toString()));
- debug_logger->endElement("sendProperty");
+ debug_logger->endElement("contexthandler.sendProperty");
#endif
OOXMLPropertySetEntryToString aHandler(nId);
@@ -1286,10 +1222,10 @@ OOXMLFastContextHandlerStream::getPropertySetAttrs() const
void OOXMLFastContextHandlerStream::resolvePropertySetAttrs()
{
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("resolvePropertySetAttrs");
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.resolvePropertySetAttrs");
debug_logger->chars(mpPropertySetAttrs->toString());
- debug_logger->endElement("resolvePropertySetAttrs");
+ debug_logger->endElement("contexthandler.resolvePropertySetAttrs");
#endif
mpStream->props(mpPropertySetAttrs);
}
@@ -1339,13 +1275,7 @@ void OOXMLFastContextHandlerProperties::lcl_endFastElement
{
if (isForwardEvents())
{
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("sendproperties");
-#endif
mpStream->props(mpPropertySet);
-#ifdef DEBUG_PROPERTIES
- debug_logger->endElement("sendproperties");
-#endif
}
}
else
@@ -1544,7 +1474,16 @@ OOXMLFastContextHandlerValue::~OOXMLFastContextHandlerValue()
void OOXMLFastContextHandlerValue::setValue(OOXMLValue::Pointer_t pValue)
{
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->startElement("contexthandler.setValue");
+ debug_logger->attribute("value", pValue->toString());
+#endif
+
mpValue = pValue;
+
+#ifdef DEBUG_CONTEXT_HANDLER
+ debug_logger->endElement("contexthandler.setValue");
+#endif
}
OOXMLValue::Pointer_t OOXMLFastContextHandlerValue::getValue() const
diff --git a/writerfilter/source/ooxml/OOXMLFastContextHandler.hxx b/writerfilter/source/ooxml/OOXMLFastContextHandler.hxx
index 0c441f62a180..59ee2cc42080 100644
--- a/writerfilter/source/ooxml/OOXMLFastContextHandler.hxx
+++ b/writerfilter/source/ooxml/OOXMLFastContextHandler.hxx
@@ -230,18 +230,13 @@ public:
virtual string toString() const;
#endif
-#ifdef DEBUG_MEMORY
- virtual void SAL_CALL acquire() throw();
- virtual void SAL_CALL release() throw();
-#endif
-
protected:
OOXMLFastContextHandler * mpParent;
Id mId;
Id mnDefine;
Token_t mnToken;
-#ifdef DEBUG_CONTEXT_STACK
+#ifdef DEBUG_CONTEXT_HANDLER
string msTokenString;
#endif
diff --git a/writerfilter/source/ooxml/OOXMLFastHelper.hxx b/writerfilter/source/ooxml/OOXMLFastHelper.hxx
index 5d4587922a54..961b4660f036 100644
--- a/writerfilter/source/ooxml/OOXMLFastHelper.hxx
+++ b/writerfilter/source/ooxml/OOXMLFastHelper.hxx
@@ -74,6 +74,12 @@ uno::Reference<XFastContextHandler>
OOXMLFastHelper<T>::createAndSetParent
(OOXMLFastContextHandler * pHandler, sal_uInt32 nToken, Id nId)
{
+#ifdef DEBUG_HELPER
+ debug_logger->startElement("helper.createAndSetParent");
+ debug_logger->attribute("context", pHandler->getType());
+ debug_logger->attribute("id", (*QNameToString::Instance())(nId));
+#endif
+
OOXMLFastContextHandler * pTmp = new T(pHandler);
pTmp->setToken(nToken);
@@ -88,7 +94,7 @@ OOXMLFastHelper<T>::createAndSetParent
debug_logger->startElement("created");
debug_logger->addTag(pTmp->toTag());
debug_logger->endElement("created");
- debug_logger->endElement("createAndSetParent");
+ debug_logger->endElement("helper.createAndSetParent");
#endif
uno::Reference<XFastContextHandler> aResult(pTmp);
@@ -101,27 +107,29 @@ uno::Reference<XFastContextHandler>
OOXMLFastHelper<T>::createAndSetParentAndDefine
(OOXMLFastContextHandler * pHandler, sal_uInt32 nToken, Id nId, Id nDefine)
{
- OOXMLFastContextHandler * pTmp = new T(pHandler);
-
- pTmp->setToken(nToken);
- pTmp->setId(nId);
- pTmp->setDefine(nDefine);
-
-#ifdef DEBUG_CREATE
- debug_logger->startElement("createAndSetParentAndDefine");
+#ifdef DEBUG_HELPER
+ debug_logger->startElement("helper.createAndSetParentAndDefine");
debug_logger->attribute("context", pHandler->getType());
- debug_logger->attribute("token", fastTokenToId(pTmp->getToken()));
debug_logger->attribute("id", (*QNameToString::Instance())(nId));
static char buffer[16];
snprintf(buffer, sizeof(buffer), "0x%08" SAL_PRIxUINT32, nId);
debug_logger->attribute("idnum", buffer);
+#endif
+
+ OOXMLFastContextHandler * pTmp = new T(pHandler);
+
+ pTmp->setToken(nToken);
+ pTmp->setId(nId);
+ pTmp->setDefine(nDefine);
+
+#ifdef DEBUG_HELPER
debug_logger->startElement("created");
debug_logger->addTag(pTmp->toTag());
debug_logger->endElement("created");
- debug_logger->endElement("createAndSetParentAndDefine");
+ debug_logger->endElement("helper.createAndSetParentAndDefine");
#endif
uno::Reference<XFastContextHandler> aResult(pTmp);
@@ -135,6 +143,12 @@ OOXMLFastHelper<T>::createAndSetParentRef
(OOXMLFastContextHandler * pHandler, sal_uInt32 nToken,
const uno::Reference < xml::sax::XFastAttributeList > & Attribs)
{
+#ifdef DEBUG_HELPER
+ debug_logger->startElement("helper.createAndSetParentRef");
+ debug_logger->attribute("context", pHandler->getType());
+ debug_logger->attribute("type", fastTokenToId(nToken));
+#endif
+
boost::shared_ptr<OOXMLFastContextHandler> pTmp(new T(pHandler));
uno::Reference<XFastContextHandler> xChild =
@@ -149,15 +163,11 @@ OOXMLFastHelper<T>::createAndSetParentRef
}
-#ifdef DEBUG_CREATE
- debug_logger->startElement("createAndSetParentRef");
- debug_logger->attribute("context", pHandler->getType());
- debug_logger->attribute("type", fastTokenToId(nToken));
-
+#ifdef DEBUG_HELPER
debug_logger->startElement("created");
- debug_logger->chars(pTmp->getType());
+ debug_logger->addTag(pTmp->toTag());
debug_logger->endElement("created");
- debug_logger->endElement("createAndSetParentRef");
+ debug_logger->endElement("helper.createAndSetParentRef");
#endif
return xChild;
@@ -170,7 +180,7 @@ void OOXMLFastHelper<T>::newProperty(OOXMLFastContextHandler * pHandler,
{
OOXMLValue::Pointer_t pVal(new T(rValue));
-#ifdef DEBUG_PROPERTIES
+#ifdef DEBUG_HELPER
string aStr = (*QNameToString::Instance())(nId);
debug_logger->startElement("newProperty-from-string");
@@ -182,11 +192,14 @@ void OOXMLFastHelper<T>::newProperty(OOXMLFastContextHandler * pHandler,
if (aStr.size() == 0)
debug_logger->addTag(XMLTag::Pointer_t(new XMLTag("unknown-qname")));
+#endif
+ pHandler->newProperty(nId, pVal);
+
+#ifdef DEBUG_HELPER
debug_logger->endElement("newProperty-from-string");
#endif
- pHandler->newProperty(nId, pVal);
}
template <class T>
@@ -196,17 +209,17 @@ void OOXMLFastHelper<T>::newProperty(OOXMLFastContextHandler * pHandler,
{
OOXMLValue::Pointer_t pVal(new T(nVal));
-#ifdef DEBUG_PROPERTIES
+#ifdef DEBUG_HELPER
string aStr = (*QNameToString::Instance())(nId);
- debug_logger->startElement("newProperty-from-int");
+ debug_logger->startElement("helper.newProperty-from-int");
debug_logger->attribute("name", aStr);
debug_logger->attribute("value", pVal->toString());
if (aStr.size() == 0)
debug_logger->addTag(XMLTag::Pointer_t(new XMLTag("unknown-qname")));
- debug_logger->endElement("newProperty-from-int");
+ debug_logger->endElement("helper.newProperty-from-int");
#endif
pHandler->newProperty(nId, pVal);
@@ -221,8 +234,8 @@ void OOXMLFastHelper<T>::mark(OOXMLFastContextHandler * pHandler,
string aStr = (*QNameToString::Instance())(nId);
-#ifdef DEBUG_PROPERTIES
- debug_logger->startElement("mark");
+#ifdef DEBUG_HELPER
+ debug_logger->startElement("helper.mark");
debug_logger->attribute("name", aStr);
debug_logger->attribute
("value",
@@ -232,22 +245,10 @@ void OOXMLFastHelper<T>::mark(OOXMLFastContextHandler * pHandler,
if (aStr.size() == 0)
debug_logger->addTag(XMLTag::Pointer_t(new XMLTag("unknown-qname")));
- debug_logger->endElement("mark");
+ debug_logger->endElement("helper.mark");
#endif
pHandler->mark(nId, pVal);
}
-
-template <class T>
-void OOXMLFastHelper<T>::attributes
-(OOXMLFastContextHandler * pContext,
- const uno::Reference < xml::sax::XFastAttributeList > & Attribs)
- {
- T aContext(pContext);
-
- aContext.setPropertySet(pContext->getPropertySet());
- aContext.attributes(Attribs);
-}
-
}}
#endif // INCLUDED_FAST_HELPER_HXX
diff --git a/writerfilter/source/ooxml/OOXMLParserState.cxx b/writerfilter/source/ooxml/OOXMLParserState.cxx
index fb347d02048e..41a3738ee7ab 100644
--- a/writerfilter/source/ooxml/OOXMLParserState.cxx
+++ b/writerfilter/source/ooxml/OOXMLParserState.cxx
@@ -320,6 +320,11 @@ XMLTag::Pointer_t OOXMLParserState::toTag() const
return pTag;
}
+
+XPathLogger & OOXMLParserState::getXPathLogger()
+{
+ return m_xPathLogger;
+}
#endif
}}
diff --git a/writerfilter/source/ooxml/OOXMLParserState.hxx b/writerfilter/source/ooxml/OOXMLParserState.hxx
index 2dd118a5b96b..12a9876ce6eb 100644
--- a/writerfilter/source/ooxml/OOXMLParserState.hxx
+++ b/writerfilter/source/ooxml/OOXMLParserState.hxx
@@ -33,6 +33,7 @@
#ifdef DEBUG
#include <resourcemodel/TagLogger.hxx>
+#include <resourcemodel/XPathLogger.hxx>
#endif
namespace writerfilter {
@@ -57,6 +58,9 @@ class OOXMLParserState
stack<OOXMLPropertySet::Pointer_t> mCellProps;
stack<OOXMLPropertySet::Pointer_t> mRowProps;
stack<OOXMLPropertySet::Pointer_t> mTableProps;
+#ifdef DEBUG
+ XPathLogger m_xPathLogger;
+#endif
public:
typedef boost::shared_ptr<OOXMLParserState> Pointer_t;
@@ -109,6 +113,7 @@ public:
unsigned int getContextCount() const;
string toString() const;
XMLTag::Pointer_t toTag() const;
+ XPathLogger & getXPathLogger();
#endif
};
diff --git a/writerfilter/source/ooxml/OOXMLPropertySetImpl.cxx b/writerfilter/source/ooxml/OOXMLPropertySetImpl.cxx
index f106972b23c0..6e0bcaf763cd 100644
--- a/writerfilter/source/ooxml/OOXMLPropertySetImpl.cxx
+++ b/writerfilter/source/ooxml/OOXMLPropertySetImpl.cxx
@@ -34,8 +34,6 @@
#include <ooxml/OOXMLFastTokens.hxx>
#include "ooxmlLoggers.hxx"
-//#define DEBUG_RESOLVE
-
namespace writerfilter {
namespace ooxml
{
@@ -474,15 +472,22 @@ string OOXMLPropertySetImpl::getType() const
void OOXMLPropertySetImpl::add(OOXMLProperty::Pointer_t pProperty)
{
+#ifdef DEBUG_PROPERTY_SET
+ debug_logger->startElement("propertyset.add");
+ debug_logger->chars(pProperty->toString());
+#endif
+
if (pProperty.get() != NULL && pProperty->getId() != 0x0)
{
mProperties.push_back(pProperty);
}
-#ifdef DEBUG_PROPERTIES
+#ifdef DEBUG_PROPERTY_SET
else
{
debug_logger->element("warning.property_not_added");
}
+
+ debug_logger->endElement("propertyset.add");
#endif
}
diff --git a/writerfilter/source/ooxml/analyzemodel.xsl b/writerfilter/source/ooxml/analyzemodel.xsl
index d887a9a178a6..3cce9795a947 100644
--- a/writerfilter/source/ooxml/analyzemodel.xsl
+++ b/writerfilter/source/ooxml/analyzemodel.xsl
@@ -98,6 +98,7 @@
</xsl:for-each>
</xsl:when>
</xsl:choose>
+ <xsl:copy-of select="@tag"/>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet> \ No newline at end of file
diff --git a/writerfilter/source/ooxml/effort.xsl b/writerfilter/source/ooxml/effort.xsl
index 47f278a63f4f..3dfc102e0780 100644
--- a/writerfilter/source/ooxml/effort.xsl
+++ b/writerfilter/source/ooxml/effort.xsl
@@ -7,33 +7,40 @@
<xsl:output method="text"/>
<xsl:template match="/">
- <xsl:text>Namespace,Define,Name,Done,Planned,qname-count&#xa;</xsl:text>
- <xsl:for-each select="/todo/attribute|/todo/element">
- <xsl:for-each select=".//status">
- <xsl:for-each select="ancestor::attribute|ancestor::element">
- <xsl:value-of select="@namespace"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@define"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@name"/>
- <xsl:text>,</xsl:text>
- </xsl:for-each>
- <xsl:value-of select="@done"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@planned"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@qname-count"/>
- <xsl:text>&#xa;</xsl:text>
- </xsl:for-each>
- <xsl:if test="not(.//status)">
- <xsl:value-of select="@namespace"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@define"/>
- <xsl:text>,</xsl:text>
- <xsl:value-of select="@name"/>
- <xsl:text>,0,0.5,1&#xa;</xsl:text>
- </xsl:if>
+ <xsl:text>Namespace,Define,Name,Tag,Done,Planned,qname-count&#xa;</xsl:text>
+ <xsl:for-each select="/todo/attribute|/todo/element">
+ <xsl:variable name="namespace" select="@namespace"/>
+ <xsl:variable name="define" select="@define"/>
+ <xsl:variable name="name" select="@name"/>
+ <xsl:variable name="tag" select="@tag"/>
+
+ <xsl:for-each select=".//status">
+ <xsl:value-of select="$namespace"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$define"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$name"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$tag"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="@done"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="@planned"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="@qname-count"/>
+ <xsl:text>&#xa;</xsl:text>
</xsl:for-each>
+ <xsl:if test="not(.//status)">
+ <xsl:value-of select="$namespace"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$define"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$name"/>
+ <xsl:text>,</xsl:text>
+ <xsl:value-of select="$tag"/>
+ <xsl:text>,0,0.5,1&#xa;</xsl:text>
+ </xsl:if>
+ </xsl:for-each>
</xsl:template>
</xsl:stylesheet> \ No newline at end of file
diff --git a/writerfilter/source/ooxml/factory_ns.xsl b/writerfilter/source/ooxml/factory_ns.xsl
index 44b5c824859f..0349d832128d 100644
--- a/writerfilter/source/ooxml/factory_ns.xsl
+++ b/writerfilter/source/ooxml/factory_ns.xsl
@@ -69,19 +69,18 @@
<xsl:template name="factoryactiondecls">
<xsl:variable name="ns" select="@name"/>
- <xsl:for-each select="resource/action">
+ <xsl:for-each select="resource/action[not(@name='characters')]">
<xsl:sort select="@name"/>
<xsl:if test="generate-id(key('actions', @name)[ancestor::namespace/@name=$ns][1]) = generate-id(.)">
<xsl:text>
void </xsl:text>
<xsl:value-of select="@name"/>
<xsl:text>Action(OOXMLFastContextHandler * pHandler</xsl:text>
- <xsl:if test="@name='characters'">
- <xsl:text>, const ::rtl::OUString &amp; sText</xsl:text>
- </xsl:if>
<xsl:text>);</xsl:text>
</xsl:if>
</xsl:for-each>
+ <xsl:text>
+ virtual void charactersAction(OOXMLFastContextHandler * pHandler, const ::rtl::OUString &amp; sText);</xsl:text>
</xsl:template>
<!-- factorydecl -->
@@ -106,6 +105,10 @@ public:
virtual string getDefineName(Id nId) const;</xsl:text>
<xsl:call-template name="factoryactiondecls"/>
virtual void attributeAction(OOXMLFastContextHandler * pHandler, Token_t nToken, OOXMLValue::Pointer_t pValue);
+
+#ifdef DEBUG_FACTORY
+ virtual string getName() const;
+#endif
<xsl:text>
virtual ~</xsl:text>
diff --git a/writerfilter/source/ooxml/factoryimpl.xsl b/writerfilter/source/ooxml/factoryimpl.xsl
index 8eecf4aba813..781883b761e5 100644
--- a/writerfilter/source/ooxml/factoryimpl.xsl
+++ b/writerfilter/source/ooxml/factoryimpl.xsl
@@ -78,6 +78,10 @@ uno::Reference&lt; xml::sax::XFastContextHandler &gt; OOXMLFactory::createFastCh
uno::Reference &lt; xml::sax::XFastContextHandler &gt; aResult;
Id nDefine = pHandler->getDefine();
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.createFastChildContextFromFactory");
+#endif
+
if (pFactory.get() != NULL)
{
CreateElementMapPointer pMap = pFactory-&gt;getCreateElementMap(nDefine);
@@ -86,12 +90,13 @@ uno::Reference&lt; xml::sax::XFastContextHandler &gt; OOXMLFactory::createFastCh
if (pMap.get() != NULL)
{
Id nId = (*pTokenMap)[Element];
-#ifdef DEBUG_CREATE
+#ifdef DEBUG_FACTORY
+ string sFactoryName(pFactory->getName());
string sDefine(pFactory->getDefineName(nDefine));
string sElement(fastTokenToId(Element));
string sQName((*QNameToString::Instance())(nId));
- debug_logger->startElement("createFastChildContextFromFactory");
+ debug_logger->attribute("factory-name", sFactoryName);
debug_logger->attribute("define", sDefine);
debug_logger->attribute("element", sElement);
debug_logger->attribute("qname", sQName);
@@ -134,12 +139,13 @@ uno::Reference&lt; xml::sax::XFastContextHandler &gt; OOXMLFactory::createFastCh
break;
}
-#ifdef DEBUG_CREATE
- debug_logger->endElement("createFastChildContextFromFactory");
-#endif
}
}
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.createFastChildContextFromFactory");
+#endif
+
return aResult;
}
</xsl:text>
@@ -178,8 +184,8 @@ OOXMLFactory_ns::Pointer_t OOXMLFactory::getFactoryForNamespace(Id nId)
uno::Reference&lt; xml::sax::XFastContextHandler &gt; OOXMLFactory::createFastChildContextFromStart
(OOXMLFastContextHandler * pHandler, Token_t Element)
{
-#ifdef DEBUG_CREATE
- debug_logger->startElement("createFastChildContextFromStart");
+#ifdef DEBUG_FACTORY
+ debug_logger->startElement("factory.createFastChildContextFromStart");
#endif
uno::Reference &lt; xml::sax::XFastContextHandler &gt; aResult;
@@ -198,8 +204,8 @@ uno::Reference&lt; xml::sax::XFastContextHandler &gt; OOXMLFactory::createFastCh
</xsl:for-each>
<xsl:text>
-#ifdef DEBUG_CREATE
- debug_logger->endElement("createFastChildContextFromStart");
+#ifdef DEBUG_FACTORY
+ debug_logger->endElement("factory.createFastChildContextFromStart");
#endif
return aResult;
}
diff --git a/writerfilter/source/ooxml/factoryimpl_ns.xsl b/writerfilter/source/ooxml/factoryimpl_ns.xsl
index 533c3d16ae23..adc4c977e1f9 100644
--- a/writerfilter/source/ooxml/factoryimpl_ns.xsl
+++ b/writerfilter/source/ooxml/factoryimpl_ns.xsl
@@ -143,6 +143,47 @@ OOXMLFactory_ns::Pointer_t </xsl:text>
</xsl:text>
</xsl:template>
+<!--
+ Returns resource for attribute.
+-->
+
+<xsl:template name="resourceforattribute">
+ <xsl:variable name="mynsid" select="generate-id(ancestor::namespace)"/>
+ <xsl:for-each select="rng:ref">
+ <xsl:variable name="name" select="@name"/>
+ <xsl:variable name="resource1">
+ <xsl:for-each select="key('context-resource', @name)[generate-id(ancestor::namespace) = $mynsid]">
+ <xsl:value-of select="@resource"/>
+ </xsl:for-each>
+ </xsl:variable>
+ <xsl:choose>
+ <xsl:when test="string-length($resource1) > 0">
+ <xsl:value-of select="$resource1"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:for-each select="ancestor::namespace/rng:grammar/rng:define[@name=$name]">
+ <xsl:call-template name="resourceforattribute"/>
+ </xsl:for-each>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:for-each>
+ <xsl:for-each select=".//rng:text">
+ <xsl:text>String</xsl:text>
+ </xsl:for-each>
+ <xsl:for-each select=".//rng:data[@type='base64Binary']">
+ <xsl:text>String</xsl:text>
+ </xsl:for-each>
+ <xsl:for-each select=".//rng:data[@type='boolean']">
+ <xsl:text>Boolean</xsl:text>
+ </xsl:for-each>
+ <xsl:for-each select=".//rng:data[@type='unsignedInt']">
+ <xsl:text>Integer</xsl:text>
+ </xsl:for-each>
+ <xsl:for-each select=".//rng:data[@type='int']">
+ <xsl:text>Integer</xsl:text>
+ </xsl:for-each>
+</xsl:template>
+
<!--
creates code block in OOXMLFactory_<namespace>::createAttributeToResourceMap
@@ -164,42 +205,30 @@ for a rng:define
// </xsl:text>
<xsl:value-of select="$defname"/>
</xsl:if>
- <xsl:variable name="mynsid" select="generate-id(ancestor::namespace)"/>
<xsl:variable name="resource">
- <xsl:for-each select="rng:ref">
- <xsl:for-each select="key('context-resource', @name)[generate-id(ancestor::namespace) = $mynsid]">
- <xsl:value-of select="@resource"/>
- </xsl:for-each>
- </xsl:for-each>
- <xsl:for-each select=".//rng:text">
- <xsl:text>String</xsl:text>
- </xsl:for-each>
- <xsl:for-each select=".//rng:data[@type='base64Binary']">
- <xsl:text>String</xsl:text>
- </xsl:for-each>
- </xsl:variable>
-
- <xsl:variable name="refdefine1">
- <xsl:for-each select="rng:ref">
- <xsl:variable name="refname" select="@name"/>
- <xsl:for-each select="ancestor::rng:grammar/rng:define[@name=$refname]">
- <xsl:call-template name="idfordefine"/>
- </xsl:for-each>
- </xsl:for-each>
- </xsl:variable>
- <xsl:variable name="refdefine">
- <xsl:choose>
- <xsl:when test="string-length($refdefine1) > 0">
- <xsl:value-of select="$refdefine1"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:text>0</xsl:text>
- </xsl:otherwise>
- </xsl:choose>
+ <xsl:call-template name="resourceforattribute"/>
</xsl:variable>
<xsl:choose>
<xsl:when test="string-length($resource) > 0">
+ <xsl:variable name="refdefine1">
+ <xsl:for-each select="rng:ref">
+ <xsl:variable name="refname" select="@name"/>
+ <xsl:for-each select="ancestor::rng:grammar/rng:define[@name=$refname]">
+ <xsl:call-template name="idfordefine"/>
+ </xsl:for-each>
+ </xsl:for-each>
+ </xsl:variable>
+ <xsl:variable name="refdefine">
+ <xsl:choose>
+ <xsl:when test="string-length($refdefine1) > 0">
+ <xsl:value-of select="$refdefine1"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:text>0</xsl:text>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
<xsl:text>
(*pMap)[</xsl:text>
<xsl:call-template name="fasttoken"/>
@@ -541,42 +570,103 @@ CreateElementMapPointer </xsl:text>
<!-- factoryaction -->
<xsl:template name="factoryaction">
- <xsl:param name="action"/>
- <xsl:text>
-void </xsl:text>
- <xsl:call-template name="factoryclassname"/>
- <xsl:text>::</xsl:text>
- <xsl:value-of select="$action"/>
- <xsl:text>Action(OOXMLFastContextHandler * pHandler</xsl:text>
+ <xsl:param name="action"/>
+ <xsl:variable name="switchblock1">
+ <xsl:for-each select="resource[action/@name=$action]">
+ <xsl:text>
+ </xsl:text>
+ <xsl:call-template name="caselabeldefine"/>
+ <xsl:for-each select="action[@name=$action]">
+ <xsl:call-template name="factorychooseaction"/>
+ </xsl:for-each>
+ <xsl:text> break;&#xa;</xsl:text>
+ </xsl:for-each>
+ </xsl:variable>
+ <xsl:variable name="switchblock2">
<xsl:if test="$action='characters'">
- <xsl:text>, const ::rtl::OUString &amp; sText</xsl:text>
+ <xsl:for-each select="resource[@resource='Value']">
+ <xsl:if test="count(attribute) = 0">
+ <xsl:variable name="name" select="@name"/>
+ <xsl:text> </xsl:text>
+ <xsl:call-template name="caselabeldefine"/>
+ <xsl:text>&#xa;</xsl:text>
+ <xsl:for-each select="ancestor::namespace/rng:grammar/rng:define[@name=$name]">
+ <xsl:for-each select="rng:ref">
+ <xsl:call-template name="charactersactionforvalues"/>
+ </xsl:for-each>
+ </xsl:for-each>
+ <xsl:text> break;&#xa;</xsl:text>
+ </xsl:if>
+ </xsl:for-each>
</xsl:if>
- <xsl:text>)
-{
- switch (pHandler->getDefine())
- {</xsl:text>
- <xsl:for-each select="resource[action/@name=$action]">
- <xsl:text>
- </xsl:text>
- <xsl:call-template name="caselabeldefine"/>
- <xsl:for-each select="action[@name=$action]">
- <xsl:call-template name="factorychooseaction"/>
- </xsl:for-each>
- <xsl:text>
- break;</xsl:text>
+ </xsl:variable>
+ <xsl:text>&#xa;&#xa;</xsl:text>
+ <xsl:text>void </xsl:text>
+ <xsl:call-template name="factoryclassname"/>
+ <xsl:text>::</xsl:text>
+ <xsl:value-of select="$action"/>
+ <xsl:text>Action(OOXMLFastContextHandler*</xsl:text>
+ <xsl:if test="string-length($switchblock1) &gt; 0 or string-length($switchblock2) &gt; 0">
+ <xsl:text> pHandler</xsl:text>
+ </xsl:if>
+ <xsl:if test="$action='characters'">
+ <xsl:text>, const ::rtl::OUString &amp;</xsl:text>
+ <xsl:if test="contains($switchblock1, 'sText') or contains($switchblock2, 'sText')">
+ <xsl:text> sText</xsl:text>
+ </xsl:if>
+ </xsl:if>
+ <xsl:text>)&#xa;</xsl:text>
+ <xsl:text>{&#xa;</xsl:text>
+ <xsl:if test="string-length($switchblock1) > 0 or string-length($switchblock2) > 0">
+ <xsl:text> sal_uInt32 nDefine = pHandler->getDefine();&#xa;</xsl:text>
+ </xsl:if>
+ <xsl:if test="string-length($switchblock1) > 0">
+ <xsl:text> switch (nDefine)&#xa;</xsl:text>
+ <xsl:text> {&#xa;</xsl:text>
+ <xsl:value-of select="$switchblock1"/>
+ <xsl:text> default:&#xa;</xsl:text>
+ <xsl:text> break;&#xa;</xsl:text>
+ <xsl:text> }&#xa;</xsl:text>
+ </xsl:if>
+ <xsl:if test="string-length($switchblock2) > 0">
+ <xsl:text> OOXMLFastContextHandlerValue * pValueHandler = dynamic_cast&lt;OOXMLFastContextHandlerValue *&gt;(pHandler);&#xa;</xsl:text>
+ <xsl:text> switch (nDefine)&#xa;</xsl:text>
+ <xsl:text> {&#xa;</xsl:text>
+ <xsl:value-of select="$switchblock2"/>
+ <xsl:text> default:&#xa;</xsl:text>
+ <xsl:text> break;&#xa;</xsl:text>
+ <xsl:text> }&#xa;</xsl:text>
+ </xsl:if>
+ <xsl:text>}&#xa;</xsl:text>
+</xsl:template>
+
+<xsl:template name="charactersactionforvalues">
+ <xsl:variable name="name" select="@name"/>
+ <xsl:for-each select="ancestor::namespace/rng:grammar/rng:define[@name=$name]">
+ <xsl:text> {&#xa;</xsl:text>
+ <xsl:text> // </xsl:text>
+ <xsl:value-of select="@name"/>
+ <xsl:text>&#xa;</xsl:text>
+ <xsl:for-each select="rng:data[@type='int']">
+ <xsl:text> OOXMLValue::Pointer_t pValue(new OOXMLIntegerValue(sText));&#xa;</xsl:text>
+ <xsl:text> pValueHandler->setValue(pValue);&#xa;</xsl:text>
</xsl:for-each>
- <xsl:text>
- default:
- break;
- }
-}
-</xsl:text>
+ <xsl:for-each select="rng:list">
+ <xsl:text> ListValueMapPointer pListValueMap = getListValueMap(nDefine);&#xa;</xsl:text>
+ <xsl:text> if (pListValueMap.get() != NULL)&#xa;</xsl:text>
+ <xsl:text> {&#xa;</xsl:text>
+ <xsl:text> OOXMLValue::Pointer_t pValue(new OOXMLIntegerValue((*pListValueMap)[sText]));&#xa;</xsl:text>
+ <xsl:text> pValueHandler->setValue(pValue);</xsl:text>
+ <xsl:text> }&#xa;</xsl:text>
+ </xsl:for-each>
+ <xsl:text> }&#xa;</xsl:text>
+ </xsl:for-each>
</xsl:template>
<!-- factoryactions -->
<xsl:template name="factoryactions">
<xsl:variable name="ns" select="@name"/>
- <xsl:for-each select="resource/action">
+ <xsl:for-each select="resource/action[not(@name='characters')]">
<xsl:sort select="@name"/>
<xsl:if test="generate-id(key('actions', @name)[ancestor::namespace/@name=$ns][1]) = generate-id(.)">
<xsl:variable name="name" select="@name"/>
@@ -587,6 +677,9 @@ void </xsl:text>
</xsl:for-each>
</xsl:if>
</xsl:for-each>
+ <xsl:call-template name="factoryaction">
+ <xsl:with-param name="action">characters</xsl:with-param>
+ </xsl:call-template>
</xsl:template>
<xsl:template name="factorygetdefinename">
@@ -794,6 +887,22 @@ void </xsl:text>
</xsl:choose>
</xsl:template>
+<xsl:template name="factorygetname">
+ <xsl:param name="ns"/>
+ <xsl:text>
+#ifdef DEBUG_FACTORY
+string </xsl:text>
+<xsl:call-template name="factoryclassname"/>
+<xsl:text>::getName() const
+{
+ return "</xsl:text>
+ <xsl:value-of select="$ns"/>
+ <xsl:text>";
+}
+#endif
+</xsl:text>
+</xsl:template>
+
<xsl:template match="/">
<xsl:variable name="ns" select="substring-before(substring-after($file, 'OOXMLFactory_'), '.cxx')"/>
<xsl:text>
@@ -823,6 +932,9 @@ namespace ooxml {
<xsl:call-template name="factorygetdefinename"/>
<xsl:call-template name="factorytokentoidmap"/>
<xsl:call-template name="factoryattributeaction"/>
+ <xsl:call-template name="factorygetname">
+ <xsl:with-param name="ns" select="$ns"/>
+ </xsl:call-template>
</xsl:for-each>
<xsl:text>
/// @endcond
diff --git a/writerfilter/source/ooxml/model.xml b/writerfilter/source/ooxml/model.xml
index b00fd433c884..49998622e65d 100644
--- a/writerfilter/source/ooxml/model.xml
+++ b/writerfilter/source/ooxml/model.xml
@@ -191,11 +191,11 @@
</define>
</grammar>
<resource name="CT_OfficeStyleSheet" resource="Table" tokenid="ooxml:THEMETABLE"/>
- <resource name="theme" resource="Stream">
+ <resource name="theme" resource="Stream" tag="theme">
<element name="theme" tokenid="ooxml:THEMETABLE"/>
</resource>
- <resource name="themeOverride" resource="Stream"/>
- <resource name="themeManager" resource="Stream"/>
+ <resource name="themeOverride" resource="Stream" tag="theme"/>
+ <resource name="themeManager" resource="Stream" tag="theme"/>
</namespace>
<namespace name="dml-styleDefaults" file="dml-styleDefaults">
<grammar xmlns="http://relaxng.org/ns/structure/1.0" ns="http://schemas.openxmlformats.org/drawingml/2006/main">
@@ -1114,7 +1114,7 @@
<value name="hlink" tokenid="ooxml:Value_drawingml_ST_ColorSchemeIndex_hlink">hlink</value>
<value name="folHlink" tokenid="ooxml:Value_drawingml_ST_ColorSchemeIndex_folHlink">folHlink</value>
</resource>
- <resource name="CT_ColorScheme" resource="Properties">
+ <resource name="CT_ColorScheme" resource="Properties" tag="theme">
<element name="dk1" tokenid="ooxml:CT_ColorScheme_dk1"/>
<element name="lt1" tokenid="ooxml:CT_ColorScheme_lt1"/>
<element name="dk2" tokenid="ooxml:CT_ColorScheme_dk2"/>
@@ -1130,39 +1130,39 @@
<element name="extLst" tokenid="ooxml:CT_ColorScheme_extLst"/>
<attribute name="name" tokenid="ooxml:CT_ColorScheme_name"/>
</resource>
- <resource name="CT_SupplementalFont" resource="Properties">
+ <resource name="CT_SupplementalFont" resource="Properties" tag="theme">
<attribute name="script" tokenid="ooxml:CT_SupplementalFont_script"/>
<attribute name="typeface" tokenid="ooxml:CT_SupplementalFont_typeface"/>
</resource>
- <resource name="CT_FontCollection" resource="Properties">
+ <resource name="CT_FontCollection" resource="Properties" tag="theme">
<element name="latin" tokenid="ooxml:CT_FontCollection_latin"/>
<element name="ea" tokenid="ooxml:CT_FontCollection_ea"/>
<element name="cs" tokenid="ooxml:CT_FontCollection_cs"/>
<element name="font" tokenid="ooxml:CT_FontCollection_font"/>
<element name="extLst" tokenid="ooxml:CT_FontCollection_extLst"/>
</resource>
- <resource name="CT_FontScheme" resource="Properties">
+ <resource name="CT_FontScheme" resource="Properties" tag="theme">
<element name="majorFont" tokenid="ooxml:CT_FontScheme_majorFont"/>
<element name="minorFont" tokenid="ooxml:CT_FontScheme_minorFont"/>
<element name="extLst" tokenid="ooxml:CT_FontScheme_extLst"/>
<attribute name="name" tokenid="ooxml:CT_FontScheme_name"/>
</resource>
- <resource name="CT_FillStyleList" resource="Properties"/>
- <resource name="CT_LineStyleList" resource="Properties">
+ <resource name="CT_FillStyleList" resource="Properties" tag="theme"/>
+ <resource name="CT_LineStyleList" resource="Properties" tag="theme">
<element name="ln" tokenid="ooxml:CT_LineStyleList_ln"/>
</resource>
- <resource name="CT_EffectStyleList" resource="Properties">
+ <resource name="CT_EffectStyleList" resource="Properties" tag="theme">
<element name="effectStyle" tokenid="ooxml:CT_EffectStyleList_effectStyle"/>
</resource>
- <resource name="CT_BackgroundFillStyleList" resource="Properties"/>
- <resource name="CT_StyleMatrix" resource="Properties">
+ <resource name="CT_BackgroundFillStyleList" resource="Properties" tag="theme"/>
+ <resource name="CT_StyleMatrix" resource="Properties" tag="theme">
<element name="fillStyleLst" tokenid="ooxml:CT_StyleMatrix_fillStyleLst"/>
<element name="lnStyleLst" tokenid="ooxml:CT_StyleMatrix_lnStyleLst"/>
<element name="effectStyleLst" tokenid="ooxml:CT_StyleMatrix_effectStyleLst"/>
<element name="bgFillStyleLst" tokenid="ooxml:CT_StyleMatrix_bgFillStyleLst"/>
<attribute name="name" tokenid="ooxml:CT_StyleMatrix_name"/>
</resource>
- <resource name="CT_BaseStyles" resource="Properties">
+ <resource name="CT_BaseStyles" resource="Properties" tag="theme">
<element name="clrScheme" tokenid="ooxml:CT_BaseStyles_clrScheme"/>
<element name="fontScheme" tokenid="ooxml:CT_BaseStyles_fontScheme"/>
<element name="fmtScheme" tokenid="ooxml:CT_BaseStyles_fmtScheme"/>
@@ -1541,7 +1541,7 @@
<resource name="ST_TextFontSize" resource="Integer" generated="yes"/>
<resource name="ST_Panose" resource="Hex" generated="yes"/>
<resource name="ST_TextTypeface" resource="String" generated="yes"/>
- <resource name="CT_TextFont" resource="Properties">
+ <resource name="CT_TextFont" resource="Properties" tag="character">
<attribute name="typeface" tokenid="ooxml:CT_TextFont_typeface"/>
<attribute name="panose" tokenid="ooxml:CT_TextFont_panose"/>
<attribute name="pitchFamily" tokenid="ooxml:CT_TextFont_pitchFamily"/>
@@ -2738,7 +2738,7 @@
<value name="shdw19" tokenid="ooxml:Value_drawingml_ST_PresetShadowVal_shdw19">shdw19</value>
<value name="shdw20" tokenid="ooxml:Value_drawingml_ST_PresetShadowVal_shdw20">shdw20</value>
</resource>
- <resource name="CT_SolidColorFillProperties" resource="Properties"/>
+ <resource name="CT_SolidColorFillProperties" resource="Properties" tag="shape"/>
<resource name="ST_PathShadeType" resource="List" generated="yes">
<value name="shape" tokenid="ooxml:Value_drawingml_ST_PathShadeType_shape">shape</value>
<value name="circle" tokenid="ooxml:Value_drawingml_ST_PathShadeType_circle">circle</value>
@@ -2750,7 +2750,7 @@
<value name="y" tokenid="ooxml:Value_drawingml_ST_TileFlipMode_y">y</value>
<value name="xy" tokenid="ooxml:Value_drawingml_ST_TileFlipMode_xy">xy</value>
</resource>
- <resource name="CT_GradientStop" resource="Properties">
+ <resource name="CT_GradientStop" resource="Properties" tag="shape">
<attribute name="pos" tokenid="ooxml:CT_GradientStop_pos"/>
</resource>
<resource name="CT_TileInfoProperties" resource="Properties">
@@ -2761,10 +2761,10 @@
<attribute name="flip" tokenid="ooxml:CT_TileInfoProperties_flip"/>
<attribute name="algn" tokenid="ooxml:CT_TileInfoProperties_algn"/>
</resource>
- <resource name="CT_StretchInfoProperties" resource="Properties">
+ <resource name="CT_StretchInfoProperties" resource="Properties" tag="shape">
<element name="fillRect" tokenid="ooxml:CT_StretchInfoProperties_fillRect"/>
</resource>
- <resource name="EG_FillModeProperties" resource="Properties">
+ <resource name="EG_FillModeProperties" resource="Properties" tag="shape">
<element name="tile" tokenid="ooxml:EG_FillModeProperties_tile"/>
<element name="stretch" tokenid="ooxml:EG_FillModeProperties_stretch"/>
</resource>
@@ -2775,7 +2775,7 @@
<value name="hqprint" tokenid="ooxml:Value_drawingml_ST_BlipCompression_hqprint">hqprint</value>
<value name="none" tokenid="ooxml:Value_drawingml_ST_BlipCompression_none">none</value>
</resource>
- <resource name="CT_Blip" resource="Properties">
+ <resource name="CT_Blip" resource="Properties" tag="shape">
<element name="alphaBiLevel" tokenid="ooxml:CT_Blip_alphaBiLevel"/>
<element name="alphaCeiling" tokenid="ooxml:CT_Blip_alphaCeiling"/>
<element name="alphaFloor" tokenid="ooxml:CT_Blip_alphaFloor"/>
@@ -2796,7 +2796,7 @@
<element name="extLst" tokenid="ooxml:CT_Blip_extLst"/>
<attribute name="cstate" tokenid="ooxml:CT_Blip_cstate"/>
</resource>
- <resource name="CT_BlipFillProperties" resource="Properties">
+ <resource name="CT_BlipFillProperties" resource="Properties" tag="shape">
<element name="blip" tokenid="ooxml:CT_BlipFillProperties_blip"/>
<element name="srcRect" tokenid="ooxml:CT_BlipFillProperties_srcRect"/>
<attribute name="dpi" tokenid="ooxml:CT_BlipFillProperties_dpi"/>
@@ -2865,7 +2865,7 @@
<value name="darken" tokenid="ooxml:Value_drawingml_ST_BlendMode_darken">darken</value>
<value name="lighten" tokenid="ooxml:Value_drawingml_ST_BlendMode_lighten">lighten</value>
</resource>
- <resource name="EG_Effect" resource="Properties">
+ <resource name="EG_Effect" resource="Properties" tag="shape">
<element name="cont" tokenid="ooxml:EG_Effect_cont"/>
<element name="effect" tokenid="ooxml:EG_Effect_effect"/>
<element name="alphaBiLevel" tokenid="ooxml:EG_Effect_alphaBiLevel"/>
@@ -2901,7 +2901,7 @@
<value name="sib" tokenid="ooxml:Value_drawingml_ST_EffectContainerType_sib">sib</value>
<value name="tree" tokenid="ooxml:Value_drawingml_ST_EffectContainerType_tree">tree</value>
</resource>
- <resource name="CT_EffectContainer" resource="Properties">
+ <resource name="CT_EffectContainer" resource="Properties" tag="shape">
<attribute name="type" tokenid="ooxml:CT_EffectContainer_type"/>
<attribute name="name" tokenid="ooxml:CT_EffectContainer_name"/>
</resource>
@@ -3197,12 +3197,12 @@
<value name="med" tokenid="ooxml:Value_drawingml_ST_LineEndLength_med">med</value>
<value name="lg" tokenid="ooxml:Value_drawingml_ST_LineEndLength_lg">lg</value>
</resource>
- <resource name="CT_LineEndProperties" resource="Properties">
+ <resource name="CT_LineEndProperties" resource="Properties" tag="shape">
<attribute name="type" tokenid="ooxml:CT_LineEndProperties_type"/>
<attribute name="w" tokenid="ooxml:CT_LineEndProperties_w"/>
<attribute name="len" tokenid="ooxml:CT_LineEndProperties_len"/>
</resource>
- <resource name="EG_LineFillProperties" resource="Properties">
+ <resource name="EG_LineFillProperties" resource="Properties" tag="shape">
<element name="noFill" tokenid="ooxml:EG_LineFillProperties_noFill"/>
<element name="solidFill" tokenid="ooxml:EG_LineFillProperties_solidFill"/>
<element name="gradFill" tokenid="ooxml:EG_LineFillProperties_gradFill"/>
@@ -3237,7 +3237,7 @@
<value name="thinThick" tokenid="ooxml:Value_drawingml_ST_CompoundLine_thinThick">thinThick</value>
<value name="tri" tokenid="ooxml:Value_drawingml_ST_CompoundLine_tri">tri</value>
</resource>
- <resource name="CT_LineProperties" resource="Properties">
+ <resource name="CT_LineProperties" resource="Properties" tag="shape">
<element name="headEnd" tokenid="ooxml:CT_LineProperties_headEnd"/>
<element name="tailEnd" tokenid="ooxml:CT_LineProperties_tailEnd"/>
<element name="extLst" tokenid="ooxml:CT_LineProperties_extLst"/>
@@ -3331,7 +3331,7 @@
</optional>
</define>
</grammar>
- <resource name="CT_ShapeProperties" resource="Properties">
+ <resource name="CT_ShapeProperties" resource="Properties" tag="shape">
<element name="xfrm" tokenid="ooxml:CT_ShapeProperties_xfrm"/>
<element name="ln" tokenid="ooxml:CT_ShapeProperties_ln"/>
<element name="scene3d" tokenid="ooxml:CT_ShapeProperties_scene3d"/>
@@ -4429,41 +4429,41 @@
<attribute name="val" tokenid="ooxml:CT_Angle_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
- <resource name="CT_PositiveFixedAngle" resource="Value" generated="yes">
+ <resource name="CT_PositiveFixedAngle" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_PositiveFixedAngle_val" action="setValue"/>
</resource>
<resource name="ST_Percentage" resource="Integer" generated="yes"/>
- <resource name="CT_Percentage" resource="Value" generated="yes">
+ <resource name="CT_Percentage" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Percentage_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
- <resource name="CT_PositivePercentage" resource="Value" generated="yes">
+ <resource name="CT_PositivePercentage" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_PositivePercentage_val" action="setValue"/>
</resource>
- <resource name="CT_FixedPercentage" resource="Value" generated="yes">
+ <resource name="CT_FixedPercentage" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_FixedPercentage_val" action="setValue"/>
</resource>
- <resource name="CT_PositiveFixedPercentage" resource="Value" generated="yes">
+ <resource name="CT_PositiveFixedPercentage" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_PositiveFixedPercentage_val" action="setValue"/>
</resource>
- <resource name="CT_Point2D" resource="Properties">
+ <resource name="CT_Point2D" resource="Properties" tag="shape">
<attribute name="x" tokenid="ooxml:CT_Point2D_x"/>
<attribute name="y" tokenid="ooxml:CT_Point2D_y"/>
</resource>
- <resource name="CT_PositiveSize2D" resource="Properties">
+ <resource name="CT_PositiveSize2D" resource="Properties" tag="shape">
<attribute name="cx" tokenid="ooxml:CT_PositiveSize2D_cx"/>
<attribute name="cy" tokenid="ooxml:CT_PositiveSize2D_cy"/>
</resource>
- <resource name="CT_ScRgbColor" resource="Properties">
+ <resource name="CT_ScRgbColor" resource="Properties" tag="shape">
<attribute name="r" tokenid="ooxml:CT_ScRgbColor_r"/>
<attribute name="g" tokenid="ooxml:CT_ScRgbColor_g"/>
<attribute name="b" tokenid="ooxml:CT_ScRgbColor_b"/>
</resource>
<resource name="ST_HexBinary3" resource="Hex" generated="yes"/>
- <resource name="CT_SRgbColor" resource="Properties">
+ <resource name="CT_SRgbColor" resource="Properties" tag="shape">
<attribute name="val" tokenid="ooxml:CT_SRgbColor_val"/>
</resource>
- <resource name="CT_HslColor" resource="Properties">
+ <resource name="CT_HslColor" resource="Properties" tag="shape">
<attribute name="hue" tokenid="ooxml:CT_HslColor_hue"/>
<attribute name="sat" tokenid="ooxml:CT_HslColor_sat"/>
<attribute name="lum" tokenid="ooxml:CT_HslColor_lum"/>
@@ -4500,7 +4500,7 @@
<value name="menuHighlight" tokenid="ooxml:Value_drawingml_ST_SystemColorVal_menuHighlight">menuHighlight</value>
<value name="menuBar" tokenid="ooxml:Value_drawingml_ST_SystemColorVal_menuBar">menuBar</value>
</resource>
- <resource name="CT_SystemColor" resource="Properties">
+ <resource name="CT_SystemColor" resource="Properties" tag="shape">
<attribute name="val" tokenid="ooxml:CT_SystemColor_val"/>
<attribute name="lastClr" tokenid="ooxml:CT_SytemColor_lastClr"/>
</resource>
@@ -4523,7 +4523,7 @@
<value name="dk2" tokenid="ooxml:Value_drawingml_ST_SchemeColorVal_dk2">dk2</value>
<value name="lt2" tokenid="ooxml:Value_drawingml_ST_SchemeColorVal_lt2">lt2</value>
</resource>
- <resource name="CT_SchemeColor" resource="Properties">
+ <resource name="CT_SchemeColor" resource="Properties" tag="shape">
<attribute name="val" tokenid="ooxml:CT_SchemeColor_val"/>
</resource>
<resource name="ST_PresetColorVal" resource="List">
@@ -4668,10 +4668,10 @@
<value tokenid="0xffff00">yellow</value>
<value tokenid="0x9acd32">yellowGreen</value>
</resource>
- <resource name="CT_PresetColor" resource="Properties">
+ <resource name="CT_PresetColor" resource="Properties" tag="shape">
<attribute name="val" tokenid="ooxml:CT_PresetColor_val"/>
</resource>
- <resource name="CT_Transform2D" resource="Properties">
+ <resource name="CT_Transform2D" resource="Properties" tag="shape">
<element name="off" tokenid="ooxml:CT_Transform2D_off"/>
<element name="ext" tokenid="ooxml:CT_Transform2D_ext"/>
<attribute name="rot" tokenid="ooxml:CT_Transform2D_rot"/>
@@ -4690,7 +4690,7 @@
<value name="br" tokenid="ooxml:Value_drawingml_ST_RectAlignment_br">br</value>
</resource>
<resource name="ST_Guid" resource="String" generated="yes"/>
- <resource name="EG_ColorChoice" resource="Properties">
+ <resource name="EG_ColorChoice" resource="Properties" tag="shape">
<element name="scrgbClr" tokenid="ooxml:EG_ColorChoice_scrgbClr"/>
<element name="srgbClr" tokenid="ooxml:EG_ColorChoice_srgbClr"/>
<element name="hslClr" tokenid="ooxml:EG_ColorChoice_hslClr"/>
@@ -4698,8 +4698,8 @@
<element name="schemeClr" tokenid="ooxml:EG_ColorChoice_schemeClr"/>
<element name="prstClr" tokenid="ooxml:EG_ColorChoice_prstClr"/>
</resource>
- <resource name="CT_Color" resource="Properties"/>
- <resource name="CT_ColorMRU" resource="Properties"/>
+ <resource name="CT_Color" resource="Properties" tag="shape"/>
+ <resource name="CT_ColorMRU" resource="Properties" tag="shape"/>
<resource name="ST_BlackWhiteMode" resource="List" generated="yes">
<value name="clr" tokenid="ooxml:Value_drawingml_ST_BlackWhiteMode_clr">clr</value>
<value name="auto" tokenid="ooxml:Value_drawingml_ST_BlackWhiteMode_auto">auto</value>
@@ -4713,7 +4713,7 @@
<value name="white" tokenid="ooxml:Value_drawingml_ST_BlackWhiteMode_white">white</value>
<value name="hidden" tokenid="ooxml:Value_drawingml_ST_BlackWhiteMode_hidden">hidden</value>
</resource>
- <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="AG_Blob" resource="Properties">
+ <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="AG_Blob" resource="Properties" tag="shape">
<attribute name="r:embed" tokenid="ooxml:AG_Blob_r_embed"/>
<attribute name="r:link" tokenid="ooxml:AG_Blob_r_link"/>
</resource>
@@ -5100,7 +5100,7 @@
</optional>
</define>
</grammar>
- <resource name="CT_GraphicalObjectFrameLocking" resource="Properties">
+ <resource name="CT_GraphicalObjectFrameLocking" resource="Properties" tag="shape">
<element name="extLst" tokenid="ooxml:CT_GraphicalObjectFrameLocking_extLst"/>
<attribute name="noGrp" tokenid="ooxml:CT_GraphicalObjectFrameLocking_noGrp"/>
<attribute name="noDrilldown" tokenid="ooxml:CT_GraphicalObjectFrameLocking_noDrilldown"/>
@@ -5109,7 +5109,7 @@
<attribute name="noMove" tokenid="ooxml:CT_GraphicalObjectFrameLocking_noMove"/>
<attribute name="noResize" tokenid="ooxml:CT_GraphicalObjectFrameLocking_noResize"/>
</resource>
- <resource name="CT_NonVisualDrawingProps" resource="Properties">
+ <resource name="CT_NonVisualDrawingProps" resource="Properties" tag="shape">
<element name="hlinkClick" tokenid="ooxml:CT_NonVisualDrawingProps_hlinkClick"/>
<element name="hlinkHover" tokenid="ooxml:CT_NonVisualDrawingProps_hlinkHover"/>
<element name="extLst" tokenid="ooxml:CT_NonVisualDrawingProps_extLst"/>
@@ -5118,12 +5118,12 @@
<attribute name="descr" tokenid="ooxml:CT_NonVisualDrawingProps_descr"/>
<attribute name="hidden" tokenid="ooxml:CT_NonVisualDrawingProps_hidden"/>
</resource>
- <resource name="CT_NonVisualPictureProperties" resource="Properties">
+ <resource name="CT_NonVisualPictureProperties" resource="Properties" tag="shape">
<element name="picLocks" tokenid="ooxml:CT_NonVisualPictureProperties_picLocks"/>
<element name="extLst" tokenid="ooxml:CT_NonVisualPictureProperties_extLst"/>
<attribute name="preferRelativeResize" tokenid="ooxml:CT_NonVisualPictureProperties_preferRelativeResize"/>
</resource>
- <resource name="CT_NonVisualGraphicFrameProperties" resource="Properties">
+ <resource name="CT_NonVisualGraphicFrameProperties" resource="Properties" tag="shape">
<element name="graphicFrameLocks" tokenid="ooxml:CT_NonVisualGraphicFrameProperties_graphicFrameLocks"/>
<element name="extLst" tokenid="ooxml:CT_NonVisualGraphicFrameProperties_extLst"/>
</resource>
@@ -5159,14 +5159,14 @@
</element>
</define>
</grammar>
- <resource name="CT_GraphicalObjectData" resource="Properties">
+ <resource name="CT_GraphicalObjectData" resource="Properties" tag="shape">
<element name="pic" tokenid="ooxml:CT_GraphicalObjectData_pic"/>
<attribute name="uri" tokenid="ooxml:CT_GraphicalObjectData_uri"/>
</resource>
- <resource name="CT_GraphicalObject" resource="Properties">
+ <resource name="CT_GraphicalObject" resource="Properties" tag="shape">
<element name="graphicData" tokenid="ooxml:CT_GraphicalObject_graphicData"/>
</resource>
- <resource name="graphic" resource="Properties">
+ <resource name="graphic" resource="Properties" tag="shape">
<element name="graphic" tokenid="ooxml:graphic_graphic"/>
</resource>
</namespace>
@@ -6271,7 +6271,7 @@
</resource>
<resource name="ST_GeomGuideName" resource="String" generated="yes"/>
<resource name="ST_GeomGuideFormula" resource="String" generated="yes"/>
- <resource name="CT_GeomGuideList" resource="Properties">
+ <resource name="CT_GeomGuideList" resource="Properties" tag="shape">
<element name="gd" tokenid="ooxml:CT_GeomGuideList_gd"/>
</resource>
<resource name="ST_PathFillMode" resource="List" generated="yes">
@@ -6282,11 +6282,11 @@
<value name="darken" tokenid="ooxml:Value_drawingml_ST_PathFillMode_darken">darken</value>
<value name="darkenLess" tokenid="ooxml:Value_drawingml_ST_PathFillMode_darkenLess">darkenLess</value>
</resource>
- <resource name="CT_PresetGeometry2D" resource="Properties">
+ <resource name="CT_PresetGeometry2D" resource="Properties" tag="shape">
<element name="avLst" tokenid="ooxml:CT_PresetGeometry2D_avLst"/>
<attribute name="prst" tokenid="ooxml:CT_PresetGeometry2D_prst"/>
</resource>
- <resource name="CT_CustomGeometry2D" resource="Properties">
+ <resource name="CT_CustomGeometry2D" resource="Properties" tag="shape">
<element name="avLst" tokenid="ooxml:CT_CustomGeometry2D_avLst"/>
<element name="gdLst" tokenid="ooxml:CT_CustomGeometry2D_gdLst"/>
<element name="ahLst" tokenid="ooxml:CT_CustomGeometry2D_ahLst"/>
@@ -6294,7 +6294,7 @@
<element name="rect" tokenid="ooxml:CT_CustomGeometry2D_rect"/>
<element name="pathLst" tokenid="ooxml:CT_CustomGeometry2D_pathLst"/>
</resource>
- <resource name="EG_Geometry" resource="Properties">
+ <resource name="EG_Geometry" resource="Properties" tag="shape">
<element name="custGeom" tokenid="ooxml:EG_Geometry_custGeom"/>
<element name="prstGeom" tokenid="ooxml:EG_Geometry_prstGeom"/>
</resource>
@@ -6764,14 +6764,14 @@
</element>
</define>
</grammar>
- <resource name="CT_EffectExtent" resource="Properties">
+ <resource name="CT_EffectExtent" resource="Properties" tag="shape">
<attribute name="l" tokenid="ooxml:CT_EffectExtent_l"/>
<attribute name="t" tokenid="ooxml:CT_EffectExtent_t"/>
<attribute name="r" tokenid="ooxml:CT_EffectExtent_r"/>
<attribute name="b" tokenid="ooxml:CT_EffectExtent_b"/>
</resource>
<resource name="ST_WrapDistance" resource="Integer" generated="yes"/>
- <resource xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="CT_Inline" resource="Properties">
+ <resource xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="CT_Inline" resource="Properties" tag="shape">
<element name="extent" tokenid="ooxml:CT_Inline_extent"/>
<element name="effectExtent" tokenid="ooxml:CT_Inline_effectExtent"/>
<element name="docPr" tokenid="ooxml:CT_Inline_docPr"/>
@@ -6788,13 +6788,13 @@
<value name="right" tokenid="ooxml:Value_wordprocessingDrawing_ST_WrapText_right">right</value>
<value name="largest" tokenid="ooxml:Value_wordprocessingDrawing_ST_WrapText_largest">largest</value>
</resource>
- <resource name="CT_WrapPath" resource="Properties">
+ <resource name="CT_WrapPath" resource="Properties" tag="shape">
<element name="start" tokenid="ooxml:CT_WrapPath_start"/>
<element name="lineTo" tokenid="ooxml:CT_WrapPath_lineTo"/>
<attribute name="edited" tokenid="ooxml:CT_WrapPath_edited"/>
</resource>
- <resource name="CT_WrapNone" resource="Properties"/>
- <resource name="CT_WrapSquare" resource="Properties">
+ <resource name="CT_WrapNone" resource="Properties" tag="shape"/>
+ <resource name="CT_WrapSquare" resource="Properties" tag="shape">
<element name="effectExtent" tokenid="ooxml:CT_WrapSquare_effectExtent"/>
<attribute name="wrapText" tokenid="ooxml:CT_WrapSquare_wrapText"/>
<attribute name="distT" tokenid="ooxml:CT_WrapSquare_distT"/>
@@ -6802,34 +6802,34 @@
<attribute name="distL" tokenid="ooxml:CT_WrapSquare_distL"/>
<attribute name="distR" tokenid="ooxml:CT_WrapSquare_distR"/>
</resource>
- <resource name="CT_WrapTight" resource="Properties">
+ <resource name="CT_WrapTight" resource="Properties" tag="shape">
<element name="wrapPolygon" tokenid="ooxml:CT_WrapTight_wrapPolygon"/>
<attribute name="wrapText" tokenid="ooxml:CT_WrapTight_wrapText"/>
<attribute name="distL" tokenid="ooxml:CT_WrapTight_distL"/>
<attribute name="distR" tokenid="ooxml:CT_WrapTight_distR"/>
</resource>
- <resource name="CT_WrapThrough" resource="Properties">
+ <resource name="CT_WrapThrough" resource="Properties" tag="shape">
<element name="wrapPolygon" tokenid="ooxml:CT_WrapThrough_wrapPolygon"/>
<attribute name="wrapText" tokenid="ooxml:CT_WrapThrough_wrapText"/>
<attribute name="distL" tokenid="ooxml:CT_WrapThrough_distL"/>
<attribute name="distR" tokenid="ooxml:CT_WrapThrough_distR"/>
</resource>
- <resource name="CT_WrapTopBottom" resource="Properties">
+ <resource name="CT_WrapTopBottom" resource="Properties" tag="shape">
<element name="effectExtent" tokenid="ooxml:CT_WrapTopBottom_effectExtent"/>
<attribute name="distT" tokenid="ooxml:CT_WrapTopBottom_distT"/>
<attribute name="distB" tokenid="ooxml:CT_WrapTopBottom_distB"/>
</resource>
- <resource name="EG_WrapType" resource="Properties">
+ <resource name="EG_WrapType" resource="Properties" tag="shape">
<element name="wrapNone" tokenid="ooxml:EG_WrapType_wrapNone"/>
<element name="wrapSquare" tokenid="ooxml:EG_WrapType_wrapSquare"/>
<element name="wrapTight" tokenid="ooxml:EG_WrapType_wrapTight"/>
<element name="wrapThrough" tokenid="ooxml:EG_WrapType_wrapThrough"/>
<element name="wrapTopAndBottom" tokenid="ooxml:EG_WrapType_wrapTopAndBottom"/>
</resource>
- <resource name="CT_PositionOffset" resource="Value"/>
+ <resource name="CT_PositionOffset" resource="Value" tag="shape"/>
<resource name="ST_PositionOffset" resource="Integer" generated="yes"/>
- <resource name="CT_AlignH" resource="Value"/>
- <resource name="ST_AlignH" resource="List" generated="yes">
+ <resource name="CT_AlignH" resource="Value" tag="shape"/>
+ <resource name="ST_AlignH" resource="List" generated="yes" tag="shape">
<value name="left" tokenid="ooxml:Value_wordprocessingDrawing_ST_AlignH_left">left</value>
<value name="right" tokenid="ooxml:Value_wordprocessingDrawing_ST_AlignH_right">right</value>
<value name="center" tokenid="ooxml:Value_wordprocessingDrawing_ST_AlignH_center">center</value>
@@ -6846,12 +6846,12 @@
<value name="insideMargin" tokenid="ooxml:Value_wordprocessingDrawing_ST_RelFromH_insideMargin">insideMargin</value>
<value name="outsideMargin" tokenid="ooxml:Value_wordprocessingDrawing_ST_RelFromH_outsideMargin">outsideMargin</value>
</resource>
- <resource name="CT_PosH" resource="Properties">
+ <resource name="CT_PosH" resource="Properties" tag="shape">
<element name="align" tokenid="ooxml:CT_PosH_align"/>
<element name="posOffset" tokenid="ooxml:CT_PosH_posOffset"/>
<attribute name="relativeFrom" tokenid="ooxml:CT_PosH_relativeFrom"/>
</resource>
- <resource name="CT_AlignV" resource="Value"/>
+ <resource name="CT_AlignV" resource="Value" tag="shape"/>
<resource name="ST_AlignV" resource="List" generated="yes">
<value name="top" tokenid="ooxml:Value_wordprocessingDrawing_ST_AlignV_top">top</value>
<value name="bottom" tokenid="ooxml:Value_wordprocessingDrawing_ST_AlignV_bottom">bottom</value>
@@ -6869,12 +6869,12 @@
<value name="insideMargin" tokenid="ooxml:Value_wordprocessingDrawing_ST_RelFromV_insideMargin">insideMargin</value>
<value name="outsideMargin" tokenid="ooxml:Value_wordprocessingDrawing_ST_RelFromV_outsideMargin">outsideMargin</value>
</resource>
- <resource name="CT_PosV" resource="Properties">
+ <resource name="CT_PosV" resource="Properties" tag="shape">
<element name="align" tokenid="ooxml:CT_PosV_align"/>
<element name="posOffset" tokenid="ooxml:CT_PosV_posOffset"/>
<attribute name="relativeFrom" tokenid="ooxml:CT_PosV_relativeFrom"/>
</resource>
- <resource xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="CT_Anchor" resource="Properties">
+ <resource xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="CT_Anchor" resource="Properties" tag="shape">
<element name="simplePos" tokenid="ooxml:CT_Anchor_simplePos_elem"/>
<element name="positionH" tokenid="ooxml:CT_Anchor_positionH"/>
<element name="positionV" tokenid="ooxml:CT_Anchor_positionV"/>
@@ -6895,10 +6895,10 @@
<attribute name="hidden" tokenid="ooxml:CT_Anchor_hidden"/>
<attribute name="allowOverlap" tokenid="ooxml:CT_Anchor_allowOverlap"/>
</resource>
- <resource name="inline" resource="Properties">
+ <resource name="inline" resource="Properties" tag="shape">
<element name="inline" tokenid="ooxml:inline_inline"/>
</resource>
- <resource name="anchor" resource="Properties">
+ <resource name="anchor" resource="Properties" tag="shape">
<element name="anchor" tokenid="ooxml:anchor_anchor"/>
</resource>
</namespace>
@@ -8202,27 +8202,27 @@
</define>
</grammar>
<resource name="ST_Integer255" resource="Integer" generated="yes"/>
- <resource name="CT_Integer255" resource="Value" generated="yes">
+ <resource name="CT_Integer255" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Integer255_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_Integer2" resource="Integer" generated="yes"/>
- <resource name="CT_Integer2" resource="Value" generated="yes">
+ <resource name="CT_Integer2" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Integer2_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_SpacingRule" resource="Integer" generated="yes"/>
- <resource name="CT_SpacingRule" resource="Value" generated="yes">
+ <resource name="CT_SpacingRule" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_SpacingRule_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_UnSignedInteger" resource="Integer" generated="yes"/>
- <resource name="CT_UnSignedInteger" resource="Value" generated="yes">
+ <resource name="CT_UnSignedInteger" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_UnSignedInteger_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_Char" resource="String" generated="yes"/>
- <resource name="CT_Char" resource="Value" generated="yes">
+ <resource name="CT_Char" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Char_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -8230,12 +8230,12 @@
<value name="on" tokenid="ooxml:Value_math_ST_OnOff_on">on</value>
<value name="off" tokenid="ooxml:Value_math_ST_OnOff_off">off</value>
</resource>
- <resource name="CT_OnOff" resource="Value">
+ <resource name="CT_OnOff" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_OnOff_val" action="setValue"/>
<action name="start" action="setDefaultBooleanValue"/>
</resource>
<resource name="ST_String" resource="String" generated="yes"/>
- <resource name="CT_String" resource="Value" generated="yes">
+ <resource name="CT_String" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_String_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -8244,7 +8244,7 @@
<value name="center" tokenid="ooxml:Value_math_ST_XAlign_center">center</value>
<value name="right" tokenid="ooxml:Value_math_ST_XAlign_right">right</value>
</resource>
- <resource name="CT_XAlign" resource="Value" generated="yes">
+ <resource name="CT_XAlign" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_XAlign_val" action="setValue"/>
</resource>
<resource name="ST_YAlign" resource="List" generated="yes">
@@ -8252,14 +8252,14 @@
<value name="center" tokenid="ooxml:Value_math_ST_YAlign_center">center</value>
<value name="bot" tokenid="ooxml:Value_math_ST_YAlign_bot">bot</value>
</resource>
- <resource name="CT_YAlign" resource="Value" generated="yes">
+ <resource name="CT_YAlign" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_YAlign_val" action="setValue"/>
</resource>
<resource name="ST_Shp" resource="List" generated="yes">
<value name="centered" tokenid="ooxml:Value_math_ST_Shp_centered">centered</value>
<value name="match" tokenid="ooxml:Value_math_ST_Shp_match">match</value>
</resource>
- <resource name="CT_Shp" resource="Value" generated="yes">
+ <resource name="CT_Shp" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_Shp_val" action="setValue"/>
</resource>
<resource name="ST_FType" resource="List" generated="yes">
@@ -8268,21 +8268,21 @@
<value name="lin" tokenid="ooxml:Value_math_ST_FType_lin">lin</value>
<value name="noBar" tokenid="ooxml:Value_math_ST_FType_noBar">noBar</value>
</resource>
- <resource name="CT_FType" resource="Value" generated="yes">
+ <resource name="CT_FType" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_FType_val" action="setValue"/>
</resource>
<resource name="ST_LimLoc" resource="List" generated="yes">
<value name="undOvr" tokenid="ooxml:Value_math_ST_LimLoc_undOvr">undOvr</value>
<value name="subSup" tokenid="ooxml:Value_math_ST_LimLoc_subSup">subSup</value>
</resource>
- <resource name="CT_LimLoc" resource="Value" generated="yes">
+ <resource name="CT_LimLoc" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_LimLoc_val" action="setValue"/>
</resource>
<resource name="ST_TopBot" resource="List" generated="yes">
<value name="top" tokenid="ooxml:Value_math_ST_TopBot_top">top</value>
<value name="bot" tokenid="ooxml:Value_math_ST_TopBot_bot">bot</value>
</resource>
- <resource name="CT_TopBot" resource="Value" generated="yes">
+ <resource name="CT_TopBot" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_TopBot_val" action="setValue"/>
</resource>
<resource name="ST_Script" resource="List" generated="yes">
@@ -8293,7 +8293,7 @@
<value name="sansmserif" tokenid="ooxml:Value_math_ST_Script_sansmserif">sans-serif</value>
<value name="monospace" tokenid="ooxml:Value_math_ST_Script_monospace">monospace</value>
</resource>
- <resource name="CT_Script" resource="Value" generated="yes">
+ <resource name="CT_Script" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_Script_val" action="setValue"/>
</resource>
<resource name="ST_Style" resource="List">
@@ -8302,7 +8302,7 @@
<value tokenid="ooxml:Value_ST_Style_i">i</value>
<value tokenid="ooxml:Value_ST_Style_p">p</value>
</resource>
- <resource name="CT_Style" resource="Value">
+ <resource name="CT_Style" resource="Value" tag="math">
<attribute name="val" tokenid="ooxml:CT_Style_val" action="setValue"/>
</resource>
<resource name="ST_Jc" resource="List" generated="yes">
@@ -8311,11 +8311,11 @@
<value name="center" tokenid="ooxml:Value_math_ST_Jc_center">center</value>
<value name="centerGroup" tokenid="ooxml:Value_math_ST_Jc_centerGroup">centerGroup</value>
</resource>
- <resource name="CT_OMathJc" resource="Value" generated="yes">
+ <resource name="CT_OMathJc" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_OMathJc_val" action="setValue"/>
</resource>
<resource name="ST_TwipsMeasure" resource="Integer" generated="yes"/>
- <resource name="CT_TwipsMeasure" resource="Value" generated="yes">
+ <resource name="CT_TwipsMeasure" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_TwipsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
@@ -8324,7 +8324,7 @@
<value name="after" tokenid="ooxml:Value_math_ST_BreakBin_after">after</value>
<value name="repeat" tokenid="ooxml:Value_math_ST_BreakBin_repeat">repeat</value>
</resource>
- <resource name="CT_BreakBin" resource="Value" generated="yes">
+ <resource name="CT_BreakBin" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_BreakBin_val" action="setValue"/>
</resource>
<resource name="ST_BreakBinSub" resource="List" generated="yes">
@@ -8332,7 +8332,7 @@
<value name="mp" tokenid="ooxml:Value_math_ST_BreakBinSub_mp">-+</value>
<value name="pm" tokenid="ooxml:Value_math_ST_BreakBinSub_pm">+-</value>
</resource>
- <resource name="CT_BreakBinSub" resource="Value" generated="yes">
+ <resource name="CT_BreakBinSub" resource="Value" generated="yes" tag="math">
<attribute name="val" tokenid="ooxml:CT_BreakBinSub_val" action="setValue"/>
</resource>
</namespace>
@@ -8418,16 +8418,16 @@
</element>
</define>
</grammar>
- <resource name="CT_PictureNonVisual" resource="Properties">
+ <resource name="CT_PictureNonVisual" resource="Properties" tag="shape">
<element name="cNvPr" tokenid="ooxml:CT_PictureNonVisual_cNvPr"/>
<element name="cNvPicPr" tokenid="ooxml:CT_PictureNonVisual_cNvPicPr"/>
</resource>
- <resource name="CT_Picture" resource="Shape">
+ <resource name="CT_Picture" resource="Shape" tag="shape">
<element name="nvPicPr" tokenid="ooxml:CT_Picture_nvPicPr"/>
<element name="blipFill" tokenid="ooxml:CT_Picture_blipFill"/>
<element name="spPr" tokenid="ooxml:CT_Picture_spPr"/>
</resource>
- <resource name="pic" resource="Properties">
+ <resource name="pic" resource="Properties" tag="shape">
<element name="pic" tokenid="ooxml:pic_pic"/>
</resource>
</namespace>
@@ -11939,10 +11939,10 @@
</zeroOrMore>
</define>
</grammar>
- <resource name="OLEObject" resource="Properties">
+ <resource name="OLEObject" resource="Properties" tag="ole">
<element name="OLEObject" tokenid="ooxml:OLEObject_OLEObject"/>
</resource>
- <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_OLEObject" resource="Properties">
+ <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_OLEObject" resource="Properties" tag="ole">
<element name="LinkType" tokenid="ooxml:CT_OLEObject_LinkType"/>
<element name="LockedField" tokenid="ooxml:CT_OLEObject_LockedField"/>
<element name="FieldCodes" tokenid="ooxml:CT_OLEObject_FieldCodes"/>
@@ -12320,10 +12320,10 @@
</list>
</define>
</grammar>
- <resource name="wrap" resource="Properties">
+ <resource name="wrap" resource="Properties" tag="shape">
<element name="wrap" tokenid="ooxml:wrap_wrap"/>
</resource>
- <resource name="CT_Wrap" resource="Properties">
+ <resource name="CT_Wrap" resource="Properties" tag="shape">
<attribute name="type" tokenid="ooxml:CT_Wrap_type"/>
<attribute name="side" tokenid="ooxml:CT_Wrap_side"/>
<attribute name="anchorx" tokenid="ooxml:CT_Wrap_anchorx"/>
@@ -13962,6 +13962,11 @@
</choice>
</list>
</define>
+ <define name="ST_Percentage">
+ <data type="int">
+ <xs:documentation>Percentage</xs:documentation>
+ </data>
+ </define>
<define name="CT_Zoom">
<optional>
<attribute name="val">
@@ -21043,77 +21048,77 @@
</zeroOrMore>
</define>
</grammar>
- <resource name="CT_Empty" resource="Stream">
+ <resource name="CT_Empty" resource="Stream" tag="content">
<action name="end" tokenid="ooxml:EG_RunInnerContent_noBreakHyphen" action="noBreakHyphen"/>
<action name="end" tokenid="ooxml:EG_RunInnerContent_softHyphen" action="softHyphen"/>
<action name="end" tokenid="ooxml:EG_RunInnerContent_cr" action="cr"/>
</resource>
<resource name="ST_OnOff" resource="Boolean"/>
- <resource name="CT_OnOff" resource="Value">
+ <resource name="CT_OnOff" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_OnOff_val" action="setValue"/>
<action name="start" action="setDefaultBooleanValue"/>
</resource>
<resource name="ST_LongHexNumber" resource="Hex"/>
- <resource name="CT_LongHexNumber" resource="Value">
+ <resource name="CT_LongHexNumber" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_LongHexNumber_val" action="setValue"/>
<action name="start" action="setDefaultHexValue"/>
</resource>
<resource name="ST_ShortHexNumber" resource="Hex"/>
- <resource name="CT_ShortHexNumber" resource="Value">
+ <resource name="CT_ShortHexNumber" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_ShortHexNumber_val" action="setValue"/>
<action name="start" action="setDefaultHexValue"/>
</resource>
<resource name="ST_UcharHexNumber" resource="Hex"/>
- <resource name="CT_UcharHexNumber" resource="Value">
+ <resource name="CT_UcharHexNumber" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_UcharHexNumber_val" action="setValue"/>
<action name="start" action="setDefaultHexValue"/>
</resource>
<resource name="ST_DecimalNumber" resource="Integer"/>
- <resource name="CT_DecimalNumber" resource="Value">
+ <resource name="CT_DecimalNumber" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_DecimalNumber_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_UnsignedDecimalNumber" resource="Integer" generated="yes"/>
<resource name="ST_TwipsMeasure" resource="Integer"/>
- <resource name="CT_TwipsMeasure" resource="Value">
+ <resource name="CT_TwipsMeasure" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_TwipsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_SignedTwipsMeasure" resource="Integer"/>
- <resource name="CT_SignedTwipsMeasure" resource="Value">
+ <resource name="CT_SignedTwipsMeasure" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_SignedTwipsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_PixelsMeasure" resource="Integer" generated="yes"/>
- <resource name="CT_PixelsMeasure" resource="Value">
+ <resource name="CT_PixelsMeasure" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_PixelsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_HpsMeasure" resource="Integer"/>
- <resource name="CT_HpsMeasure" resource="Value">
+ <resource name="CT_HpsMeasure" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_HpsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_SignedHpsMeasure" resource="Integer"/>
- <resource name="CT_SignedHpsMeasure" resource="Value">
+ <resource name="CT_SignedHpsMeasure" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_SignedHpsMeasure_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_DateTime" resource="String" generated="yes"/>
<resource name="ST_MacroName" resource="String" generated="yes"/>
- <resource name="CT_MacroName" resource="Value" generated="yes">
+ <resource name="CT_MacroName" resource="Value" generated="yes" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_MacroName_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
<resource name="ST_EighthPointMeasure" resource="Integer"/>
<resource name="ST_PointMeasure" resource="Integer"/>
<resource name="ST_String" resource="String"/>
- <resource name="CT_String" resource="Value">
+ <resource name="CT_String" resource="Value" tag="attribute" >
<attribute name="val" tokenid="ooxml:CT_String_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
<resource name="ST_TextScale" resource="Integer"/>
- <resource name="CT_TextScale" resource="Value">
+ <resource name="CT_TextScale" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_TextScale_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
@@ -21136,7 +21141,7 @@
<value tokenid="16">lightGray</value>
<value tokenid="0">none</value>
</resource>
- <resource name="CT_Highlight" resource="Value">
+ <resource name="CT_Highlight" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Highlight_val" action="setValue"/>
</resource>
<resource name="ST_HexColorAuto" resource="List">
@@ -21144,7 +21149,7 @@
</resource>
<resource name="ST_HexColorRGB" resource="Hex"/>
<resource name="ST_HexColor" resource="Hex"/>
- <resource name="CT_Color" resource="Properties">
+ <resource name="CT_Color" resource="Properties" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Color_val"/>
<attribute name="themeColor" tokenid="ooxml:CT_Color_themeColor"/>
<attribute name="themeTint" tokenid="ooxml:CT_Color_themeTint"/>
@@ -21152,12 +21157,12 @@
</resource>
<resource name="ST_LangCode" resource="Hex" generated="yes"/>
<resource name="ST_Lang" resource="String"/>
- <resource name="CT_Lang" resource="Value">
+ <resource name="CT_Lang" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Lang_val" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
<resource name="ST_Guid" resource="String"/>
- <resource name="CT_Guid" resource="Value">
+ <resource name="CT_Guid" resource="Value" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Guid_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -21181,7 +21186,7 @@
<value tokenid="43">wavyDouble</value>
<value tokenid="0">none</value>
</resource>
- <resource name="CT_Underline" resource="Properties">
+ <resource name="CT_Underline" resource="Properties" tag="character">
<attribute name="val" tokenid="ooxml:CT_Underline_val" default="single"/>
<attribute name="color" tokenid="ooxml:CT_Underline_color"/>
<attribute name="themeColor" tokenid="ooxml:CT_Underline_themeColor"/>
@@ -21197,7 +21202,7 @@
<value tokenid="5">antsRed</value>
<value tokenid="6">shimmer</value>
</resource>
- <resource name="CT_TextEffect" resource="Value">
+ <resource name="CT_TextEffect" resource="Value" tag="character">
<attribute name="val" tokenid="ooxml:CT_TextEffect_val" action="setValue"/>
</resource>
<resource name="ST_Border" resource="List">
@@ -21393,7 +21398,7 @@
<value tokenid="226">zigZag</value>
<value tokenid="227">zigZagStitch</value>
</resource>
- <resource name="CT_Border" resource="Properties">
+ <resource name="CT_Border" resource="Properties" tag="attribute">
<attribute name="val" tokenid="rtf:BRCTYPE"/>
<attribute name="color" tokenid="ooxml:CT_Border_color"/>
<attribute name="themeColor" tokenid="ooxml:CT_Border_themeColor"/>
@@ -21444,7 +21449,7 @@
<value tokenid="13">pct90</value>
<value tokenid="60">pct95</value>
</resource>
- <resource name="CT_Shd" resource="Properties">
+ <resource name="CT_Shd" resource="Properties" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Shd_val"/>
<attribute name="color" tokenid="ooxml:CT_Shd_color"/>
<attribute name="themeColor" tokenid="ooxml:CT_Shd_themeColor"/>
@@ -21455,16 +21460,16 @@
<attribute name="themeFillTint" tokenid="ooxml:CT_Shd_themeFillTint"/>
<attribute name="themeFillShade" tokenid="ooxml:CT_Shd_themeFillShade"/>
</resource>
- <resource name="ST_VerticalAlignRun" resource="List" generated="yes">
+ <resource name="ST_VerticalAlignRun" resource="List" generated="yes" tag="character">
<value name="baseline" tokenid="ooxml:Value_wordprocessingml_ST_VerticalAlignRun_baseline">baseline</value>
<value name="superscript" tokenid="ooxml:Value_wordprocessingml_ST_VerticalAlignRun_superscript">superscript</value>
<value name="subscript" tokenid="ooxml:Value_wordprocessingml_ST_VerticalAlignRun_subscript">subscript</value>
</resource>
- <resource name="CT_VerticalAlignRun" resource="Value" generated="yes">
+ <resource name="CT_VerticalAlignRun" resource="Value" generated="yes" tag="character">
<attribute name="val" tokenid="ooxml:CT_VerticalAlignRun_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_FitText" resource="Properties">
+ <resource name="CT_FitText" resource="Properties" tag="paragraph">
<attribute name="val" tokenid="ooxml:CT_FitText_val"/>
<attribute name="id" tokenid="ooxml:CT_FitText_id"/>
</resource>
@@ -21475,10 +21480,10 @@
<value tokenid="3">circle</value>
<value tokenid="4">underDot</value>
</resource>
- <resource name="CT_Em" resource="Value">
+ <resource name="CT_Em" resource="Value" tag="character">
<attribute name="val" tokenid="ooxml:CT_Em_val" action="setValue"/>
</resource>
- <resource name="CT_Language" resource="Properties">
+ <resource name="CT_Language" resource="Properties" tag="character">
<attribute name="val" tokenid="ooxml:CT_Language_val"/>
<attribute name="eastAsia" tokenid="ooxml:CT_Language_eastAsia"/>
<attribute name="bidi" tokenid="ooxml:CT_Language_bidi"/>
@@ -21490,7 +21495,7 @@
<value tokenid="3">angle</value>
<value tokenid="4">curly</value>
</resource>
- <resource name="CT_EastAsianLayout" resource="Properties">
+ <resource name="CT_EastAsianLayout" resource="Properties" tag="character">
<attribute name="id" tokenid="ooxml:CT_EastAsianLayout_id"/>
<attribute name="combine" tokenid="ooxml:CT_EastAsianLayout_combine"/>
<attribute name="combineBrackets" tokenid="ooxml:CT_EastAsianLayout_combineBrackets"/>
@@ -21540,7 +21545,7 @@
<value name="drop" tokenid="ooxml:Value_wordprocessingml_ST_DropCap_drop">drop</value>
<value name="margin" tokenid="ooxml:Value_wordprocessingml_ST_DropCap_margin">margin</value>
</resource>
- <resource name="CT_FramePr" resource="Properties">
+ <resource name="CT_FramePr" resource="Properties" tag="frame">
<kind name="paragraph"/>
<attribute name="dropCap" tokenid="ooxml:CT_FramePr_dropCap"/>
<attribute name="lines" tokenid="ooxml:CT_FramePr_lines"/>
@@ -21575,7 +21580,7 @@
<value tokenid="4">heavy</value>
<value tokenid="ooxml:Value_ST_TabTlc_middleDot">middleDot</value>
</resource>
- <resource name="CT_TabStop" resource="Properties">
+ <resource name="CT_TabStop" resource="Properties" tag="paragraph">
<attribute name="val" tokenid="ooxml:CT_TabStop_val"/>
<attribute name="leader" tokenid="ooxml:CT_TabStop_leader"/>
<attribute name="pos" tokenid="ooxml:CT_TabStop_pos"/>
@@ -21585,7 +21590,7 @@
<value name="exact" tokenid="ooxml:Value_wordprocessingml_ST_LineSpacingRule_exact">exact</value>
<value name="atLeast" tokenid="ooxml:Value_wordprocessingml_ST_LineSpacingRule_atLeast">atLeast</value>
</resource>
- <resource name="CT_Spacing" resource="Properties">
+ <resource name="CT_Spacing" resource="Properties" tag="paragraüh">
<attribute name="before" tokenid="ooxml:CT_Spacing_before"/>
<attribute name="beforeLines" tokenid="ooxml:CT_Spacing_beforeLines"/>
<attribute name="beforeAutospacing" tokenid="ooxml:CT_Spacing_beforeAutospacing"/>
@@ -21595,7 +21600,7 @@
<attribute name="line" tokenid="ooxml:CT_Spacing_line"/>
<attribute name="lineRule" tokenid="ooxml:CT_Spacing_lineRule"/>
</resource>
- <resource name="CT_Ind" resource="Properties">
+ <resource name="CT_Ind" resource="Properties" tag="paragraph">
<attribute name="left" tokenid="ooxml:CT_Ind_left"/>
<attribute name="leftChars" tokenid="ooxml:CT_Ind_leftChars"/>
<attribute name="right" tokenid="ooxml:CT_Ind_right"/>
@@ -21617,7 +21622,7 @@
<value tokenid="ooxml:Value_ST_Jc_lowKashida">lowKashida</value>
<value tokenid="ooxml:Value_ST_Jc_thaiDistribute">thaiDistribute</value>
</resource>
- <resource name="CT_Jc" resource="Value">
+ <resource name="CT_Jc" resource="Value" tag="character">
<attribute name="val" tokenid="ooxml:CT_Jc_val" action="setValue"/>
</resource>
<resource name="ST_View" resource="List" generated="yes">
@@ -21628,7 +21633,7 @@
<value name="normal" tokenid="ooxml:Value_wordprocessingml_ST_View_normal">normal</value>
<value name="web" tokenid="ooxml:Value_wordprocessingml_ST_View_web">web</value>
</resource>
- <resource name="CT_View" resource="Properties">
+ <resource name="CT_View" resource="Properties" tag="settings">
<attribute name="val" tokenid="ooxml:CT_View_val"/>
</resource>
<resource name="ST_Zoom" resource="List" generated="yes">
@@ -21637,11 +21642,11 @@
<value name="bestFit" tokenid="ooxml:Value_wordprocessingml_ST_Zoom_bestFit">bestFit</value>
<value name="textFit" tokenid="ooxml:Value_wordprocessingml_ST_Zoom_textFit">textFit</value>
</resource>
- <resource name="CT_Zoom" resource="Properties">
+ <resource name="CT_Zoom" resource="Properties" tag="settings">
<attribute name="val" tokenid="ooxml:CT_Zoom_val"/>
<attribute name="percent" tokenid="ooxml:CT_Zoom_percent"/>
</resource>
- <resource name="CT_WritingStyle" resource="Properties">
+ <resource name="CT_WritingStyle" resource="Properties" tag="settings">
<attribute name="lang" tokenid="ooxml:CT_WritingStyle_lang"/>
<attribute name="vendorID" tokenid="ooxml:CT_WritingStyle_vendorID"/>
<attribute name="dllVersion" tokenid="ooxml:CT_WritingStyle_dllVersion"/>
@@ -21653,7 +21658,7 @@
<value name="clean" tokenid="ooxml:Value_wordprocessingml_ST_Proof_clean">clean</value>
<value name="dirty" tokenid="ooxml:Value_wordprocessingml_ST_Proof_dirty">dirty</value>
</resource>
- <resource name="CT_Proof" resource="Properties">
+ <resource name="CT_Proof" resource="Properties" tag="redline">
<attribute name="spelling" tokenid="ooxml:CT_Proof_spelling"/>
<attribute name="grammar" tokenid="ooxml:CT_Proof_grammar"/>
</resource>
@@ -21662,7 +21667,7 @@
<value name="letter" tokenid="ooxml:Value_wordprocessingml_ST_DocType_letter">letter</value>
<value name="eMail" tokenid="ooxml:Value_wordprocessingml_ST_DocType_eMail">eMail</value>
</resource>
- <resource name="CT_DocType" resource="Properties">
+ <resource name="CT_DocType" resource="Properties" tag="document">
<attribute name="val" tokenid="ooxml:CT_DocType_val"/>
</resource>
<resource name="ST_DocProtect" resource="List" generated="yes">
@@ -21696,7 +21701,7 @@
<attribute name="hash" tokenid="ooxml:AG_Password_hash"/>
<attribute name="salt" tokenid="ooxml:AG_Password_salt"/>
</resource>
- <resource name="CT_DocProtect" resource="Properties">
+ <resource name="CT_DocProtect" resource="Properties" tag="document">
<attribute name="edit" tokenid="ooxml:CT_DocProtect_edit"/>
<attribute name="formatting" tokenid="ooxml:CT_DocProtect_formatting"/>
<attribute name="enforcement" tokenid="ooxml:CT_DocProtect_enforcement"/>
@@ -21709,7 +21714,7 @@
<value name="email" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDocType_email">email</value>
<value name="fax" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDocType_fax">fax</value>
</resource>
- <resource name="CT_MailMergeDocType" resource="Value" generated="yes">
+ <resource name="CT_MailMergeDocType" resource="Value" generated="yes" tag="mailmerge">
<attribute name="val" tokenid="ooxml:CT_MailMergeDocType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -21721,7 +21726,7 @@
<value name="odbc" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDataType_odbc">odbc</value>
<value name="native" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDataType_native">native</value>
</resource>
- <resource name="CT_MailMergeDataType" resource="Value" generated="yes">
+ <resource name="CT_MailMergeDataType" resource="Value" generated="yes" tag="mailmerge">
<attribute name="val" tokenid="ooxml:CT_MailMergeDataType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -21731,7 +21736,7 @@
<value name="email" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDest_email">email</value>
<value name="fax" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeDest_fax">fax</value>
</resource>
- <resource name="CT_MailMergeDest" resource="Value" generated="yes">
+ <resource name="CT_MailMergeDest" resource="Value" generated="yes" tag="mailmerge">
<attribute name="val" tokenid="ooxml:CT_MailMergeDest_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -21739,18 +21744,18 @@
<value name="null" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeOdsoFMDFieldType_null">null</value>
<value name="dbColumn" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeOdsoFMDFieldType_dbColumn">dbColumn</value>
</resource>
- <resource name="CT_MailMergeOdsoFMDFieldType" resource="Value" generated="yes">
+ <resource name="CT_MailMergeOdsoFMDFieldType" resource="Value" generated="yes" tag="mailmerge">
<attribute name="val" tokenid="ooxml:CT_MailMergeOdsoFMDFieldType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_TrackChangesView" resource="Properties">
+ <resource name="CT_TrackChangesView" resource="Properties" tag="redline">
<attribute name="markup" tokenid="ooxml:CT_TrackChangesView_markup"/>
<attribute name="comments" tokenid="ooxml:CT_TrackChangesView_comments"/>
<attribute name="insDel" tokenid="ooxml:CT_TrackChangesView_insDel"/>
<attribute name="formatting" tokenid="ooxml:CT_TrackChangesView_formatting"/>
<attribute name="inkAnnotations" tokenid="ooxml:CT_TrackChangesView_inkAnnotations"/>
</resource>
- <resource name="CT_Kinsoku" resource="Properties">
+ <resource name="CT_Kinsoku" resource="Properties" tag="character">
<attribute name="lang" tokenid="ooxml:CT_Kinsoku_lang"/>
<attribute name="val" tokenid="ooxml:CT_Kinsoku_val"/>
</resource>
@@ -21762,7 +21767,7 @@
<value tokenid="5">tbRlV</value>
<value tokenid="ooxml:Value_ST_TextDirection_tbLrV">tbLrV</value>
</resource>
- <resource name="CT_TextDirection" resource="Value">
+ <resource name="CT_TextDirection" resource="Value" tag="paragraph">
<attribute name="val" tokenid="ooxml:CT_TextDirection_val" action="setValue"/>
</resource>
<resource name="ST_TextAlignment" resource="List" generated="yes">
@@ -21772,7 +21777,7 @@
<value name="bottom" tokenid="ooxml:Value_wordprocessingml_ST_TextAlignment_bottom">bottom</value>
<value name="auto" tokenid="ooxml:Value_wordprocessingml_ST_TextAlignment_auto">auto</value>
</resource>
- <resource name="CT_TextAlignment" resource="Value" generated="yes">
+ <resource name="CT_TextAlignment" resource="Value" generated="yes" tag="paragraph">
<attribute name="val" tokenid="ooxml:CT_TextAlignment_val" action="setValue"/>
</resource>
<resource name="ST_DisplacedByCustomXml" resource="List" generated="yes">
@@ -21783,80 +21788,80 @@
<value name="cont" tokenid="ooxml:Value_wordprocessingml_ST_AnnotationVMerge_cont">cont</value>
<value name="rest" tokenid="ooxml:Value_wordprocessingml_ST_AnnotationVMerge_rest">rest</value>
</resource>
- <resource name="CT_Markup" resource="Properties">
+ <resource name="CT_Markup" resource="Properties" tag="redline">
<attribute name="id" tokenid="ooxml:CT_Markup_id"/>
</resource>
- <resource name="CT_TrackChange" resource="Properties">
+ <resource name="CT_TrackChange" resource="Properties" tag="redline">
<attribute name="author" tokenid="ooxml:CT_TrackChange_author"/>
<attribute name="date" tokenid="ooxml:CT_TrackChange_date"/>
</resource>
- <resource name="CT_CellMergeTrackChange" resource="Properties">
+ <resource name="CT_CellMergeTrackChange" resource="Properties" tag="redline">
<attribute name="vMerge" tokenid="ooxml:CT_CellMergeTrackChange_vMerge"/>
<attribute name="vMergeOrig" tokenid="ooxml:CT_CellMergeTrackChange_vMergeOrig"/>
</resource>
- <resource name="CT_TrackChangeRange" resource="Properties">
+ <resource name="CT_TrackChangeRange" resource="Properties" tag="redline">
<attribute name="displacedByCustomXml" tokenid="ooxml:CT_TrackChangeRange_displacedByCustomXml"/>
</resource>
- <resource name="CT_MarkupRange" resource="Properties">
+ <resource name="CT_MarkupRange" resource="Properties" tag="redline">
<attribute name="displacedByCustomXml" tokenid="ooxml:CT_MarkupRange_displacedByCustomXml"/>
</resource>
- <resource name="CT_MarkupRangeBookmark" resource="Properties">
+ <resource name="CT_MarkupRangeBookmark" resource="Properties" tag="redline">
<attribute name="id" tokenid="rtf:IBKL"/>
</resource>
- <resource name="CT_BookmarkRange" resource="Properties">
+ <resource name="CT_BookmarkRange" resource="Properties" tag="reference">
<type name="Bookmark"/>
<attribute name="colFirst" tokenid="ooxml:CT_BookmarkRange_colFirst"/>
<attribute name="colLast" tokenid="ooxml:CT_BookmarkRange_colLast"/>
</resource>
- <resource name="CT_Bookmark" resource="Properties">
+ <resource name="CT_Bookmark" resource="Properties" tag="reference">
<type name="Bookmark"/>
<attribute name="name" tokenid="rtf:BOOKMARKNAME"/>
</resource>
- <resource name="CT_MoveBookmark" resource="Properties">
+ <resource name="CT_MoveBookmark" resource="Properties" tag="reference">
<attribute name="author" tokenid="ooxml:CT_MoveBookmark_author"/>
<attribute name="date" tokenid="ooxml:CT_MoveBookmark_date"/>
</resource>
- <resource name="CT_Comment" resource="XNote">
+ <resource name="CT_Comment" resource="XNote" tag="content">
<attribute name="id" action="checkId"/>
<attribute name="initials" tokenid="ooxml:CT_Comment_initials"/>
</resource>
- <resource name="CT_TrackChangeNumbering" resource="Properties">
+ <resource name="CT_TrackChangeNumbering" resource="Properties" tag="numbering">
<attribute name="original" tokenid="ooxml:CT_TrackChangeNumbering_original"/>
</resource>
- <resource name="CT_TblPrExChange" resource="Properties">
+ <resource name="CT_TblPrExChange" resource="Properties" tag="table">
<element name="tblPrEx" tokenid="ooxml:CT_TblPrExChange_tblPrEx"/>
</resource>
- <resource name="CT_TcPrChange" resource="Properties">
+ <resource name="CT_TcPrChange" resource="Properties" tag="table">
<element name="tcPr" tokenid="ooxml:CT_TcPrChange_tcPr"/>
</resource>
- <resource name="CT_TrPrChange" resource="Properties">
+ <resource name="CT_TrPrChange" resource="Properties" tag="table">
<element name="trPr" tokenid="ooxml:CT_TrPrChange_trPr"/>
</resource>
- <resource name="CT_TblGridChange" resource="Properties">
+ <resource name="CT_TblGridChange" resource="Properties" tag="table">
<element name="tblGrid" tokenid="ooxml:CT_TblGridChange_tblGrid"/>
</resource>
- <resource name="CT_TblPrChange" resource="Properties">
+ <resource name="CT_TblPrChange" resource="Properties" tag="table">
<element name="tblPr" tokenid="ooxml:CT_TblPrChange_tblPr"/>
</resource>
- <resource name="CT_SectPrChange" resource="Properties">
+ <resource name="CT_SectPrChange" resource="Properties" tag="section">
<element name="sectPr" tokenid="ooxml:CT_SectPrChange_sectPr"/>
</resource>
- <resource name="CT_PPrChange" resource="Properties">
+ <resource name="CT_PPrChange" resource="Properties" tag="paragraph">
<element name="pPr" tokenid="ooxml:CT_PPrChange_pPr"/>
</resource>
- <resource name="CT_RPrChange" resource="Properties">
+ <resource name="CT_RPrChange" resource="Properties" tag="character">
<element name="rPr" tokenid="ooxml:CT_RPrChange_rPr"/>
</resource>
- <resource name="CT_ParaRPrChange" resource="Properties">
+ <resource name="CT_ParaRPrChange" resource="Properties" tag="character">
<element name="rPr" tokenid="ooxml:CT_ParaRPrChange_rPr"/>
</resource>
- <resource name="CT_RunTrackChange" resource="Stream">
+ <resource name="CT_RunTrackChange" resource="Stream" tag="redlines">
<action name="start" action="tokenproperty"/>
<action name="start" action="propagateCharacterPropertiesAsSet" sendtokenid="ooxml:trackchange"/>
<action name="start" action="clearProps"/>
<action name="end" action="mark" sendtokenid="ooxml:endtrackchange"/>
</resource>
- <resource name="EG_RangeMarkupElements" resource="Properties">
+ <resource name="EG_RangeMarkupElements" resource="Properties" tag="redlines">
<element name="bookmarkStart" tokenid="ooxml:EG_RangeMarkupElements_bookmarkStart"/>
<element name="bookmarkEnd" tokenid="ooxml:EG_RangeMarkupElements_bookmarkEnd"/>
<element name="moveFromRangeStart" tokenid="ooxml:EG_RangeMarkupElements_moveFromRangeStart"/>
@@ -21874,14 +21879,14 @@
<element name="customXmlMoveToRangeStart" tokenid="ooxml:EG_RangeMarkupElements_customXmlMoveToRangeStart"/>
<element name="customXmlMoveToRangeEnd" tokenid="ooxml:EG_RangeMarkupElements_customXmlMoveToRangeEnd"/>
</resource>
- <resource name="CT_NumPr" resource="Properties">
+ <resource name="CT_NumPr" resource="Properties" tag="numbering">
<kind name="paragraph"/>
<element name="ilvl" tokenid="sprm:PIlvl"/>
<element name="numId" tokenid="sprm:PIlfo"/>
<element name="numberingChange" tokenid="ooxml:CT_NumPr_numberingChange"/>
<element name="ins" tokenid="ooxml:CT_NumPr_ins"/>
</resource>
- <resource name="CT_PBdr" resource="Properties">
+ <resource name="CT_PBdr" resource="Properties" tag="paragraph">
<kind name="paragraph"/>
<element name="top" tokenid="sprm:PBrcTop"/>
<element name="left" tokenid="sprm:PBrcLeft"/>
@@ -21890,7 +21895,7 @@
<element name="between" tokenid="sprm:PBrcBetween"/>
<element name="bar" tokenid="sprm:PBrcBar"/>
</resource>
- <resource name="CT_Tabs" resource="Properties">
+ <resource name="CT_Tabs" resource="Properties" tag="paragraph">
<element name="tab" tokenid="ooxml:CT_Tabs_tab"/>
</resource>
<resource name="ST_TextboxTightWrap" resource="List" generated="yes">
@@ -21900,11 +21905,11 @@
<value name="firstLineOnly" tokenid="ooxml:Value_wordprocessingml_ST_TextboxTightWrap_firstLineOnly">firstLineOnly</value>
<value name="lastLineOnly" tokenid="ooxml:Value_wordprocessingml_ST_TextboxTightWrap_lastLineOnly">lastLineOnly</value>
</resource>
- <resource name="CT_TextboxTightWrap" resource="Value" generated="yes">
+ <resource name="CT_TextboxTightWrap" resource="Value" generated="yes" tag="textbox">
<attribute name="val" tokenid="ooxml:CT_TextboxTightWrap_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_PPrBase" resource="Properties">
+ <resource name="CT_PPrBase" resource="Properties" tag="paragraph">
<kind name="paragraph"/>
<element name="pStyle" tokenid="ooxml:CT_PPrBase_pStyle"/>
<element name="keepNext" tokenid="sprm:PFKeepFollow"/>
@@ -21940,12 +21945,12 @@
<element name="divId" tokenid="ooxml:CT_PPrBase_divId"/>
<element name="cnfStyle" tokenid="ooxml:CT_PPrBase_cnfStyle"/>
</resource>
- <resource name="CT_PPr" resource="Properties">
+ <resource name="CT_PPr" resource="Properties" tag="paragraph">
<element name="rPr" tokenid="ooxml:CT_PPr_rPr"/>
<element name="sectPr" tokenid="ooxml:CT_PPr_sectPr"/>
<element name="pPrChange" tokenid="ooxml:CT_PPr_pPrChange"/>
</resource>
- <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_Control" resource="Properties">
+ <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_Control" resource="Properties" tag="control">
<attribute name="name" tokenid="ooxml:CT_Control_name"/>
<attribute name="shapeid" tokenid="ooxml:CT_Control_shapeid"/>
<attribute name="r:id" tokenid="ooxml:CT_Control_r_id"/>
@@ -21959,24 +21964,24 @@
<resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_Rel" resource="Properties">
<attribute name="r:id" tokenid="ooxml:CT_Rel_id"/>
</resource>
- <resource name="CT_PictureBase" resource="Properties"/>
- <resource name="CT_Object" resource="Shape">
+ <resource name="CT_PictureBase" resource="Properties" tag="shape"/>
+ <resource name="CT_Object" resource="Shape" tag="shape">
<element name="control" tokenid="ooxml:CT_Object_control"/>
<attribute name="dxaOrig" tokenid="ooxml:CT_Object_dxaOrig"/>
<attribute name="dyaOrig" tokenid="ooxml:CT_Object_dyaOrig"/>
<action name="end" action="sendPropertiesWithId" sendtokenid="ooxml:object"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_Picture" resource="Shape">
+ <resource name="CT_Picture" resource="Shape" tag="shape">
<element name="movie" tokenid="ooxml:CT_Picture_movie"/>
<element name="control" tokenid="ooxml:CT_Picture_control"/>
<action name="end" action="sendPropertiesWithId" sendtokenid="ooxml:object"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_Drawing" resource="Properties">
+ <resource name="CT_Drawing" resource="Properties" tag="shape">
<action name="end" action="handlePicture"/>
</resource>
- <resource name="CT_SimpleField" resource="Stream">
+ <resource name="CT_SimpleField" resource="Stream" tag="field">
<element name="fldData" tokenid="ooxml:CT_SimpleField_fldData"/>
<attribute name="instr" tokenid="ooxml:CT_SimpleField_instr"/>
<attribute name="fldLock" tokenid="ooxml:CT_SimpleField_fldLock"/>
@@ -22008,15 +22013,15 @@
<value name="currentDate" tokenid="ooxml:Value_wordprocessingml_ST_FFTextType_currentDate">currentDate</value>
<value name="calculated" tokenid="ooxml:Value_wordprocessingml_ST_FFTextType_calculated">calculated</value>
</resource>
- <resource name="CT_FFTextType" resource="Value" generated="yes">
+ <resource name="CT_FFTextType" resource="Value" generated="yes" tag="field">
<attribute name="val" tokenid="ooxml:CT_FFTextType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_FFName" resource="Value" generated="yes">
+ <resource name="CT_FFName" resource="Value" generated="yes" tag="field">
<attribute name="val" tokenid="ooxml:CT_FFName_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_FldChar" resource="Stream">
+ <resource name="CT_FldChar" resource="Stream" tag="field">
<element name="fldData" tokenid="ooxml:CT_FldChar_fldData"/>
<element name="ffData" tokenid="ooxml:CT_FldChar_ffData"/>
<element name="numberingChange" tokenid="ooxml:CT_FldChar_numberingChange"/>
@@ -22033,7 +22038,7 @@
<cond tokenid="ooxml:CT_FldChar_fldCharType" value="ooxml:Value_ST_FldCharType_end"/>
</action>
</resource>
- <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_Hyperlink" resource="Stream">
+ <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_Hyperlink" resource="Stream" tag="link">
<attribute name="tgtFrame" tokenid="ooxml:CT_Hyperlink_tgtFrame"/>
<attribute name="tooltip" tokenid="ooxml:CT_Hyperlink_tooltip"/>
<attribute name="docLocation" tokenid="ooxml:CT_Hyperlink_docLocation"/>
@@ -22045,7 +22050,7 @@
<action name="start" action="fieldsep"/>
<action name="end" action="fieldend"/>
</resource>
- <resource name="CT_FFData" resource="Properties">
+ <resource name="CT_FFData" resource="Properties" tag="field">
<element name="name" tokenid="ooxml:CT_FFData_name"/>
<element name="enabled" tokenid="ooxml:CT_FFData_enabled"/>
<element name="calcOnExit" tokenid="ooxml:CT_FFData_calcOnExit"/>
@@ -22059,39 +22064,39 @@
<action name="end" action="propagateCharacterPropertiesAsSet" sendtokenid="ooxml:ffdata"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_FFHelpText" resource="Properties">
+ <resource name="CT_FFHelpText" resource="Properties" tag="field">
<attribute name="type" tokenid="ooxml:CT_FFHelpText_type"/>
<attribute name="val" tokenid="ooxml:CT_FFHelpText_val"/>
</resource>
- <resource name="CT_FFStatusText" resource="Properties">
+ <resource name="CT_FFStatusText" resource="Properties" tag="field">
<attribute name="type" tokenid="ooxml:CT_FFStatusText_type"/>
<attribute name="val" tokenid="ooxml:CT_FFStatusText_val"/>
</resource>
- <resource name="CT_FFCheckBox" resource="Properties">
+ <resource name="CT_FFCheckBox" resource="Properties" tag="field">
<element name="size" tokenid="ooxml:CT_FFCheckBox_size"/>
<element name="sizeAuto" tokenid="ooxml:CT_FFCheckBox_sizeAuto"/>
<element name="default" tokenid="ooxml:CT_FFCheckBox_default"/>
<element name="checked" tokenid="ooxml:CT_FFCheckBox_checked"/>
</resource>
- <resource name="CT_FFDDList" resource="Properties">
+ <resource name="CT_FFDDList" resource="Properties" tag="field">
<element name="result" tokenid="ooxml:CT_FFDDList_result"/>
<element name="default" tokenid="ooxml:CT_FFDDList_default"/>
<element name="listEntry" tokenid="ooxml:CT_FFDDList_listEntry"/>
</resource>
- <resource name="CT_FFTextInput" resource="Properties">
+ <resource name="CT_FFTextInput" resource="Properties" tag="field">
<element name="type" tokenid="ooxml:CT_FFTextInput_type"/>
<element name="default" tokenid="ooxml:CT_FFTextInput_default"/>
<element name="maxLength" tokenid="ooxml:CT_FFTextInput_maxLength"/>
<element name="format" tokenid="ooxml:CT_FFTextInput_format"/>
</resource>
- <resource name="ST_SectionMark" resource="List">
+ <resource name="ST_SectionMark" resource="List" tag="section">
<value tokenid="0">continuous</value>
<value tokenid="1">nextColumn</value>
<value tokenid="2">nextPage</value>
<value tokenid="3">evenPage</value>
<value tokenid="4">oddPage</value>
</resource>
- <resource name="CT_SectType" resource="Value">
+ <resource name="CT_SectType" resource="Value" tag="section">
<attribute name="val" tokenid="ooxml:CT_SectType_val" action="setValue"/>
</resource>
<resource name="ST_NumberFormat" resource="List">
@@ -22160,13 +22165,13 @@
<value tokenid="0">portrait</value>
<value tokenid="1">landscape</value>
</resource>
- <resource name="CT_PageSz" resource="Properties">
+ <resource name="CT_PageSz" resource="Properties" tag="page">
<attribute name="w" tokenid="ooxml:CT_PageSz_w"/>
<attribute name="h" tokenid="ooxml:CT_PageSz_h"/>
<attribute name="orient" tokenid="ooxml:CT_PageSz_orient"/>
<attribute name="code" tokenid="ooxml:CT_PageSz_code"/>
</resource>
- <resource name="CT_PageMar" resource="Properties">
+ <resource name="CT_PageMar" resource="Properties" tag="page">
<attribute name="top" tokenid="ooxml:CT_PageMar_top"/>
<attribute name="right" tokenid="ooxml:CT_PageMar_right"/>
<attribute name="bottom" tokenid="ooxml:CT_PageMar_bottom"/>
@@ -22188,7 +22193,7 @@
<value name="page" tokenid="ooxml:Value_wordprocessingml_ST_PageBorderOffset_page">page</value>
<value name="text" tokenid="ooxml:Value_wordprocessingml_ST_PageBorderOffset_text">text</value>
</resource>
- <resource name="CT_PageBorders" resource="Properties">
+ <resource name="CT_PageBorders" resource="Properties" tag="page">
<element name="top" tokenid="ooxml:CT_PageBorders_top"/>
<element name="left" tokenid="ooxml:CT_PageBorders_left"/>
<element name="bottom" tokenid="ooxml:CT_PageBorders_bottom"/>
@@ -22209,23 +22214,23 @@
<value tokenid="1">newSection</value>
<value tokenid="2">continuous</value>
</resource>
- <resource name="CT_LineNumber" resource="Properties">
+ <resource name="CT_LineNumber" resource="Properties" tag="section">
<attribute name="countBy" tokenid="ooxml:CT_LineNumber_countBy"/>
<attribute name="start" tokenid="ooxml:CT_LineNumber_start"/>
<attribute name="distance" tokenid="ooxml:CT_LineNumber_distance"/>
<attribute name="restart" tokenid="ooxml:CT_LineNumber_restart"/>
</resource>
- <resource name="CT_PageNumber" resource="Properties">
+ <resource name="CT_PageNumber" resource="Properties" tag="page">
<attribute name="fmt" tokenid="ooxml:CT_PageNumber_fmt"/>
<attribute name="start" tokenid="ooxml:CT_PageNumber_start"/>
<attribute name="chapStyle" tokenid="ooxml:CT_PageNumber_chapStyle"/>
<attribute name="chapSep" tokenid="ooxml:CT_PageNumber_chapSep"/>
</resource>
- <resource name="CT_Column" resource="Properties">
+ <resource name="CT_Column" resource="Properties" tag="page">
<attribute name="space" tokenid="ooxml:CT_Column_space"/>
<attribute name="w" tokenid="ooxml:CT_Column_w"/>
</resource>
- <resource name="CT_Columns" resource="Properties">
+ <resource name="CT_Columns" resource="Properties" tag="page">
<attribute name="equalWidth" tokenid="ooxml:CT_Columns_equalWidth"/>
<attribute name="space" tokenid="ooxml:CT_Columns_space"/>
<attribute name="num" tokenid="ooxml:CT_Columns_num"/>
@@ -22238,7 +22243,7 @@
<value tokenid="2">both</value>
<value tokenid="3">bottom</value>
</resource>
- <resource name="CT_VerticalJc" resource="Value">
+ <resource name="CT_VerticalJc" resource="Value" tag="page">
<attribute name="val" tokenid="ooxml:CT_VerticalJc_val" action="setValue"/>
</resource>
<resource name="ST_DocGrid" resource="List" generated="yes">
@@ -22247,7 +22252,7 @@
<value name="linesAndChars" tokenid="ooxml:Value_wordprocessingml_ST_DocGrid_linesAndChars">linesAndChars</value>
<value name="snapToChars" tokenid="ooxml:Value_wordprocessingml_ST_DocGrid_snapToChars">snapToChars</value>
</resource>
- <resource name="CT_DocGrid" resource="Properties">
+ <resource name="CT_DocGrid" resource="Properties" tag="document">
<attribute name="type" tokenid="ooxml:CT_DocGrid_type"/>
<attribute name="linePitch" tokenid="ooxml:CT_DocGrid_linePitch"/>
<attribute name="charSpace" tokenid="ooxml:CT_DocGrid_charSpace"/>
@@ -22263,17 +22268,17 @@
<value name="continuationSeparator" tokenid="ooxml:Value_wordprocessingml_ST_FtnEdn_continuationSeparator">continuationSeparator</value>
<value name="continuationNotice" tokenid="ooxml:Value_wordprocessingml_ST_FtnEdn_continuationNotice">continuationNotice</value>
</resource>
- <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_HdrFtrRef" resource="Properties">
+ <resource xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" name="CT_HdrFtrRef" resource="Properties" tag="header">
<attribute name="type" tokenid="ooxml:CT_HdrFtrRef_type"/>
<attribute name="r:id" tokenid="ooxml:CT_HdrFtrRef_id"/>
<action name="end" action="handleHdrFtr"/>
</resource>
- <resource name="EG_HdrFtrReferences" resource="Properties">
+ <resource name="EG_HdrFtrReferences" resource="Properties" tag="header">
<element name="headerReference" tokenid="ooxml:EG_HdrFtrReferences_headerReference"/>
<element name="footerReference" tokenid="ooxml:EG_HdrFtrReferences_footerReference"/>
</resource>
- <resource name="CT_HdrFtr" resource="Stream"/>
- <resource name="EG_SectPrContents" resource="Properties">
+ <resource name="CT_HdrFtr" resource="Stream" tag="header"/>
+ <resource name="EG_SectPrContents" resource="Properties" tag="section">
<element name="bidi" tokenid="ooxml:EG_SectPrContents_bidi"/>
<element name="cols" tokenid="ooxml:EG_SectPrContents_cols"/>
<element name="docGrid" tokenid="ooxml:EG_SectPrContents_docGrid"/>
@@ -22294,8 +22299,8 @@
<element name="type" tokenid="sprm:SBkc"/>
<element name="vAlign" tokenid="ooxml:EG_SectPrContents_vAlign"/>
</resource>
- <resource name="CT_SectPrBase" resource="Properties"/>
- <resource name="CT_SectPr" resource="Properties">
+ <resource name="CT_SectPrBase" resource="Properties" tag="section"/>
+ <resource name="CT_SectPr" resource="Properties" tag="section">
<element name="sectPrChange" tokenid="ooxml:CT_SectPr_sectPrChange"/>
<action name="start" action="setLastParagraphInSection"/>
</resource>
@@ -22310,7 +22315,7 @@
<value tokenid="ooxml:Value_ST_BrClear_right">right</value>
<value tokenid="ooxml:Value_ST_BrClear_all">all</value>
</resource>
- <resource name="CT_Br" resource="Properties">
+ <resource name="CT_Br" resource="Properties" tag="content">
<attribute name="type" tokenid="ooxml:CT_Br_type"/>
<attribute name="clear" tokenid="ooxml:CT_Br_clear"/>
<action name="end" action="handleBreak"/>
@@ -22331,13 +22336,13 @@
<value tokenid="ooxml:Value_ST_PTabLeader_underscore">underscore</value>
<value tokenid="ooxml:Value_ST_PTabLeader_middleDot">middleDot</value>
</resource>
- <resource name="CT_PTab" resource="Stream">
+ <resource name="CT_PTab" resource="Stream" tag="paragraph">
<attribute name="alignment" tokenid="ooxml:CT_PTab_alignment"/>
<attribute name="relativeTo" tokenid="ooxml:CT_PTab_relativeTo"/>
<attribute name="leader" tokenid="ooxml:CT_PTab_leader"/>
<action name="end" action="tab"/>
</resource>
- <resource name="CT_Sym" resource="Properties">
+ <resource name="CT_Sym" resource="Properties" tag="character">
<attribute name="font" tokenid="ooxml:CT_Sym_font"/>
<attribute name="char" tokenid="ooxml:CT_Sym_char"/>
</resource>
@@ -22356,29 +22361,29 @@
<value name="owners" tokenid="ooxml:Value_wordprocessingml_ST_EdGrp_owners">owners</value>
<value name="current" tokenid="ooxml:Value_wordprocessingml_ST_EdGrp_current">current</value>
</resource>
- <resource name="CT_Text" resource="Stream">
+ <resource name="CT_Text" resource="Stream" tag="content">
<attribute name="xml:space" tokenid="ooxml:CT_Text_space"/>
<action name="characters" action="text"/>
</resource>
- <resource name="CT_FtnEdnRefChar" resource="Stream">
+ <resource name="CT_FtnEdnRefChar" resource="Stream" tag="reference">
<action name="end" action="ftnednref"/>
</resource>
- <resource name="CT_FtnEdnSep" resource="Stream">
+ <resource name="CT_FtnEdnSep" resource="Stream" tag="reference">
<action name="end" action="ftnednsep"/>
</resource>
- <resource name="CT_FtnEdnCont" resource="Stream">
+ <resource name="CT_FtnEdnCont" resource="Stream" tag="reference">
<action name="end" action="ftnedncont"/>
</resource>
- <resource name="CT_PgNum" resource="Stream">
+ <resource name="CT_PgNum" resource="Stream" tag="reference">
<action name="end" action="pgNum"/>
</resource>
- <resource name="CT_Cr" resource="Stream">
+ <resource name="CT_Cr" resource="Stream" tag="content">
<action name="end" action="endOfParagraph"/>
</resource>
- <resource name="CT_Tab" resource="Stream">
+ <resource name="CT_Tab" resource="Stream" tag="content">
<action name="end" action="tab"/>
</resource>
- <resource name="EG_RunInnerContent" resource="Stream">
+ <resource name="EG_RunInnerContent" resource="Stream" tag="content">
<element name="br" tokenid="ooxml:EG_RunInnerContent_br"/>
<element name="t" tokenid="ooxml:EG_RunInnerContent_t"/>
<element name="delText" tokenid="ooxml:EG_RunInnerContent_delText"/>
@@ -22412,7 +22417,7 @@
<element name="ptab" tokenid="ooxml:EG_RunInnerContent_ptab"/>
<element name="lastRenderedPageBreak" tokenid="ooxml:EG_RunInnerContent_lastRenderedPageBreak"/>
</resource>
- <resource name="CT_R" resource="Stream">
+ <resource name="CT_R" resource="Stream" tag="content">
<action name="start" action="startCharacterGroup"/>
</resource>
<resource name="ST_Hint" resource="List">
@@ -22430,7 +22435,7 @@
<value tokenid="ooxml:Value_ST_Theme_minorAscii">minorAscii</value>
<value tokenid="ooxml:Value_ST_Theme_minorHAnsi">minorHAnsi</value>
</resource>
- <resource name="CT_Fonts" resource="Properties">
+ <resource name="CT_Fonts" resource="Properties" tag="font">
<attribute name="hint" tokenid="ooxml:CT_Fonts_hint"/>
<attribute name="ascii" tokenid="ooxml:CT_Fonts_ascii"/>
<attribute name="hAnsi" tokenid="ooxml:CT_Fonts_hAnsi"/>
@@ -22441,7 +22446,7 @@
<attribute name="eastAsiaTheme" tokenid="ooxml:CT_Fonts_eastAsiaTheme"/>
<attribute name="cstheme" tokenid="ooxml:CT_Fonts_cstheme"/>
</resource>
- <resource name="EG_RPrBase" resource="Properties">
+ <resource name="EG_RPrBase" resource="Properties" tag="paragraph">
<kind name="paragraph"/>
<element name="rStyle" tokenid="ooxml:EG_RPrBase_rStyle"/>
<element name="rFonts" tokenid="ooxml:EG_RPrBase_rFonts"/>
@@ -22483,19 +22488,19 @@
<element name="specVanish" tokenid="0x818"/>
<element name="oMath" tokenid="ooxml:EG_RPrBase_oMath"/>
</resource>
- <resource name="EG_RPrContent" resource="Properties">
+ <resource name="EG_RPrContent" resource="Properties" tag="character">
<element name="rPrChange" tokenid="ooxml:EG_RPrContent_rPrChange"/>
</resource>
- <resource name="CT_RPr" resource="Properties">
+ <resource name="CT_RPr" resource="Properties" tag="character">
</resource>
- <resource name="CT_RPrOriginal" resource="Properties"/>
- <resource name="CT_ParaRPrOriginal" resource="Properties"/>
- <resource name="CT_ParaRPr" resource="Properties">
+ <resource name="CT_RPrOriginal" resource="Properties" tag="character"/>
+ <resource name="CT_ParaRPrOriginal" resource="Properties" tag="paragraph"/>
+ <resource name="CT_ParaRPr" resource="Properties" tag="redline">
<element name="ins" tokenid="ooxml:CT_ParaRPr_ins"/>
<element name="del" tokenid="ooxml:CT_ParaRPr_del"/>
<element name="rPrChange" tokenid="ooxml:CT_ParaRPr_rPrChange"/>
</resource>
- <resource name="CT_ParaTrackChange" resource="Properties">
+ <resource name="CT_ParaTrackChange" resource="Properties" tag="redline">
<action name="start" action="tokenproperty"/>
<action name="start" action="propagateCharacterPropertiesAsSet" sendtokenid="ooxml:paratrackchange"/>
<action name="start" action="clearProps"/>
@@ -22508,7 +22513,7 @@
<value name="right" tokenid="ooxml:Value_wordprocessingml_ST_RubyAlign_right">right</value>
<value name="rightVertical" tokenid="ooxml:Value_wordprocessingml_ST_RubyAlign_rightVertical">rightVertical</value>
</resource>
- <resource name="CT_RubyAlign" resource="Value" generated="yes">
+ <resource name="CT_RubyAlign" resource="Value" generated="yes" tag="character">
<attribute name="val" tokenid="ooxml:CT_RubyAlign_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -22518,7 +22523,7 @@
<value name="unlocked" tokenid="ooxml:Value_wordprocessingml_ST_Lock_unlocked">unlocked</value>
<value name="sdtContentLocked" tokenid="ooxml:Value_wordprocessingml_ST_Lock_sdtContentLocked">sdtContentLocked</value>
</resource>
- <resource name="CT_Lock" resource="Value" generated="yes">
+ <resource name="CT_Lock" resource="Value" generated="yes" tag="content">
<attribute name="val" tokenid="ooxml:CT_Lock_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -22527,7 +22532,7 @@
<value name="date" tokenid="ooxml:Value_wordprocessingml_ST_SdtDateMappingType_date">date</value>
<value name="dateTime" tokenid="ooxml:Value_wordprocessingml_ST_SdtDateMappingType_dateTime">dateTime</value>
</resource>
- <resource name="CT_SdtDateMappingType" resource="Value" generated="yes">
+ <resource name="CT_SdtDateMappingType" resource="Value" generated="yes" tag="content">
<attribute name="val" tokenid="ooxml:CT_SdtDateMappingType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -22543,32 +22548,32 @@
<value name="gregorianXlitEnglish" tokenid="ooxml:Value_wordprocessingml_ST_CalendarType_gregorianXlitEnglish">gregorianXlitEnglish</value>
<value name="gregorianXlitFrench" tokenid="ooxml:Value_wordprocessingml_ST_CalendarType_gregorianXlitFrench">gregorianXlitFrench</value>
</resource>
- <resource name="CT_CalendarType" resource="Value" generated="yes">
+ <resource name="CT_CalendarType" resource="Value" generated="yes" tag="content">
<attribute name="val" tokenid="ooxml:CT_CalendarType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_SdtContentRun" resource="Properties"/>
- <resource name="CT_Attr" resource="Properties">
+ <resource name="CT_SdtContentRun" resource="Properties" tag="content"/>
+ <resource name="CT_Attr" resource="Properties" tag="content">
<attribute name="uri" tokenid="ooxml:CT_Attr_uri"/>
<attribute name="name" tokenid="ooxml:CT_Attr_name"/>
<attribute name="val" tokenid="ooxml:CT_Attr_val"/>
</resource>
- <resource name="CT_CustomXmlRun" resource="Properties">
+ <resource name="CT_CustomXmlRun" resource="Properties" tag="content">
<element name="customXmlPr" tokenid="ooxml:CT_CustomXmlRun_customXmlPr"/>
<attribute name="uri" tokenid="ooxml:CT_CustomXmlRun_uri"/>
<attribute name="element" tokenid="ooxml:CT_CustomXmlRun_element"/>
</resource>
- <resource name="CT_SmartTagRun" resource="Properties">
+ <resource name="CT_SmartTagRun" resource="Properties" tag="content">
<element name="smartTagPr" tokenid="ooxml:CT_SmartTagRun_smartTagPr"/>
<attribute name="uri" tokenid="ooxml:CT_SmartTagRun_uri"/>
<attribute name="element" tokenid="ooxml:CT_SmartTagRun_element"/>
</resource>
- <resource name="EG_PContent" resource="Properties">
+ <resource name="EG_PContent" resource="Properties" tag="content">
<element name="fldSimple" tokenid="ooxml:EG_PContent_fldSimple"/>
<element name="hyperlink" tokenid="ooxml:EG_PContent_hyperlink"/>
<element name="subDoc" tokenid="ooxml:EG_PContent_subDoc"/>
</resource>
- <resource name="CT_P" resource="Stream">
+ <resource name="CT_P" resource="Stream" tag="content">
<action name="start" action="handleLastParagraphInSection"/>
<action name="start" action="startParagraphGroup"/>
<action name="start" action="setHandle"/>
@@ -22581,27 +22586,27 @@
<value tokenid="ooxml:Value_ST_TblWidth_dxa">dxa</value>
<value tokenid="ooxml:Value_ST_TblWidth_auto">auto</value>
</resource>
- <resource name="CT_Height" resource="Properties">
+ <resource name="CT_Height" resource="Properties" tag="attribute">
<attribute name="val" tokenid="ooxml:CT_Height_val"/>
<attribute name="hRule" tokenid="ooxml:CT_Height_hRule"/>
</resource>
- <resource name="CT_TblWidth" resource="Properties">
+ <resource name="CT_TblWidth" resource="Properties" tag="table">
<attribute name="w" tokenid="ooxml:CT_TblWidth_w"/>
<attribute name="type" tokenid="ooxml:CT_TblWidth_type"/>
</resource>
- <resource name="CT_TblGridCol" resource="Value">
+ <resource name="CT_TblGridCol" resource="Value" tag="table">
<attribute name="w" tokenid="ooxml:CT_TblGridCol_w" action="setValue"/>
<action name="start" action="setDefaultIntegerValue"/>
</resource>
- <resource name="CT_TblGridBase" resource="Properties">
+ <resource name="CT_TblGridBase" resource="Properties" tag="table">
<element name="gridCol" tokenid="ooxml:CT_TblGridBase_gridCol"/>
</resource>
- <resource name="CT_TblGrid" resource="Properties">
+ <resource name="CT_TblGrid" resource="Properties" tag="table">
<element name="tblGridChange" tokenid="ooxml:CT_TblGrid_tblGridChange"/>
<action name="end" action="propagateTableProperties"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_TcBorders" resource="Properties">
+ <resource name="CT_TcBorders" resource="Properties" tag="table">
<kind name="table"/>
<element name="top" tokenid="ooxml:CT_TcBorders_top"/>
<element name="left" tokenid="ooxml:CT_TcBorders_left"/>
@@ -22612,7 +22617,7 @@
<element name="tl2br" tokenid="ooxml:CT_TcBorders_tl2br"/>
<element name="tr2bl" tokenid="ooxml:CT_TcBorders_tr2bl"/>
</resource>
- <resource name="CT_TcMar" resource="Properties">
+ <resource name="CT_TcMar" resource="Properties" tag="table">
<kind name="table"/>
<element name="top" tokenid="ooxml:CT_TcMar_top"/>
<element name="left" tokenid="ooxml:CT_TcMar_left"/>
@@ -22624,13 +22629,13 @@
<value tokenid="ooxml:Value_ST_Merge_restart">restart</value>
<default tokenid="ooxml:Value_ST_Merge_continue"/>
</resource>
- <resource name="CT_VMerge" resource="Value">
+ <resource name="CT_VMerge" resource="Value" tag="table">
<attribute name="val" tokenid="ooxml:CT_VMerge_val" action="setValue"/>
</resource>
- <resource name="CT_HMerge" resource="Value">
+ <resource name="CT_HMerge" resource="Value" tag="table">
<attribute name="val" tokenid="ooxml:CT_HMerge_val" action="setValue"/>
</resource>
- <resource name="CT_TcPrBase" resource="Properties">
+ <resource name="CT_TcPrBase" resource="Properties" tag="table">
<kind name="table"/>
<element name="cnfStyle" tokenid="ooxml:CT_TcPrBase_cnfStyle"/>
<element name="tcW" tokenid="ooxml:CT_TcPrBase_tcW"/>
@@ -22646,12 +22651,12 @@
<element name="vAlign" tokenid="ooxml:CT_TcPrBase_vAlign"/>
<element name="hideMark" tokenid="ooxml:CT_TcPrBase_hideMark"/>
</resource>
- <resource name="CT_TcPr" resource="Properties">
+ <resource name="CT_TcPr" resource="Properties" tag="table">
<element name="tcPrChange" tokenid="ooxml:CT_TcPr_tcPrChange"/>
<action name="end" action="propagateCellProperties"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_TcPrInner" resource="Properties"/>
+ <resource name="CT_TcPrInner" resource="Properties" tag="table"/>
<resource name="CT_Tc" resource="TextTableCell">
<action name="start" action="startCell"/>
<action name="end" action="endCell"/>
@@ -22659,11 +22664,11 @@
<action name="end" action="endParagraphGroup"/>
</resource>
<resource name="ST_Cnf" resource="String" generated="yes"/>
- <resource name="CT_Cnf" resource="Value" generated="yes">
+ <resource name="CT_Cnf" resource="Value" generated="yes" tag="content">
<attribute name="val" tokenid="ooxml:CT_Cnf_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_TrPrBase" resource="Properties">
+ <resource name="CT_TrPrBase" resource="Properties" tag="table">
<kind name="table"/>
<element name="cnfStyle" tokenid="ooxml:CT_TrPrBase_cnfStyle"/>
<element name="divId" tokenid="ooxml:CT_TrPrBase_divId"/>
@@ -22678,7 +22683,7 @@
<element name="jc" tokenid="ooxml:CT_TrPrBase_jc"/>
<element name="hidden" tokenid="ooxml:CT_TrPrBase_hidden"/>
</resource>
- <resource name="CT_TrPr" resource="Properties">
+ <resource name="CT_TrPr" resource="Properties" tag="table">
<kind name="table"/>
<element name="ins" tokenid="ooxml:CT_TrPr_ins"/>
<element name="del" tokenid="ooxml:CT_TrPr_del"/>
@@ -22686,7 +22691,7 @@
<action name="end" action="propagateRowProperties"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_Row" resource="TextTableRow">
+ <resource name="CT_Row" resource="TextTableRow" tag="table">
<action name="start" action="startRow"/>
<action name="end" action="sendRowProperties"/>
<action name="end" action="sendTableProperties"/>
@@ -22700,16 +22705,16 @@
<value tokenid="ooxml:Value_ST_TblOverlap_never">never</value>
<value tokenid="ooxml:Value_ST_TblOverlap_overlap">overlap</value>
</resource>
- <resource name="CT_TblOverlap" resource="Value">
+ <resource name="CT_TblOverlap" resource="Value" tag="table">
<attribute name="val" tokenid="ooxml:CT_TblOverlap_val" action="setValue"/>
</resource>
- <resource name="CT_TblCellMar" resource="Properties">
+ <resource name="CT_TblCellMar" resource="Properties" tag="table">
<element name="top" tokenid="ooxml:CT_TblCellMar_top"/>
<element name="left" tokenid="ooxml:CT_TblCellMar_left"/>
<element name="bottom" tokenid="ooxml:CT_TblCellMar_bottom"/>
<element name="right" tokenid="ooxml:CT_TblCellMar_right"/>
</resource>
- <resource name="CT_TblBorders" resource="Properties">
+ <resource name="CT_TblBorders" resource="Properties" tag="table">
<kind name="table"/>
<element name="top" tokenid="ooxml:CT_TblBorders_top"/>
<element name="left" tokenid="ooxml:CT_TblBorders_left"/>
@@ -22718,7 +22723,7 @@
<element name="insideH" tokenid="ooxml:CT_TblBorders_insideH"/>
<element name="insideV" tokenid="ooxml:CT_TblBorders_insideV"/>
</resource>
- <resource name="CT_TblPrBase" resource="Properties">
+ <resource name="CT_TblPrBase" resource="Properties" tag="table">
<kind name="table"/>
<element name="tblStyle" tokenid="ooxml:CT_TblPrBase_tblStyle"/>
<element name="tblpPr" tokenid="ooxml:CT_TblPrBase_tblpPr"/>
@@ -22736,30 +22741,30 @@
<element name="tblCellMar" tokenid="ooxml:CT_TblPrBase_tblCellMar"/>
<element name="tblLook" tokenid="ooxml:CT_TblPrBase_tblLook"/>
</resource>
- <resource name="CT_TblPr" resource="Properties">
+ <resource name="CT_TblPr" resource="Properties" tag="table">
<kind name="table"/>
<element name="tblPrChange" tokenid="ooxml:CT_TblPr_tblPrChange"/>
<action name="end" action="propagateTableProperties"/>
<action name="end" action="clearProps"/>
</resource>
- <resource name="CT_Tbl" resource="TextTable"/>
+ <resource name="CT_Tbl" resource="TextTable" tag="table"/>
<resource name="ST_FtnPos" resource="List">
<value tokenid="ooxml:Value_ST_FtnPos_pageBottom">pageBottom</value>
<value tokenid="ooxml:Value_ST_FtnPos_beneathText">beneathText</value>
<value tokenid="ooxml:Value_ST_FtnPos_sectEnd">sectEnd</value>
<value tokenid="ooxml:Value_ST_FtnPos_docEnd">docEnd</value>
</resource>
- <resource name="CT_FtnPos" resource="Value">
+ <resource name="CT_FtnPos" resource="Value" tag="reference">
<attribute name="val" tokenid="ooxml:CT_FtnPos_val" action="setValue"/>
</resource>
<resource name="ST_EdnPos" resource="List">
<value tokenid="ooxml:Value_ST_EdnPos_sectEnd">sectEnd</value>
<value tokenid="ooxml:Value_ST_EdnPos_docEnd">docEnd</value>
</resource>
- <resource name="CT_EdnPos" resource="Value">
+ <resource name="CT_EdnPos" resource="Value" tag="reference">
<attribute name="val" tokenid="ooxml:CT_EdnPos_val" action="setValue"/>
</resource>
- <resource name="CT_NumFmt" resource="Value">
+ <resource name="CT_NumFmt" resource="Value" tag="numbering">
<attribute name="val" tokenid="ooxml:CT_NumFmt_val" action="setValue"/>
</resource>
<resource name="ST_RestartNumber" resource="List">
@@ -22767,42 +22772,42 @@
<value tokenid="ooxml:Value_ST_RestartNumber_eachSect">eachSect</value>
<value tokenid="ooxml:Value_ST_RestartNumber_eachPage">eachPage</value>
</resource>
- <resource name="CT_NumRestart" resource="Value">
+ <resource name="CT_NumRestart" resource="Value" tag="numbering">
<attribute name="val" tokenid="ooxml:CT_NumRestart_val" action="setValue"/>
</resource>
- <resource name="CT_FtnEdnRef" resource="Properties">
+ <resource name="CT_FtnEdnRef" resource="Properties" tag="reference">
<attribute name="customMarkFollows" tokenid="ooxml:CT_FtnEdnRef_customMarkFollows"/>
<attribute name="id" tokenid="ooxml:CT_FtnEdnRef_id" action="setXNoteId"/>
<action name="end" action="handleXNotes"/>
</resource>
- <resource name="CT_FtnEdnSepRef" resource="Properties">
+ <resource name="CT_FtnEdnSepRef" resource="Properties" tag="reference">
<attribute name="id" tokenid="ooxml:CT_FtnEdnSepRef_id"/>
</resource>
- <resource name="CT_FtnEdn" resource="XNote">
+ <resource name="CT_FtnEdn" resource="XNote" tag="reference">
<attribute name="type" tokenid="ooxml:CT_FtnEdn_type"/>
<attribute name="id" tokenid="ooxml:CT_FtnEdn_id" action="checkId"/>
<action name="start" action="propagateCharacterProperties"/>
<action name="end" action="endSectionGroup"/>
</resource>
- <resource name="CT_CommentRef" resource="Properties">
+ <resource name="CT_CommentRef" resource="Properties" tag="reference">
<action name="end" action="handleComment"/>
</resource>
- <resource name="EG_FtnEdnNumProps" resource="Properties">
+ <resource name="EG_FtnEdnNumProps" resource="Properties" tag="reference">
<element name="numStart" tokenid="ooxml:EG_FtnEdnNumProps_numStart"/>
<element name="numRestart" tokenid="ooxml:EG_FtnEdnNumProps_numRestart"/>
</resource>
- <resource name="CT_FtnProps" resource="Properties">
+ <resource name="CT_FtnProps" resource="Properties" tag="reference">
<element name="pos" tokenid="ooxml:CT_FtnProps_pos"/>
<element name="numFmt" tokenid="ooxml:CT_FtnProps_numFmt"/>
</resource>
- <resource name="CT_EdnProps" resource="Properties">
+ <resource name="CT_EdnProps" resource="Properties" tag="reference">
<element name="pos" tokenid="ooxml:CT_EdnProps_pos"/>
<element name="numFmt" tokenid="ooxml:CT_EdnProps_numFmt"/>
</resource>
- <resource name="CT_FtnDocProps" resource="Properties">
+ <resource name="CT_FtnDocProps" resource="Properties" tag="reference">
<element name="footnote" tokenid="ooxml:CT_FtnDocProps_footnote"/>
</resource>
- <resource name="CT_EdnDocProps" resource="Properties">
+ <resource name="CT_EdnDocProps" resource="Properties" tag="reference">
<element name="endnote" tokenid="ooxml:CT_EdnDocProps_endnote"/>
</resource>
<resource name="ST_MailMergeSourceType" resource="List" generated="yes">
@@ -22816,11 +22821,11 @@
<value name="legacy" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeSourceType_legacy">legacy</value>
<value name="master" tokenid="ooxml:Value_wordprocessingml_ST_MailMergeSourceType_master">master</value>
</resource>
- <resource name="CT_MailMergeSourceType" resource="Value" generated="yes">
+ <resource name="CT_MailMergeSourceType" resource="Value" generated="yes" tag="mailmerge">
<attribute name="val" tokenid="ooxml:CT_MailMergeSourceType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_MailMerge" resource="Properties">
+ <resource name="CT_MailMerge" resource="Properties" tag="mailmerge">
<element name="mainDocumentType" tokenid="ooxml:CT_MailMerge_mainDocumentType"/>
<element name="linkToQuery" tokenid="ooxml:CT_MailMerge_linkToQuery"/>
<element name="dataType" tokenid="ooxml:CT_MailMerge_dataType"/>
@@ -22851,11 +22856,11 @@
<value name="1800x1440" tokenid="ooxml:Value_wordprocessingml_ST_TargetScreenSz_1800x1440">1800x1440</value>
<value name="1920x1200" tokenid="ooxml:Value_wordprocessingml_ST_TargetScreenSz_1920x1200">1920x1200</value>
</resource>
- <resource name="CT_TargetScreenSz" resource="Value" generated="yes">
+ <resource name="CT_TargetScreenSz" resource="Value" generated="yes" tag="settings">
<attribute name="val" tokenid="ooxml:CT_TargetScreenSz_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_Compat" resource="Properties">
+ <resource name="CT_Compat" resource="Properties" tag="settings">
<element name="useSingleBorderforContiguousCells" tokenid="ooxml:CT_Compat_useSingleBorderforContiguousCells"/>
<element name="wpJustification" tokenid="ooxml:CT_Compat_wpJustification"/>
<element name="noTabHangInd" tokenid="ooxml:CT_Compat_noTabHangInd"/>
@@ -22922,11 +22927,11 @@
<element name="useAnsiKerningPairs" tokenid="ooxml:CT_Compat_useAnsiKerningPairs"/>
<element name="cachedColBalance" tokenid="ooxml:CT_Compat_cachedColBalance"/>
</resource>
- <resource name="CT_DocVar" resource="Properties">
+ <resource name="CT_DocVar" resource="Properties" tag="document">
<attribute name="name" tokenid="ooxml:CT_DocVar_name"/>
<attribute name="val" tokenid="ooxml:CT_DocVar_val"/>
</resource>
- <resource name="CT_DocRsids" resource="Properties">
+ <resource name="CT_DocRsids" resource="Properties" tag="redline">
<element name="rsidRoot" tokenid="ooxml:CT_DocRsids_rsidRoot"/>
<element name="rsid" tokenid="ooxml:CT_DocRsids_rsid"/>
</resource>
@@ -22935,21 +22940,21 @@
<value name="compressPunctuation" tokenid="ooxml:Value_wordprocessingml_ST_CharacterSpacing_compressPunctuation">compressPunctuation</value>
<value name="compressPunctuationAndJapaneseKana" tokenid="ooxml:Value_wordprocessingml_ST_CharacterSpacing_compressPunctuationAndJapaneseKana">compressPunctuationAndJapaneseKana</value>
</resource>
- <resource name="CT_CharacterSpacing" resource="Value" generated="yes">
+ <resource name="CT_CharacterSpacing" resource="Value" generated="yes" tag="character">
<attribute name="val" tokenid="ooxml:CT_CharacterSpacing_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_SaveThroughXslt" resource="Properties">
+ <resource name="CT_SaveThroughXslt" resource="Properties" tag="settings">
<attribute name="r:id" tokenid="ooxml:CT_SaveThroughXslt_r_id"/>
<attribute name="solutionID" tokenid="ooxml:CT_SaveThroughXslt_solutionID"/>
</resource>
- <resource name="CT_RPrDefault" resource="Properties">
+ <resource name="CT_RPrDefault" resource="Properties" tag="character">
<element name="rPr" tokenid="ooxml:CT_RPrDefault_rPr"/>
</resource>
- <resource name="CT_PPrDefault" resource="Properties">
+ <resource name="CT_PPrDefault" resource="Properties" tag="paragraph">
<element name="pPr" tokenid="ooxml:CT_PPrDefault_pPr"/>
</resource>
- <resource name="CT_DocDefaults" resource="Properties">
+ <resource name="CT_DocDefaults" resource="Properties" tag="document">
<element name="pPrDefault" tokenid="ooxml:CT_DocDefaults_pPrDefault"/>
<element name="rPrDefault" tokenid="ooxml:CT_DocDefaults_rPrDefault"/>
</resource>
@@ -22973,10 +22978,10 @@
<attribute name="h" tokenid="ooxml:CT_ReadingModeInkLockDown_h"/>
<attribute name="fontSz" tokenid="ooxml:CT_ReadingModeInkLockDown_fontSz"/>
</resource>
- <resource name="CT_WriteProtection" resource="Properties">
+ <resource name="CT_WriteProtection" resource="Properties" tag="document">
<attribute name="recommended" tokenid="ooxml:CT_WriteProtection_recommended"/>
</resource>
- <resource name="CT_Settings" resource="PropertyTable" tokenid="ooxml:SETTINGS">
+ <resource name="CT_Settings" resource="PropertyTable" tokenid="ooxml:SETTINGS" tag="settings">
<element name="writeProtection" tokenid="ooxml:CT_Settings_writeProtection"/>
<element name="view" tokenid="ooxml:CT_Settings_view"/>
<element name="zoom" tokenid="ooxml:CT_Settings_zoom"/>
@@ -23080,7 +23085,7 @@
<value name="off" tokenid="ooxml:Value_wordprocessingml_ST_FrameScrollbar_off">off</value>
<value name="auto" tokenid="ooxml:Value_wordprocessingml_ST_FrameScrollbar_auto">auto</value>
</resource>
- <resource name="CT_FrameScrollbar" resource="Value" generated="yes">
+ <resource name="CT_FrameScrollbar" resource="Value" generated="yes" tag="frame">
<attribute name="val" tokenid="ooxml:CT_FrameScrollbar_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -23089,7 +23094,7 @@
<value name="cols" tokenid="ooxml:Value_wordprocessingml_ST_FrameLayout_cols">cols</value>
<value name="none" tokenid="ooxml:Value_wordprocessingml_ST_FrameLayout_none">none</value>
</resource>
- <resource name="CT_FrameLayout" resource="Value" generated="yes">
+ <resource name="CT_FrameLayout" resource="Value" generated="yes" tag="frame">
<attribute name="val" tokenid="ooxml:CT_FrameLayout_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -23098,20 +23103,20 @@
<value name="space" tokenid="ooxml:Value_wordprocessingml_ST_LevelSuffix_space">space</value>
<value name="nothing" tokenid="ooxml:Value_wordprocessingml_ST_LevelSuffix_nothing">nothing</value>
</resource>
- <resource name="CT_LevelSuffix" resource="Value" generated="yes">
+ <resource name="CT_LevelSuffix" resource="Value" generated="yes" tag="numbering">
<attribute name="val" tokenid="ooxml:CT_LevelSuffix_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_LevelText" resource="Properties">
+ <resource name="CT_LevelText" resource="Properties" tag="numbering">
<attribute name="val" tokenid="ooxml:CT_LevelText_val"/>
<attribute name="null" tokenid="ooxml:CT_LevelText_null"/>
</resource>
- <resource name="CT_LvlLegacy" resource="Properties">
+ <resource name="CT_LvlLegacy" resource="Properties" tag="numbering">
<attribute name="legacy" tokenid="ooxml:CT_LvlLegacy_legacy"/>
<attribute name="legacySpace" tokenid="ooxml:CT_LvlLegacy_legacySpace"/>
<attribute name="legacyIndent" tokenid="ooxml:CT_LvlLegacy_legacyIndent"/>
</resource>
- <resource name="CT_Lvl" resource="Properties">
+ <resource name="CT_Lvl" resource="Properties" tag="numbering">
<kind name="paragraph"/>
<element name="start" tokenid="rtf:ISTARTAT"/>
<element name="numFmt" tokenid="rtf:NFC"/>
@@ -23129,15 +23134,15 @@
<attribute name="tplc" tokenid="ooxml:CT_Lvl_tplc"/>
<attribute name="tentative" tokenid="ooxml:CT_Lvl_tentative"/>
</resource>
- <resource name="ST_MultiLevelType" resource="List">
+ <resource name="ST_MultiLevelType" resource="List" tag="numbering">
<value tokenid="ooxml:Value_ST_MultiLevelType_singleLevel">singleLevel</value>
<value tokenid="ooxml:Value_ST_MultiLevelType_multilevel">multilevel</value>
<value tokenid="ooxml:Value_ST_MultiLevelType_hybridMultilevel">hybridMultilevel</value>
</resource>
- <resource name="CT_MultiLevelType" resource="Value">
+ <resource name="CT_MultiLevelType" resource="Value" tag="numbering">
<attribute name="val" tokenid="ooxml:CT_MultiLevelType_val" action="setValue"/>
</resource>
- <resource name="CT_AbstractNum" resource="Properties">
+ <resource name="CT_AbstractNum" resource="Properties" tag="numbering">
<kind name="paragraph"/>
<element name="nsid" tokenid="rtf:LSID"/>
<element name="multiLevelType" tokenid="ooxml:CT_AbstractNum_multiLevelType"/>
@@ -23148,19 +23153,19 @@
<element name="lvl" tokenid="ooxml:CT_AbstractNum_lvl"/>
<attribute name="abstractNumId" tokenid="ooxml:CT_AbstractNum_abstractNumId"/>
</resource>
- <resource name="CT_NumLvl" resource="Properties">
+ <resource name="CT_NumLvl" resource="Properties" tag="numbering">
<kind name="paragraph"/>
<element name="startOverride" tokenid="ooxml:CT_NumLvl_startOverride"/>
<element name="lvl" tokenid="ooxml:CT_NumLvl_lvl"/>
<attribute name="ilvl" tokenid="ooxml:CT_NumLvl_ilvl"/>
</resource>
- <resource name="CT_Num" resource="Properties">
+ <resource name="CT_Num" resource="Properties" tag="numbering">
<kind name="paragraph"/>
<element name="abstractNumId" tokenid="ooxml:CT_Num_abstractNumId"/>
<element name="lvlOverride" tokenid="ooxml:CT_Num_lvlOverride"/>
<attribute name="numId" tokenid="ooxml:CT_Num_numId"/>
</resource>
- <resource name="CT_Numbering" resource="PropertyTable" tokenid="ooxml:NUMBERING">
+ <resource name="CT_Numbering" resource="PropertyTable" tokenid="ooxml:NUMBERING" tag="numbering">
<kind name="paragraph"/>
<element name="numPicBullet" tokenid="ooxml:CT_Numbering_numPicBullet"/>
<element name="abstractNum" tokenid="ooxml:CT_Numbering_abstractNum"/>
@@ -23182,7 +23187,7 @@
<value tokenid="12">seCell</value>
<value tokenid="13">swCell</value>
</resource>
- <resource name="CT_Style_tblStylePr" resource="Properties">
+ <resource name="CT_Style_tblStylePr" resource="Properties" tag="style">
<element name="pPr" tokenid="ooxml:CT_PPrBase"/>
<element name="rPr" tokenid="ooxml:EG_RPrBase"/>
<element name="tblPr" tokenid="ooxml:CT_TblPrBase"/>
@@ -23196,7 +23201,7 @@
<value tokenid="3">table</value>
<value tokenid="4">numbering</value>
</resource>
- <resource name="CT_Style" resource="Properties">
+ <resource name="CT_Style" resource="Properties" tag="style">
<element name="name" tokenid="ooxml:CT_Style_name"/>
<element name="aliases" tokenid="ooxml:CT_Style_aliases"/>
<element name="basedOn" tokenid="ooxml:CT_Style_basedOn"/>
@@ -23224,9 +23229,9 @@
<attribute name="default" tokenid="ooxml:CT_Style_default"/>
<attribute name="customStyle" tokenid="ooxml:CT_Style_customStyle"/>
</resource>
- <resource name="CT_Styles" resource="Table" tokenid="rtf:STYLESHEET"/>
+ <resource name="CT_Styles" resource="Table" tokenid="rtf:STYLESHEET" tag="style"/>
<resource name="ST_Panose" resource="Hex"/>
- <resource name="CT_Panose" resource="Value">
+ <resource name="CT_Panose" resource="Value" tag="font">
<attribute name="val" tokenid="ooxml:CT_Panose_val" action="setValue"/>
<action name="start" action="setDefaultHexValue"/>
</resource>
@@ -23238,7 +23243,7 @@
<value tokenid="ooxml:Value_ST_FontFamily_swiss">swiss</value>
<value tokenid="ooxml:Value_ST_FontFamily_auto">auto</value>
</resource>
- <resource name="CT_FontFamily" resource="Value">
+ <resource name="CT_FontFamily" resource="Value" tag="font">
<attribute name="val" tokenid="ooxml:CT_FontFamily_val" action="setValue"/>
</resource>
<resource name="ST_Pitch" resource="List">
@@ -23246,10 +23251,10 @@
<value tokenid="ooxml:Value_ST_Pitch_variable">variable</value>
<value tokenid="ooxml:Value_ST_Pitch_default">default</value>
</resource>
- <resource name="CT_Pitch" resource="Value">
+ <resource name="CT_Pitch" resource="Value" tag="font">
<attribute name="val" tokenid="ooxml:CT_Pitch_val" action="setValue"/>
</resource>
- <resource name="CT_FontSig" resource="Properties">
+ <resource name="CT_FontSig" resource="Properties" tag="font">
<attribute name="usb0" tokenid="ooxml:CT_FontSig_usb0"/>
<attribute name="usb1" tokenid="ooxml:CT_FontSig_usb1"/>
<attribute name="usb2" tokenid="ooxml:CT_FontSig_usb2"/>
@@ -23257,11 +23262,11 @@
<attribute name="csb0" tokenid="ooxml:CT_FontSig_csb0"/>
<attribute name="csb1" tokenid="ooxml:CT_FontSig_csb1"/>
</resource>
- <resource name="CT_FontRel" resource="Properties">
+ <resource name="CT_FontRel" resource="Properties" tag="font">
<attribute name="fontKey" tokenid="ooxml:CT_FontRel_fontKey"/>
<attribute name="subsetted" tokenid="ooxml:CT_FontRel_subsetted"/>
</resource>
- <resource name="CT_Font" resource="Properties">
+ <resource name="CT_Font" resource="Properties" tag="font">
<kind name="character"/>
<element name="altName" tokenid="ooxml:CT_Font_altName"/>
<element name="panose1" tokenid="ooxml:CT_Font_panose1"/>
@@ -23276,8 +23281,8 @@
<element name="embedBoldItalic" tokenid="ooxml:CT_Font_embedBoldItalic"/>
<attribute name="name" tokenid="ooxml:CT_Font_name"/>
</resource>
- <resource name="CT_FontsList" resource="Table" tokenid="rtf:FONTTABLE"/>
- <resource name="EG_RunLevelElts" resource="Stream">
+ <resource name="CT_FontsList" resource="Table" tokenid="rtf:FONTTABLE" tag="font"/>
+ <resource name="EG_RunLevelElts" resource="Stream" tag="character">
<element name="proofErr" tokenid="ooxml:EG_RunLevelElts_proofErr"/>
<element name="permStart" tokenid="ooxml:EG_RunLevelElts_permStart"/>
<element name="permEnd" tokenid="ooxml:EG_RunLevelElts_permEnd"/>
@@ -23288,7 +23293,7 @@
<element name="moveFrom" tokenid="ooxml:EG_RunLevelElts_moveFrom"/>
<element name="moveTo" tokenid="ooxml:EG_RunLevelElts_moveTo"/>
</resource>
- <resource name="CT_Body" resource="Stream">
+ <resource name="CT_Body" resource="Stream" tag="content">
<action name="start" action="startSectionGroup"/>
<!--
<action name="start" action="footnoteSeparator"/>
@@ -23300,7 +23305,7 @@
<action name="end" action="endParagraphGroup"/>
<action name="end" action="endSectionGroup"/>
</resource>
- <resource xmlns:v="urn:schemas-microsoft-com:vml" name="CT_ShapeDefaults" resource="Properties">
+ <resource xmlns:v="urn:schemas-microsoft-com:vml" name="CT_ShapeDefaults" resource="Properties" tag="shape">
<element name="v:fill" tokenid="ooxml:CT_ShapeDefaults_v_fill"/>
<element name="v:stroke" tokenid="ooxml:CT_ShapeDefaults_v_stroke"/>
<element name="v:textbox" tokenid="ooxml:CT_ShapeDefaults_v_textbox"/>
@@ -23315,15 +23320,15 @@
<attribute name="strokecolor" tokenid="ooxml:CT_ShapeDefaults_strokecolor"/>
<attribute name="allowincell" tokenid="ooxml:CT_ShapeDefaults_allowincell"/>
</resource>
- <resource name="CT_Comments" resource="Stream">
+ <resource name="CT_Comments" resource="Stream" tag="content">
<action name="start" action="startSectionGroup"/>
<action name="end" action="endSectionGroup"/>
</resource>
- <resource name="CT_Footnotes" resource="Stream"/>
- <resource name="footnotes" resource="Stream"/>
- <resource name="CT_Endnotes" resource="Stream"/>
- <resource name="endnotes" resource="Stream"/>
- <resource name="CT_SmartTagType" resource="Properties">
+ <resource name="CT_Footnotes" resource="Stream" tag="reference"/>
+ <resource name="footnotes" resource="Stream" tag="reference"/>
+ <resource name="CT_Endnotes" resource="Stream" tag="reference"/>
+ <resource name="endnotes" resource="Stream" tag="reference"/>
+ <resource name="CT_SmartTagType" resource="Properties" tag="content">
<attribute name="namespaceuri" tokenid="ooxml:CT_SmartTagType_namespaceuri"/>
<attribute name="name" tokenid="ooxml:CT_SmartTagType_name"/>
<attribute name="url" tokenid="ooxml:CT_SmartTagType_url"/>
@@ -23352,7 +23357,7 @@
<value name="p" tokenid="ooxml:Value_wordprocessingml_ST_DocPartBehavior_p">p</value>
<value name="pg" tokenid="ooxml:Value_wordprocessingml_ST_DocPartBehavior_pg">pg</value>
</resource>
- <resource name="CT_DocPartBehavior" resource="Value" generated="yes">
+ <resource name="CT_DocPartBehavior" resource="Value" generated="yes" tag="document">
<attribute name="val" tokenid="ooxml:CT_DocPartBehavior_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -23365,7 +23370,7 @@
<value name="formFld" tokenid="ooxml:Value_wordprocessingml_ST_DocPartType_formFld">formFld</value>
<value name="bbPlcHdr" tokenid="ooxml:Value_wordprocessingml_ST_DocPartType_bbPlcHdr">bbPlcHdr</value>
</resource>
- <resource name="CT_DocPartType" resource="Value" generated="yes">
+ <resource name="CT_DocPartType" resource="Value" generated="yes" tag="document">
<attribute name="val" tokenid="ooxml:CT_DocPartType_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
@@ -23409,24 +23414,24 @@
<value name="custom4" tokenid="ooxml:Value_wordprocessingml_ST_DocPartGallery_custom4">custom4</value>
<value name="custom5" tokenid="ooxml:Value_wordprocessingml_ST_DocPartGallery_custom5">custom5</value>
</resource>
- <resource name="CT_DocPartGallery" resource="Value" generated="yes">
+ <resource name="CT_DocPartGallery" resource="Value" generated="yes" tag="document">
<attribute name="val" tokenid="ooxml:CT_DocPartGallery_val" action="setValue"/>
<action name="start" action="setDefaultStringValue"/>
</resource>
- <resource name="CT_DocPartName" resource="Properties">
+ <resource name="CT_DocPartName" resource="Properties" tag="document">
<attribute name="val" tokenid="ooxml:CT_DocPartName_val"/>
<attribute name="decorated" tokenid="ooxml:CT_DocPartName_decorated"/>
</resource>
- <resource name="settings" resource="Stream">
+ <resource name="settings" resource="Stream" tag="settings">
<element name="settings" tokenid="ooxml:settings_settings"/>
</resource>
- <resource name="fonts" resource="Stream">
+ <resource name="fonts" resource="Stream" tag="font">
<element name="fonts" tokenid="rtf:FONTTABLE"/>
</resource>
- <resource name="numbering" resource="Stream">
+ <resource name="numbering" resource="Stream" tag="numbering">
<element name="numbering" tokenid="ooxml:NUMBERING"/>
</resource>
- <resource name="styles" resource="Stream">
+ <resource name="styles" resource="Stream" tag="style">
<element name="styles" tokenid="rtf:STYLESHEET"/>
</resource>
<resource name="ST_CaptionPos" resource="List" generated="yes">
@@ -23435,7 +23440,7 @@
<value name="left" tokenid="ooxml:Value_wordprocessingml_ST_CaptionPos_left">left</value>
<value name="right" tokenid="ooxml:Value_wordprocessingml_ST_CaptionPos_right">right</value>
</resource>
- <resource name="CT_Caption" resource="Properties">
+ <resource name="CT_Caption" resource="Properties" tag="content">
<attribute name="name" tokenid="ooxml:CT_Caption_name"/>
<attribute name="pos" tokenid="ooxml:CT_Caption_pos"/>
<attribute name="chapNum" tokenid="ooxml:CT_Caption_chapNum"/>
@@ -23444,23 +23449,23 @@
<attribute name="numFmt" tokenid="ooxml:CT_Caption_numFmt"/>
<attribute name="sep" tokenid="ooxml:CT_Caption_sep"/>
</resource>
- <resource name="CT_AutoCaption" resource="Properties">
+ <resource name="CT_AutoCaption" resource="Properties" tag="content">
<attribute name="name" tokenid="ooxml:CT_AutoCaption_name"/>
<attribute name="caption" tokenid="ooxml:CT_AutoCaption_caption"/>
</resource>
- <resource name="CT_AutoCaptions" resource="Properties">
+ <resource name="CT_AutoCaptions" resource="Properties" tag="content">
<element name="autoCaption" tokenid="ooxml:CT_AutoCaptions_autoCaption"/>
</resource>
- <resource name="CT_Captions" resource="Properties">
+ <resource name="CT_Captions" resource="Properties" tag="content">
<element name="caption" tokenid="ooxml:CT_Captions_caption"/>
<element name="autoCaptions" tokenid="ooxml:CT_Captions_autoCaptions"/>
</resource>
- <resource name="CT_DocumentBase" resource="Properties">
+ <resource name="CT_DocumentBase" resource="Properties" tag="content">
<element name="background" tokenid="ooxml:CT_DocumentBase_background"/>
</resource>
- <resource name="CT_Document" resource="Stream"/>
- <resource name="CT_GlossaryDocument" resource="Stream"/>
- <resource name="document" resource="Stream"/>
- <resource name="glossaryDocument" resource="Stream"/>
+ <resource name="CT_Document" resource="Stream" tag="content"/>
+ <resource name="CT_GlossaryDocument" resource="Stream" tag="content"/>
+ <resource name="document" resource="Stream" tag="content"/>
+ <resource name="glossaryDocument" resource="Stream" tag="content"/>
</namespace>
</model>
diff --git a/writerfilter/source/resourcemodel/Fraction.cxx b/writerfilter/source/resourcemodel/Fraction.cxx
new file mode 100644
index 000000000000..c50668a7db03
--- /dev/null
+++ b/writerfilter/source/resourcemodel/Fraction.cxx
@@ -0,0 +1,150 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <resourcemodel/Fraction.hxx>
+
+namespace writerfilter {
+namespace resourcemodel {
+
+sal_uInt32 gcd(sal_uInt32 a, sal_uInt32 b)
+{
+ if (a == 0 || b == 0)
+ return a | b;
+
+ sal_uInt32 nShift = 0;
+ while (((a | b) & 1) == 0)
+ {
+ a >>= 1;
+ b >>= 1;
+ ++nShift;
+ }
+
+ while ((a & 1) == 0)
+ a >>= 1;
+
+ do
+ {
+ while ((b & 1) == 0)
+ b >>= 1;
+
+ if (a < b)
+ {
+ b -= a;
+ }
+ else
+ {
+ sal_uInt32 nDiff = a - b;
+ a = b;
+ b = nDiff;
+ }
+
+ b >>= 1;
+ }
+ while (b != 0);
+
+ return a << nShift;
+}
+
+sal_uInt32 lcm(sal_Int32 a, sal_Int32 b)
+{
+ return abs(a * b) / gcd(abs(a), abs(b));
+}
+
+Fraction::Fraction(sal_Int32 nNumerator, sal_Int32 nDenominator)
+{
+ init(nNumerator, nDenominator);
+}
+
+Fraction::Fraction(const Fraction & a, const Fraction & b)
+{
+ init(a.mnNumerator * b.mnDenominator, a.mnDenominator * b.mnNumerator);
+}
+
+Fraction::~Fraction()
+{
+}
+
+void Fraction::init(sal_Int32 nNumerator, sal_Int32 nDenominator)
+{
+ sal_uInt32 nGCD = gcd(nNumerator, nDenominator);
+
+ mnNumerator = nNumerator/ nGCD;
+ mnDenominator = nDenominator / nGCD;
+}
+
+void Fraction::assign(const Fraction & rFraction)
+{
+ init(rFraction.mnNumerator, rFraction.mnDenominator);
+}
+
+Fraction Fraction::inverse() const
+{
+ return Fraction(mnDenominator, mnNumerator);
+}
+
+Fraction Fraction::operator + (const Fraction & rFraction) const
+{
+ sal_uInt32 nLCM = lcm(mnDenominator, rFraction.mnDenominator);
+
+ return Fraction(mnNumerator * nLCM / mnDenominator + rFraction.mnNumerator * nLCM / rFraction.mnDenominator, nLCM);
+}
+
+Fraction Fraction::operator - (const Fraction & rFraction) const
+{
+ sal_uInt32 nLCM = lcm(mnDenominator, rFraction.mnDenominator);
+
+ return Fraction(mnNumerator * nLCM / mnDenominator - rFraction.mnNumerator * nLCM / rFraction.mnDenominator, nLCM);
+}
+
+Fraction Fraction::operator * (const Fraction & rFraction) const
+{
+ return Fraction(mnNumerator * rFraction.mnNumerator, mnDenominator * rFraction.mnDenominator);
+}
+
+Fraction Fraction::operator / (const Fraction & rFraction) const
+{
+ return *this * rFraction.inverse();
+}
+
+Fraction Fraction::operator = (const Fraction & rFraction)
+{
+ assign(rFraction);
+
+ return *this;
+}
+
+Fraction::operator sal_Int32() const
+{
+ return mnNumerator / mnDenominator;
+}
+
+Fraction::operator float() const
+{
+ return static_cast<float>(mnNumerator) / static_cast<float>(mnDenominator);
+}
+
+}}
diff --git a/writerfilter/source/resourcemodel/LoggedResources.cxx b/writerfilter/source/resourcemodel/LoggedResources.cxx
new file mode 100644
index 000000000000..f60b48b82b5b
--- /dev/null
+++ b/writerfilter/source/resourcemodel/LoggedResources.cxx
@@ -0,0 +1,322 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <rtl/ustrbuf.hxx>
+#include <resourcemodel/LoggedResources.hxx>
+#include <resourcemodel/QNameToString.hxx>
+
+namespace writerfilter
+{
+
+// class: LoggedResourcesHelper
+
+LoggedResourcesHelper::LoggedResourcesHelper(TagLogger::Pointer_t pLogger, const string & sPrefix)
+: mpLogger(pLogger), msPrefix(sPrefix)
+{
+}
+
+LoggedResourcesHelper::~LoggedResourcesHelper()
+{
+}
+
+void LoggedResourcesHelper::startElement(const string & sElement)
+{
+ mpLogger->startElement(msPrefix + "." + sElement);
+}
+
+void LoggedResourcesHelper::endElement(const string & sElement)
+{
+ mpLogger->endElement(msPrefix + "." + sElement);
+}
+
+void LoggedResourcesHelper::chars(const ::rtl::OUString & rChars)
+{
+ mpLogger->chars(rChars);
+}
+
+void LoggedResourcesHelper::chars(const string & rChars)
+{
+ mpLogger->chars(rChars);
+}
+
+void LoggedResourcesHelper::attribute(const string & rName, const string & rValue)
+{
+ mpLogger->attribute(rName, rValue);
+}
+
+void LoggedResourcesHelper::attribute(const string & rName, sal_uInt32 nValue)
+{
+ mpLogger->attribute(rName, nValue);
+}
+
+void LoggedResourcesHelper::setPrefix(const string & rPrefix)
+{
+ msPrefix = rPrefix;
+}
+
+// class: LoggedStream
+
+LoggedStream::LoggedStream(TagLogger::Pointer_t pLogger, const string & sPrefix)
+: mHelper(pLogger, sPrefix)
+{
+}
+
+LoggedStream::~LoggedStream()
+{
+}
+
+void LoggedStream::startSectionGroup()
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("section");
+#endif
+
+ lcl_startSectionGroup();
+}
+
+void LoggedStream::endSectionGroup()
+{
+ lcl_endSectionGroup();
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("section");
+#endif
+}
+
+void LoggedStream::startParagraphGroup()
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("paragraph");
+#endif
+
+ lcl_startParagraphGroup();
+}
+
+void LoggedStream::endParagraphGroup()
+{
+ lcl_endParagraphGroup();
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("paragraph");
+#endif
+}
+
+
+void LoggedStream::startCharacterGroup()
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("charactergroup");
+#endif
+
+ lcl_startCharacterGroup();
+}
+
+void LoggedStream::endCharacterGroup()
+{
+ lcl_endCharacterGroup();
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("charactergroup");
+#endif
+}
+
+void LoggedStream::startShape( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > xShape )
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("shape");
+#endif
+
+ lcl_startShape(xShape);
+}
+
+void LoggedStream::endShape()
+{
+ lcl_endShape();
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("shape");
+#endif
+}
+
+void LoggedStream::text(const sal_uInt8 * data, size_t len)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("text");
+
+ ::rtl::OUString sText( (const sal_Char*) data, len, RTL_TEXTENCODING_MS_1252 );
+
+ mHelper.startElement("data");
+ mHelper.chars(sText);
+ mHelper.endElement("data");
+#endif
+
+ lcl_text(data, len);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("text");
+#endif
+}
+
+void LoggedStream::utext(const sal_uInt8 * data, size_t len)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("utext");
+ mHelper.startElement("data");
+
+ ::rtl::OUString sText;
+ ::rtl::OUStringBuffer aBuffer = ::rtl::OUStringBuffer(len);
+ aBuffer.append( (const sal_Unicode *) data, len);
+ sText = aBuffer.makeStringAndClear();
+
+ mHelper.chars(sText);
+
+ mHelper.endElement("data");
+#endif
+
+ lcl_utext(data, len);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("utext");
+#endif
+}
+
+void LoggedStream::props(writerfilter::Reference<Properties>::Pointer_t ref)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("props");
+#endif
+
+ lcl_props(ref);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("props");
+#endif
+}
+
+void LoggedStream::table(Id name, writerfilter::Reference<Table>::Pointer_t ref)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("table");
+ mHelper.attribute("name", (*QNameToString::Instance())(name));
+#endif
+
+ lcl_table(name, ref);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("table");
+#endif
+}
+
+void LoggedStream::substream(Id name, writerfilter::Reference<Stream>::Pointer_t ref)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("substream");
+ mHelper.attribute("name", (*QNameToString::Instance())(name));
+#endif
+
+ lcl_substream(name, ref);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("substream");
+#endif
+}
+
+void LoggedStream::info(const string & _info)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("info");
+ mHelper.attribute("text", _info);
+#endif
+
+ lcl_info(_info);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("info");
+#endif
+}
+
+// class LoggedProperties
+LoggedProperties::LoggedProperties(TagLogger::Pointer_t pLogger, const string & sPrefix)
+: mHelper(pLogger, sPrefix)
+{
+}
+
+LoggedProperties::~LoggedProperties()
+{
+}
+
+void LoggedProperties::attribute(Id name, Value & val)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("attribute");
+ mHelper.attribute("name", (*QNameToString::Instance())(name));
+ mHelper.attribute("value", val.toString());
+ mHelper.endElement("attribute");
+#endif
+
+ lcl_attribute(name, val);
+}
+
+void LoggedProperties::sprm(Sprm & _sprm)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("sprm");
+ mHelper.attribute("name", (*QNameToString::Instance())(_sprm.getId()));
+ mHelper.chars(sprm.toString());
+#endif
+
+ lcl_sprm(_sprm);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("sprm");
+#endif
+}
+
+LoggedTable::LoggedTable(TagLogger::Pointer_t pLogger, const string & sPrefix)
+: mHelper(pLogger, sPrefix)
+{
+}
+
+LoggedTable::~LoggedTable()
+{
+}
+
+void LoggedTable::entry(int pos, writerfilter::Reference<Properties>::Pointer_t ref)
+{
+#ifdef DEBUG_LOGGING
+ mHelper.startElement("entry");
+ mHelper.attribute("pos", pos);
+#endif
+
+ lcl_entry(pos, ref);
+
+#ifdef DEBUG_LOGGING
+ mHelper.endElement("entry");
+#endif
+}
+
+}
diff --git a/writerfilter/source/resourcemodel/TagLogger.cxx b/writerfilter/source/resourcemodel/TagLogger.cxx
index f19bef7c01d1..ebb28aa0148b 100644
--- a/writerfilter/source/resourcemodel/TagLogger.cxx
+++ b/writerfilter/source/resourcemodel/TagLogger.cxx
@@ -25,7 +25,6 @@
*
************************************************************************/
-#ifdef DEBUG
#include <fstream>
#include <string.h>
#include <resourcemodel/TagLogger.hxx>
@@ -34,28 +33,28 @@
namespace writerfilter
{
- XMLTag::Pointer_t XMLTag::NIL(new XMLTag("NIL"));
+XMLTag::Pointer_t XMLTag::NIL(new XMLTag("NIL"));
- void XMLTag::addAttr(string sName, string sValue)
- {
- XMLAttribute aAttr(sName, sValue);
+void XMLTag::addAttr(string sName, string sValue)
+{
+ XMLAttribute aAttr(sName, sValue);
- mAttrs.push_back(aAttr);
- }
+ mAttrs.push_back(aAttr);
+}
- void XMLTag::addAttr(string sName, const ::rtl::OUString & sValue)
- {
- addAttr(sName,
- OUStringToOString
- (sValue, RTL_TEXTENCODING_ASCII_US).getStr());
- }
+void XMLTag::addAttr(string sName, const ::rtl::OUString & sValue)
+{
+ addAttr(sName,
+ OUStringToOString
+ (sValue, RTL_TEXTENCODING_ASCII_US).getStr());
+}
- void XMLTag::addAttr(string sName, sal_uInt32 nValue)
- {
- static char buffer[256];
- snprintf(buffer, sizeof(buffer), "%" SAL_PRIdINT32, nValue);
- addAttr(sName, buffer);
- }
+void XMLTag::addAttr(string sName, sal_uInt32 nValue)
+{
+ static char buffer[256];
+ snprintf(buffer, sizeof(buffer), "%" SAL_PRIdINT32, nValue);
+ addAttr(sName, buffer);
+}
void XMLTag::addAttr(string sName, uno::Any aAny)
{
@@ -111,322 +110,346 @@ void XMLTag::addAttr(string sName, uno::Any aAny)
aTmpStrString);
}
- void XMLTag::addTag(XMLTag::Pointer_t pTag)
- {
- if (pTag != XMLTag::Pointer_t())
- mTags.push_back(pTag);
- }
+void XMLTag::addTag(XMLTag::Pointer_t pTag)
+{
+ if (pTag != XMLTag::Pointer_t())
+ mTags.push_back(pTag);
+}
- void XMLTag::chars(const string & rChars)
- {
- mChars += rChars;
- }
+void XMLTag::chars(const string & rChars)
+{
+ mChars += rChars;
+}
void XMLTag::chars(const ::rtl::OUString & rChars)
{
chars(OUStringToOString(rChars, RTL_TEXTENCODING_ASCII_US).getStr());
}
- const string & XMLTag::getTag() const
- {
- return mTag;
- }
+const string & XMLTag::getTag() const
+{
+ return mTag;
+}
- string XMLTag::toString() const
- {
- if (mChars.length() > 0)
- return mChars;
+string XMLTag::toString() const
+{
+ if (mChars.length() > 0)
+ return mChars;
- string sResult;
+ string sResult;
- if (mMode == START || mMode == COMPLETE)
- {
- sResult += "<" + mTag;
+ if (mMode == START || mMode == COMPLETE)
+ {
+ sResult += "<" + mTag;
- XMLAttributes_t::const_iterator aIt = mAttrs.begin();
- while (aIt != mAttrs.end())
- {
- sResult += " ";
- sResult += aIt->mName;
- sResult += "=\"";
- sResult += xmlify(aIt->mValue);
- sResult += "\"";
+ XMLAttributes_t::const_iterator aIt = mAttrs.begin();
+ while (aIt != mAttrs.end())
+ {
+ sResult += " ";
+ sResult += aIt->mName;
+ sResult += "=\"";
+ sResult += xmlify(aIt->mValue);
+ sResult += "\"";
- aIt++;
- }
+ aIt++;
+ }
- sResult +=">";
+ sResult +=">";
- if (mTags.size() > 0)
+ if (mTags.size() > 0)
+ {
+ XMLTags_t::const_iterator aItTags = mTags.begin();
+ while (aItTags != mTags.end())
{
- XMLTags_t::const_iterator aItTags = mTags.begin();
- while (aItTags != mTags.end())
- {
- if ((*aItTags).get() != NULL)
- sResult += (*aItTags)->toString();
-
- aItTags++;
- }
+ if ((*aItTags).get() != NULL)
+ sResult += (*aItTags)->toString();
+
+ aItTags++;
}
}
+ }
- if (mMode == END || mMode == COMPLETE)
- sResult += "</" + mTag + ">";
+ if (mMode == END || mMode == COMPLETE)
+ sResult += "</" + mTag + ">";
- return sResult;
- }
+ return sResult;
+}
+
+ostream & XMLTag::output(ostream & o, const string & sIndent) const
+{
+ bool bHasContent = mChars.size() > 0 || mTags.size() > 0;
- ostream & XMLTag::output(ostream & o) const
+ if (mMode == START || mMode == COMPLETE)
{
- if (mMode == START || mMode == COMPLETE)
- {
- o << "<" << mTag;
+ o << sIndent << "<" << mTag;
- XMLAttributes_t::const_iterator aItAttrs(mAttrs.begin());
- while (aItAttrs != mAttrs.end())
- {
- o << " " << aItAttrs->mName << "=\""
- << xmlify(aItAttrs->mValue)
- << "\"";
+ XMLAttributes_t::const_iterator aItAttrs(mAttrs.begin());
+ while (aItAttrs != mAttrs.end())
+ {
+ o << " " << aItAttrs->mName << "=\""
+ << xmlify(aItAttrs->mValue)
+ << "\"";
- aItAttrs++;
- }
+ aItAttrs++;
+ }
+ if (bHasContent)
+ {
o << ">";
+ string sNewIndent = sIndent + " ";
XMLTags_t::const_iterator aItTags(mTags.begin());
while (aItTags != mTags.end())
{
- (*aItTags)->output(o);
+ if (aItTags == mTags.begin())
+ o << endl;
+
+ (*aItTags)->output(o, sNewIndent);
aItTags++;
}
o << mChars;
}
-
- if (mMode == END || mMode == COMPLETE)
- o << "</" << mTag << ">";
-
- return o;
}
- struct eqstr
+ if (mMode == END || mMode == COMPLETE)
{
- bool operator()(const char* s1, const char* s2) const
+ if (bHasContent)
{
- return strcmp(s1, s2) == 0;
- }
- };
-
- typedef hash_map<const char *, TagLogger::Pointer_t, hash<const char *>, eqstr> TagLoggerHashMap_t;
- static TagLoggerHashMap_t * tagLoggers = NULL;
+ if (mTags.size() > 0)
+ o << sIndent;
- TagLogger::TagLogger()
- : mFileName("writerfilter")
- {
+ o << "</" << mTag << ">" << endl;
+ }
+ else
+ o << "/>" << endl;
}
- TagLogger::~TagLogger()
- {
- }
+ return o;
+}
- void TagLogger::setFileName(const string & rName)
+struct eqstr
+{
+ bool operator()(const char* s1, const char* s2) const
{
- mFileName = rName;
+ return strcmp(s1, s2) == 0;
}
+};
- TagLogger::Pointer_t TagLogger::getInstance(const char * name)
- {
- if (tagLoggers == NULL)
- tagLoggers = new TagLoggerHashMap_t();
+typedef hash_map<const char *, TagLogger::Pointer_t, hash<const char *>, eqstr> TagLoggerHashMap_t;
+static TagLoggerHashMap_t * tagLoggers = NULL;
- TagLoggerHashMap_t::iterator aIt = tagLoggers->end();
+TagLogger::TagLogger()
+: mFileName("writerfilter")
+{
+}
- if (! tagLoggers->empty())
- aIt = tagLoggers->find(name);
+TagLogger::~TagLogger()
+{
+}
- if (aIt == tagLoggers->end())
- {
- TagLogger::Pointer_t pTagLogger(new TagLogger());
- pair<const char *, TagLogger::Pointer_t> entry(name, pTagLogger);
- aIt = tagLoggers->insert(entry).first;
- }
+void TagLogger::setFileName(const string & rName)
+{
+ mFileName = rName;
+}
- return aIt->second;
- }
+TagLogger::Pointer_t TagLogger::getInstance(const char * name)
+{
+ if (tagLoggers == NULL)
+ tagLoggers = new TagLoggerHashMap_t();
- XMLTag::Pointer_t TagLogger::currentTag() const
- {
- bool bEmpty=mTags.empty();
- if (!bEmpty)
- return mTags.top();
+ TagLoggerHashMap_t::iterator aIt = tagLoggers->end();
- return XMLTag::NIL;
- }
+ if (! tagLoggers->empty())
+ aIt = tagLoggers->find(name);
- void TagLogger::startDocument()
+ if (aIt == tagLoggers->end())
{
- XMLTag::Pointer_t pTag(new XMLTag("root"));
- mTags.push(pTag);
- mpRoot = pTag;
+ TagLogger::Pointer_t pTagLogger(new TagLogger());
+ pair<const char *, TagLogger::Pointer_t> entry(name, pTagLogger);
+ aIt = tagLoggers->insert(entry).first;
}
- void TagLogger::element(const string & name)
- {
- startElement(name);
- endElement(name);
- }
+ return aIt->second;
+}
- void TagLogger::startElement(const string & name)
- {
- XMLTag::Pointer_t pTag(new XMLTag(name));
- currentTag()->addTag(pTag);
- mTags.push(pTag);
- }
+XMLTag::Pointer_t TagLogger::currentTag() const
+{
+ bool bEmpty=mTags.empty();
+ if (!bEmpty)
+ return mTags.top();
- void TagLogger::attribute(const string & name, const string & value)
- {
- currentTag()->addAttr(name, value);
- }
+ return XMLTag::NIL;
+}
- void TagLogger::attribute(const string & name, const ::rtl::OUString & value)
- {
- currentTag()->addAttr(name, value);
- }
+void TagLogger::startDocument()
+{
+ XMLTag::Pointer_t pTag(new XMLTag("root"));
+ mTags.push(pTag);
+ mpRoot = pTag;
+}
- void TagLogger::attribute(const string & name, sal_uInt32 value)
- {
- currentTag()->addAttr(name, value);
- }
+void TagLogger::element(const string & name)
+{
+ startElement(name);
+ endElement(name);
+}
-void TagLogger::attribute(const string & name, const uno::Any aAny)
+void TagLogger::startElement(const string & name)
{
- currentTag()->addAttr(name, aAny);
+ XMLTag::Pointer_t pTag(new XMLTag(name));
+ currentTag()->addTag(pTag);
+ mTags.push(pTag);
}
- void TagLogger::addTag(XMLTag::Pointer_t pTag)
- {
- currentTag()->addTag(pTag);
- }
+void TagLogger::attribute(const string & name, const string & value)
+{
+ currentTag()->addAttr(name, value);
+}
- void TagLogger::chars(const string & rChars)
- {
- currentTag()->chars(xmlify(rChars));
- }
+void TagLogger::attribute(const string & name, const ::rtl::OUString & value)
+{
+ currentTag()->addAttr(name, value);
+}
- void TagLogger::chars(const ::rtl::OUString & rChars)
- {
- chars(OUStringToOString(rChars, RTL_TEXTENCODING_ASCII_US).getStr());
- }
+void TagLogger::attribute(const string & name, sal_uInt32 value)
+{
+ currentTag()->addAttr(name, value);
+}
- void TagLogger::endElement(const string & name)
- {
- string nameRemoved = currentTag()->getTag();
+void TagLogger::attribute(const string & name, const uno::Any aAny)
+{
+ currentTag()->addAttr(name, aAny);
+}
- if (name == nameRemoved)
- mTags.pop();
- else {
- XMLTag::Pointer_t pTag(new XMLTag("end.mismatch"));
- pTag->addAttr("name", name);
- pTag->addAttr("top", nameRemoved);
+void TagLogger::addTag(XMLTag::Pointer_t pTag)
+{
+ currentTag()->addTag(pTag);
+}
- currentTag()->addTag(pTag);
- }
+void TagLogger::chars(const string & rChars)
+{
+ currentTag()->chars(xmlify(rChars));
+}
- }
+void TagLogger::chars(const ::rtl::OUString & rChars)
+{
+ chars(OUStringToOString(rChars, RTL_TEXTENCODING_ASCII_US).getStr());
+}
- void TagLogger::endDocument()
- {
+void TagLogger::endElement(const string & name)
+{
+ string nameRemoved = currentTag()->getTag();
+
+ if (name == nameRemoved)
mTags.pop();
- }
+ else {
+ XMLTag::Pointer_t pTag(new XMLTag("end.mismatch"));
+ pTag->addAttr("name", name);
+ pTag->addAttr("top", nameRemoved);
- ostream & TagLogger::output(ostream & o) const
- {
- return mpRoot->output(o);
+ currentTag()->addTag(pTag);
}
- void TagLogger::dump(const char * name)
- {
- TagLoggerHashMap_t::iterator aIt(tagLoggers->find(name));
- if (aIt != tagLoggers->end())
- {
- string fileName;
- char * temp = getenv("TAGLOGGERTMP");
-
- if (temp != NULL)
- fileName += temp;
- else
- fileName += "/tmp";
-
- string sPrefix = aIt->second->mFileName;
- size_t nLastSlash = sPrefix.find_last_of('/');
- size_t nLastBackslash = sPrefix.find_last_of('\\');
- size_t nCutPos = nLastSlash;
- if (nLastBackslash < nCutPos)
- nCutPos = nLastBackslash;
- if (nCutPos < sPrefix.size())
- sPrefix = sPrefix.substr(nCutPos + 1);
-
- fileName += "/";
- fileName += sPrefix;
- fileName +=".";
- fileName += name;
- fileName += ".xml";
-
- ofstream dumpStream(fileName.c_str());
- aIt->second->output(dumpStream);
- }
- }
+}
- PropertySetToTagHandler::~PropertySetToTagHandler()
- {
+void TagLogger::endDocument()
+{
+ mTags.pop();
+}
+
+ostream & TagLogger::output(ostream & o) const
+{
+ return mpRoot->output(o);
+}
+
+void TagLogger::dump(const char * name)
+{
+ TagLoggerHashMap_t::iterator aIt(tagLoggers->find(name));
+ if (aIt != tagLoggers->end())
+ {
+ string fileName;
+ char * temp = getenv("TAGLOGGERTMP");
+
+ if (temp != NULL)
+ fileName += temp;
+ else
+ fileName += "/tmp";
+
+ string sPrefix = aIt->second->mFileName;
+ size_t nLastSlash = sPrefix.find_last_of('/');
+ size_t nLastBackslash = sPrefix.find_last_of('\\');
+ size_t nCutPos = nLastSlash;
+ if (nLastBackslash < nCutPos)
+ nCutPos = nLastBackslash;
+ if (nCutPos < sPrefix.size())
+ sPrefix = sPrefix.substr(nCutPos + 1);
+
+ fileName += "/";
+ fileName += sPrefix;
+ fileName +=".";
+ fileName += name;
+ fileName += ".xml";
+
+ ofstream dumpStream(fileName.c_str());
+ aIt->second->output(dumpStream);
}
+}
+
+PropertySetToTagHandler::PropertySetToTagHandler(IdToString::Pointer_t pIdToString)
+ : mpTag(new XMLTag("propertyset")), mpIdToString(pIdToString)
+{
+}
+
+PropertySetToTagHandler::~PropertySetToTagHandler()
+{
+}
- void PropertySetToTagHandler::resolve
- (XMLTag & rTag, writerfilter::Reference<Properties>::Pointer_t pProps)
+void PropertySetToTagHandler::resolve
+(XMLTag & rTag, writerfilter::Reference<Properties>::Pointer_t pProps)
+{
+ if (pProps.get() != NULL)
{
- if (pProps.get() != NULL)
- {
- PropertySetToTagHandler aHandler(mpIdToString);
- pProps->resolve(aHandler);
- rTag.addTag(aHandler.getTag());
- }
+ PropertySetToTagHandler aHandler(mpIdToString);
+ pProps->resolve(aHandler);
+ rTag.addTag(aHandler.getTag());
}
+}
- void PropertySetToTagHandler::attribute(Id name, Value & val)
- {
- XMLTag::Pointer_t pTag(new XMLTag("attribute"));
+void PropertySetToTagHandler::attribute(Id name, Value & val)
+{
+ XMLTag::Pointer_t pTag(new XMLTag("attribute"));
- pTag->addAttr("name", (*QNameToString::Instance())(name));
- pTag->addAttr("value", val.toString());
+ pTag->addAttr("name", (*QNameToString::Instance())(name));
+ pTag->addAttr("value", val.toString());
- resolve(*pTag, val.getProperties());
+ resolve(*pTag, val.getProperties());
- mpTag->addTag(pTag);
- }
+ mpTag->addTag(pTag);
+}
- void PropertySetToTagHandler::sprm(Sprm & rSprm)
- {
- XMLTag::Pointer_t pTag(new XMLTag("sprm"));
+void PropertySetToTagHandler::sprm(Sprm & rSprm)
+{
+ XMLTag::Pointer_t pTag(new XMLTag("sprm"));
- string sName;
+ string sName;
- if (mpIdToString != IdToString::Pointer_t())
- sName = mpIdToString->toString(rSprm.getId());
+ if (mpIdToString != IdToString::Pointer_t())
+ sName = mpIdToString->toString(rSprm.getId());
- pTag->addAttr("name", sName);
+ pTag->addAttr("name", sName);
- static char sBuffer[256];
- snprintf(sBuffer, sizeof(sBuffer),
- "0x%" SAL_PRIxUINT32 ", %" SAL_PRIuUINT32, rSprm.getId(),
- rSprm.getId());
- pTag->addAttr("id", sBuffer);
- pTag->addAttr("value", rSprm.getValue()->toString());
+ static char sBuffer[256];
+ snprintf(sBuffer, sizeof(sBuffer),
+ "0x%" SAL_PRIxUINT32 ", %" SAL_PRIuUINT32, rSprm.getId(),
+ rSprm.getId());
+ pTag->addAttr("id", sBuffer);
+ pTag->addAttr("value", rSprm.getValue()->toString());
- resolve(*pTag, rSprm.getProps());
+ resolve(*pTag, rSprm.getProps());
- mpTag->addTag(pTag);
- }
+ mpTag->addTag(pTag);
+}
XMLTag::Pointer_t unoPropertySetToTag(uno::Reference<beans::XPropertySet> rPropSet)
@@ -464,4 +487,3 @@ XMLTag::Pointer_t unoPropertySetToTag(uno::Reference<beans::XPropertySet> rPropS
}
}
-#endif // DEBUG
diff --git a/writerfilter/source/resourcemodel/XPathLogger.cxx b/writerfilter/source/resourcemodel/XPathLogger.cxx
new file mode 100644
index 000000000000..89255c8311f8
--- /dev/null
+++ b/writerfilter/source/resourcemodel/XPathLogger.cxx
@@ -0,0 +1,90 @@
+/*************************************************************************
+ *
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * Copyright 2000, 2010 Oracle and/or its affiliates.
+ *
+ * OpenOffice.org - a multi-platform office productivity suite
+ *
+ * This file is part of OpenOffice.org.
+ *
+ * OpenOffice.org is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License version 3
+ * only, as published by the Free Software Foundation.
+ *
+ * OpenOffice.org is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License version 3 for more details
+ * (a copy is included in the LICENSE file that accompanied this code).
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * version 3 along with OpenOffice.org. If not, see
+ * <http://www.openoffice.org/license.html>
+ * for a copy of the LGPLv3 License.
+ *
+ ************************************************************************/
+
+#include <stdio.h>
+#include <resourcemodel/XPathLogger.hxx>
+
+namespace writerfilter
+{
+XPathLogger::XPathLogger()
+: mp_tokenMap(new TokenMap_t)
+{
+}
+
+XPathLogger::~XPathLogger()
+{
+}
+
+string XPathLogger::getXPath() const
+{
+ return m_currentPath;
+}
+
+void XPathLogger::updateCurrentPath()
+{
+ m_currentPath = "";
+
+ for (vector<string>::const_iterator aIt = m_path.begin();
+ aIt != m_path.end();
+ aIt++)
+ {
+ if (m_currentPath.size() > 0)
+ m_currentPath += "/";
+
+ m_currentPath += *aIt;
+ }
+}
+
+void XPathLogger::startElement(string _token)
+{
+ TokenMap_t::const_iterator aIt = mp_tokenMap->find(_token);
+
+ if (aIt == mp_tokenMap->end())
+ (*mp_tokenMap)[_token] = 1;
+ else
+ (*mp_tokenMap)[_token]++;
+
+ static char sBuffer[256];
+ snprintf(sBuffer, sizeof(sBuffer), "[%d]", (*mp_tokenMap)[_token]);
+ m_path.push_back(_token + sBuffer);
+
+ m_tokenMapStack.push(mp_tokenMap);
+ mp_tokenMap.reset(new TokenMap_t);
+
+ updateCurrentPath();
+}
+
+void XPathLogger::endElement()
+{
+ mp_tokenMap = m_tokenMapStack.top();
+ m_tokenMapStack.pop();
+ m_path.pop_back();
+
+ updateCurrentPath();
+}
+
+}
diff --git a/writerfilter/source/resourcemodel/makefile.mk b/writerfilter/source/resourcemodel/makefile.mk
index 384cf8cfe38e..cf7941b3ed1c 100644
--- a/writerfilter/source/resourcemodel/makefile.mk
+++ b/writerfilter/source/resourcemodel/makefile.mk
@@ -49,14 +49,17 @@ NOOPTFILES= \
$(SLO)$/qnametostr.obj
SLOFILES= \
+ $(SLO)$/Fraction.obj \
+ $(SLO)$/LoggedResources.obj \
+ $(SLO)$/Protocol.obj \
+ $(SLO)$/ResourceModelHelper.obj \
+ $(SLO)$/TagLogger.obj \
+ $(SLO)$/WW8Analyzer.obj \
+ $(SLO)$/XPathLogger.obj \
$(SLO)$/qnametostr.obj \
- $(SLO)$/sprmcodetostr.obj \
$(SLO)$/resourcemodel.obj \
+ $(SLO)$/sprmcodetostr.obj \
$(SLO)$/util.obj \
- $(SLO)$/TagLogger.obj \
- $(SLO)$/ResourceModelHelper.obj \
- $(SLO)$/WW8Analyzer.obj \
- $(SLO)$/Protocol.obj
# linux 64 bit: compiler (gcc 4.2.3) fails with 'out of memory'
.IF "$(OUTPATH)"=="unxlngx6"