com.googlecode.wickedcharts.highcharts.options.color
Class LinearGradient

java.lang.Object
  extended by com.googlecode.wickedcharts.highcharts.options.color.ColorReference
      extended by com.googlecode.wickedcharts.highcharts.options.color.Gradient
          extended by com.googlecode.wickedcharts.highcharts.options.color.LinearGradient
All Implemented Interfaces:
Nullable, Serializable

public class LinearGradient
extends Gradient

A ColorReference defining a linear gradient with one or more changes between colors.

Author:
Tom Hombergs (tom.hombergs@gmail.com)
See Also:
Serialized Form

Nested Class Summary
static class LinearGradient.GradientDirection
           
 
Constructor Summary
LinearGradient(LinearGradient.GradientDirection direction)
          Constructs a linear gradient with a predefined direction.
LinearGradient(Number x1, Number y1, Number x2, Number y2)
          Constructs a linear gradient with a custom direction.
 
Method Summary
protected  ColorReference copy()
           
 List<Number> getLinearGradient()
           
 
Methods inherited from class com.googlecode.wickedcharts.highcharts.options.color.Gradient
addStop, addStopsInternal, brighten, getStops
 
Methods inherited from class com.googlecode.wickedcharts.highcharts.options.color.ColorReference
getBrightness, isNull, setBrightness
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LinearGradient

public LinearGradient(LinearGradient.GradientDirection direction)
Constructs a linear gradient with a predefined direction.

Parameters:
direction - the direction of the gradient.

LinearGradient

public LinearGradient(Number x1,
                      Number y1,
                      Number x2,
                      Number y2)
Constructs a linear gradient with a custom direction. The direction is defined by a starting and ending point.

Parameters:
x1 - x-axis percentage of the starting point of the gradient. Must be a value between 0 and 1.
y1 - y-axis percentage of the starting point of the gradient. Must be a value between 0 and 1.
x2 - x-axis percentage of the ending point of the gradient. Must be a value between 0 and 1.
y2 - y-axis percentage of the ending point of the gradient. Must be a value between 0 and 1.
Method Detail

copy

protected ColorReference copy()
Specified by:
copy in class ColorReference

getLinearGradient

public List<Number> getLinearGradient()


Copyright © 2013. All Rights Reserved.