Class Gradient
Colors and direction to fill areas with gradients
Defined in: <..\..\src\teechart.js>.
Constructor Attributes | Constructor Name and Description |
---|---|
Gradient(chart)
|
Field Attributes | Field Name and Description |
---|---|
Color position from center, percentage from 0 to 1, for radial gradients only.
|
|
Array of colors to define the gradient.
|
|
Defines the gradient orientation
("topbottom", "bottomtop", "leftright", "rightleft", "radial", "diagonalup", "diagonaldown").
|
|
Determines if contents will be filled using this gradient.
|
Method Attributes | Method Name and Description |
---|---|
create(r, color)
|
|
createrect(x, y, width, height, color)
|
Class Detail
Gradient(chart)
- Parameters:
- {Tee.Chart} chart
- The parent chart this gradient object belongs to.
Field Detail
{Number}
balance
Color position from center, percentage from 0 to 1, for radial gradients only.
{Color[]}
colors
Array of colors to define the gradient.
{String}
direction
Defines the gradient orientation
("topbottom", "bottomtop", "leftright", "rightleft", "radial", "diagonalup", "diagonaldown").
{Boolean}
visible
Determines if contents will be filled using this gradient.
Method Detail
{CanvasGradient}
create(r, color)
- Parameters:
- r
- color
- Returns:
- {CanvasGradient} Returns a canvas gradient
{CanvasGradient}
createrect(x, y, width, height, color)
- Parameters:
- x
- y
- width
- height
- color
- Returns:
- {CanvasGradient} Returns a canvas gradient