Class FillGradientMode
- java.lang.Object
-
- com.supermap.data.FillGradientMode
-
public final class FillGradientMode extends java.lang.Object
Defines the fill gradient mode constant.Defines the fill gradient mode.
All gradient modes gradate between two colors, starting from the start color to the end color.
For different gradient types, you are allowed to set the start color, end color, center, etc. with the
GeoStyle
. By default, the gradient rotation angle is zero, the center of the gradient fill is the center of bounds of the filled shape. The following descriptions of all the gradient fill types are given provided that these settings apply the default values. See thegetFillGradientAngle()
andsetFillGradientAngle()
method of theGeoStyle
class, see thegetFillGradientOffsetRatioX()
(setFillGradientOffsetRatioX()
) andgetFillGradientOffsetRatioY()
(setFillGradientOffsetRatioY()
) method of theGeoStyle
class for the setting of the center of bounds of the filled shape. The computing of the gradient styles is based on the minimum bounding box of the fill area, i.e. the minimum enclosing rectangle. Therefore, the fill area extent mentioned in the following is the minimum bounding box of the fill area.
-
-
Field Summary
Fields Modifier and Type Field and Description static FillGradientMode
CONICAL
A conical gradient.static FillGradientMode
LINEAR
Linear gradient fill.static FillGradientMode
NONE
No gradient.static FillGradientMode
RADIAL
A radial gradient.static FillGradientMode
SQUARE
A foursquare gradient.
-
-
-
Field Detail
-
NONE
public static final FillGradientMode NONE
No gradient.When using normal fill mode, the gradient mode is set to non-gradient.
-
LINEAR
public static final FillGradientMode LINEAR
Linear gradient fill.It is a gradient from the start point of the horizontal line to the end line. As shown, the color gradates from the start color to the end color, and the color of a line perpendicular to the line does not change.
-
RADIAL
public static final FillGradientMode RADIAL
A radial gradient.It is a circular gradient that regards the center of the fill area as the start point and the farthest boundary point as the end point. Please note that the color in the same circle does not change, the gradient happens between different circles. As shown in the figure, from the origin point to the end point of the gradient fill, the colors of the circles centered at the origin point of the fill gradually changes from the start color to the end color as the circle radius increases.
-
CONICAL
public static final FillGradientMode CONICAL
A conical gradient.In a conical gradient, gradient will be performed both anticlockwise and clockwise, and the color changes along two directions all from the starting color to the ending color. Note: The fill area is treated as the conical vertex, and color in generatrix is the same. As shown in the figure, the start line of the gradient fill is the horizontal line which is on the right side of the fill extent center and passes this center. The color of the upper half of the conic gradually changes counterclockwise, and the color of the lower half of the conic gradually changes clockwise. The start line and the end line of one half is the end line and the start line of the other half, respectively. When moving from the start line to the end line in the counterclockwise direction or in the clockwise direction, the color changes from the start color to the end color in both directions.
-
SQUARE
public static final FillGradientMode SQUARE
A foursquare gradient.In a foursquare gradient, the color of the shape changes gradually from starting point to ending point with square pattern, and the starting point is the center of the boundary rectangle, while the ending point is the middle point of one of the short side(the shorter one between width and height ) of the boundary rectangle.Please note that the color in the same circle does not change, the gradient happens between different circles. As shown in the figure, from the origin point to the end point of the gradient fill, the colors of the circles centered at the origin point of the fill gradually changes from the start color to the end color as the circle radius increases.
-
-