|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.moxieapps.gwt.highcharts.client.Configurable<T> org.moxieapps.gwt.highcharts.client.plotOptions.BaseGaugePart<T>
public abstract class BaseGaugePart<T extends BaseGaugePart>
A common base class for both Dial
and Pivot
to prevent code duplication
while still maintaining a cleaner way for the user to utilize the method chaining with the generics
in place. You should not use this class directly, but instead use one of the base classes.
Constructor Summary | |
---|---|
BaseGaugePart()
|
Method Summary | |
---|---|
T |
setBackgroundColor(Color backgroundColor)
Convenience method for setting the "backgroundColor" option for a gauge's pivot. |
T |
setBackgroundColor(String backgroundColor)
Convenience method for setting the "backgroundColor" option for a gauge's pivot. |
T |
setBorderColor(Color borderColor)
Convenience method for setting the "borderColor" option for a gauge's pivot. |
T |
setBorderColor(String borderColor)
Convenience method for setting the "borderColor" option for a gauge's pivot. |
T |
setBorderWidth(Number borderWidth)
Convenience method for setting the "borderWidth" option for a gauge's pivot. |
T |
setRadius(String radius)
Convenience method for setting the "radius" option for a gauge's pivot. |
Methods inherited from class org.moxieapps.gwt.highcharts.client.Configurable |
---|
getOptions, setOption |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BaseGaugePart()
Method Detail |
---|
public T setBackgroundColor(String backgroundColor)
pivotOptions.setOption("backgroundColor", #CCCCCC)
The background or fill color of the gauge's pivot. Defaults to black.
Note that this method is intended for setting the color to a simple RBG hex value. If you instead
want to set a color to include an alpha channel or a gradient, use the setBackgroundColor(org.moxieapps.gwt.highcharts.client.Color)
version instead.
backgroundColor
- The value to set as the 'backgroundColor' option of the box plots.
BaseGaugePart
for convenient method chaining.public T setBackgroundColor(Color backgroundColor)
pivotOptions.setOption("fillColor", new Color()
.setLinearGradient(0.0, 0.0, 1.0, 1.0)
.addStop(new Color(255, 255, 255))
.addStop(new Color(200, 200, 255))
);
The background or fill color of the gauge's pivot. Defaults to black.
Note that this method is intended for setting the color to a gradient or color that includes
an alpha channel. If you instead just want to set the color to a normal RGB hex value
you can use the setBackgroundColor(String)
version instead.
backgroundColor
- The color gradient or color with an alpha channel to set as the 'backgroundColor' option of the box plot.
BaseGaugePart
for convenient method chainingpublic T setBorderColor(String borderColor)
pivotOptions.setOption("borderColor", #CCCCCC);
The border color or stroke of the gauge's pivot. By default, the borderWidth is 0, so this must be set in addition to a custom border color. Defaults to silver.
Note that this method is intended for setting the color to a simple RBG hex value. If you instead
want to set a color to include an alpha channel or a gradient, use the setBorderColor(Color)
version instead.
borderColor
- The value to set as the 'borderColor' option of the box plots.
BaseGaugePart
for convenient method chainingpublic T setBorderColor(Color borderColor)
pivotOptions.setOption("fillColor", new Color()
.setLinearGradient(0.0, 0.0, 1.0, 1.0)
.addStop(new Color(255, 255, 255))
.addStop(new Color(200, 200, 255))
);
The border color or stroke of the gauge's pivot. By default, the borderWidth is 0,
so this must be set in addition to a custom border color. Defaults to silver.
Note that this method is intended for setting the color to a gradient or color that includes
an alpha channel. If you instead just want to set the color to a normal RGB hex value
you can use the setBorderColor(String)
version instead.
borderColor
- The color gradient or color with an alpha channel to set as the 'borderColor' option of the box plot.
BaseGaugePart
for convenient method chainingpublic T setBorderWidth(Number borderWidth)
pivotOptions.setOption("borderWidth", 5);
The width of the gauge pivot border in pixels. Defaults to 0.
borderWidth
- The width of the gauge pivot border in pixels.
BaseGaugePart
for convenient method chainingpublic T setRadius(String radius)
pivotOptions.setOption("radius", "50%");
The radius or length of the pivot, in percentages relative to the radius of the gauge itself. Defaults to 80%.
radius
- The radius of the pivot as a percentage of the radius of the gauge itself.
BaseGaugePart
for convenient method chaining
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |