org.scilab.forge.jlatexmath
Class AccentedAtom

java.lang.Object
  extended by org.scilab.forge.jlatexmath.Atom
      extended by org.scilab.forge.jlatexmath.AccentedAtom
All Implemented Interfaces:
java.lang.Cloneable

public class AccentedAtom
extends Atom

An atom representing another atom with an accent symbol above it.


Field Summary
protected  Atom base
           
protected  Atom underbase
           
 
Fields inherited from class org.scilab.forge.jlatexmath.Atom
type, type_limits
 
Constructor Summary
AccentedAtom(Atom base, Atom accent)
           
AccentedAtom(Atom base, java.lang.String accentName)
          Creates an AccentedAtom from a base atom and an accent symbol defined by its name
AccentedAtom(Atom base, TeXFormula acc)
          Creates an AccentedAtom from a base atom and an accent symbol defined as a TeXFormula.
 
Method Summary
 Box createBox(TeXEnvironment env)
          Convert this atom into a Box, using properties set by "parent" atoms, like the TeX style, the last used font, color settings, ...
 
Methods inherited from class org.scilab.forge.jlatexmath.Atom
clone, getLeftType, getRightType
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

base

protected Atom base

underbase

protected Atom underbase
Constructor Detail

AccentedAtom

public AccentedAtom(Atom base,
                    Atom accent)
             throws InvalidSymbolTypeException
Throws:
InvalidSymbolTypeException

AccentedAtom

public AccentedAtom(Atom base,
                    java.lang.String accentName)
             throws InvalidSymbolTypeException,
                    SymbolNotFoundException
Creates an AccentedAtom from a base atom and an accent symbol defined by its name

Parameters:
base - base atom
accentName - name of the accent symbol to be put over the base atom
Throws:
InvalidSymbolTypeException - if the symbol is not defined as an accent ('acc')
SymbolNotFoundException - if there's no symbol defined with the given name

AccentedAtom

public AccentedAtom(Atom base,
                    TeXFormula acc)
             throws InvalidTeXFormulaException,
                    InvalidSymbolTypeException
Creates an AccentedAtom from a base atom and an accent symbol defined as a TeXFormula. This is used for parsing MathML.

Parameters:
base - base atom
acc - TeXFormula representing an accent (SymbolAtom)
Throws:
InvalidTeXFormulaException - if the given TeXFormula does not represent a single SymbolAtom (type "TeXConstants.TYPE_ACCENT")
InvalidSymbolTypeException - if the symbol is not defined as an accent ('acc')
Method Detail

createBox

public Box createBox(TeXEnvironment env)
Description copied from class: Atom
Convert this atom into a Box, using properties set by "parent" atoms, like the TeX style, the last used font, color settings, ...

Specified by:
createBox in class Atom
Parameters:
env - the current environment settings
Returns:
the resulting box.