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
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
ConstructorsConstructorDescriptionShading(AbstractPdfShading shading) Creates a new instance of Shading Pattern.Shading(PdfDictionary pdfObject) Creates new instance from thePdfStreamobject. -
Method Summary
Modifier and TypeMethodDescriptionGets the dictionary of the pattern'sAbstractPdfShading.voidsetShading(AbstractPdfShading shading) Sets theAbstractPdfShadingthat specifies the details of a particular gradient fill.voidsetShading(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, setMatrixMethods inherited from class com.itextpdf.kernel.pdf.PdfObjectWrapper
ensureObjectIsAddedToDocument, ensureUnderlyingObjectHasIndirectReference, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidRelease
-
Constructor Details
-
Shading
Creates new instance from thePdfStreamobject. This stream should have PatternType equals to 2.- Parameters:
-
pdfObject- thePdfStreamthat represents Shading Pattern.
-
Shading
Creates a new instance of Shading Pattern.- Parameters:
-
shading- theAbstractPdfShadingthat specifies the details of a particular gradient fill
-
-
Method Details
-
getShading
Gets the dictionary of the pattern'sAbstractPdfShading.- Returns:
-
the dictionary of the pattern's
AbstractPdfShading
-
setShading
Sets theAbstractPdfShadingthat specifies the details of a particular gradient fill.- Parameters:
-
shading- theAbstractPdfShadingthat specifies the details of a particular gradient fill
-
setShading
Sets the dictionary which specifies the details of a particular gradient fill.- Parameters:
-
shading- the dictionary of the pattern'sAbstractPdfShading
-