org.apache.poi.hslf.model
Class Polygon

java.lang.Object
  extended by org.apache.poi.hslf.model.Shape
      extended by org.apache.poi.hslf.model.SimpleShape
          extended by org.apache.poi.hslf.model.TextShape
              extended by org.apache.poi.hslf.model.AutoShape
                  extended by org.apache.poi.hslf.model.Polygon

public final class Polygon
extends AutoShape

A simple closed polygon shape

Author:
Yegor Kozlov

Field Summary
 
Fields inherited from class org.apache.poi.hslf.model.TextShape
AlignCenter, AlignJustify, AlignLeft, AlignRight, AnchorBottom, AnchorBottomBaseline, AnchorBottomCentered, AnchorBottomCenteredBaseline, AnchorMiddle, AnchorMiddleCentered, AnchorTop, AnchorTopBaseline, AnchorTopCentered, AnchorTopCenteredBaseline, WrapByPoints, WrapNone, WrapSquare, WrapThrough, WrapTopBottom
 
Fields inherited from class org.apache.poi.hslf.model.SimpleShape
DEFAULT_LINE_WIDTH
 
Fields inherited from class org.apache.poi.hslf.model.Shape
EMU_PER_CENTIMETER, EMU_PER_INCH, EMU_PER_POINT, MASTER_DPI, PIXEL_DPI, POINT_DPI
 
Constructor Summary
Polygon()
          Create a new Polygon.
Polygon(Shape parent)
          Create a new Polygon.
 
Method Summary
 void setPoints(float[] xPoints, float[] yPoints)
          Set the polygon vertices
 void setPoints(java.awt.geom.Point2D[] points)
          Set the polygon vertices
 
Methods inherited from class org.apache.poi.hslf.model.AutoShape
getAdjustmentValue, getOutline, setAdjustmentValue
 
Methods inherited from class org.apache.poi.hslf.model.TextShape
createTextRun, draw, getHorizontalAlignment, getMarginBottom, getMarginLeft, getMarginRight, getMarginTop, getPlaceholderAtom, getText, getTextId, getTextRun, getVerticalAlignment, getWordWrap, resizeToFitText, setHorizontalAlignment, setHyperlink, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setSheet, setText, setTextId, setVerticalAlignment, setWordWrap
 
Methods inherited from class org.apache.poi.hslf.model.SimpleShape
getFillColor, getFlipHorizontal, getFlipVertical, getLineColor, getLineDashing, getLineStyle, getLineWidth, getLogicalAnchor2D, getRotation, setFillColor, setHyperlink, setLineColor, setLineDashing, setLineStyle, setLineWidth, setRotation
 
Methods inherited from class org.apache.poi.hslf.model.Shape
getAnchor, getAnchor2D, getEscherChild, getEscherProperty, getEscherProperty, getEscherProperty, getFill, getHyperlink, getParent, getShapeId, getShapeName, getShapeType, getSheet, getSpContainer, moveTo, setAnchor, setEscherProperty, setEscherProperty, setShapeId, setShapeType
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Polygon

public Polygon(Shape parent)
Create a new Polygon. This constructor is used when a new shape is created.

Parameters:
parent - the parent of this Shape. For example, if this text box is a cell in a table then the parent is Table.

Polygon

public Polygon()
Create a new Polygon. This constructor is used when a new shape is created.

Method Detail

setPoints

public void setPoints(float[] xPoints,
                      float[] yPoints)
Set the polygon vertices

Parameters:
xPoints -
yPoints -

setPoints

public void setPoints(java.awt.geom.Point2D[] points)
Set the polygon vertices

Parameters:
points - the polygon vertices