Package org.apache.poi.xssf.usermodel
Class XSSFShape
java.lang.Object
org.apache.poi.xssf.usermodel.XSSFShape
- All Implemented Interfaces:
Shape
- Direct Known Subclasses:
XSSFConnector,XSSFGraphicFrame,XSSFPicture,XSSFShapeGroup,XSSFSimpleShape
Represents a shape in a SpreadsheetML drawing.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected XSSFAnchoranchor that is used by this shapeprotected XSSFDrawingParent drawingprotected XSSFShapeGroupThe parent shape, always not-null for shapes in groups -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturn the drawing that owns this shapeprotected abstract org.openxmlformats.schemas.drawingml.x2006.main.CTShapePropertiesReturns xml bean with shape properties.booleanisNoFill()Whether this shape is not filled with a colorvoidsetFillColor(int red, int green, int blue) Sets the color used to fill this shape using the solid fill pattern.voidsetLineStyle(int lineStyle) Sets the line style.voidsetLineStyleColor(int red, int green, int blue) The color applied to the lines of this shape.voidsetLineWidth(double lineWidth) Specifies the width to be used for the underline stroke.voidsetNoFill(boolean noFill) Sets whether this shape is filled or transparent.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.poi.ss.usermodel.Shape
getShapeName
-
Field Details
-
drawing
Parent drawing -
parent
The parent shape, always not-null for shapes in groups -
anchor
anchor that is used by this shape
-
-
Constructor Details
-
XSSFShape
public XSSFShape()
-
-
Method Details
-
getDrawing
Return the drawing that owns this shape- Returns:
- the parent drawing that owns this shape
-
getParent
-
getAnchor
-
getShapeProperties
protected abstract org.openxmlformats.schemas.drawingml.x2006.main.CTShapeProperties getShapeProperties()Returns xml bean with shape properties.- Returns:
- xml bean with shape properties.
-
isNoFill
public boolean isNoFill()Description copied from interface:ShapeWhether this shape is not filled with a color -
setNoFill
public void setNoFill(boolean noFill) Description copied from interface:ShapeSets whether this shape is filled or transparent. -
setFillColor
public void setFillColor(int red, int green, int blue) Description copied from interface:ShapeSets the color used to fill this shape using the solid fill pattern.- Specified by:
setFillColorin interfaceShape
-
setLineStyleColor
public void setLineStyleColor(int red, int green, int blue) Description copied from interface:ShapeThe color applied to the lines of this shape.- Specified by:
setLineStyleColorin interfaceShape
-
setLineWidth
public void setLineWidth(double lineWidth) Specifies the width to be used for the underline stroke.- Parameters:
lineWidth- width in points
-
setLineStyle
public void setLineStyle(int lineStyle) Sets the line style.- Parameters:
lineStyle-
-