Documentation

  • Demos
  • Visit our website
  • Contact us
  • MathType

    • Wiris Quizzes

      • Learning Lemur

        • CalcMe

          • MathPlayer

            • Store FAQ

              • VPAT for the electronic documentation

                • MathFlow

                  • BF FAQ

                    • Home
                    • MathFlow
                    • MathFlow SDK for Developers
                    • Editing (Java only)
                    • Applications
                    • Applications

                    Communicating with the MathFlow editors

                    Reading time: 1min

                    {{htmlmetatags> metatag-keywords=(mathflow, xml editor, sdk, mathml, equation, wiris, math, maths, documentation, advanced user-guide) metatag-description=(Learn how to use MathFlow SDK to customize the MathFlow editor in an XML environment.) }}

                    ====== Communicating with the MathFlow editors ======

                    ===== MathML =====

                    Use the following Javascript methods when working with MathML:

                    ^Javascript MethodDescription |string getFormattedMathML(int markupType, int formatLevel, boolean [[http://www.w3.org/TR/MathML/chapter2.html#interf.namespace|namespaceAttr]], string [[http://www.w3.org/TR/MathML2/appendixa.html#parsing.dtd.prefix|namespacePrefix]], int characterType)|Returns the MathML for the current equation with the specified format. Specific values for the parameters are as follows:

                    markupType 0 Mixed content/presentation markup 1 Presentation markup format 2 Content markup format (if possible) 3 Normalized presentation format (extra mrows removed)

                    formatLevel 0 Pretty printed (on multiple lines and indented to make reading easier) 1 Packed (all on one line, no indenting or extra spaces) 2 Packed and escaped (all on one line, all <>& shown as escaped characters) 3 Packed and wrapped (no extra white space, but returns added at nearest tag at 80 columns)

                    [[http://www.w3.org/TR/MathML/chapter2.html#interf.namespace|namespaceAttr]] States whether or not a namespace prefix should be added to each tag.

                    [[http://www.w3.org/TR/MathML2/appendixa.html#parsing.dtd.prefix|namespacePrefix]] Used with namespaceAttr. Prepends every tag with this namespace.

                    characterType 0 Special characters are shown as entity names if possible. 1 Special characters are shown in the format &#xXXXX; where X is a hexadecimal value. 2 Special characters are shown in UTF-8 format. This is the binary representation of the characters and may look strange in many text-processing programs.| |void setMathML(String new_mml)|Sets the MathML source for the current equation.| ===== Options file =====

                    The SDK editor components allow you to pass an optional OptionsInfo object as a parameter to their constructor. The “’OptionsInfo”’ class allows you to create, save and read options to a file. This allows the application to retain user settings.

                    <a><button>Previous: Applications</button></a><a><button>Next: Simple Editor application</button></a>

                    Was this article helpful?

                    Yes
                    No
                    Give feedback about this article

                    Related Articles

                    • WirisQuizzes in your assessment system
                    • MathFlow toolbar definition language
                    • Structure Editor
                    • Structure Editor application

                    Making people’s STEM work more meaningful

                    MathType

                    • MathType for Office Tools
                    • MathType for Mac
                    • MathType for Microsoft 365
                    • MathType for Google Workspace
                    • MathType for LMS
                    • MathType for XML Editors
                    • Arabic notation
                    • Our products accessibility
                    • MathType is online

                    WirisQuizzes

                    Learning Lemur

                    Solutions for Education

                    • Blackboard Learn
                    • Brightspace by D2L
                    • Canvas
                    • Google Classroom
                    • Moodle
                    • Schoology

                    Solutions for Publishing Houses

                    Solutions for Technical Writers

                    Solutions for Chemistry

                    Integrations

                    • HTML Editors
                    • MathType in WordPress

                    Pricing

                    Company

                    Careers

                    Blog

                    Contact Us

                    Buy Now

                    Plugin Downloads

                    © Wiris 2025

                    • Cookie Preferences
                    • Cookie Policy
                    • Terms of Use
                    • Privacy Policy / GDPR
                    • Student Data Privacy
                    • Compliance
                    • Powered by Helpjuice
                    Expand