Package org.meteoinfo.chart.plot
Class Plot2D
- java.lang.Object
-
- org.meteoinfo.chart.plot.Plot
-
- org.meteoinfo.chart.plot.AbstractPlot2D
-
- org.meteoinfo.chart.plot.Plot2D
-
public class Plot2D extends AbstractPlot2D
-
-
Field Summary
-
Fields inherited from class org.meteoinfo.chart.plot.AbstractPlot2D
background
-
Fields inherited from class org.meteoinfo.chart.plot.Plot
columnIndex, DEFAULT_BACKGROUND_ALPHA, DEFAULT_BACKGROUND_PAINT, DEFAULT_FOREGROUND_ALPHA, DEFAULT_LEGEND_ITEM_BOX, DEFAULT_LEGEND_ITEM_CIRCLE, DEFAULT_OUTLINE_PAINT, DEFAULT_OUTLINE_STROKE, isSubPlot, MINIMUM_HEIGHT_TO_DRAW, MINIMUM_WIDTH_TO_DRAW, outerPosition, position, rowIndex, symbolAntialias, units
-
-
Constructor Summary
Constructors Constructor Description Plot2D()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddGraphic(int idx, Graphic g)Add a graphic by indexvoidaddGraphic(Graphic g)Add a graphicvoidaddGraphics(java.util.List<Graphic> gs)Add graphic listfloatgetBarsWidth()Get bars width (0 - 1), only used for automatic bar width.DatasetgetDataset()Get datasetjava.awt.RectanglegetGraphicRectangle(java.awt.Graphics2D g, Graphic aGraphic, java.awt.geom.Rectangle2D area)Get graphic rectangleGraphicCollectiongetGraphics()Get graphicsLegendSchemegetLegendScheme()Get legend schemevoidremoveGraphic(int idx)Remove a graphic by indexvoidremoveGraphic(Graphic g)Remove a graphicvoidremoveLastGraphic()Remove last graphicvoidsetAutoExtent()Set auto extentvoidsetBarsWidth(float value)Set bars width (0 - 1), only used for automatic bar width.voidsetDataset(Dataset dataset)Set datasetvoidsetGraphics(GraphicCollection value)Set graphicsvoidupdateLegendScheme()-
Methods inherited from class org.meteoinfo.chart.plot.AbstractPlot2D
addLegend, addText, draw, getAspect, getAxis, getBackground, getDrawExtent, getExtent, getGraphArea, getGridLine, getLeftTitle, getLegend, getLegend, getLegends, getOuterPositionArea, getPlotOrientation, getPlotType, getPositionArea, getRightTitle, getSelectedColor, getTexts, getTightInset, getTightInsetArea, getTitle, getWindArrow, getXAxis, getXAxisLocation, getYAxis, getYAxisLocation, isAutoAspect, isDrawNeatLine, isDrawRightAxis, isDrawTopAxis, isInsideTick, isLogX, isLogY, isXReverse, isYReverse, projToScreen, projXLength, projYLength, removeLegend, removeLegend, screenToProj, setAspect, setAutoAspect, setAxis, setAxisLabelFont, setAxisOn, setBackground, setDrawExtent, setDrawExtent1, setDrawLegend, setDrawNeatLine, setDrawRightAxis, setDrawTopAxis, setExtent, setInsideTick, setLeftTitle, setLeftTitle, setLegend, setLegends, setPlotOrientation, setRightTitle, setRightTitle, setSelectedColor, setTexts, setTitle, setTitle, setWindArrow, setXAxis, setXAxisLocation, setYAxis, setYAxisLocation, updateDrawExtent, zoomToExtentScreen
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from class org.meteoinfo.chart.plot.Plot
getGraphArea, getOuterPosition, getOuterPositionArea, getPlotShrink, getPosition, getPositionArea, getPositionArea, getPositionAreaZoom, getTightInset, getUnits, isOuterPosActive, isSameShrink, isSymbolAntialias, setGraphArea, setOuterPosActive, setOuterPosition, setOuterPosition, setOuterPosition, setOuterPositionArea, setPlotShrink, setPosition, setPosition, setPosition, setPositionArea, setPositionAreaZoom, setSameShrink, setSymbolAntialias, setTightInset, setUnits, setUnits, updatePosition, updatePosition, updatePositionArea, updatePostionAreaZoom
-
-
-
-
Method Detail
-
getGraphics
public GraphicCollection getGraphics()
Get graphics- Returns:
- Graphics
-
setGraphics
public void setGraphics(GraphicCollection value)
Set graphics- Parameters:
value- Graphics
-
getBarsWidth
public float getBarsWidth()
Get bars width (0 - 1), only used for automatic bar width.- Returns:
- Bars width
-
setBarsWidth
public void setBarsWidth(float value)
Set bars width (0 - 1), only used for automatic bar width.- Parameters:
value- Bars width
-
addGraphic
public void addGraphic(Graphic g)
Add a graphic- Parameters:
g- Grahic
-
addGraphic
public void addGraphic(int idx, Graphic g)Add a graphic by index- Parameters:
idx- Indexg- Graphic
-
removeGraphic
public void removeGraphic(Graphic g)
Remove a graphic- Parameters:
g- Graphic
-
removeGraphic
public void removeGraphic(int idx)
Remove a graphic by index- Parameters:
idx- Index
-
removeLastGraphic
public void removeLastGraphic()
Remove last graphic
-
addGraphics
public void addGraphics(java.util.List<Graphic> gs)
Add graphic list- Parameters:
gs- Graphic list
-
getGraphicRectangle
public java.awt.Rectangle getGraphicRectangle(java.awt.Graphics2D g, Graphic aGraphic, java.awt.geom.Rectangle2D area)Get graphic rectangle- Parameters:
g- The graphicsaGraphic- The graphicarea- Area- Returns:
- Rectangle
-
setAutoExtent
public void setAutoExtent()
Set auto extent- Specified by:
setAutoExtentin classAbstractPlot2D
-
updateLegendScheme
public void updateLegendScheme()
- Specified by:
updateLegendSchemein classAbstractPlot2D
-
getDataset
public Dataset getDataset()
Description copied from class:PlotGet dataset- Specified by:
getDatasetin classPlot- Returns:
- Dataset
-
setDataset
public void setDataset(Dataset dataset)
Description copied from class:PlotSet dataset- Specified by:
setDatasetin classPlot- Parameters:
dataset- Dataset
-
getLegendScheme
public LegendScheme getLegendScheme()
Get legend scheme- Returns:
- Legend scheme
-
-