Package org.esa.snap.ui.diagram
Class Diagram
- java.lang.Object
-
- org.esa.snap.ui.diagram.Diagram
-
public class Diagram extends Object
TheDiagram
class is used to plot simple X/Y graphs. Instances of this class are composed of
and twoDiagramGraph
objects for the X and Y axes.DiagramAxis
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Diagram.RectTransform
-
Field Summary
Fields Modifier and Type Field Description static Color
DEFAULT_BACKGROUND_COLOR
static String
DEFAULT_FONT_NAME
static int
DEFAULT_FONT_SIZE
static Color
DEFAULT_FOREGROUND_COLOR
-
Constructor Summary
Constructors Constructor Description Diagram()
Diagram(DiagramAxis xAxis, DiagramAxis yAxis, DiagramGraph graph)
-
Method Summary
-
-
-
Field Detail
-
DEFAULT_FONT_NAME
public static final String DEFAULT_FONT_NAME
- See Also:
- Constant Field Values
-
DEFAULT_FONT_SIZE
public static final int DEFAULT_FONT_SIZE
- See Also:
- Constant Field Values
-
DEFAULT_FOREGROUND_COLOR
public static final Color DEFAULT_FOREGROUND_COLOR
-
DEFAULT_BACKGROUND_COLOR
public static final Color DEFAULT_BACKGROUND_COLOR
-
-
Constructor Detail
-
Diagram
public Diagram()
-
Diagram
public Diagram(DiagramAxis xAxis, DiagramAxis yAxis, DiagramGraph graph)
-
-
Method Detail
-
enableChangeEventMerging
public void enableChangeEventMerging()
-
disableChangeEventMerging
public void disableChangeEventMerging()
-
getTransform
public Diagram.RectTransform getTransform()
-
getDrawGrid
public boolean getDrawGrid()
-
setDrawGrid
public void setDrawGrid(boolean drawGrid)
-
getXAxis
public DiagramAxis getXAxis()
-
setXAxis
public void setXAxis(DiagramAxis xAxis)
-
getYAxis
public DiagramAxis getYAxis()
-
setYAxis
public void setYAxis(DiagramAxis yAxis)
-
getGraphs
public DiagramGraph[] getGraphs()
-
getGraphCount
public int getGraphCount()
-
getGraph
public DiagramGraph getGraph(int index)
-
addGraph
public void addGraph(DiagramGraph graph)
-
removeGraph
public void removeGraph(DiagramGraph graph)
-
removeAllGraphs
public void removeAllGraphs()
-
getFont
public Font getFont()
-
setFont
public void setFont(Font font)
-
getMajorGridColor
public Color getMajorGridColor()
-
setMajorGridColor
public void setMajorGridColor(Color majorGridColor)
-
getMinorGridColor
public Color getMinorGridColor()
-
setMinorGridColor
public void setMinorGridColor(Color minorGridColor)
-
getForegroundColor
public Color getForegroundColor()
-
setForegroundColor
public void setForegroundColor(Color foregroundColor)
-
getBackgroundColor
public Color getBackgroundColor()
-
setBackgroundColor
public void setBackgroundColor(Color backgroundColor)
-
getTextGap
public int getTextGap()
-
setTextGap
public void setTextGap(int textGap)
-
isValid
public boolean isValid()
-
setValid
public void setValid(boolean valid)
-
invalidate
public void invalidate()
-
getGraphArea
public Rectangle getGraphArea()
-
render
public void render(Graphics2D g2d, int x, int y, int width, int height)
-
getClosestGraph
public DiagramGraph getClosestGraph(int x, int y)
-
adjustAxes
public void adjustAxes(boolean reset)
-
adjustAxes
protected void adjustAxes(DiagramGraph graph)
-
resetMinMaxAccumulators
public void resetMinMaxAccumulators()
-
resetMinMaxAccumulatorsFromAxes
public void resetMinMaxAccumulatorsFromAxes()
-
getChangeListeners
public DiagramChangeListener[] getChangeListeners()
-
addChangeListener
public void addChangeListener(DiagramChangeListener listener)
-
removeChangeListener
public void removeChangeListener(DiagramChangeListener listener)
-
dispose
public void dispose()
-
-