12.3.20 Styles Part

Content Type:

application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml

Root Namespace:

http://purl.oclc.org/ooxml/spreadsheetml/main

Source Relationship:

http://purl.oclc.org/ooxml/officeDocument/relationships/styles

An instance of this part type contains all the characteristics for all the cells in the workbook. Such information includes numeric and text formatting, alignment, font, color, and border.

A package shall contain no more than one Styles part, and that part shall be the target of an implicit relationship from the Workbook (12.3.23) part.

[Example: The following Workbook part-relationship item contains a relationship to the Styles part, which is stored in the ZIP item styles.xml:

<Relationships xmlns="…">
  <Relationship Id="rId5"
    Type="http://…/styles" Target="styles.xml"/>
</Relationships>

end example]

The root element for a part of this content type shall be styleSheet.

[Example:

<styleSheet xmlns="…">
  <numFmts count="5">
    <numFmt numFmtId="164" formatCode="&quot;$&quot;#,##0.00"/>
    <numFmt numFmtId="165"
      formatCode="&quot;Yes&quot;;&quot;Yes&quot;;&quot;No&quot;"/>
    <numFmt numFmtId="166"
      formatCode="&quot;True&quot;;&quot;True&quot;;&quot;False&quot;"/>
    <numFmt numFmtId="167"
      formatCode="&quot;On&quot;;&quot;On&quot;;&quot;Off&quot;"/>
    <numFmt numFmtId="168"
      formatCode="[$€-2]\ #,##0.00_);[Red]\([$€-2]\ #,##0.00\)"/>
  </numFmts>
  <fonts count="5">
  </fonts>
  <fills count="4">
  </fills>
  <borders count="1">
  </borders>
  <colors>
  </colors>
</styleSheet>

end example]

A Styles part shall be located within the package containing the relationships part (expressed syntactically, the TargetMode attribute of the Relationship element shall be Internal).

A Styles part shall not have implicit or explicit relationships to any other part defined by ISO/IEC 29500.

Last updated on