kcl.waterloo.graphics.plots2D
Class GJBox
- java.lang.Object
-
- kcl.waterloo.observable.GJAbstractObservable
-
- kcl.waterloo.graphics.plots2D.GJAbstractPlotModelImpl
-
- kcl.waterloo.graphics.plots2D.GJAbstractPlot
-
- kcl.waterloo.graphics.plots2D.GJBox
-
- All Implemented Interfaces:
- java.beans.PropertyChangeListener, java.util.EventListener, GJEffectorInterface, GJFastPlotInterface, GJPlotInterface, GJLinkableInterface, GJObservableInterface, GJDataModelInterface<java.awt.geom.Rectangle2D,GJGraphInterface>, GJFillableInterface<java.awt.Shape,java.awt.Paint>, GJScreenDataInterface<java.awt.Shape>, GJVisualsInterface<GJMarker,java.awt.Paint,java.awt.BasicStroke,java.awt.Dimension,java.awt.Shape>
public abstract class GJBox extends GJAbstractPlot
Abstract class that is extended by box-style concrete classes such as GJBar. Subclasses should implement the painting mechanism.
-
-
Field Summary
-
Fields inherited from class kcl.waterloo.graphics.plots2D.GJAbstractPlotModelImpl
screenDataArray
-
-
Constructor Summary
Constructors Constructor and Description GJBox()GJBox(GJAbstractPlot p)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.util.ArrayList<java.awt.Shape>createBoxes(double[] x, double[] y)Returns an ArrayList of rectangles as Path2D instances.java.awt.geom.Rectangle2DgetDataRange()getDataRange returns the range on the X and Y axes that can potentially be filled by the data points given the current contents of the XData and YData properties.-
Methods inherited from class kcl.waterloo.graphics.plots2D.GJAbstractPlot
add, createFrame, findPlotBelow, findPlotBelow, getAreaFill, getAreaPaint, getEffect, getFillable, getFillAlpha, getFillComposite, getNode, getParentPlot, getPlots, getTopPlot, getVisualRange, intersects, intersects, isMultiplexible, isOnEDT, isSelected, isShowing, isTopPlot, isVisible, paintPlot, paintPlotEntry, plotRedraw, plotRedraw, plotUpdate, plotUpdate, plus, propertyChange, saveAsXML, setAntialiasing, setAreaFill, setAreaPaint, setEffect, setFillAlpha, setFillComposite, setParentPlot, setSelected, setSelectionFlag, setVisible, toString, toString
-
Methods inherited from class kcl.waterloo.graphics.plots2D.GJAbstractPlotModelImpl
getAlpha, getCompositeMode, getDataModel, getDynamicMarkerSize, getEdgeColor, getEdgeStroke, getFill, getLineColor, getLineStroke, getMarker, getMarkerArray, getMultiplexLength, getName, getParentGraph, getPlotList, getRenderHintState, getScreenDataArray, getScreenDataArrayAsCopy, getTextHintState, getVisualModel, getXData, getXDataValues, getXTransform, getYData, getYDataValues, getYTransform, isMultiplexed, setAlpha, setCompositeMode, setData, setDataModel, setDynamicMarkerSize, setEdgeColor, setEdgeColor, setEdgeColor, setEdgeColor, setEdgeColor, setEdgeStroke, setEdgeStroke, setEdgeStroke, setEdgeStroke, setEdgeStroke, setExtraData0, setExtraData1, setExtraData2, setExtraData3, setFill, setFill, setFill, setFill, setFill, setLineColor, setLineColor, setLineColor, setLineColor, setLineStroke, setLineStroke, setLineStroke, setLineStroke, setLineStroke, setMarker, setMarker, setMarkerArray, setMarkerArray, setMarkerArray, setName, setName, setParentGraph, setPlotList, setRenderHintState, setScreenDataArray, setTextHintState, setVisualModel, setXData, setXData, setXData, setXData, setXData, setYData, setYData, setYData, setYData, setYData
-
Methods inherited from class kcl.waterloo.observable.GJAbstractObservable
addLink, addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, getLinks, getPCS, getPropertyChangeListeners, getPropertyChangeListeners, hasListeners, hasSelfListener, removeLink, removePropertyChangeListener, removePropertyChangeListener, setLinks
-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface kcl.waterloo.observable.GJObservableInterface
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, getPropertyChangeListeners, getPropertyChangeListeners, hasListeners, hasSelfListener, removePropertyChangeListener, removePropertyChangeListener
-
Methods inherited from interface kcl.waterloo.observable.GJLinkableInterface
addLink, getLinks, removeLink, setLinks
-
-
-
-
Constructor Detail
-
GJBox
public GJBox()
-
GJBox
public GJBox(GJAbstractPlot p)
-
-
Method Detail
-
createBoxes
public final java.util.ArrayList<java.awt.Shape> createBoxes(double[] x, double[] y)Returns an ArrayList of rectangles as Path2D instances. The position of each rectangle is set by the values in the XData property and the height by the YData values.- Parameters:
x- the x datay- the y data- Returns:
- an ArrayList
, each element of which describes a rectangle
-
getDataRange
public final java.awt.geom.Rectangle2D getDataRange()
Description copied from class:GJAbstractPlotgetDataRange returns the range on the X and Y axes that can potentially be filled by the data points given the current contents of the XData and YData properties. Note that this is not necessarily the same as the range of the data contained in the XData and YData properties (although it often will be for a simple Cartesian plot). getVisualRange can be used instead to assess the required axes limits needed to render the data given e.g. the set marker size etc. However, getVisualRange can only be used to update the display: it requires that data have already been rendered to screen at least once.- Specified by:
getDataRangein interfaceGJDataModelInterface<java.awt.geom.Rectangle2D,GJGraphInterface>- Overrides:
getDataRangein classGJAbstractPlot- Returns:
- a Rectangle2D instance
-
-
DMelt 3.0 © DataMelt by jWork.ORG