OpenXML Filter: perform the minification of directly specified run properties
It is possible to perform the minification of run properties.
1. A directly specified property is already available in the styles hierarchy of a current run. E.g.: if <w:b/> is a directly specified property in the following run
<w:r>
<w:rPr>
<w:rStyle w:val="DefaultParagraphFont"/>
<w:b/>
</w:rPr>
<w:t>Run1</w:t>
</w:r>
with a style
<w:style w:type="character" w:default="1" w:styleId="DefaultParagraphFont">
<w:name w:val="Default Paragraph Font"/>
<w:rPr>
<w:b/>
</w:rPr>
</w:style>
then the minified run properties for this run can be just
<w:rPr>
<w:rStyle w:val="DefaultParagraphFont"/>
</w:rPr>
2. A directly specified property has a clearing-formatting value (false, off, none, nil etc.) and it is not available in the styles hierarchy of a current run. E.g.: if <w:b w:val="false"/> is a directly specified property in the following run
<w:r>
<w:rPr>
<w:rStyle w:val="DefaultParagraphFont"/>
<w:b w:val="false"/>
</w:rPr>
<w:t>Run1</w:t>
</w:r>
with a style
<w:style w:type="character" w:default="1" w:styleId="DefaultParagraphFont">
<w:name w:val="Default Paragraph Font"/>
<w:rPr>
<w:i/>
</w:rPr>
</w:style>
then the minified run properties for this run can be just
<w:rPr>
<w:rStyle w:val="DefaultParagraphFont"/>
</w:rPr>
For more details please refer to the attached sample document with the following UI:
