Class OfficeMath
An equation (Office Math, ECMA-376 Part 1 §22.1): one m:oMath in a paragraph's
text (an inline equation), or one m:oMathPara (a display paragraph of one or more
equations, each on its own line).
public sealed class OfficeMath : Inline
- Inheritance
-
OfficeMath
- Inherited Members
- Extension Methods
Remarks
Content is the markup as it was read, and it is what a save writes: an
equation survives a round trip byte for byte. Equations is the model read
from it, which layout draws. Once an edit changes the model (Phase 166,
EquationEditingExtensions), or for an equation created here, IsEdited is true
and a save writes the model instead.
Constructors
- OfficeMath(UnknownXml, bool)
Initializes an equation.
- OfficeMath(bool)
Initializes a new equation (Phase 166): one empty slot, written from its model.
Fields
- MaxLinearTextLength
The longest linear text FromLinearText(string, bool) reads.
Properties
- Equations
Gets the equations: one for an inline equation, one per
m:oMathof a display paragraph. Each is the sequence of elements on its baseline.
- IsDisplay
Gets whether this is a display paragraph (
m:oMathPara).
- IsEdited
Gets whether a save writes the model (Equations) rather than Content: true for an equation created or changed by an edit (Phase 166); an undone edit sets it back.
- Justification
Gets or sets a display paragraph's justification (
m:oMathParaPr/m:jc), or null to use the document's default (DefaultJustification).
Methods
- Accept(DomVisitor)
Dispatches to the visitor method for this node's concrete type.
- CloneCore()
Creates the deep copy for Clone(). Implementations copy all owned state, deep-clone children and copy unknown-XML islands.
- FromLinearText(string, bool)
Builds a new equation from linear text (Phase 166): UnicodeMath as Word's Linear mode and ToLinearText() write it (
a/b,x^2,x_i,√(x+1),∑_(i=1)^n▒i,■(a&b@c&d)); one equation per line of a display paragraph. What it cannot read stays text.
- ToLinearText()
Gets the equation's linear text, as Word's equation editor shows it in Linear mode (UnicodeMath:
(a+b)/c,x^2, a sum as∑_(i=1)^n▒i), one line per equation of a display paragraph.