|
![]() |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.droplets.api.Component | +--com.droplets.api.Panel | +--com.droplets.api.Graph
Inner Class Summary | |
static class |
Graph.AnnotationComponentProxy
|
static class |
Graph.PlotComponentProxy
|
Inner classes inherited from class com.droplets.api.Panel |
Panel.ImageMode |
Inner classes inherited from class com.droplets.api.IGraph |
IGraph.GraphImpl, IGraph.GraphProxy |
Fields inherited from class com.droplets.api.Panel |
IMAGE_CENTER, IMAGE_FIT, IMAGE_SCALE_BOTH, IMAGE_SCALE_DOWN, IMAGE_SCALE_UP, IMAGE_TILE, IMAGE_TILE_WRT_WINDOW, SCROLLBARS_AUTO, SCROLLBARS_OFF, SCROLLBARS_ON |
Fields inherited from class com.droplets.api.Component |
ANCHOR_CENTER, ANCHOR_EAST, ANCHOR_NORTH, ANCHOR_NORTHEAST, ANCHOR_NORTHWEST, ANCHOR_SOUTH, ANCHOR_SOUTHEAST, ANCHOR_SOUTHWEST, ANCHOR_WEST, FILL_BOTH, FILL_HORIZONTAL, FILL_NONE, FILL_VERTICAL |
Fields inherited from interface com.droplets.api.IGraph |
HALIGN_LEFT, HALIGN_RIGHT, TYPE_DATE, TYPE_NUMERICAL, VALIGN_BOTTOM, VALIGN_TOP |
Constructor Summary | |
Graph(LayoutPlacement lp,
Window window)
Creates a new Graph area. |
Method Summary | |
void |
addAnnotation(GraphAnnotation a)
Adds an annotation to this Graph. |
void |
addComponent(Component c)
This method is not used in Graphs. |
void |
addPlot(PlotComponent plot)
Adds a plot to this Graph. |
boolean |
getBoolAttribute(java.lang.String name,
boolean defaultValue)
Convenience method to get a boolean attribute. |
int |
getLegendHorizontalAlignment()
Gets the horizontal alignment of the legend. |
int |
getLegendHorizontalMargin()
Gets the distance from the horizontal alignment position in pixels. |
int |
getLegendVerticalAlignment()
Gets the vertical alignment of the legend. |
int |
getLegendVerticalMargin()
Gets the distance from the vertical alignment position in pixels. |
boolean |
getLegendVisible()
Gets the visibility of the legend |
java.lang.String |
getStringAttribute(java.lang.String name,
java.lang.String defaultValue)
Gets the value of an attribute. |
java.lang.String |
getXAxisDataType()
Gets the type of the x-axis and x coordinate of the data points. |
java.lang.String[] |
getXTickLabels()
Gets the x-tick labels |
java.lang.String |
getYAxisDataType()
Gets the type of the y-axis and y coordinate of the data points. |
boolean |
getZoomable()
Gets whether the graph is zoomable or not |
protected boolean |
isFocusTraversableDefault()
See Component.isFocusTraversableDefault() . |
com.droplets.api.GraphAnnotation.AnnotationProxy |
makeAnnotationProxy(GraphAnnotation a,
int orientation)
Makes the appropriate PlotProxy class for this graph type. |
com.droplets.api.PlotComponent.PlotProxy |
makePlotProxy(PlotComponent plot,
java.lang.String type)
Makes the appropriate PlotProxy class for this graph type. |
void |
notifyAddAnnotation(GraphAnnotation a)
|
void |
notifyAddPlot(PlotComponent plot)
|
void |
setAddedToWindow(boolean isAddedToWindow)
Window uses this to inform the component that it is added to a window |
void |
setBoolAttribute(java.lang.String name,
boolean value,
java.lang.String skinName)
Convenience method to set a boolean attribute. |
void |
setLegendHorizontalPosition(int halign,
int margin)
Sets the Horizontal position of the legend. |
void |
setLegendHorizontalPosition(int halign,
int margin,
java.lang.String skinName)
Sets the Horizontal position of the legend. |
void |
setLegendVerticalPosition(int halign,
int margin)
Sets the Vertical position of the legend. |
void |
setLegendVerticalPosition(int halign,
int margin,
java.lang.String skinName)
Sets the Vertical position of the legend. |
void |
setLegendVisible(boolean visible)
Sets the visibility of the legend |
void |
setLegendVisible(boolean visible,
java.lang.String skinName)
Sets the visibility of the legend |
void |
setStringAttribute(java.lang.String name,
java.lang.String value,
java.lang.String skinName)
Sets the value of an attribute. |
void |
setXAxisDataType(java.lang.String type)
Sets the type of the x-axis and x coordinate of the data points. |
void |
setXTickLabels(java.lang.String[] ticks)
Sets the x-tick labels |
void |
setXTickLabels(java.lang.String[] ticks,
java.lang.String skinName)
Sets the x-tick labels. |
void |
setYAxisDataType(java.lang.String type)
Sets the type of the x-axis and x coordinate of the data points. |
void |
setZoomable(boolean z)
Sets whether the graph is zoomable or not |
void |
setZoomable(boolean z,
java.lang.String skinName)
Sets whether the graph is zoomable or not |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.droplets.api.IGraph.GraphProxy |
isAddedToWindow |
Constructor Detail |
public Graph(LayoutPlacement lp, Window window)
Graph
area.p
- specifies how this component should be laid out in the
enclosing panel (see LayoutPlacement
)window
- the window in which this component will be placedMethod Detail |
public void addPlot(PlotComponent plot)
addPlot
in interface IGraph
public void addAnnotation(GraphAnnotation a)
addAnnotation
in interface IGraph
public void notifyAddPlot(PlotComponent plot)
notifyAddPlot
in interface IGraph.GraphProxy
public void notifyAddAnnotation(GraphAnnotation a)
notifyAddAnnotation
in interface IGraph.GraphProxy
public void addComponent(Component c)
addComponent
in class Panel
c
- the component to add to this Panelpublic void setAddedToWindow(boolean isAddedToWindow)
setAddedToWindow
in interface IGraph
isAddedToWindow
- true if the component is in a windowpublic java.lang.String getXAxisDataType()
getXAxisDataType
in interface IGraph
public void setXAxisDataType(java.lang.String type)
setXAxisDataType
in interface IGraph
type
- the type of the x-axis, chosen from the TYPE_* fields in this classpublic java.lang.String getYAxisDataType()
getYAxisDataType
in interface IGraph
public void setYAxisDataType(java.lang.String type)
setYAxisDataType
in interface IGraph
type
- the type of the x-axis, chosen from the TYPE_* fields in this classpublic boolean getLegendVisible()
getLegendVisible
in interface IGraph
public void setLegendVisible(boolean visible, java.lang.String skinName)
setLegendVisible
in interface IGraph
visible
- true if the legend should be visibleskinName
- the skinName of this settingpublic void setLegendVisible(boolean visible)
setLegendVisible
in interface IGraph
visible
- true if the legend should be visiblepublic int getLegendHorizontalAlignment()
getLegendHorizontalAlignment
in interface IGraph
public int getLegendHorizontalMargin()
getLegendHorizontalMargin
in interface IGraph
public void setLegendHorizontalPosition(int halign, int margin, java.lang.String skinName)
setLegendHorizontalPosition
in interface IGraph
halign
- either HALIGN_LEFT or HALIGN_RIGHTmargin
- the distance from the base position given by halign.skinName
- the skinName of this settingpublic void setLegendHorizontalPosition(int halign, int margin)
setLegendHorizontalPosition
in interface IGraph
halign
- either HALIGN_LEFT or HALIGN_RIGHTmargin
- the distance from the base position given by halign.public int getLegendVerticalAlignment()
getLegendVerticalAlignment
in interface IGraph
public int getLegendVerticalMargin()
getLegendVerticalMargin
in interface IGraph
public void setLegendVerticalPosition(int halign, int margin, java.lang.String skinName)
setLegendVerticalPosition
in interface IGraph
halign
- either HALIGN_LEFT or HALIGN_RIGHTmargin
- the distance from the base position given by halign.
Use negative numbers to be left of that position and positive to be rightskinName
- the skinName of this settingpublic void setLegendVerticalPosition(int halign, int margin)
setLegendVerticalPosition
in interface IGraph
halign
- either HALIGN_LEFT or HALIGN_RIGHTmargin
- the distance from the base position given by halign.
Use negative numbers to be left of that position and positive to be rightpublic java.lang.String[] getXTickLabels()
getXTickLabels
in interface IGraph
public void setXTickLabels(java.lang.String[] ticks, java.lang.String skinName)
setXTickLabels
in interface IGraph
ticks
- labels to use on the x-axisskinName
- the skinName of this settingpublic void setXTickLabels(java.lang.String[] ticks)
setXTickLabels
in interface IGraph
ticks
- labels to use on the x-axissetXTickLabels(String[], String)
public boolean getZoomable()
getZoomable
in interface IGraph
public void setZoomable(boolean z, java.lang.String skinName)
setZoomable
in interface IGraph
z
- true if the graph is zoomable, false otherwiseskinName
- the skinName of this settingpublic void setZoomable(boolean z)
setZoomable
in interface IGraph
z
- true if the graph is zoomable, false otherwiseprotected boolean isFocusTraversableDefault()
Component.isFocusTraversableDefault()
.isFocusTraversableDefault
in class Component
com.droplets.api.Component
Component.setFocusTraversable(boolean)
public void setStringAttribute(java.lang.String name, java.lang.String value, java.lang.String skinName)
Component
setStringAttribute
in interface IGraph.GraphProxy
setStringAttribute
in class Component
com.droplets.api.Component
name
- name of the attributevalue
- the desired valueskin
- the skin name to use for this attributepublic java.lang.String getStringAttribute(java.lang.String name, java.lang.String defaultValue)
Component
getStringAttribute
in interface IGraph.GraphProxy
getStringAttribute
in class Component
com.droplets.api.Component
name
- name of the attributedefaultValue
- the value to return if this attribute has not been
set. Note that if you pass in null, it will be interpreted as the
empty string - this method will never return null.defaultValue
argument if the attribute has no value.public void setBoolAttribute(java.lang.String name, boolean value, java.lang.String skinName)
Component
setBoolAttribute
in interface IGraph.GraphProxy
setBoolAttribute
in class Component
com.droplets.api.Component
name
- name of the attributevalue
- the desired valueskin
- the skin name to use for this attributepublic boolean getBoolAttribute(java.lang.String name, boolean defaultValue)
Component
getBoolAttribute
in interface IGraph.GraphProxy
getBoolAttribute
in class Component
com.droplets.api.Component
name
- name of the attributedefaultValue
- value to return if the attribute is not setpublic com.droplets.api.PlotComponent.PlotProxy makePlotProxy(PlotComponent plot, java.lang.String type)
makePlotProxy
in interface IGraph
plot
- the plot for which to make a proxytype
- the type of the plotpublic com.droplets.api.GraphAnnotation.AnnotationProxy makeAnnotationProxy(GraphAnnotation a, int orientation)
IGraph
makeAnnotationProxy
in interface IGraph
com.droplets.api.IGraph
plot
- the plot for which to make a proxytype
- the type of the plot
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |