Package com.github.weisj.jsvg.nodes
Class LinearGradient
- java.lang.Object
-
@ElementCategories(Gradient) @PermittedContent(categories=Descriptive, anyOf={Stop.class,Animate.class,AnimateTransform.class,Set.class}) public final class LinearGradient extends AbstractGradient<LinearGradient>
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
TAG
private Length
x1
private Length
x2
private Length
y1
private Length
y2
-
Fields inherited from class com.github.weisj.jsvg.nodes.AbstractGradient
gradientTransform, gradientUnits, spreadMethod
-
Fields inherited from interface com.github.weisj.jsvg.attributes.paint.SVGPaint
CONTEXT_FILL, CONTEXT_STROKE, CURRENT_COLOR, DEFAULT_PAINT, NONE
-
-
Constructor Summary
Constructors Constructor Description LinearGradient()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
buildGradient(@NotNull AttributeNode attributeNode, @Nullable LinearGradient template)
protected @NotNull java.awt.Paint
gradientForBounds(@NotNull MeasureContext measure, @NotNull java.awt.geom.Rectangle2D bounds, float[] gradOffsets, @NotNull java.awt.Color[] gradColors)
@NotNull java.lang.String
tagName()
java.lang.String
toString()
-
Methods inherited from class com.github.weisj.jsvg.nodes.AbstractGradient
build, colors, computeViewTransform, drawShape, fillShape, offsets
-
Methods inherited from class com.github.weisj.jsvg.nodes.container.ContainerNode
children, doAdd
-
Methods inherited from class com.github.weisj.jsvg.nodes.container.BaseContainerNode
acceptChild, addChild, isAcceptableType
-
Methods inherited from class com.github.weisj.jsvg.nodes.AbstractSVGNode
addContent, id
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.github.weisj.jsvg.nodes.prototype.Container
childrenOfType
-
-
-
-
Field Detail
-
TAG
public static final java.lang.String TAG
- See Also:
- Constant Field Values
-
x1
private Length x1
-
x2
private Length x2
-
y1
private Length y1
-
y2
private Length y2
-
-
Method Detail
-
tagName
@NotNull public @NotNull java.lang.String tagName()
-
buildGradient
protected void buildGradient(@NotNull @NotNull AttributeNode attributeNode, @Nullable @Nullable LinearGradient template)
- Specified by:
buildGradient
in classAbstractGradient<LinearGradient>
-
gradientForBounds
@NotNull protected @NotNull java.awt.Paint gradientForBounds(@NotNull @NotNull MeasureContext measure, @NotNull @NotNull java.awt.geom.Rectangle2D bounds, float[] gradOffsets, @NotNull @NotNull java.awt.Color[] gradColors)
- Specified by:
gradientForBounds
in classAbstractGradient<LinearGradient>
-
toString
public java.lang.String toString()
- Overrides:
toString
in classAbstractSVGNode
-
-