AxialShading
Overview
AxialShading is a class in Aspose.PDF FOSS for Java.
Inherits from: Shading.
Axial shading / linear gradient — ShadingType 2 (ISO 32000-1:2008, §8.7.4.5.2).
This class provides 17 methods for working with AxialShading objects in Java programs.
Available methods include: AxialShading, getBBox, getBackground, getColorAt, getColorSpace, getPdfDictionary, getShadingType, getT0, getT1, getX0, getX1, getY0, and 5 additional methods.
All public members are accessible to any Java application after installing the Aspose.PDF FOSS for Java package.
Properties: antiAlias, bBox, background, colorSpace, extendEnd, extendStart, and 8 more.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
shadingType | int | Read | Gets the shading type. |
x0 | double | Read | Returns the start point X coordinate. |
y0 | double | Read | Returns the start point Y coordinate. |
x1 | double | Read | Returns the end point X coordinate. |
y1 | double | Read | Returns the end point Y coordinate. |
t0 | double | Read | Returns the start of the parametric domain. |
t1 | double | Read | Returns the end of the parametric domain. |
extendStart | boolean | Read | Returns whether the gradient extends before the start point. |
extendEnd | boolean | Read | Returns whether the gradient extends past the end point. |
colorSpace | ColorSpaceBase | Read | Returns the color space. |
background | double[] | Read | Returns the optional background color, or {@code null}. |
bBox | Rectangle | Read | Returns the optional bounding box, or {@code null}. |
antiAlias | boolean | Read | Returns whether anti-aliasing is requested. |
pdfDictionary | PdfDictionary | Read | Returns the underlying dictionary. |
Methods
| Signature | Description |
|---|---|
AxialShading(dict: PdfDictionary, parser: PDFParser) | Creates an AxialShading from its dictionary. |
getShadingType() → int | Returns the shading type. |
getColorAt(x: double, y: double) → double[] | |
getX0() → double | Returns the start point X coordinate. |
getY0() → double | Returns the start point Y coordinate. |
getX1() → double | Returns the end point X coordinate. |
getY1() → double | Returns the end point Y coordinate. |
getT0() → double | Returns the start of the parametric domain. |
getT1() → double | Returns the end of the parametric domain. |
isExtendStart() → boolean | Returns whether the gradient extends before the start point. |
isExtendEnd() → boolean | Returns whether the gradient extends past the end point. |
getColorSpace() → ColorSpaceBase | Returns the color space. |
getBackground() → double[] | Returns the optional background color, or {@code null}. |
getBBox() → Rectangle | Returns the optional bounding box, or {@code null}. |
isAntiAlias() → boolean | Returns whether anti-aliasing is requested. |
getPdfDictionary() → PdfDictionary | Returns the underlying dictionary. |
parse(obj: PdfBase, parser: PDFParser) → Shading | Factory: parses a shading from a PDF object. |