|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Canvas
|
+--edu.davidson.graph.Graph2D
|
+--edu.davidson.display.SGraph
|
+--edu.davidson.display.SContour
This class extends the graphics class Graph2D to incorporate contouring.
| Field Summary | |
boolean |
noContours
Boolean value if true Contours will not be calculated |
| Fields inherited from class edu.davidson.graph.Graph2D |
borderBottom,
borderLeft,
borderRight,
borderTop,
clearAll,
datarect,
drawgrid,
drawzero,
frame,
framecolor,
gridcolor,
lastText,
loadingData,
paintAll,
square,
zerocolor |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
| Constructor Summary | |
SContour()
Instantaite the class |
|
| Method Summary | |
void |
attachContours()
Attach contours so that they will be plotted. |
void |
calculateCurve(double aLevel)
|
void |
createSampleData()
|
void |
deleteAllSeries()
Delete all series from the graph. |
void |
deleteContours()
Delete all the Contours |
void |
detachContours()
Detach contours so that they will not be plotted. |
int[] |
getDim()
return the dimensions of the grid |
double[] |
getGrid()
Return the grid |
int |
getLabelPrecision()
Get the label precision. |
int |
getLabelSignificance()
Get the number of significant figures for labels. |
int |
getLabelStyle()
Get the label style, either TextLine.SCIENTIFIC or TextLine.ALGEBRAIC. |
double[] |
getLevels()
Return the contour levels. |
double[] |
getRange()
Return the range of the grid |
void |
jbInit()
|
void |
paintFirst(java.awt.Graphics g,
java.awt.Rectangle r)
|
void |
paintLast(java.awt.Graphics g,
java.awt.Rectangle rect)
A hook into the Graph2D.paint method. |
void |
setAutoLevels(boolean b)
If true contour levels are calculated automatically. |
void |
setContourColor(java.awt.Color c)
Set the contour's color. |
void |
setDrawLabels(boolean b)
If true contour levels are not labeled. |
void |
setGrid(double[][] newGrid)
Set the grid to be contoured. |
void |
setGrid(double[][] newGrid,
double _xmin,
double _xmax,
double _ymin,
double _ymax)
|
void |
setGrid(double[] grid,
int nx,
int ny)
Set the grid to be contoured. |
void |
setLabelColor(java.awt.Color c)
Set the Color to be used with all the labels. |
void |
setLabelFont(java.awt.Font f)
Set the font to be used with All the labels |
void |
setLabelledContourColor(java.awt.Color c)
Set the labelled contour's color. |
void |
setLabelLevels(int i)
Set the contour levels that are to have labels. |
void |
setLabelPrecision(int p)
Set the label precision. |
void |
setLabels(edu.davidson.graph.TextLine[] labels,
int nl)
Manually set the Contour labels. |
void |
setLabelSignificance(int s)
Set the label significant figures. |
void |
setLabelStyle(int s)
Set the label style, either TextLine.SCIENTIFIC or TextLine.ALGEBRAIC. |
void |
setLevels(double[] levels,
int nl)
Manually set the contour levels. |
void |
setLimitsToGrid(boolean b)
If true the limits of the plot will be the grid limits. |
void |
setLogLevels(boolean b)
If true contour levels are calculated on a log scale. |
void |
setNLevels(int l)
Set the number of contour levels. |
void |
setNoContours(boolean nc)
Do not draw contours |
void |
setRange(double xmin,
double xmax,
double ymin,
double ymax)
Set the range of the grid |
| Methods inherited from class edu.davidson.graph.Graph2D |
attachAxis,
attachDataSet,
createAxis,
detachAxes,
detachAxis,
detachDataSet,
detachDataSets,
finishedloading,
getDataBackground,
getMarkers,
getXmax,
getXmin,
getYmax,
getYmin,
isShowAxis,
loadDataSet,
loadFile,
loadmessage,
paint,
paint,
paintBeforeData,
setDataBackground,
setGraphBackground,
setMarkers,
setShowAxis,
startedloading,
update |
| Methods inherited from class java.awt.Canvas |
addNotify,
getAccessibleContext |
| Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addHierarchyBoundsListener,
addHierarchyListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
contains,
contains,
createImage,
createImage,
deliverEvent,
disable,
dispatchEvent,
doLayout,
enable,
enable,
enableInputMethods,
getAlignmentX,
getAlignmentY,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentAt,
getComponentAt,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getGraphicsConfiguration,
getHeight,
getInputContext,
getInputMethodRequests,
getListeners,
getLocale,
getLocation,
getLocation,
getLocationOnScreen,
getMaximumSize,
getMinimumSize,
getName,
getParent,
getPeer,
getPreferredSize,
getSize,
getSize,
getToolkit,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
invalidate,
isDisplayable,
isDoubleBuffered,
isEnabled,
isFocusTraversable,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
layout,
list,
list,
list,
list,
list,
locate,
location,
lostFocus,
minimumSize,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
postEvent,
preferredSize,
prepareImage,
prepareImage,
print,
printAll,
remove,
removeComponentListener,
removeFocusListener,
removeHierarchyBoundsListener,
removeHierarchyListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removeNotify,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setEnabled,
setFont,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus,
validate |
| Methods inherited from class java.lang.Object |
equals,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
| Field Detail |
public boolean noContours
| Constructor Detail |
public SContour()
| Method Detail |
public void setRange(double xmin,
double xmax,
double ymin,
double ymax)
xmin - Minimum X valuexmax - Maximum X valueymin - Minimum Y valueymax - Maximum Y valuepublic void setNoContours(boolean nc)
no - contourspublic double[] getRange()
public int[] getDim()
public double[] getGrid()
public void setLevels(double[] levels,
int nl)
levels - An array containing the contour levelsnl - The number of contour levels in the arrray
public void setLabels(edu.davidson.graph.TextLine[] labels,
int nl)
labels - An array containing the labels.nl - Number of labels in the Array.public void setLabelFont(java.awt.Font f)
f - Fontpublic void setLabelColor(java.awt.Color c)
c - Color
public void setGrid(double[] grid,
int nx,
int ny)
grid - Array of valuesnx - Number of columnsny - Number of rowspublic void setGrid(double[][] newGrid)
grid - Array of double[][]
public void setGrid(double[][] newGrid,
double _xmin,
double _xmax,
double _ymin,
double _ymax)
public void deleteContours()
public void detachContours()
public void attachContours()
public void setContourColor(java.awt.Color c)
c - Colorpublic void setLabelledContourColor(java.awt.Color c)
c - Colorpublic double[] getLevels()
public void setLimitsToGrid(boolean b)
b - booleanpublic void setLabelLevels(int i)
if 0 no labels are drawn
if 1 every level gets a label
If 2 every 2nd level gets a label
etc.
public void setLogLevels(boolean b)
b - booleanpublic void setNLevels(int l)
public void setAutoLevels(boolean b)
b - booleanpublic void setDrawLabels(boolean b)
b - booleanpublic void setLabelStyle(int s)
s - Stylepublic int getLabelStyle()
public void setLabelPrecision(int p)
s - Precisionpublic int getLabelPrecision()
public void setLabelSignificance(int s)
s - number of significant figurespublic int getLabelSignificance()
public void paintFirst(java.awt.Graphics g,
java.awt.Rectangle r)
public void paintLast(java.awt.Graphics g,
java.awt.Rectangle rect)
public void calculateCurve(double aLevel)
public void deleteAllSeries()
public void createSampleData()
public void jbInit()
throws java.lang.Exception
|
Copyright Wolfgang Christian | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||