element.type() == Element.TABLE) {
element.type() == Element.TABLE || element.type() == Element.GRAPHIC) {
    public void add(int index, Object o) {        try {            Element element = (Element) o;            if (element.type() == Element.CHUNK) {                Chunk chunk = (Chunk) element;                if (!font.isStandardFont()) {                    chunk.setFont(font.difference(chunk.font()));                }                super.add(index, chunk);            }            else if (element.type() == Element.PHRASE ||            element.type() == Element.ANCHOR ||            element.type() == Element.ANNOTATION ||            element.type() == Element.TABLE) { // line added by David Freels                super.add(index, element);            }            else {                throw new ClassCastException(String.valueOf(element.type()));            }        }        catch(ClassCastException cce) {            throw new ClassCastException("Insertion of illegal Element: " + cce.getMessage());        }    }