|
||||||||||
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<Style> org.moxieapps.gwt.highcharts.client.Style
public class Style
A configurable class that can be used to represent custom CSS style options for the
chart, which can then be set on various other configuration objects (e.g.
BaseChart.setStyle(Style)
, ChartTitle.setStyle(Style)
, etc.).
Example usage:
Note that some convenience methods are provided on this class for setting commonly used
CSS options (such as
chart.setStyle(
new Style()
.setOption("fontFamily", "serif")
);
setColor(String)
, setFontFamily(String)
,
setFontSize(String)
, etc). But, any arbitrary CSS option can be set by
simply using the Configurable.setOption(String, Object)
method. E.g., the following two
lines are equivalent:
style.setFontFamily("serif");
style.setOption("fontFamily", "serif");
Constructor Summary | |
---|---|
Style()
|
Method Summary | |
---|---|
Style |
setBottom(String bottom)
Convenience method for setting the "bottom" CSS style option. |
Style |
setColor(String color)
Convenience method for setting the "color" CSS style option. |
Style |
setCursor(String cursor)
Convenience method for setting the "cursor" CSS style option. |
Style |
setFont(String font)
Convenience method for setting the "font" CSS style option. |
Style |
setFontFamily(String fontFamily)
Convenience method for setting the "fontFamily" CSS style option. |
Style |
setFontSize(String fontSize)
Convenience method for setting the "fontSize" CSS style option. |
Style |
setFontStyle(String fontStyle)
Convenience method for setting the "fontStyle" CSS style option. |
Style |
setFontWeight(String fontWeight)
Convenience method for setting the "fontWeight" CSS style option. |
Style |
setLeft(String left)
Convenience method for setting the "left" CSS style option. |
Style |
setMargin(String margin)
Convenience method for setting the "margin" CSS style option. |
Style |
setPosition(String position)
Convenience method for setting the "position" CSS style option. |
Style |
setRight(String right)
Convenience method for setting the "right" CSS style option. |
Style |
setTop(String top)
Convenience method for setting the "top" CSS style option. |
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 Style()
Method Detail |
---|
public Style setBottom(String bottom)
chart.setOption("bottom", "10px");
bottom
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setColor(String color)
chart.setOption("color", "#FF0000");
color
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setCursor(String cursor)
chart.setOption("cursor", "pointer");
cursor
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setFont(String font)
chart.setOption("font", "normal 13px Verdana, sans-serif");
font
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setFontFamily(String fontFamily)
chart.setOption("fontFamily", "serif");
fontFamily
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setFontSize(String fontSize)
chart.setOption("fontSize", "16px");
fontSize
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setFontStyle(String fontStyle)
chart.setOption("fontStyle", "italic");
fontStyle
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setFontWeight(String fontWeight)
chart.setOption("fontWeight", "bold");
fontWeight
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setLeft(String left)
chart.setOption("left", "10px");
left
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setMargin(String margin)
chart.setOption("margin", "0px");
margin
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setPosition(String position)
chart.setOption("position", "absolute");
position
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setRight(String right)
chart.setOption("right", "10px");
right
- The value to use for the CSS style option.
Style
instance for convenient method chaining.public Style setTop(String top)
chart.setOption("top", "10px");
top
- The value to use for the CSS style option.
Style
instance for convenient method chaining.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |