Method CorrectMathAfterCharacter
CorrectMathAfterCharacter(WordDocument, MathPosition)
Math AutoCorrect after a character typed in an equation (Phase 177, WQ-0158), as Word does it: when the character before the caret ends a control word (anything but a letter or a digit) and the word is one of Entries, the word becomes its symbol; a space that ended it goes with it, any other character stays. Letters and digits continue the word; an unknown word stays as typed.
public static EquationEdit CorrectMathAfterCharacter(this WordDocument document, MathPosition caret)
Parameters
documentWordDocumentThe document that holds the equation.
caretMathPositionJust after the character typed.
Returns
- EquationEdit
The edit (empty when there is nothing to correct); After is where the caret goes.
Exceptions
- ArgumentNullException
An argument is null.
- ArgumentException
The equation is not in
document.