2.4.8.2.7 CT_ShapeInfo

Referenced by: CT_Page

The CT_ShapeInfo complex type specifies information about a shape.

Child Elements:

ShapeDataItems : An optional CT_ShapeDataItems element. CT_ShapeDataItems element is not present if the shape is not associated with shape data items.

Hyperlinks : An optional CT_Hyperlinks element. CT_Hyperlinks element is not present if the shape is not associated with hyperlinks

Attributes:

Name :  An xsd:string ([XMLSCHEMA2] section 3.2.1) attribute that specifies the identifier of the shape. It MUST match exactly the Name of the XAML element that represents the shape as specified in the ShapeGraphic Part. It MUST NOT be an empty string and MUST be unique amongst all the identifiers specified by the Name attribute of the CT_ShapeInfo elements in this XML part.

DisplayName :  An xsd:string ([XMLSCHEMA2] section 3.2.1) attribute that specifies a display name for the shape.

Guid :  An optional xsd:string ([XMLSCHEMA2] section 3.2.1) attribute that specifies a GUID for the shape. If this attribute does not exist then the shape does not have a GUID.

Layout :  An xsd:string ([XMLSCHEMA2] section 3.2.1) attribute that specifies geometric information for the bounding rectangle of the shape. The structure of this information is specified in the following table:

Name

Description

type

A string that specifies the shape type. MUST be "2D" and specifies a bi-dimensional shape.

bounds

A structure that specifies the minimum bounding rectangle for the shape as specified in the following table:

Name

Description

x

An integer that specifies the upper left x-coordinate of the bounding rectangle.

y

An integer that specifies the upper left y-coordinate of the bounding rectangle.

width

A positive integer that specifies the width of the bounding rectangle.

height

A positive integer that specifies the height of the bounding rectangle.

The coordinates of the bounding rectangle MUST be relative to the top, left corner of the drawing page that contains the shape. All the values MUST be specified in pixels. The string MUST be formatted using the JavaScript Object Notation as specified in [RFC4627] as follows:

 {"type":"2D","bounds":{"x":x-val,"y":y-val,"width":width-val,"height":height-val}}

where x-val, y-val, width-val, and height-val are integers specifying the x, y, width and height fields, respectively.

The following W3C XML Schema ([XMLSCHEMA1] section 2.1) fragment specifies the contents of this complex type.

 <xsd:complexType name="CT_ShapeInfo">
   <xsd:sequence>
     <xsd:element name="ShapeDataItems" minOccurs="0" maxOccurs="1" type="CT_ShapeDataItems"/>
     <xsd:element name="Hyperlinks" minOccurs="0" maxOccurs="1" type="CT_Hyperlinks"/>
   </xsd:sequence>
   <xsd:attribute name="Name" type="xsd:string" use="required"/>
   <xsd:attribute name="DisplayName" type="xsd:string"/>
   <xsd:attribute name="Guid" type="xsd:string" use="optional"/>
   <xsd:attribute name="Layout" type="xsd:string" use="required"/>
 </xsd:complexType>