public final class FillFormat extends PVIObject implements IFillFormat
Represents a fill formatting options.
| Modifier and Type | Method and Description |
|---|---|
IFillFormatEffectiveData |
getEffective()
Gets effective fill formatting data with the inheritance applied.
|
byte |
getFillType()
Returns or sets the type of filling.
|
IGradientFormat |
getGradientFormat()
Returns the gradient fill format.
|
IPatternFormat |
getPatternFormat()
Returns the pattern fill format.
|
IPictureFillFormat |
getPictureFillFormat()
Returns the picture fill format.
|
byte |
getRotateWithShape()
Determines whether the fill should be rotated with shape.
|
IColorFormat |
getSolidFillColor()
Returns the fill color.
|
long |
getVersion()
Version.
|
void |
setFillType(byte value)
Returns or sets the type of filling.
|
void |
setRotateWithShape(byte value)
Determines whether the fill should be rotated with shape.
|
equals, getParent_Immediate, getParent_IPresentationComponent, getParent_ISlideComponent, getPresentation, getSlide, hashCodepublic long getVersion()
Version.
Read-only long.
getVersion in class PVIObjectpublic final byte getFillType()
Returns or sets the type of filling.
Read/write FillType.
getFillType in interface IFillFormatpublic final void setFillType(byte value)
Returns or sets the type of filling.
Read/write FillType.
setFillType in interface IFillFormatpublic final IColorFormat getSolidFillColor()
Returns the fill color.
Read-only IColorFormat.
getSolidFillColor in interface IFillFormatpublic final IGradientFormat getGradientFormat()
Returns the gradient fill format.
Read-only IGradientFormat.
getGradientFormat in interface IFillFormatpublic final IPatternFormat getPatternFormat()
Returns the pattern fill format.
Read-only IPatternFormat.
getPatternFormat in interface IFillFormatpublic final IPictureFillFormat getPictureFillFormat()
Returns the picture fill format.
Read-only IPictureFillFormat.
getPictureFillFormat in interface IFillFormatpublic final byte getRotateWithShape()
Determines whether the fill should be rotated with shape.
Read/write NullableBool.
getRotateWithShape in interface IFillFormatpublic final void setRotateWithShape(byte value)
Determines whether the fill should be rotated with shape.
Read/write NullableBool.
setRotateWithShape in interface IFillFormatpublic final IFillFormatEffectiveData getEffective()
Gets effective fill formatting data with the inheritance applied.
This example demonstrates getting shape's effective fill format properties.Presentation pres = new Presentation("MyPresentation.pptx"); try { IFillFormatEffectiveData effectiveFillFormat = pres.getSlides().get_Item(0).getShapes().get_Item(0).getFillFormat().getEffective(); System.out.println("Type: " + effectiveFillFormat.getFillType()); switch (effectiveFillFormat.getFillType()) { case FillType.Solid: System.out.println("Fill color: " + effectiveFillFormat.getSolidFillColor()); break; case FillType.Pattern: System.out.println("Pattern style: " + effectiveFillFormat.getPatternFormat().getPatternStyle()); System.out.println("Fore color: " + effectiveFillFormat.getPatternFormat().getForeColor()); System.out.println("Back color: " + effectiveFillFormat.getPatternFormat().getBackColor()); break; case FillType.Gradient: System.out.println("Gradient direction: " + effectiveFillFormat.getGradientFormat().getGradientDirection()); System.out.println("Gradient stops count: " + effectiveFillFormat.getGradientFormat().getGradientStops().size()); break; case FillType.Picture: System.out.println("Picture width: " + effectiveFillFormat.getPictureFillFormat().getPicture().getImage().getWidth()); System.out.println("Picture height: " + effectiveFillFormat.getPictureFillFormat().getPicture().getImage().getHeight()); break; } } finally { if (pres != null) pres.dispose(); }
getEffective in interface IFillFormatIFillFormatEffectiveData.Copyright © 2004-2025 Aspose Pty Ltd. All Rights Reserved.