Browse Source

Renamed GenericGraphics2DImagePainter to a slightly more meaningful name of BatikGraphics2DImagePainter.


git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AFPGOCAResources@708877 13f79535-47bb-0310-9956-ffa450edef68
tags/fop-1_0
Adrian Cumiskey 15 years ago
parent
commit
6ba537ec89

src/java/org/apache/fop/image/loader/batik/GenericGraphics2DImagePainter.java → src/java/org/apache/fop/image/loader/batik/BatikGraphics2DImagePainter.java View File

@@ -12,7 +12,7 @@ import org.apache.xmlgraphics.java2d.Graphics2DImagePainter;
/**
* A generic graphics 2D image painter implementation
*/
public class GenericGraphics2DImagePainter implements Graphics2DImagePainter {
public class BatikGraphics2DImagePainter implements Graphics2DImagePainter {

protected final ImageXMLDOM svg;
protected final BridgeContext ctx;
@@ -25,7 +25,7 @@ public class GenericGraphics2DImagePainter implements Graphics2DImagePainter {
* @param ctx the bridge context
* @param root the graphics node root
*/
public GenericGraphics2DImagePainter(ImageXMLDOM svg, BridgeContext ctx, GraphicsNode root) {
public BatikGraphics2DImagePainter(ImageXMLDOM svg, BridgeContext ctx, GraphicsNode root) {
this.svg = svg;
this.ctx = ctx;
this.root = root;

+ 1
- 1
src/java/org/apache/fop/image/loader/batik/ImageConverterSVG2G2D.java View File

@@ -116,7 +116,7 @@ public class ImageConverterSVG2G2D extends AbstractImageConverter {
*/
protected Graphics2DImagePainter createPainter(
final ImageXMLDOM svg, final BridgeContext ctx, final GraphicsNode root) {
return new GenericGraphics2DImagePainter(svg, ctx, root);
return new BatikGraphics2DImagePainter(svg, ctx, root);
}

/** {@inheritDoc} */

+ 5
- 5
src/java/org/apache/fop/render/afp/AFPImageGraphics2DFactory.java View File

@@ -36,7 +36,7 @@ import org.apache.fop.afp.AFPState;
import org.apache.fop.afp.AFPTextElementBridge;
import org.apache.fop.afp.AFPTextHandler;
import org.apache.fop.afp.AFPTextPainter;
import org.apache.fop.image.loader.batik.GenericGraphics2DImagePainter;
import org.apache.fop.image.loader.batik.BatikGraphics2DImagePainter;
import org.apache.fop.render.RendererContext;
import org.apache.fop.svg.SVGUserAgent;
import org.apache.xmlgraphics.image.loader.impl.ImageGraphics2D;
@@ -117,8 +117,8 @@ public class AFPImageGraphics2DFactory extends AFPDataObjectInfoFactory {

// set painter
ImageGraphics2D imageG2D = (ImageGraphics2D)rendererImageInfo.getImage();
GenericGraphics2DImagePainter painter
= (GenericGraphics2DImagePainter)imageG2D.getGraphics2DImagePainter();
BatikGraphics2DImagePainter painter
= (BatikGraphics2DImagePainter)imageG2D.getGraphics2DImagePainter();
painter = new AFPGraphics2DImagePainter(painter);
imageG2D.setGraphics2DImagePainter(painter);
graphicsObjectInfo.setPainter(painter);
@@ -131,13 +131,13 @@ public class AFPImageGraphics2DFactory extends AFPDataObjectInfoFactory {
return graphicsObjectInfo;
}

private class AFPGraphics2DImagePainter extends GenericGraphics2DImagePainter {
private class AFPGraphics2DImagePainter extends BatikGraphics2DImagePainter {
/**
* Copy constructor
*
* @param painter a graphics 2D image painter
*/
public AFPGraphics2DImagePainter(GenericGraphics2DImagePainter painter) {
public AFPGraphics2DImagePainter(BatikGraphics2DImagePainter painter) {
super(painter.getImageXMLDOM(), painter.getBridgeContext(), painter.getRoot());
}


Loading…
Cancel
Save