org.apache.poi.hslf.usermodel
Class HSLFAutoShape
java.lang.Object
org.apache.poi.hslf.usermodel.HSLFShape
org.apache.poi.hslf.usermodel.HSLFSimpleShape
org.apache.poi.hslf.usermodel.HSLFTextShape
org.apache.poi.hslf.usermodel.HSLFAutoShape
- All Implemented Interfaces:
- java.lang.Iterable<HSLFTextParagraph>, IAdjustableShape, AutoShape<HSLFShape,HSLFTextParagraph>, PlaceableShape<HSLFShape,HSLFTextParagraph>, Shape<HSLFShape,HSLFTextParagraph>, SimpleShape<HSLFShape,HSLFTextParagraph>, TextShape<HSLFShape,HSLFTextParagraph>
- Direct Known Subclasses:
- HSLFFreeformShape, Polygon
public class HSLFAutoShape
- extends HSLFTextShape
- implements AutoShape<HSLFShape,HSLFTextParagraph>
Represents an AutoShape.
AutoShapes are drawing objects with a particular shape that may be customized through smart resizing and adjustments.
See ShapeTypes
- Author:
- Yegor Kozlov
Methods inherited from class org.apache.poi.hslf.usermodel.HSLFTextShape |
afterInsert, appendText, getBottomInset, getEscherTextboxWrapper, getHFPlaceholderAtom, getHyperlinks, getInsets, getLeftInset, getMetroShape, getPlaceholderAtom, getRawText, getRightInset, getRunType, getText, getTextDirection, getTextHeight, getTextHeight, getTextId, getTextParagraphs, getTextPlaceholder, getTextRotation, getTopInset, getVerticalAlignment, getWordWrap, getWordWrapEx, isAlignToBaseline, isHorizontalCentered, isPlaceholder, iterator, resizeToFitText, resizeToFitText, setAlignToBaseline, setBottomInset, setHorizontalCentered, setInsets, setLeftInset, setRightInset, setRunType, setSheet, setText, setTextDirection, setTextId, setTextPlaceholder, setTextRotation, setTopInset, setVerticalAlignment, setWordWrap, setWordWrapEx, storeText |
Methods inherited from class org.apache.poi.hslf.usermodel.HSLFSimpleShape |
createHyperlink, createSpContainer, getAdjustValue, getFillColor, getGeometry, getHyperlink, getLineBackgroundColor, getLineCap, getLineColor, getLineCompound, getLineDash, getLineDecoration, getLineHeadDecoration, getLineHeadLength, getLineHeadWidth, getLineTailDecoration, getLineTailLength, getLineTailWidth, getLineWidth, getPlaceholder, getShadow, getShadowAngle, getShadowColor, getShadowDistance, getStrokeStyle, setFillColor, setHyperlink, setLineBackgroundColor, setLineCap, setLineColor, setLineCompound, setLineDash, setLineHeadDecoration, setLineHeadLength, setLineHeadWidth, setLineTailDecoration, setLineTailLength, setLineTailWidth, setLineWidth, setPlaceholder, setStrokeStyle |
Methods inherited from class org.apache.poi.hslf.usermodel.HSLFShape |
draw, getAnchor, getClientData, getClientDataRecord, getClientRecords, getEscherChild, getEscherChild, getEscherChild, getEscherChild, getEscherOptRecord, getEscherProperty, getEscherProperty, getEscherProperty, getFill, getFillStyle, getFlipHorizontal, getFlipVertical, getParent, getRotation, getShapeId, getShapeName, getShapeType, getSheet, getSpContainer, moveTo, setAnchor, setEscherProperty, setEscherProperty, setFlipHorizontal, setFlipVertical, setRotation, setShapeId, setShapeType |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.poi.sl.usermodel.TextShape |
appendText, getInsets, getText, getTextDirection, getTextHeight, getTextHeight, getTextParagraphs, getTextPlaceholder, getTextRotation, getVerticalAlignment, getWordWrap, isHorizontalCentered, resizeToFitText, resizeToFitText, setHorizontalCentered, setInsets, setText, setTextDirection, setTextPlaceholder, setTextRotation, setVerticalAlignment, setWordWrap |
Methods inherited from interface org.apache.poi.sl.usermodel.SimpleShape |
createHyperlink, getFillColor, getFillStyle, getGeometry, getHyperlink, getLineDecoration, getPlaceholder, getShadow, getShapeType, getStrokeStyle, setFillColor, setPlaceholder, setShapeType, setStrokeStyle |
Methods inherited from interface java.lang.Iterable |
iterator |
HSLFAutoShape
protected HSLFAutoShape(EscherContainerRecord escherRecord,
ShapeContainer<HSLFShape,HSLFTextParagraph> parent)
HSLFAutoShape
public HSLFAutoShape(ShapeType type,
ShapeContainer<HSLFShape,HSLFTextParagraph> parent)
HSLFAutoShape
public HSLFAutoShape(ShapeType type)
createSpContainer
protected EscherContainerRecord createSpContainer(ShapeType shapeType,
boolean isChild)
setDefaultTextProperties
protected void setDefaultTextProperties(HSLFTextParagraph _txtrun)
- Description copied from class:
HSLFTextShape
- Set default properties for the TextRun.
Depending on the text and shape type the defaults are different:
TextBox: align=left, valign=top
AutoShape: align=center, valign=middle
- Overrides:
setDefaultTextProperties
in class HSLFTextShape
getAdjustmentValue
public int getAdjustmentValue(int idx)
- Gets adjust value which controls smart resizing of the auto-shape.
The adjustment values are given in shape coordinates:
the origin is at the top-left, positive-x is to the right, positive-y is down.
The region from (0,0) to (S,S) maps to the geometry box of the shape (S=21600 is a constant).
- Parameters:
idx
- the adjust index in the [0, 9] range
- Returns:
- the adjustment value
setAdjustmentValue
public void setAdjustmentValue(int idx,
int val)
- Sets adjust value which controls smart resizing of the auto-shape.
The adjustment values are given in shape coordinates:
the origin is at the top-left, positive-x is to the right, positive-y is down.
The region from (0,0) to (S,S) maps to the geometry box of the shape (S=21600 is a constant).
- Parameters:
idx
- the adjust index in the [0, 9] rangeval
- the adjustment value
Copyright 2017 The Apache Software Foundation or
its licensors, as applicable.