OfficeMathJustification

OfficeMathJustification enumeration

Anger motiveringen av ekvationen.

public enum OfficeMathJustification

Värderingar

namnVärdeBeskrivning
CenterGroup1Justerar instanser av matematisk text till vänster i förhållande till varandra och centrerar gruppen matematisk text (Matematisk stycke) med avseende på sidan.
Center2Centrerar varje instans av matematisk text individuellt med avseende på marginaler.
Left3Vänster motivering av Math Paragraph.
Right4Rätt motivering av matematisk paragraf.
Inline7Inline position för Math.
Default1StandardvärdeCenterGroup .

Exempel

Visar hur du ställer in kontorsmattevisningsformatering.

Document doc = new Document(MyDir + "Office math.docx");

OfficeMath officeMath = (OfficeMath) doc.GetChild(NodeType.OfficeMath, 0, true);

// OfficeMath-noder som är barn till andra OfficeMath-noder är alltid inline.
// Noden vi arbetar med är basnoden för att ändra dess plats och visningstyp.
Assert.AreEqual(MathObjectType.OMathPara, officeMath.MathObjectType);
Assert.AreEqual(NodeType.OfficeMath, officeMath.NodeType);
Assert.AreEqual(officeMath.ParentNode, officeMath.ParentParagraph);

// Ändra plats och visningstyp för OfficeMath-noden.
officeMath.DisplayType = OfficeMathDisplayType.Display;
officeMath.Justification = OfficeMathJustification.Left;

doc.Save(ArtifactsDir + "Shape.OfficeMath.docx");

Se även