Class PdfPattern.Shading
- java.lang.Object
-
- com.itextpdf.kernel.pdf.PdfObjectWrapper<PdfDictionary>
-
- com.itextpdf.kernel.pdf.colorspace.PdfPattern
-
- com.itextpdf.kernel.pdf.colorspace.PdfPattern.Shading
-
- Enclosing class:
- PdfPattern
public static class PdfPattern.Shading extends PdfPattern
Shading pattern provides a smooth transition between colors across an area to be painted, independent of the resolution of any particular output device and without specifying the number of steps in the color transition. Patterns of this type are described by pattern dictionaries with a pattern type of 2.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.itextpdf.kernel.pdf.colorspace.PdfPattern
PdfPattern.Shading, PdfPattern.Tiling
-
-
Constructor Summary
Constructors Constructor Description Shading(PdfShading shading)
Creates a new instance of Shading Pattern.Shading(PdfDictionary pdfObject)
Creates new instance from thePdfStream
object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PdfDictionary
getShading()
Gets the dictionary of the pattern'sPdfShading
.void
setShading(PdfShading shading)
Sets thePdfShading
that specifies the details of a particular gradient fill.void
setShading(PdfDictionary shading)
Sets the dictionary which specifies the details of a particular gradient fill.-
Methods inherited from class com.itextpdf.kernel.pdf.colorspace.PdfPattern
flush, getMatrix, getPatternInstance, isWrappedObjectMustBeIndirect, setMatrix
-
Methods inherited from class com.itextpdf.kernel.pdf.PdfObjectWrapper
ensureObjectIsAddedToDocument, ensureUnderlyingObjectHasIndirectReference, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidRelease
-
-
-
-
Constructor Detail
-
Shading
public Shading(PdfDictionary pdfObject)
Creates new instance from thePdfStream
object. This stream should have PatternType equals to 2.- Parameters:
pdfObject
- thePdfStream
that represents Shading Pattern.
-
Shading
public Shading(PdfShading shading)
Creates a new instance of Shading Pattern.- Parameters:
shading
- thePdfShading
that specifies the details of a particular gradient fill
-
-
Method Detail
-
getShading
public PdfDictionary getShading()
Gets the dictionary of the pattern'sPdfShading
.- Returns:
- the dictionary of the pattern's
PdfShading
-
setShading
public void setShading(PdfShading shading)
Sets thePdfShading
that specifies the details of a particular gradient fill.- Parameters:
shading
- thePdfShading
that specifies the details of a particular gradient fill
-
setShading
public void setShading(PdfDictionary shading)
Sets the dictionary which specifies the details of a particular gradient fill.- Parameters:
shading
- the dictionary of the pattern'sPdfShading
-
-