public final class SXSSFPicture extends Object implements Picture
| Modifier and Type | Method and Description |
|---|---|
XSSFAnchor |
getAnchor() |
XSSFClientAnchor |
getClientAnchor() |
org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTPicture |
getCTPicture()
Return the underlying CTPicture bean that holds all properties for this picture
|
XSSFDrawing |
getDrawing() |
Dimension |
getImageDimension() |
protected static Dimension |
getImageDimension(PackagePart part,
int type)
Return the dimension of this image
|
Shape |
getParent() |
XSSFPictureData |
getPictureData()
Return picture data for this shape
|
XSSFClientAnchor |
getPreferredSize()
Calculate the preferred size for this picture.
|
XSSFClientAnchor |
getPreferredSize(double scale)
Calculate the preferred size for this picture.
|
XSSFClientAnchor |
getPreferredSize(double scaleX,
double scaleY) |
String |
getShapeName() |
protected org.openxmlformats.schemas.drawingml.x2006.main.CTShapeProperties |
getShapeProperties() |
XSSFSheet |
getSheet() |
boolean |
isNoFill() |
void |
resize()
Reset the image to the original size.
|
void |
resize(double scale)
Reset the image to the original size.
|
void |
resize(double scaleX,
double scaleY) |
void |
setFillColor(int red,
int green,
int blue) |
void |
setLineStyleColor(int red,
int green,
int blue) |
void |
setNoFill(boolean noFill) |
@Internal public org.openxmlformats.schemas.drawingml.x2006.spreadsheetDrawing.CTPicture getCTPicture()
public void resize()
Please note, that this method works correctly only for workbooks with the default font size (Calibri 11pt for .xlsx). If the default font is changed the resized image can be streched vertically or horizontally.
public void resize(double scale)
Please note, that this method works correctly only for workbooks with the default font size (Calibri 11pt for .xlsx). If the default font is changed the resized image can be streched vertically or horizontally.
public XSSFClientAnchor getPreferredSize()
getPreferredSize in interface Picturepublic XSSFClientAnchor getPreferredSize(double scale)
scale - the amount by which image dimensions are multiplied relative to the original size.protected static Dimension getImageDimension(PackagePart part, int type)
part - the package part holding raw picture datatype - type of the picture: Workbook.PICTURE_TYPE_JPEG,
Workbook.PICTURE_TYPE_PNG or Workbook.PICTURE_TYPE_DIBpublic XSSFPictureData getPictureData()
getPictureData in interface Pictureprotected org.openxmlformats.schemas.drawingml.x2006.main.CTShapeProperties getShapeProperties()
public XSSFAnchor getAnchor()
public XSSFClientAnchor getPreferredSize(double scaleX, double scaleY)
getPreferredSize in interface Picturepublic Dimension getImageDimension()
getImageDimension in interface Picturepublic XSSFClientAnchor getClientAnchor()
getClientAnchor in interface Picturepublic XSSFDrawing getDrawing()
public String getShapeName()
getShapeName in interface Shapepublic void setFillColor(int red,
int green,
int blue)
setFillColor in interface Shapepublic void setLineStyleColor(int red,
int green,
int blue)
setLineStyleColor in interface Shape