MathML Support in Figue

* Figue's main page

* Mathematical Formula Layout in Figue

See the related paper .

* Download Figue version supporting MathML2.0

See the Copyright Notices.

Last version available as a single jar file figue.jar

Source of Figue classes figue.tar.gz

Remember the requirements:

  • you need to have a least JDK1.2 installed properly on your machine
  • you need also to load the XML parser (Xerces Java Parser 1.0.3 xerces.jar)

* How to use Figue to display MathML presentation ?

  • Input : MathML File or MathML String
  • parse the MathML input and give a corresponding MathML Document
  • process and gernerate Figue Facade from the MathML Document

Figue module for importing and processing the MathML

* Example of MathML display by using Figue (Step by Step)

* The Whole Program

Import the usual figue packages.
import figue.*;
import figue.resource.*;
Import the xerces java parser packag
import org.apache.xerces.parsers.DOMParser;
import org.xml.sax.SAXException; 
import org.w3c.dom.Document; 
Import the java package
import java.awt.*;
import java.awt.event.*;
import java.util.*;
import java.lang.reflect.*;
Create a xerces java parser
          try {
            parser = new org.apache.xerces.parsers.DOMParser();
            // specifying validation
            boolean validate = true;
            parser.setFeature("", validate);
            boolean nameSpaceProcessing = true;
            parser.setFeature("", nameSpaceProcessing);         
        catch (SAXException  e ) {
Create a Figue facade and init the resources for it (font, color ...)
        _facade = new AWTFacade();
Get the edited MathML text and parse it afterwards. We have a three different forms of input data of
String text = textArea.getText();
try {
catch (SAXException  e) {
catch (IOException e) {
Build a FIGUE facade from MathML Element
Utility.buildFacade( _facade, doc.getDocumentElement(),"MathML"); 

Display a facade

*My home page