OfficeMath module

class OfficeMath.OfficeMath

Bases: ParagraphBase, ICompositeObject

property ChildObjects: DocumentObjectCollection

Gets the child objects of the OfficeMath object. :return: The child objects.

property DocumentObjectType: DocumentObjectType

Gets the type of the document object. :return: The type of the document object.

static FromEqField(eqField: Field) OfficeMath

Creates an OfficeMath object from eqField.

FromLatexMathCode(latexMathCode: str)

Creates an OfficeMath object from LaTeX math code. :param latexMathCode: The LaTeX math code.

FromMathMLCode(mathMLCode: str)

Creates an OfficeMath object from MathML code. :param mathMLCode: The MathML code.

property ParentParagraph: Paragraph

Gets the parent paragraph. :return: The parent paragraph.

SaveImageToStream

Save the specified page as image return stream. The default is PNG format image.

Parameters:

type (ImageType) – The type.

Returns:

The stream.

Return type:

Stream

ToMathMLCode() str

Converts the OfficeMath object to MathML code. :return: The MathML code.

ToOfficeMathMLCode() str

Converts the OfficeMath object to OfficeMathML code. return: The OfficeMathML code.