Package de.rototor.pdfbox.graphics2d
Class PdfBoxGraphics2DDrawControlDefault
- java.lang.Object
-
- de.rototor.pdfbox.graphics2d.PdfBoxGraphics2DDrawControlDefault
-
- All Implemented Interfaces:
IPdfBoxGraphics2DDrawControl
public class PdfBoxGraphics2DDrawControlDefault extends java.lang.Object implements IPdfBoxGraphics2DDrawControl
Default implementation which does nothing. You can derive from it to only override the needed methods
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface de.rototor.pdfbox.graphics2d.IPdfBoxGraphics2DDrawControl
IPdfBoxGraphics2DDrawControl.IDrawControlEnv
-
-
Field Summary
Fields Modifier and Type Field Description static PdfBoxGraphics2DDrawControlDefaultINSTANCE
-
Constructor Summary
Constructors Modifier Constructor Description protectedPdfBoxGraphics2DDrawControlDefault()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidafterShapeDraw(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Called after shape was drawn.voidafterShapeFill(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Called after shape was filled.java.awt.ShapetransformShapeBeforeDraw(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)You may optional change the shape that is going to be drawn.java.awt.ShapetransformShapeBeforeFill(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)You may optional change the shape that is going to be filled.
-
-
-
Field Detail
-
INSTANCE
public static final PdfBoxGraphics2DDrawControlDefault INSTANCE
-
-
Method Detail
-
transformShapeBeforeFill
public java.awt.Shape transformShapeBeforeFill(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Description copied from interface:IPdfBoxGraphics2DDrawControlYou may optional change the shape that is going to be filled. You can also do other stuff here like drawing an overfill before the real shape.- Specified by:
transformShapeBeforeFillin interfaceIPdfBoxGraphics2DDrawControl- Parameters:
shape- the shape that will be drawnenv- Environment- Returns:
- the shape to be filled. If you return null, nothing will be filled
-
transformShapeBeforeDraw
public java.awt.Shape transformShapeBeforeDraw(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Description copied from interface:IPdfBoxGraphics2DDrawControlYou may optional change the shape that is going to be drawn. You can also do other stuff here like drawing an overfill before the real shape.- Specified by:
transformShapeBeforeDrawin interfaceIPdfBoxGraphics2DDrawControl- Parameters:
shape- the shape that will be drawnenv- Environment- Returns:
- the shape to be filled. If you return null, nothing will be drawn
-
afterShapeFill
public void afterShapeFill(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Description copied from interface:IPdfBoxGraphics2DDrawControlCalled after shape was filled. This method is always called, even ifIPdfBoxGraphics2DDrawControl.transformShapeBeforeFill(java.awt.Shape, IDrawControlEnv)returns null.- Specified by:
afterShapeFillin interfaceIPdfBoxGraphics2DDrawControl- Parameters:
shape- the shape that was filled. This is the original shape, not the one transformed byIPdfBoxGraphics2DDrawControl.transformShapeBeforeFill(java.awt.Shape, IDrawControlEnv).env- Environment
-
afterShapeDraw
public void afterShapeDraw(java.awt.Shape shape, IPdfBoxGraphics2DDrawControl.IDrawControlEnv env)Description copied from interface:IPdfBoxGraphics2DDrawControlCalled after shape was drawn. This method is always called, even ifIPdfBoxGraphics2DDrawControl.transformShapeBeforeDraw(java.awt.Shape, IDrawControlEnv)returns null.- Specified by:
afterShapeDrawin interfaceIPdfBoxGraphics2DDrawControl- Parameters:
shape- the shape that was drawn. This is the original shape, not the one transformed byIPdfBoxGraphics2DDrawControl.transformShapeBeforeDraw(java.awt.Shape, IDrawControlEnv).env- Environment
-
-