MatchSource Class
Keep Source Formatting on Import.When the object is serialized out as xml, its qualified name is w:matchSrc.
Inheritance Hierarchy
System.Object
DocumentFormat.OpenXml.OpenXmlElement
DocumentFormat.OpenXml.OpenXmlLeafElement
DocumentFormat.OpenXml.Wordprocessing.OnOffType
DocumentFormat.OpenXml.Wordprocessing.MatchSource
Namespace: DocumentFormat.OpenXml.Wordprocessing
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
Syntax
'Declaration
Public Class MatchSource _
Inherits OnOffType
'Usage
Dim instance As MatchSource
public class MatchSource : OnOffType
Remarks
[ISO/IEC 29500-1 1st Edition]
17.17.2.3 matchSrc (Keep Source Formatting on Import)
This element specifies if any style definitions present in the imported content shall be overridden by identical styles present in the host WordprocessingML document. If this element's val attribute is true, then any style exists in both the imported content and main document shall be maintained on the imported content by redefining the style name and/or ID as needed. Conversely, if this element's val attribute is false, any style which exists in both the imported content and main document shall apply the style form the main document in place of the style in the imported content.
If this element is omitted, then styles from the main document shall override identical styles from the imported content.
[Example: Consider a WordprocessingML document consisting of contents which contains an external content import anchor in the appropriate location:
<w:body> <w:altChunk r:id="altChunk1"> <w:altChunkPr> <w:matchSrc w:val="true" /> </w:altChunkPr> </w:altChunk> <w:p/> <w:sectPr> … </w:sectPr> </w:body>
The matchSrc element has a val attribute value of true, which specifies that conflicting styles must be maintained when importing the specified content. For example, if the Heading 1 style was defined in both places, then applications must ensure that the resulting document does not lose either instance of its formatting as appropriate. end example]
Parent Elements |
---|
altChunkPr (§17.17.2.2) |
This element’s content model is defined by the common boolean property definition in §17.17.4.
© ISO/IEC29500: 2008.
Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.