public class Line extends Entity<T>
Modifier and Type | Method and Description |
---|---|
double |
getFillAlpha()
Returns the alpha of the fill of this
Shape as a percentage. |
java.lang.Integer |
getFillColor()
Returns the color of the fill of this
Shape as an RGB integer. |
double |
getLineAlpha()
Returns the alpha of the border of this
Shape as a percentage. |
int |
getLineColor()
Returns the color of the border of this
Shape as an RGB integer. |
int |
getLineWidth()
Returns the width of the border of this
Shape in world units. |
int |
getX2()
Returns the X coordinate of this
Line 's end point. |
int |
getY2()
Returns the Y coordinate of this
Line 's end point. |
T |
setFillAlpha(double alpha)
Sets the alpha of the fill of this
Shape as a percentage. |
T |
setFillAlpha(double alpha,
Curve curve)
Sets the alpha of the fill of this
Shape as a percentage. |
T |
setFillColor(int color)
Sets the color of the fill of this
Shape as an RGB integer or null if the fill should not be drawn. |
T |
setFillColor(int color,
Curve curve)
Sets the color of the fill of this
Shape as an RGB integer or null if the fill should not be drawn. |
T |
setLineAlpha(double alpha)
Sets the alpha of the border of this
Shape as a percentage. |
T |
setLineAlpha(double alpha,
Curve curve)
Sets the alpha of the border of this
Shape as a percentage. |
T |
setLineColor(int lineColor)
Sets the color of the border of this
Shape as an RGB integer. |
T |
setLineColor(int lineColor,
Curve curve)
Sets the color of the border of this
Shape as an RGB integer. |
T |
setLineWidth(int lineWidth)
Sets the width of the border of this
Shape in world units. |
T |
setLineWidth(int lineWidth,
Curve curve)
Sets the width of the border of this
Shape in world units. |
Line |
setX2(int x2)
Sets the X coordinate of the end point of this
Line . |
Line |
setX2(int x2,
Curve curve)
Sets the X coordinate of the end point of this
Line . |
Line |
setY2(int y2)
Sets the y coordinate of the end point of this
Line . |
Line |
setY2(int y2,
Curve curve)
Sets the y coordinate of the end point of this
Line . |
getAlpha, getId, getRotation, getScaleX, getScaleY, getX, getY, getZIndex, isVisible, setAlpha, setAlpha, setRotation, setRotation, setScale, setScale, setScaleX, setScaleX, setScaleY, setScaleY, setVisible, setX, setX, setY, setY, setZIndex
public Line setX2(int x2)
Line
.
The starting point of this line is its position.
x2
- the X coordinate for the end point of this Line
.Line
.public Line setX2(int x2, Curve curve)
Line
.
The starting point of this line is its position.
x2
- the X coordinate for the end point of this Line
.curve
- the transition to animate between values of this property.Line
.public int getX2()
Line
's end point.Line
's end point.public Line setY2(int y2)
Line
.
The starting point of this line is its position.
y2
- the Y coordinate for the end point of this Line
.Line
.public Line setY2(int y2, Curve curve)
Line
.
The starting point of this line is its position.
y2
- the Y coordinate for the end point of this Line
.curve
- the transition to animate between values of this property.Line
.public int getY2()
Line
's end point.Line
's end point.public T setFillColor(int color)
Shape
as an RGB integer or null if the fill should not be drawn.color
- the color of the fill of this Shape
.Shape
.java.lang.IllegalArgumentException
- if color isn't a valid RGB integerpublic T setFillColor(int color, Curve curve)
Shape
as an RGB integer or null if the fill should not be drawn.color
- the color of the fill of this Shape
.curve
- the transition to animate between values of this property.Shape
.java.lang.IllegalArgumentException
- if color isn't a valid RGB integerpublic java.lang.Integer getFillColor()
Shape
as an RGB integer.
Can be null if no fill should be drawn.
Shape
.public T setFillAlpha(double alpha)
Shape
as a percentage.alpha
- the alpha of the fill of this Shape
.Shape
.java.lang.IllegalArgumentException
- if alpha < 0 or alpha > 1public T setFillAlpha(double alpha, Curve curve)
Shape
as a percentage.alpha
- the alpha of the fill of this Shape
.curve
- the transition to animate between values of this property.Shape
.java.lang.IllegalArgumentException
- if alpha < 0 or alpha > 1public double getFillAlpha()
Shape
as a percentage.
Default is 1.
Shape
.public T setLineAlpha(double alpha)
Shape
as a percentage.alpha
- the alpha for the border of this Shape
.Shape
.java.lang.IllegalArgumentException
- if alpha < 0 or alpha > 1public T setLineAlpha(double alpha, Curve curve)
Shape
as a percentage.alpha
- the alpha for the border of this Shape
.curve
- the transition to animate between values of this property.Shape
.java.lang.IllegalArgumentException
- if alpha < 0 or alpha > 1public double getLineAlpha()
Shape
as a percentage.
Default is 1.
Shape
.public T setLineWidth(int lineWidth)
Shape
in world units.lineWidth
- the width for the border of this Shape
.Shape
.public T setLineWidth(int lineWidth, Curve curve)
Shape
in world units.lineWidth
- the width for the border of this Shape
.curve
- the transition to animate between values of this property.Shape
.public int getLineWidth()
Shape
in world units.
Default is 1.
Shape
.public T setLineColor(int lineColor)
Shape
as an RGB integer.lineColor
- the color for the border of this Shape
.Shape
.java.lang.IllegalArgumentException
- if lineColor isn't a valid RGB integerpublic T setLineColor(int lineColor, Curve curve)
Shape
as an RGB integer.lineColor
- the color for the border of this Shape
.curve
- the transition to animate between values of this property.Shape
.java.lang.IllegalArgumentException
- if lineColor isn't a valid RGB integerpublic int getLineColor()
Shape
as an RGB integer.
Default is 0xFFFFFF (white).
Shape
.