Package org.apache.poi.hslf.usermodel
Class HSLFTextBox
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.HSLFTextBox
- All Implemented Interfaces:
Iterable<HSLFTextParagraph>,IAdjustableShape,AutoShape<HSLFShape,,HSLFTextParagraph> PlaceableShape<HSLFShape,,HSLFTextParagraph> Shape<HSLFShape,,HSLFTextParagraph> SimpleShape<HSLFShape,,HSLFTextParagraph> TextBox<HSLFShape,,HSLFTextParagraph> TextShape<HSLFShape,HSLFTextParagraph>
- Direct Known Subclasses:
HSLFPlaceholder,HSLFTableCell
Represents a TextFrame shape in PowerPoint.
Contains the text in a text frame as well as the properties and methods that control alignment and anchoring of the text.
- Author:
- Yegor Kozlov
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.poi.sl.usermodel.TextShape
TextShape.TextAutofit, TextShape.TextDirection, TextShape.TextPlaceholder -
Field Summary
Fields inherited from class org.apache.poi.hslf.usermodel.HSLFTextShape
WrapByPoints, WrapNone, WrapSquare, WrapThrough, WrapTopBottomFields inherited from class org.apache.poi.hslf.usermodel.HSLFSimpleShape
_hyperlink, DEFAULT_LINE_WIDTH -
Constructor Summary
ConstructorsModifierConstructorDescriptionCreate a new TextBox.protectedHSLFTextBox(EscherContainerRecord escherRecord, ShapeContainer<HSLFShape, HSLFTextParagraph> parent) Create a TextBox object and initialize it from the supplied Record container.Create a new TextBox. -
Method Summary
Modifier and TypeMethodDescriptionprotected EscherContainerRecordcreateSpContainer(boolean isChild) Create a new TextBox and initialize its internal structuresprotected voidSet default properties for the TextRun.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, storeTextMethods inherited from class org.apache.poi.hslf.usermodel.HSLFSimpleShape
createHyperlink, getAdjustValue, getFillColor, getGeometry, getHyperlink, getLineBackgroundColor, getLineCap, getLineColor, getLineCompound, getLineDash, getLineDecoration, getLineHeadDecoration, getLineHeadLength, getLineHeadWidth, getLineTailDecoration, getLineTailLength, getLineTailWidth, getLineWidth, getPlaceholder, getPlaceholderDetails, getShadow, getShadowAngle, getShadowColor, getShadowDistance, getStrokeStyle, setFillColor, setHyperlink, setLineBackgroundColor, setLineCap, setLineColor, setLineCompound, setLineDash, setLineHeadDecoration, setLineHeadLength, setLineHeadWidth, setLineTailDecoration, setLineTailLength, setLineTailWidth, setLineWidth, setPlaceholder, setStrokeStyleMethods 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, setShapeTypeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.poi.sl.draw.geom.IAdjustableShape
getAdjustValueMethods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface org.apache.poi.sl.usermodel.PlaceableShape
getAnchor, getFlipHorizontal, getFlipVertical, getParent, getRotation, getSheet, setAnchor, setFlipHorizontal, setFlipVertical, setRotationMethods inherited from interface org.apache.poi.sl.usermodel.Shape
draw, getAnchor, getParent, getShapeId, getShapeName, getSheetMethods inherited from interface org.apache.poi.sl.usermodel.SimpleShape
createHyperlink, getFillColor, getFillStyle, getGeometry, getHyperlink, getLineDecoration, getPlaceholder, getPlaceholderDetails, getShadow, getShapeType, getStrokeStyle, isPlaceholder, setFillColor, setPlaceholder, setShapeType, setStrokeStyleMethods 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
-
Constructor Details
-
HSLFTextBox
protected HSLFTextBox(EscherContainerRecord escherRecord, ShapeContainer<HSLFShape, HSLFTextParagraph> parent) Create a TextBox object and initialize it from the supplied Record container.- Parameters:
escherRecord-EscherSpContainercontainer which holds information about this shapeparent- the parent of the shape
-
HSLFTextBox
Create a new TextBox. 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.
-
HSLFTextBox
public HSLFTextBox()Create a new TextBox. This constructor is used when a new shape is created.
-
-
Method Details
-
createSpContainer
Create a new TextBox and initialize its internal structures- Overrides:
createSpContainerin classHSLFSimpleShape- Parameters:
isChild-trueif the Line is inside a group,falseotherwise- Returns:
- the created
EscherContainerRecordwhich holds shape data
-
setDefaultTextProperties
Description copied from class:HSLFTextShapeSet 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:
setDefaultTextPropertiesin classHSLFTextShape
-