Class LinearGradient
java.lang.Object
com.independentsoft.office.odf.styles.LinearGradient
Define linear gradients to fill or stroke graphical elements.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()Creates a new object that is a deep copy of the current instance.Gets the name of a gradient.Gets the definition of an optional additional transformation from the gradient coordinate system onto the target coordinate system.Gets the coordinate system.getName()Gets the name by which a gradient can be referenced.Specifies what happens if the gradient starts or ends inside the bounds of the target rectangle.getStops()Contains a collection of SvgStop objects.getX1()Gets the x1-axis coordinate of the start of the vector gradient onto which the elements are mapped.getX2()Gets the x2-axis coordinate of the start of the vector gradient onto which the elements are mapped.getY1()Gets the y1-axis coordinate of the start of the vector gradient onto which the elements are mapped.getY2()Gets the y2-axis coordinate of the start of the vector gradient onto which the elements are mapped.voidsetDisplayName(String displayName)Sets the name of a gradient.voidsetGradientTransform(String gradientTransform)Sets the definition of an optional additional transformation from the gradient coordinate system onto the target coordinate system.voidsetGradientUnits(String gradientUnits)Sets the coordinate system.voidSets the name by which a gradient can be referenced.voidsetSpreadMethod(SpreadMethod spreadMethod)Specifies what happens if the gradient starts or ends inside the bounds of the target rectangle.voidSets the x1-axis coordinate of the start of the vector gradient onto which the elements are mapped.voidSets the x2-axis coordinate of the start of the vector gradient onto which the elements are mapped.voidSets the y1-axis coordinate of the start of the vector gradient onto which the elements are mapped.voidSets the y2-axis coordinate of the start of the vector gradient onto which the elements are mapped.toString()Converts the value of the current LinearGradient object to its equivalent string representation.
-
Constructor Details
-
LinearGradient
public LinearGradient()Initializes a new instance of the LinearGradient class.
-
-
Method Details
-
clone
Creates a new object that is a deep copy of the current instance. -
toString
Converts the value of the current LinearGradient object to its equivalent string representation. -
getName
Gets the name by which a gradient can be referenced.- Returns:
- the name
-
setName
Sets the name by which a gradient can be referenced.- Parameters:
name- the new name
-
getDisplayName
Gets the name of a gradient.- Returns:
- the display name
-
setDisplayName
Sets the name of a gradient.- Parameters:
displayName- the new display name
-
getX1
Gets the x1-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Returns:
- the x1
-
setX1
Sets the x1-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Parameters:
x1- the new x1
-
getX2
Gets the x2-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Returns:
- the x2
-
setX2
Sets the x2-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Parameters:
x2- the new x2
-
getY1
Gets the y1-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Returns:
- the y1
-
setY1
Sets the y1-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Parameters:
y1- the new y1
-
getY2
Gets the y2-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Returns:
- the y2
-
setY2
Sets the y2-axis coordinate of the start of the vector gradient onto which the elements are mapped.- Parameters:
y2- the new y2
-
getStops
Contains a collection of SvgStop objects.- Returns:
- the stops
-
getGradientUnits
Gets the coordinate system.- Returns:
- the gradient units
-
setGradientUnits
Sets the coordinate system.- Parameters:
gradientUnits- the new gradient units
-
getGradientTransform
Gets the definition of an optional additional transformation from the gradient coordinate system onto the target coordinate system.- Returns:
- the gradient transform
-
setGradientTransform
Sets the definition of an optional additional transformation from the gradient coordinate system onto the target coordinate system.- Parameters:
gradientTransform- the new gradient transform
-
getSpreadMethod
Specifies what happens if the gradient starts or ends inside the bounds of the target rectangle.- Returns:
- the spread method
-
setSpreadMethod
Specifies what happens if the gradient starts or ends inside the bounds of the target rectangle.- Parameters:
spreadMethod- the new spread method
-