DocumentID: ECMA-376/Part1/11.3.1
Title: ECMA-376, Part1: 11.3.1 Alternative Format Import Part
Extracted-From: ECMA-376 Office Open XML File Formats, 1st Edition / December 2006
Warning: Coverted to HTML format by a script known to have bugs

Navigation:

11.3.1 Alternative Format Import Part

Content Type:

Any content, support for which is application-defined.

[Note: Some examples of formats which might be supported include:

  • Text = application/txt
  • RTF = application/rtf
  • HTML = application/html
  • XML = application/xml

end note]

Root Namespace:

not applicable

Source Relationship:

http://schemas.openxmlformats.org/officeDocument/2006/relationships/aFChunk

An alternative format import part allows content specified in an alternate format (HTML, MHTML, RTF, earlier versions of WordprocessingML, or plain text) to be embedded directly in a WordprocessingML document in order to allow that content to be migrated to the WordprocessingML format.

Any document part that permits a p element can also contain an altChunk element, whose id attribute refers to a relationship. That relationship shall target a part within the package, which contains the content to be imported into this WordprocessingML document.

A package is permitted to contain zero or more Alternative Format Import parts, each of which shall have a corresponding alternate format file that is the target of an explicit relationship from a Comments (§11.3.2), Endnotes (§11.3.4), Footer (§11.3.6), Footnotes (§11.3.7), Header (§11.3.9), or Main Document (§11.3.10) part. This relationship shall be explicitly referenced using its relationship ID in the source part using the appropriate XML syntax (i.e.; in the id attribute on the altChunk element), and the presence of this relationship without such a reference shall be considered invalid.

A WordprocessingML consumer shall treat the contents of such legacy text files as if they were formatted using equivalent WordprocessingML, and if that consumer is also a WordprocessingML producer, it shall emit the legacy text in WordprocessingML format.

This Standard does not specify how one might create a WordprocessingML package that contains Alternative Format Import relationships and altChunk elements.

However, a conforming producer shall not create a WordprocessingML package that contains Alternative Format Import relationships and elements. [Note: The Alternative Format Import machinery provides a one-time conversion facility. A producer could have an extension that allows it to generate a package containing these relationships and elements, yet when run in conforming mode, does not do so. end note]

[Example: The following Main Document part-relationship item contains a relationship to an Alternative Format Import part:

<Relationships xmlns="...">
  <Relationship Id="rId5" 
    Type="http://.../aFChunk" Target="Demo.html"
    TargetMode="Internal"/>
</Relationships>

The Main Document part contains the following XML fragment:

<w:body>
  ...
  <w:p/>
  <w:altChunk r:id="rId5"/>
  <w:p/>
  ...
</w:body>

which results in the entire contents of Demo.html being converted and brought into the document at that point (assuming that the content type of Demo.html is supported by the application consuming this WordprocessingML file). end example]

An Alternative Format Import part shall be located within the package containing the source relationship (expressed syntactically, the TargetMode attribute of the Relationship element shall be Internal).

An Alternative Format Import part shall not have any explicit or implicit relationships to parts defined by this Standard.


Converted to HTML format by ooxmlspec2html 0.1, a Perl script provided by OpenISO.org.