|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ascape.util.vis.ColorFeatureConcrete
org.ascape.util.vis.ColorFeatureGradiated
public class ColorFeatureGradiated
A class for displaying a gradiated color whose intensity is determined by the supplied UnitIntervalDataPoint. The data point is bracketed, so values outside of the range 0.0 - 1.0 will be treeated as minimum and maximum respectivly.
| Field Summary | |
|---|---|
protected float |
blueBase
The base value of the blue component of this color. |
protected float |
blueMaximum
The maximum value of the blue component of this color. |
protected float |
blueMinimum
The minimum value of the blue component of this color. |
protected UnitIntervalDataPoint |
dataPoint
The unit interval data point used to calculate the gradiated color. |
protected float |
greenBase
The base value of the green component of this color. |
protected float |
greenMaximum
The maximum value of the green component of this color. |
protected float |
greenMinimum
The minimum value of the green component of this color. |
protected float |
redBase
The base value of the red component of this color. |
protected float |
redMaximum
The maximum value of the red component of this color. |
protected float |
redMinimum
The minimum value of the red component of this color. |
| Fields inherited from class org.ascape.util.vis.ColorFeatureConcrete |
|---|
colorCache, name |
| Fields inherited from interface org.ascape.util.vis.ColorFeature |
|---|
BLACK, BLUE, CYAN, DARK_BLUE, DARK_GRAY, DARK_GREEN, DARK_MAGENTA, DARK_RED, DARK_YELLOW, DEFAULT_BG, GRAY, GREEN, HIGHLIGHT_AGENT_COLOR, LIGHT_GRAY, MAGENTA, ORANGE, RED, WHITE, YELLOW |
| Constructor Summary | |
|---|---|
ColorFeatureGradiated()
Constructs a ColorFeatureGradiated. |
|
ColorFeatureGradiated(org.eclipse.swt.graphics.Color maximumColor,
UnitIntervalDataPoint dataPoint)
Constructs a ColorFeatureGradiated with the supplied unit interval and maximum color. |
|
ColorFeatureGradiated(java.lang.String name)
Constructs the gradiated color feature with the supplied name. |
|
ColorFeatureGradiated(java.lang.String name,
org.eclipse.swt.graphics.Color maximumColor,
org.eclipse.swt.graphics.Color minimumColor,
UnitIntervalDataPoint dataPoint)
Constructs a ColorFeatureGradiated with the supplied name, maximum color, and unit interval. |
|
ColorFeatureGradiated(java.lang.String name,
org.eclipse.swt.graphics.Color maximumColor,
UnitIntervalDataPoint dataPoint)
Constructs a ColorFeatureGradiated with the supplied name, maximum color, and unit interval. |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
Clones this feature. |
org.eclipse.swt.graphics.Color |
getColor(java.lang.Object object)
Returns maximum color at intensity defined by the data point. |
org.eclipse.swt.graphics.Color |
getColor(java.lang.Object object,
float alpha)
Returns maximum color at intensity defined by the data point. |
UnitIntervalDataPoint |
getDataPoint()
Returns the data point used to calculate color. |
java.lang.String |
getName()
Returns the name of the gradiated color feature. |
void |
setDataPoint(UnitIntervalDataPoint dataPoint)
Sets a unit data point that will return some number between 0.0 and 1.0 |
void |
setMaximumColor(org.eclipse.swt.graphics.Color valueColor)
Sets the color at maximum intensity; that is, the color that would be returned if the unit value were 1.0. |
void |
setMinimumColor(org.eclipse.swt.graphics.Color valueColor)
Sets the color at minimum intensity; that is, the color that would be returned if the unit value were 0.0. |
| Methods inherited from class org.ascape.util.vis.ColorFeatureConcrete |
|---|
adjustBrightness, create, create, create, create, createHSB, createRandom, setName |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected float redMinimum
protected float greenMinimum
protected float blueMinimum
protected float redMaximum
protected float greenMaximum
protected float blueMaximum
protected float redBase
protected float greenBase
protected float blueBase
protected UnitIntervalDataPoint dataPoint
| Constructor Detail |
|---|
public ColorFeatureGradiated()
public ColorFeatureGradiated(java.lang.String name)
name - the name of this draw feature
public ColorFeatureGradiated(org.eclipse.swt.graphics.Color maximumColor,
UnitIntervalDataPoint dataPoint)
maximumColor - the color to be returned at unit maximumdataPoint - a unit interval data point (0..1) providing the relative intensity of a color for a given object
public ColorFeatureGradiated(java.lang.String name,
org.eclipse.swt.graphics.Color maximumColor,
UnitIntervalDataPoint dataPoint)
name - the name of this color featuremaximumColor - the color to be returned at unit maximumdataPoint - a unit interval data point (0..1) providing the relative intensity of a color for a given object
public ColorFeatureGradiated(java.lang.String name,
org.eclipse.swt.graphics.Color maximumColor,
org.eclipse.swt.graphics.Color minimumColor,
UnitIntervalDataPoint dataPoint)
name - the name of this color featureminimumColor - the color to be returned at unit minimummaximumColor - the color to be returned at unit maximumdataPoint - a unit interval data point (0..1) providing the relative intensity of a color for a given object| Method Detail |
|---|
public UnitIntervalDataPoint getDataPoint()
public void setDataPoint(UnitIntervalDataPoint dataPoint)
public java.lang.String getName()
getName in interface HasNamegetName in class ColorFeatureConcretepublic org.eclipse.swt.graphics.Color getColor(java.lang.Object object)
getColor in interface ColorFeaturegetColor in class ColorFeatureConcreteobject - the object to get a color from.
public org.eclipse.swt.graphics.Color getColor(java.lang.Object object,
float alpha)
object - the object to get a color from.public void setMinimumColor(org.eclipse.swt.graphics.Color valueColor)
public void setMaximumColor(org.eclipse.swt.graphics.Color valueColor)
public java.lang.Object clone()
clone in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||