Поделиться через


UseWord97LineBreakRules Class

Emulate Word 97 East Asian Line Breaking.When the object is serialized out as xml, its qualified name is w:useWord97LineBreakRules.

Inheritance Hierarchy

System.Object
  DocumentFormat.OpenXml.OpenXmlElement
    DocumentFormat.OpenXml.OpenXmlLeafElement
      DocumentFormat.OpenXml.Wordprocessing.OnOffType
        DocumentFormat.OpenXml.Wordprocessing.UseWord97LineBreakRules

Namespace:  DocumentFormat.OpenXml.Wordprocessing
Assembly:  DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)

Syntax

'Declaration
Public Class UseWord97LineBreakRules _
    Inherits OnOffType
'Usage
Dim instance As UseWord97LineBreakRules
public class UseWord97LineBreakRules : OnOffType

Remarks

[ISO/IEC 29500-1 1st Edition]

9.7.3.55 useWord97LineBreakRules (Use Incorrect Inter-Character Spacing Rules)

This element specifies that applications should perform specific calculations (detailed below) when determining inter-character spacing under certain conditions. These calculations would not normally be considered correct.

Typically, the behaviors specified by the following elements are applied unconditionally:

  • The autoSpaceDE (Part 1, §17.3.1.2) and autoSpaceDN (Part 1, §17.3.1.3) elements

  • The topLinePunct (Part 1, §17.3.1.43) element

The compatibility element described in this subclause, when present with a val attribute value of true (or equivalent), specifies that applications should ignore the settings listed above in the following scenarios:

If an ideographic character and a non-ideographic/numeric character are logically adjacent (ignoring all content which is not within a t element), but separated by a field boundary, i.e.:

The first character is within a fldSimple element, but the second is not.

The characters are separated by a fldChar element with a fldCharType attribute value of end

Then any appropriate inter-character spacing should be omitted. [Note: Inter-character spacing should still be calculated correctly within the field result. end note]

If a full-width punctuation character appears at the start of a paragraph which also specifies numbering via the numPr element (Part 1, §17.3.1.19), the compression specified by the topLinePunct element is ignored.

[Example: Consider a paragraph which contains a field ending in an ideograph and another paragraph, with numbering, which contains a full-width punctuation character in the first character position:

<w:p>
  <w:r>
    <w:fldChar w:fldCharType="begin" />
</w:r>
…
  <w:r>
    <w:t>日</w:t>
  </w:r>
  <w:r>
    <w:fldChar w:fldCharType="end" />
  </w:r>
<w:r>
    <w:t>1</w:t>
  </w:r>
</w:p>
<w:p>
  <w:pPr>
    <w:numPr>
      …
    </w:numPr>
  </w:pPr>
  <w:r>
    <w:t>(</w:t>
  </w:r>
</w:p>

Typically, if both the autoSpaceDN and topLinePunct are true, additional spacing is added after the ideograph in the first paragraph and punctuation kerning is applied in the second paragraph (with gridlines added for visual reference):

DocumentFormat.OpenXml.Wordprocessing.UseWord97Lin

If this compatibility setting is turned on:

<w:compat>
<w:useWord97LineBreakRules />
</w:compat>

Then applications should not add any inter-character spacing at th end of the field and should turn off punctuation kerning in the second paragraph:

DocumentFormat.OpenXml.Wordprocessing.UseWord97Lin

end example]

Parent Elements

compat (Part 1, §17.15.1.21)

This element’s content model is defined by the common boolean property definition in Part 1, §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.

See Also

Reference

UseWord97LineBreakRules Members

DocumentFormat.OpenXml.Wordprocessing Namespace