Package org.apache.poi.sl.draw
Class DrawShape
- java.lang.Object
-
- org.apache.poi.sl.draw.DrawShape
-
- All Implemented Interfaces:
Drawable
- Direct Known Subclasses:
DrawBackground,DrawGraphicalFrame,DrawGroupShape,DrawSimpleShape,DrawTableShape
public class DrawShape extends Object implements Drawable
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.poi.sl.draw.Drawable
Drawable.DrawableHint
-
-
Field Summary
Fields Modifier and Type Field Description protected Shape<?,?>shape-
Fields inherited from interface org.apache.poi.sl.draw.Drawable
BUFFERED_IMAGE, CACHE_IMAGE_SOURCE, CURRENT_SLIDE, DEFAULT_CHARSET, DRAW_FACTORY, EMF_FORCE_HEADER_BOUNDS, FONT_FALLBACK, FONT_HANDLER, FONT_MAP, GRADIENT_SHAPE, GRESTORE, GROUP_TRANSFORM, GSAVE, IMAGE_RENDERER, PRESET_GEOMETRY_CACHE, TEXT_AS_CHARACTERS, TEXT_AS_SHAPES, TEXT_RENDERING_MODE
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapplyTransform(Graphics2D graphics)Apply 2-D transforms before drawing this shape.voiddraw(Graphics2D graphics)Draw this shape into the supplied canvasvoiddrawContent(Graphics2D graphics)draw any content within this shape (image, text, etc.).static Rectangle2DgetAnchor(Graphics2D graphics, Rectangle2D anchor)static Rectangle2DgetAnchor(Graphics2D graphics, PlaceableShape<?,?> shape)protected Shape<?,?>getShape()protected static BasicStrokegetStroke(StrokeStyle strokeStyle)
-
-
-
Field Detail
-
shape
protected final Shape<?,?> shape
-
-
Constructor Detail
-
DrawShape
public DrawShape(Shape<?,?> shape)
-
-
Method Detail
-
applyTransform
public void applyTransform(Graphics2D graphics)
Apply 2-D transforms before drawing this shape. This includes rotation and flipping.- Specified by:
applyTransformin interfaceDrawable- Parameters:
graphics- the graphics whose transform matrix will be modified
-
draw
public void draw(Graphics2D graphics)
Description copied from interface:DrawableDraw this shape into the supplied canvas
-
drawContent
public void drawContent(Graphics2D graphics)
Description copied from interface:Drawabledraw any content within this shape (image, text, etc.).- Specified by:
drawContentin interfaceDrawable- Parameters:
graphics- the graphics to draw into
-
getAnchor
public static Rectangle2D getAnchor(Graphics2D graphics, PlaceableShape<?,?> shape)
-
getAnchor
public static Rectangle2D getAnchor(Graphics2D graphics, Rectangle2D anchor)
-
getShape
protected Shape<?,?> getShape()
-
getStroke
protected static BasicStroke getStroke(StrokeStyle strokeStyle)
-
-