Kaydet (Commit) 969a760e authored tarafından Michael Stahl's avatar Michael Stahl

reportbuilder: tdf#92720: add loext namespace

... to allow export of paragraphs in shapes.

(regression from 6acc6c01)

Change-Id: I2c23e686a2cfcd997d3393b0f9fb4cdcab7252b7
üst 131ebdeb
......@@ -51,6 +51,7 @@ public class OfficeNamespaces
public static final String OOREPORT_NS = "http://openoffice.org/2005/report";
public static final String GRDDL_NS = "http://www.w3.org/2003/g/data-view#";
public static final String CONFIG = "urn:oasis:names:tc:opendocument:xmlns:config:1.0";
public static final String LOEXT_NS = "urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0";
private OfficeNamespaces()
......
......@@ -383,6 +383,7 @@ public abstract class OfficeDocumentReportTarget extends AbstractReportTarget
rootAttributes.addNamespaceDeclaration("xsd", OfficeNamespaces.XSD_NS);
rootAttributes.addNamespaceDeclaration("xsi", OfficeNamespaces.XSI_NS);
rootAttributes.addNamespaceDeclaration("grddl", OfficeNamespaces.GRDDL_NS);
rootAttributes.addNamespaceDeclaration("loext", OfficeNamespaces.LOEXT_NS);
rootAttributes.setAttribute(OfficeNamespaces.OFFICE_NS, "version",
ODF_VERSION);
......
......@@ -246,6 +246,13 @@ ORptExport::ORptExport(const Reference< XComponentContext >& _rxContext, OUStrin
if( getExportFlags() & (SvXMLExportFlags::STYLES|SvXMLExportFlags::AUTOSTYLES|SvXMLExportFlags::MASTERSTYLES|SvXMLExportFlags::CONTENT) )
{
_GetNamespaceMap().Add( GetXMLToken(XML_NP_XHTML),GetXMLToken(XML_N_XHTML), XML_NAMESPACE_XHTML );
// loext, needed for paragraphs inside shapes
if (getDefaultVersion() > SvtSaveOptions::ODFVER_012)
{
_GetNamespaceMap().Add(
GetXMLToken(XML_NP_LO_EXT), GetXMLToken(XML_N_LO_EXT),
XML_NAMESPACE_LO_EXT);
}
}
// GRDDL: to convert RDFa and meta.xml to RDF
if( getExportFlags() & (SvXMLExportFlags::META|SvXMLExportFlags::STYLES|SvXMLExportFlags::AUTOSTYLES|SvXMLExportFlags::MASTERSTYLES|SvXMLExportFlags::CONTENT) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment