diff options
author | Sascha Ballach <sab@openoffice.org> | 2000-10-25 14:00:52 +0000 |
---|---|---|
committer | Sascha Ballach <sab@openoffice.org> | 2000-10-25 14:00:52 +0000 |
commit | 82e1e042ff92e75b82914ea09822ec4fa5b554d1 (patch) | |
tree | fe44f608e1ca1debb37cea54d07021dc0df684b6 /xmloff/source/style/impastp4.cxx | |
parent | b44cdcd334f7966cd7450b9d585608e0dde69778 (diff) |
Import/Export PageMaster with one Map and with a Start and End position
Diffstat (limited to 'xmloff/source/style/impastp4.cxx')
-rw-r--r-- | xmloff/source/style/impastp4.cxx | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/xmloff/source/style/impastp4.cxx b/xmloff/source/style/impastp4.cxx index d3b23890dc35..85260ebc4089 100644 --- a/xmloff/source/style/impastp4.cxx +++ b/xmloff/source/style/impastp4.cxx @@ -2,9 +2,9 @@ * * $RCSfile: impastp4.cxx,v $ * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * - * last change: $Author: dr $ $Date: 2000-10-18 11:37:23 $ + * last change: $Author: sab $ $Date: 2000-10-25 15:00:52 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -84,6 +84,12 @@ #ifndef _XMLOFF_XMLEXPPR_HXX #include "xmlexppr.hxx" #endif +#ifndef _XMLOFF_FAMILIES_HXX_ +#include "families.hxx" +#endif +#ifndef _XMLOFF_PAGEMASTERSTYLEMAP_HXX +#include "PageMasterStyleMap.hxx" +#endif using namespace ::std; using namespace ::rtl; @@ -348,9 +354,25 @@ void SvXMLAutoStylePoolP_Impl::exportXML( rHandler->ignorableWhitespace( msWS ); rHandler->startElement( sName, mxAttrList ); mpAttrList->Clear(); + sal_Int32 nStart(-1); + sal_Int32 nEnd(-1); + if (nFamily == XML_STYLE_FAMILY_PAGE_MASTER) + { + nStart = 0; + sal_Int32 nIndex = 0; + UniReference< XMLPropertySetMapper > aPropMapper = rPropExp.getPropertySetMapper(); + while(nIndex < aPropMapper->GetEntryCount() && nEnd == -1) + { + if (aPropMapper->GetEntryContextId( nIndex ) & CTF_PM_FLAGMASK) + nEnd = nIndex; + nIndex++; + } + if (nEnd == -1) + nEnd = nIndex; + } rPropExp.exportXML( rHandler, aExpStyles[i].mpProperties->GetProperties(), rUnitConverter, - rNamespaceMap, XML_EXPORT_FLAG_IGN_WS ); + rNamespaceMap, nStart, nEnd, XML_EXPORT_FLAG_IGN_WS ); pAntiImpl->exportStyleContent( rHandler, nFamily, aExpStyles[i].mpProperties->GetProperties(), |