FitText.Id Property
Fit Text Run ID.Represents the attribte in schema: w:id
Namespace: DocumentFormat.OpenXml.Wordprocessing
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaration
<SchemaAttrAttribute(, "id")> _
Public Property Id As Int32Value
Get
Set
'Usage
Dim instance As FitText
Dim value As Int32Value
value = instance.Id
instance.Id = value
[SchemaAttrAttribute(, "id")]
public Int32Value Id { get; set; }
Property Value
Type: DocumentFormat.OpenXml.Int32Value
Returns Int32Value.
Remarks
The following information from the ECMA International Standard ECMA-376 can be useful when working with this class.
Specifies a unique ID which shall be used to link multiple contiguous runs containing fitText elements to each other to ensure that their contents are correctly merged into the specified width in the document.
This means that multiple runs which are broken apart due to differences in formatting can be identified as belonging to the same grouping in terms of fitText properties, although they are multiple runs of text in the WordprocessingML.
If the runs are not contiguous, then the id attribute is ignored, and the runs are not linked.
If this attribute is omitted, then this run has no id and shall not be linked with any other run in the parent paragraph.
Consider the following three runs in a document, which should be fit into exactly one inch at display time:
<w:r>
<w:rPr>
<w:fitText w:id="99" w:val="1440" />
</w:rPr>
<w:t>fit this into</w:t>
</w:r>
<w:r>
<w:rPr>
<w:b/>
<w:fitText w:id="99" w:val="1440" />
</w:rPr>
<w:t>one</w:t>
</w:r>
<w:r>
<w:rPr>
<w:fitText w:id="99" w:val="1440" />
</w:rPr>
<w:t>inch</w:t>
</w:r>
Although there are three runs of content, all three regions shall be combined into a single fit text region (e.g. they all fit into one inch, rather than one inch each) based on the identical value used in the id attribute for all three runs.
The possible values for this attribute are defined by the ST_DecimalNumber simple type.