From 02990cfee364ae9fdf106f815a4772d438928a8c Mon Sep 17 00:00:00 2001 From: Keiron Liddle Date: Wed, 13 Jun 2001 16:06:21 +0000 Subject: [PATCH] prevents class cast exceptions when these methods are called not relevent for these objects git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194288 13f79535-47bb-0310-9956-ffa450edef68 --- src/org/apache/fop/svg/SVGObj.java | 30 +++++++++++++++++++++++++++--- 1 file changed, 27 insertions(+), 3 deletions(-) diff --git a/src/org/apache/fop/svg/SVGObj.java b/src/org/apache/fop/svg/SVGObj.java index 8f8384449..ca518e2ae 100644 --- a/src/org/apache/fop/svg/SVGObj.java +++ b/src/org/apache/fop/svg/SVGObj.java @@ -1,7 +1,7 @@ /* $Id$ * Copyright (C) 2001 The Apache Software Foundation. All rights reserved. * For details on use and redistribution please refer to the - * LICENSE file included with these sources." + * LICENSE file included with these sources. */ package org.apache.fop.svg; @@ -11,6 +11,7 @@ import org.apache.fop.fo.*; import org.apache.fop.layout.Area; import org.apache.fop.layout.FontState; import org.apache.fop.apps.FOPException; +import org.apache.fop.layout.LinkSet; import org.apache.batik.dom.svg.*; @@ -52,11 +53,9 @@ public abstract class SVGObj extends FObj { } else { String pref = props[count].substring(0, props[count].indexOf(":")); - System.out.println(pref); if (pref.equals("xmlns")) { ns.put(props[count].substring( props[count].indexOf(":") + 1), rf); - System.out.println(ns); } ns.put("xlink", "http://www.w3.org/1999/xlink"); element.setAttributeNS((String) ns.get(pref), @@ -91,5 +90,30 @@ public abstract class SVGObj extends FObj { /* return status */ return new Status(Status.OK); } + + /** + * These method overrides prevent problems with the different types. + */ + public void setIsInTableCell() { + } + + public void forceStartOffset(int offset) { + } + + public void forceWidth(int width) { + } + + public void resetMarker() { + } + + public void setLinkSet(LinkSet linkSet) { + } + + public Vector getMarkerSnapshot(Vector snapshot) { + return snapshot; + } + + public void rollback(Vector snapshot) { + } } -- 2.39.5