Package gov.nih.mipav.view
Class ViewJFrameGraph
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- java.awt.Window
-
- java.awt.Frame
-
- javax.swing.JFrame
-
- gov.nih.mipav.view.ViewJFrameGraph
-
- All Implemented Interfaces:
java.awt.event.ActionListener
,java.awt.event.ComponentListener
,java.awt.event.WindowListener
,java.awt.image.ImageObserver
,java.awt.MenuContainer
,java.io.Serializable
,java.util.EventListener
,javax.accessibility.Accessible
,javax.swing.event.ChangeListener
,javax.swing.RootPaneContainer
,javax.swing.WindowConstants
public class ViewJFrameGraph extends javax.swing.JFrame implements java.awt.event.ComponentListener, java.awt.event.ActionListener, javax.swing.event.ChangeListener, java.awt.event.WindowListener
This is a frame which holds a graph in one panel and a set of user buttons in the other. It uses swing components for all of the graphics and calls ViewJComponentGraph for the graph.- Version:
- 1.0 Aug 1, 1999
- Author:
- Neva Cherniavsky (primary), Harman Singh aev* @see ViewJComponentGraph
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) class
ViewJFrameGraph.bColorListener
This class is called by the color chooser when the user selects a a color from the background color chooser dialog box.(package private) class
ViewJFrameGraph.CancelListener
This class is called by the color chooser when the user cancels.(package private) class
ViewJFrameGraph.ColorListener
This class is called by the color chooser when the user selects a a color from the function line color chooser dialog.static class
ViewJFrameGraph.FitMode
-
Nested classes/interfaces inherited from class javax.swing.JFrame
javax.swing.JFrame.AccessibleJFrame
-
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow, java.awt.Window.Type
-
-
Field Summary
Fields Modifier and Type Field Description private boolean
autoShrinkDomain
private javax.swing.JCheckBox
autoShrinkDomainCheckbox
private boolean
autoShrinkRange
DOCUMENT ME!private javax.swing.JCheckBox
autoShrinkRangeCheckbox
DOCUMENT ME!private javax.swing.JPanel
axisPanel
DOCUMENT ME!private javax.swing.JButton
backgroundButton
DOCUMENT ME!private javax.swing.JLabel
backgroundLabel
DOCUMENT ME!private javax.swing.JPanel
backgroundPanel
DOCUMENT ME!private javax.swing.JTextField
binsField
private ViewJColorChooser
colorChooser
DOCUMENT ME!private javax.swing.JDialog
colorDialog
DOCUMENT ME!private javax.swing.JMenu
copyMenu
DOCUMENT ME!private java.lang.String
defaultDirectory
DOCUMENT ME!private javax.swing.JMenu
deleteMenu
DOCUMENT ME!private boolean
doLogX
private boolean
doLogY
private javax.swing.JPanel
domainPanel
private javax.swing.JMenu
editMenu
DOCUMENT ME!private boolean
entireImage
private javax.swing.JMenu
fileMenu
DOCUMENT ME!private javax.swing.JPanel
fitFunctPanel
DOCUMENT ME!private javax.swing.JPanel
fitFunctTypePanel
DOCUMENT ME!private javax.swing.JCheckBox[]
fitFunctVisibleCheckbox
DOCUMENT ME!private javax.swing.JPanel
fitFunctVisiblePanel
DOCUMENT ME!private ViewJFrameGraph.FitMode
fitMode
Current mode for fitting functionsprivate javax.swing.JComboBox
fitType
Combo box for selecting the fitting function typeprivate VOI
frameGraphVOI
DOCUMENT ME!private int
functionIndex
DOCUMENT ME!private javax.swing.JLabel[]
functionLabel
DOCUMENT ME!private javax.swing.JPanel
functionPropPanel
DOCUMENT ME!private javax.swing.JButton[]
functLineColorButton
DOCUMENT ME!private javax.swing.JCheckBox[]
functVisibleCheckbox
the slope changes.private ViewJComponentGraph
graph
DOCUMENT ME!private javax.swing.JCheckBox
gridlinesCheckbox
DOCUMENT ME!private javax.swing.JPanel
gridPanel
DOCUMENT ME!private javax.swing.JPanel
histogramPanel
private ModelImage
image
private double
imageMax
private double
imageMin
private int
initialSummaryBins
private double
initialUserMax
private double
initialUserMin
private javax.swing.JMenuItem
itemClose
DOCUMENT ME!private javax.swing.JMenuItem
itemModifyGraph
DOCUMENT ME!private javax.swing.JMenuItem
itemNormalize
DOCUMENT ME!private javax.swing.JMenuItem
itemOpenNewGraph
private javax.swing.JMenuItem
itemOpenSameGraph
DOCUMENT ME!private javax.swing.JMenuItem
itemPasteFunct
DOCUMENT ME!private javax.swing.JMenuItem
itemPrintGraph
DOCUMENT ME!private javax.swing.JMenuItem
itemResetDomain
private javax.swing.JMenuItem
itemResetGraph
DOCUMENT ME!private javax.swing.JMenuItem
itemResetRange
DOCUMENT ME!private javax.swing.JMenuItem
itemSaveGraph
DOCUMENT ME!private javax.swing.JMenuItem
itemTableOutput
private java.lang.String
lastUnits
DOCUMENT ME!private javax.swing.JCheckBox
legendCheckbox
DOCUMENT ME!private javax.swing.JPanel
legendPanel
DOCUMENT ME!private javax.swing.JRadioButton
linesOnlyButton
DOCUMENT ME!private javax.swing.JCheckBox
logScaleCheckboxX
private javax.swing.JCheckBox
logScaleCheckboxY
private javax.swing.JPanel
mainPanel
DOCUMENT ME!private int
maxBins
private javax.swing.JTextField
maxDomainField
private javax.swing.JLabel
maxDomainLabel
private javax.swing.JTextField
maxField
private javax.swing.JTextField
maxRangeField
DOCUMENT ME!private javax.swing.JLabel
maxRangeLabel
DOCUMENT ME!private javax.swing.JTextField
minDomainField
private javax.swing.JLabel
minDomainLabel
private javax.swing.JTextField
minField
private static int
MINIMUM_HEIGHT
Minimum height of the graph panelprivate static int
MINIMUM_WIDTH
Minimum width of the graph panelprivate javax.swing.JCheckBox
minorTickMarksCheckbox
DOCUMENT ME!private javax.swing.JTextField
minRangeField
DOCUMENT ME!private javax.swing.JLabel
minRangeLabel
DOCUMENT ME!private javax.swing.JDialog
modifyDialog
DOCUMENT ME!private javax.swing.JPanel
modifyGraphPanel
DOCUMENT ME!private javax.swing.JTextField[]
nameField
DOCUMENT ME!private int
numVariables
private javax.swing.JTextField
numVariablesField
private javax.swing.JLabel
numVariablesLabel
private javax.swing.JMenuBar
openingMenuBar
DOCUMENT ME!private static int
PANEL_OFFSET
Minimum distance between frame and subpanelsprivate javax.swing.JRadioButton
pointsAndLinesButton
private javax.swing.ButtonGroup
pointsAndLinesGroup
private javax.swing.JRadioButton
pointsOnlyButton
private javax.swing.JPanel
pointsVisiblePanel
DOCUMENT ME!private javax.swing.JPanel
rangePanel
DOCUMENT ME!private javax.swing.JButton
resetDomainButton
private javax.swing.JButton
resetRangeButton
DOCUMENT ME!private int
RGBOffset
private static long
serialVersionUID
Use serialVersionUID for interoperability.private javax.swing.JPanel
showPanel
DOCUMENT ME!private int
summaryBins
private javax.swing.JTabbedPane
tabbedPane
DOCUMENT ME!private javax.swing.JTextField
titleField
DOCUMENT ME!private javax.swing.JLabel
titleLabel
DOCUMENT ME!private java.lang.String
units
DOCUMENT ME!private int
updateRGBIndex
DOCUMENT ME!private double
userMax
private double
userMin
private java.util.Vector<javax.swing.JMenuItem>
vectorCopyFunct
DOCUMENT ME!private java.util.Vector<javax.swing.JMenuItem>
vectorDeleteFunct
DOCUMENT ME!private javax.swing.JMenu
viewMenu
DOCUMENT ME!private VOI
voi
DOCUMENT ME!private javax.swing.JLabel
xAxisLabel
DOCUMENT ME!private javax.swing.JTextField
xAxisLabelField
DOCUMENT ME!private javax.swing.ButtonGroup
xGridButtonGroup
private javax.swing.JCheckBox[]
xGridCheckBoxList
private javax.swing.JPanel
xGridCheckBoxPanel
private javax.swing.JRadioButton
xGridEvenSpacedButton
private javax.swing.JTextField
xGridLineField
DOCUMENT ME!private javax.swing.JLabel
xGridLineLabel
DOCUMENT ME!private javax.swing.JScrollPane
xGridScrollPane
private javax.swing.JRadioButton
xGridUserSpacedButton
private int[][]
xyCoords
this is a list of the x,y coords of the voi's boundaryprivate javax.swing.JLabel
yAxisLabel
DOCUMENT ME!private javax.swing.JTextField
yAxisLabelField
DOCUMENT ME!private javax.swing.ButtonGroup
yGridButtonGroup
private javax.swing.JCheckBox[]
yGridCheckBoxList
private javax.swing.JPanel
yGridCheckBoxPanel
private javax.swing.JRadioButton
yGridEvenSpacedButton
private javax.swing.JTextField
yGridLineField
DOCUMENT ME!private javax.swing.JLabel
yGridLineLabel
DOCUMENT ME!private javax.swing.JScrollPane
yGridScrollPane
private javax.swing.JRadioButton
yGridUserSpacedButton
-
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
-
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
-
-
Constructor Summary
Constructors Constructor Description ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[][] x, float[][] y, java.lang.String title, VOI v)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, VOI v, java.lang.String units)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, java.awt.Color[] colorArray)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, int[][] xyCoords)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] x, float[] y, java.lang.String title, VOI v)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, VOI v, java.lang.String units, int[][] xyCoords)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, boolean visible)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, java.awt.Color color)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(ModelImage image, int RGBOffset, boolean entireImage, int initialSummaryBins, double initialUserMin, double initialUserMax, float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.ViewJFrameGraph(java.lang.String title, boolean openFileGUI)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
actionPerformed(java.awt.event.ActionEvent event)
Takes the action commands and paints if the apply button is pressed, closes if the close button is pressed.private void
buildFitFunctPanel()
Creates a panel to edit various fitted function features.private void
buildFunctionPanel()
Creates a panel where various features of the functions can be edited, such as showing the legend, and changing function names.private void
buildMenu()
Function that builds the menu of various tools to be used in conjunction with the graph. ie: opening / saving files, changing gridlines, title / axis labels, etc.private void
buildModifyGraphPanel()
Creats a panel where various featuers of the graph can be edited, such as visbility of gridlines and minor tick marks, number of gridlines, background color, range, and labels for the title, x and y axiis.void
componentHidden(java.awt.event.ComponentEvent event)
DOCUMENT ME!void
componentMoved(java.awt.event.ComponentEvent event)
DOCUMENT ME!void
componentResized(java.awt.event.ComponentEvent event)
Resets the bounds of component graph if the window is resized.void
componentShown(java.awt.event.ComponentEvent event)
DOCUMENT ME!private void
createModifyDialog()
Creates a dialog box in which the user can modify various features of the graph.void
deleteFunct(int index)
Deletes the indicated function from the graph.private void
fitFunctions(ViewJFrameGraph.FitMode mode)
void
focusGained(java.awt.event.FocusEvent event)
Unchanged.void
focusLost(java.awt.event.FocusEvent event)
Unchanged.java.lang.String
getDefaultDirectory()
Accessor that gets the default directory.java.awt.Graphics
getFrameGraphics()
ViewJComponentGraph
getGraph()
private float
getMedian(float[] toSort)
DOCUMENT ME!void
itemStateChanged(java.awt.event.ItemEvent event)
Unchanged.void
makeRangeSymmetric()
DOCUMENT ME!boolean
openNew()
Opens Excel data (tab-delimited fields) into a new graph.boolean
openSame()
Opens Excel data (tab-delimited fields) into this graph.private float[]
parseString(java.lang.String s, int len)
DOCUMENT ME!private void
print()
Prints the current graph being displayed to the printer.void
removeComponentListener()
void
replaceFunction(float[] newX, float[] newY)
Replaces the function used with a line image.void
replaceFunction(float[] newX, float[] newY, int[][] newXYCoords, VOI myVoi, int index)
Replaces the function used with a line image.void
save()
Saves this graph as Excel data so that Excel can read in the data and graph it as an Excel file.void
save(java.lang.String fileName)
Saves this graph as Excel data so that Excel can read in the data and graph it as an Excel file.void
saveNewFunction(float[][] newX, float[][] newY, int ptIndex)
Replaces the first three functions (used with RGB images).void
saveNewFunction(float[] newX, float[] newY, int index)
Saves the current function and adds a blank new function.void
setDefaultDirectory(java.lang.String dir)
Accessor that sets the default directory.void
setLabels(java.lang.String labelX, java.lang.String labelY)
Sets the axis labels.void
setLabelY(java.lang.String labelY)
void
setResetEnabled(boolean enabled)
Accessor that enables or disables the reset item.void
setUnitsInLabel(java.lang.String units)
Sets the units in the default axis labels.void
setVisible(boolean status)
Makes the dialog visible in center of screen.void
setVisibleNoLocChange(boolean status)
Makes the dialog visible without setting position.void
setVOI(VOI v)
Accessor that sets the VOI ViewJFrameGraph was made from.void
showXYZLegends()
DOCUMENT ME!void
stateChanged(javax.swing.event.ChangeEvent e)
ChangeListener************************************************************************* /** Sets values based on knob along sliderprivate void
tableOutput()
private boolean
testMaxParameter(java.lang.String str, float maxValue)
Tests that the entered parameter is above maxValue.private boolean
testMinParameter(java.lang.String str, float minValue)
Tests that the entered parameter is below minValue.private boolean
testParameter(java.lang.String str, int minValue, int maxValue)
Tests that the entered parameter is in range.void
update(float[][] x, float[][] y, int ptIndex)
Updates the graph by changing the plot to the desired new 3 functions (RGB).void
update(float[] x, float[] y, int j)
Updates the graph by changing the plot to the desired new function / intensity plot.void
update(java.awt.Graphics g)
Calls paint instead of erasing.void
updateFittedFunctions()
Deprecated.If data were changed, this could be useful to refit data without pressing a new button, but this function is not currently utilized.private void
updateModifyDialog()
Updates fields of the Modify Graph Dialog which may have changed due to things such as adding/deleting functions.void
windowActivated(java.awt.event.WindowEvent event)
Unchanged.void
windowClosed(java.awt.event.WindowEvent event)
Unchanged.void
windowClosing(java.awt.event.WindowEvent event)
Disposes of error dialog, then frame.void
windowDeactivated(java.awt.event.WindowEvent event)
Unchanged.void
windowDeiconified(java.awt.event.WindowEvent event)
Unchanged.void
windowIconified(java.awt.event.WindowEvent event)
Unchanged.void
windowOpened(java.awt.event.WindowEvent event)
Unchanged.-
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler
-
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
-
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, show, toBack, toFront
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTree
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setMixingCutoutShape, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
Use serialVersionUID for interoperability.- See Also:
- Constant Field Values
-
MINIMUM_WIDTH
private static final int MINIMUM_WIDTH
Minimum width of the graph panel- See Also:
- Constant Field Values
-
MINIMUM_HEIGHT
private static final int MINIMUM_HEIGHT
Minimum height of the graph panel- See Also:
- Constant Field Values
-
PANEL_OFFSET
private static final int PANEL_OFFSET
Minimum distance between frame and subpanels- See Also:
- Constant Field Values
-
autoShrinkDomain
private boolean autoShrinkDomain
-
autoShrinkDomainCheckbox
private javax.swing.JCheckBox autoShrinkDomainCheckbox
-
autoShrinkRange
private boolean autoShrinkRange
DOCUMENT ME!
-
autoShrinkRangeCheckbox
private javax.swing.JCheckBox autoShrinkRangeCheckbox
DOCUMENT ME!
-
axisPanel
private javax.swing.JPanel axisPanel
DOCUMENT ME!
-
backgroundButton
private javax.swing.JButton backgroundButton
DOCUMENT ME!
-
backgroundLabel
private javax.swing.JLabel backgroundLabel
DOCUMENT ME!
-
backgroundPanel
private javax.swing.JPanel backgroundPanel
DOCUMENT ME!
-
colorChooser
private ViewJColorChooser colorChooser
DOCUMENT ME!
-
colorDialog
private javax.swing.JDialog colorDialog
DOCUMENT ME!
-
copyMenu
private javax.swing.JMenu copyMenu
DOCUMENT ME!
-
defaultDirectory
private java.lang.String defaultDirectory
DOCUMENT ME!
-
deleteMenu
private javax.swing.JMenu deleteMenu
DOCUMENT ME!
-
editMenu
private javax.swing.JMenu editMenu
DOCUMENT ME!
-
fileMenu
private javax.swing.JMenu fileMenu
DOCUMENT ME!
-
fitFunctPanel
private javax.swing.JPanel fitFunctPanel
DOCUMENT ME!
-
fitFunctTypePanel
private javax.swing.JPanel fitFunctTypePanel
DOCUMENT ME!
-
fitFunctVisibleCheckbox
private javax.swing.JCheckBox[] fitFunctVisibleCheckbox
DOCUMENT ME!
-
fitFunctVisiblePanel
private javax.swing.JPanel fitFunctVisiblePanel
DOCUMENT ME!
-
fitMode
private ViewJFrameGraph.FitMode fitMode
Current mode for fitting functions
-
frameGraphVOI
private VOI frameGraphVOI
DOCUMENT ME!
-
functionIndex
private int functionIndex
DOCUMENT ME!
-
functLineColorButton
private javax.swing.JButton[] functLineColorButton
DOCUMENT ME!
-
functVisibleCheckbox
private javax.swing.JCheckBox[] functVisibleCheckbox
the slope changes.
-
graph
private ViewJComponentGraph graph
DOCUMENT ME!
-
gridlinesCheckbox
private javax.swing.JCheckBox gridlinesCheckbox
DOCUMENT ME!
-
gridPanel
private javax.swing.JPanel gridPanel
DOCUMENT ME!
-
itemClose
private javax.swing.JMenuItem itemClose
DOCUMENT ME!
-
itemModifyGraph
private javax.swing.JMenuItem itemModifyGraph
DOCUMENT ME!
-
itemNormalize
private javax.swing.JMenuItem itemNormalize
DOCUMENT ME!
-
itemOpenNewGraph
private javax.swing.JMenuItem itemOpenNewGraph
-
itemOpenSameGraph
private javax.swing.JMenuItem itemOpenSameGraph
DOCUMENT ME!
-
itemPasteFunct
private javax.swing.JMenuItem itemPasteFunct
DOCUMENT ME!
-
itemPrintGraph
private javax.swing.JMenuItem itemPrintGraph
DOCUMENT ME!
-
itemResetGraph
private javax.swing.JMenuItem itemResetGraph
DOCUMENT ME!
-
itemResetDomain
private javax.swing.JMenuItem itemResetDomain
-
itemResetRange
private javax.swing.JMenuItem itemResetRange
DOCUMENT ME!
-
itemSaveGraph
private javax.swing.JMenuItem itemSaveGraph
DOCUMENT ME!
-
itemTableOutput
private javax.swing.JMenuItem itemTableOutput
-
lastUnits
private java.lang.String lastUnits
DOCUMENT ME!
-
legendCheckbox
private javax.swing.JCheckBox legendCheckbox
DOCUMENT ME!
-
nameField
private javax.swing.JTextField[] nameField
DOCUMENT ME!
-
functionLabel
private javax.swing.JLabel[] functionLabel
DOCUMENT ME!
-
legendPanel
private javax.swing.JPanel legendPanel
DOCUMENT ME!
-
mainPanel
private javax.swing.JPanel mainPanel
DOCUMENT ME!
-
maxDomainField
private javax.swing.JTextField maxDomainField
-
maxDomainLabel
private javax.swing.JLabel maxDomainLabel
-
minDomainField
private javax.swing.JTextField minDomainField
-
minDomainLabel
private javax.swing.JLabel minDomainLabel
-
maxRangeField
private javax.swing.JTextField maxRangeField
DOCUMENT ME!
-
maxRangeLabel
private javax.swing.JLabel maxRangeLabel
DOCUMENT ME!
-
minorTickMarksCheckbox
private javax.swing.JCheckBox minorTickMarksCheckbox
DOCUMENT ME!
-
minRangeField
private javax.swing.JTextField minRangeField
DOCUMENT ME!
-
minRangeLabel
private javax.swing.JLabel minRangeLabel
DOCUMENT ME!
-
modifyDialog
private javax.swing.JDialog modifyDialog
DOCUMENT ME!
-
modifyGraphPanel
private javax.swing.JPanel modifyGraphPanel
DOCUMENT ME!
-
functionPropPanel
private javax.swing.JPanel functionPropPanel
DOCUMENT ME!
-
openingMenuBar
private javax.swing.JMenuBar openingMenuBar
DOCUMENT ME!
-
linesOnlyButton
private javax.swing.JRadioButton linesOnlyButton
DOCUMENT ME!
-
pointsAndLinesButton
private javax.swing.JRadioButton pointsAndLinesButton
-
pointsOnlyButton
private javax.swing.JRadioButton pointsOnlyButton
-
pointsAndLinesGroup
private javax.swing.ButtonGroup pointsAndLinesGroup
-
pointsVisiblePanel
private javax.swing.JPanel pointsVisiblePanel
DOCUMENT ME!
-
fitType
private javax.swing.JComboBox fitType
Combo box for selecting the fitting function type
-
domainPanel
private javax.swing.JPanel domainPanel
-
resetDomainButton
private javax.swing.JButton resetDomainButton
-
logScaleCheckboxX
private javax.swing.JCheckBox logScaleCheckboxX
-
doLogX
private boolean doLogX
-
rangePanel
private javax.swing.JPanel rangePanel
DOCUMENT ME!
-
resetRangeButton
private javax.swing.JButton resetRangeButton
DOCUMENT ME!
-
logScaleCheckboxY
private javax.swing.JCheckBox logScaleCheckboxY
-
doLogY
private boolean doLogY
-
showPanel
private javax.swing.JPanel showPanel
DOCUMENT ME!
-
tabbedPane
private javax.swing.JTabbedPane tabbedPane
DOCUMENT ME!
-
titleField
private javax.swing.JTextField titleField
DOCUMENT ME!
-
titleLabel
private javax.swing.JLabel titleLabel
DOCUMENT ME!
-
units
private java.lang.String units
DOCUMENT ME!
-
updateRGBIndex
private int updateRGBIndex
DOCUMENT ME!
-
vectorCopyFunct
private java.util.Vector<javax.swing.JMenuItem> vectorCopyFunct
DOCUMENT ME!
-
vectorDeleteFunct
private java.util.Vector<javax.swing.JMenuItem> vectorDeleteFunct
DOCUMENT ME!
-
viewMenu
private javax.swing.JMenu viewMenu
DOCUMENT ME!
-
voi
private VOI voi
DOCUMENT ME!
-
xAxisLabel
private javax.swing.JLabel xAxisLabel
DOCUMENT ME!
-
xAxisLabelField
private javax.swing.JTextField xAxisLabelField
DOCUMENT ME!
-
xGridEvenSpacedButton
private javax.swing.JRadioButton xGridEvenSpacedButton
-
xGridUserSpacedButton
private javax.swing.JRadioButton xGridUserSpacedButton
-
xGridButtonGroup
private javax.swing.ButtonGroup xGridButtonGroup
-
xGridCheckBoxPanel
private javax.swing.JPanel xGridCheckBoxPanel
-
xGridCheckBoxList
private javax.swing.JCheckBox[] xGridCheckBoxList
-
xGridScrollPane
private javax.swing.JScrollPane xGridScrollPane
-
xGridLineField
private javax.swing.JTextField xGridLineField
DOCUMENT ME!
-
xGridLineLabel
private javax.swing.JLabel xGridLineLabel
DOCUMENT ME!
-
yAxisLabel
private javax.swing.JLabel yAxisLabel
DOCUMENT ME!
-
yAxisLabelField
private javax.swing.JTextField yAxisLabelField
DOCUMENT ME!
-
yGridEvenSpacedButton
private javax.swing.JRadioButton yGridEvenSpacedButton
-
yGridUserSpacedButton
private javax.swing.JRadioButton yGridUserSpacedButton
-
yGridButtonGroup
private javax.swing.ButtonGroup yGridButtonGroup
-
yGridCheckBoxPanel
private javax.swing.JPanel yGridCheckBoxPanel
-
yGridCheckBoxList
private javax.swing.JCheckBox[] yGridCheckBoxList
-
yGridScrollPane
private javax.swing.JScrollPane yGridScrollPane
-
yGridLineField
private javax.swing.JTextField yGridLineField
DOCUMENT ME!
-
yGridLineLabel
private javax.swing.JLabel yGridLineLabel
DOCUMENT ME!
-
xyCoords
private int[][] xyCoords
this is a list of the x,y coords of the voi's boundary
-
numVariablesLabel
private javax.swing.JLabel numVariablesLabel
-
numVariablesField
private javax.swing.JTextField numVariablesField
-
numVariables
private int numVariables
-
image
private ModelImage image
-
RGBOffset
private int RGBOffset
-
entireImage
private boolean entireImage
-
initialSummaryBins
private int initialSummaryBins
-
summaryBins
private int summaryBins
-
initialUserMin
private double initialUserMin
-
userMin
private double userMin
-
initialUserMax
private double initialUserMax
-
userMax
private double userMax
-
minField
private javax.swing.JTextField minField
-
maxField
private javax.swing.JTextField maxField
-
binsField
private javax.swing.JTextField binsField
-
imageMin
private double imageMin
-
imageMax
private double imageMax
-
maxBins
private int maxBins
-
histogramPanel
private javax.swing.JPanel histogramPanel
-
-
Constructor Detail
-
ViewJFrameGraph
public ViewJFrameGraph(java.lang.String title, boolean openFileGUI)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. No function is loaded by default, but the user can open a new function to be displayed- Parameters:
title
- DOCUMENT ME!openFileGUI
- DOCUMENT ME!
-
ViewJFrameGraph
public ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, int[][] xyCoords)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the frame
-
ViewJFrameGraph
public ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the frame
-
ViewJFrameGraph
public ViewJFrameGraph(float[] x, float[] y, java.lang.String title, VOI v)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Graph is assumed to be made from a VOIPoint. Draws initial default graph of desired function / intensity plot.- Parameters:
x
- the array of x coordinates to be plotted in the graphy
- the array of y coordinates to be plotted in the graphtitle
- the title of the framev
- the VOI the graph is being made for
-
ViewJFrameGraph
public ViewJFrameGraph(float[][] x, float[][] y, java.lang.String title, VOI v)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Graph is assumed to be made from a VOIPoint. Draws initial default graph of desired function / intensity plot.- Parameters:
x
- the array of x coordinates to be plotted in the graphy
- the array of y coordinates to be plotted in the graphtitle
- the title of the framev
- the VOI the graph is being made for
-
ViewJFrameGraph
public ViewJFrameGraph(ModelImage image, int RGBOffset, boolean entireImage, int initialSummaryBins, double initialUserMin, double initialUserMax, float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y aixs label
-
ViewJFrameGraph
public ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y aixs label
-
ViewJFrameGraph
public ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, boolean visible)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y aixs label
-
ViewJFrameGraph
public ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y axis label
-
ViewJFrameGraph
public ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, VOI v, java.lang.String units, int[][] xyCoords)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Graph is assumed to be made from a VOIPoint. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framev
- the VOI the graph is being made forunits
- the string representing the units of the curve (x-axis)xyCoords
- actual x,y coords of the boundary go in here if not null
-
ViewJFrameGraph
public ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, VOI v, java.lang.String units)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Graph is assumed to be made from a VOIPoint. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framev
- the VOI the graph is being made forunits
- the string representing the units of the curve (x-axis)
-
ViewJFrameGraph
public ViewJFrameGraph(float[] xInit, float[] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, java.awt.Color color)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y aixs labelcolor
- DOCUMENT ME!
-
ViewJFrameGraph
public ViewJFrameGraph(float[][] xInit, float[][] yInit, java.lang.String title, java.lang.String labelX, java.lang.String labelY, java.awt.Color[] colorArray)
Constructor Constructs the frame, with the graph component in one panel and the user options in the other. Draws initial default graph of desired function / intensity plot.- Parameters:
xInit
- the array of x coordinates to be plotted in the graphyInit
- the array of y coordinates to be plotted in the graphtitle
- the title of the framelabelX
- x axis labellabelY
- y axis labelcolorArray
- DOCUMENT ME!
-
-
Method Detail
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent event)
Takes the action commands and paints if the apply button is pressed, closes if the close button is pressed.- Specified by:
actionPerformed
in interfacejava.awt.event.ActionListener
- Parameters:
event
- event that triggers this function
-
fitFunctions
private void fitFunctions(ViewJFrameGraph.FitMode mode)
-
componentHidden
public void componentHidden(java.awt.event.ComponentEvent event)
DOCUMENT ME!- Specified by:
componentHidden
in interfacejava.awt.event.ComponentListener
- Parameters:
event
- DOCUMENT ME!
-
componentMoved
public void componentMoved(java.awt.event.ComponentEvent event)
DOCUMENT ME!- Specified by:
componentMoved
in interfacejava.awt.event.ComponentListener
- Parameters:
event
- DOCUMENT ME!
-
componentResized
public void componentResized(java.awt.event.ComponentEvent event)
Resets the bounds of component graph if the window is resized.- Specified by:
componentResized
in interfacejava.awt.event.ComponentListener
- Parameters:
event
- event that triggered this function
-
componentShown
public void componentShown(java.awt.event.ComponentEvent event)
DOCUMENT ME!- Specified by:
componentShown
in interfacejava.awt.event.ComponentListener
- Parameters:
event
- DOCUMENT ME!
-
deleteFunct
public void deleteFunct(int index)
Deletes the indicated function from the graph.- Parameters:
index
- the index of the function to be deleted
-
focusGained
public void focusGained(java.awt.event.FocusEvent event)
Unchanged.- Parameters:
event
- DOCUMENT ME!
-
focusLost
public void focusLost(java.awt.event.FocusEvent event)
Unchanged.- Parameters:
event
- DOCUMENT ME!
-
getDefaultDirectory
public java.lang.String getDefaultDirectory()
Accessor that gets the default directory.- Returns:
- the default directory
-
itemStateChanged
public void itemStateChanged(java.awt.event.ItemEvent event)
Unchanged.- Parameters:
event
- DOCUMENT ME!
-
makeRangeSymmetric
public void makeRangeSymmetric()
DOCUMENT ME!
-
openNew
public boolean openNew() throws java.io.IOException
Opens Excel data (tab-delimited fields) into a new graph. The graphs could also have been saved using MIPAV- Returns:
- DOCUMENT ME!
- Throws:
java.io.IOException
- DOCUMENT ME!
-
openSame
public boolean openSame() throws java.io.IOException
Opens Excel data (tab-delimited fields) into this graph. The graphs could also have been saved using MIPAV- Returns:
- DOCUMENT ME!
- Throws:
java.io.IOException
- DOCUMENT ME!
-
replaceFunction
public void replaceFunction(float[] newX, float[] newY)
Replaces the function used with a line image.- Parameters:
newX
- a 1-d array of which contains the x-coordinates for the functionnewY
- a 1-d array of which contains the y-coordinates for the function
-
replaceFunction
public void replaceFunction(float[] newX, float[] newY, int[][] newXYCoords, VOI myVoi, int index)
Replaces the function used with a line image.- Parameters:
newX
- a 1-d array of which contains the x-coordinates for the functionnewY
- a 1-d array of which contains the y-coordinates for the functionmyVoi
- the new VOI for this functionindex
- DOCUMENT ME!
-
saveNewFunction
public void saveNewFunction(float[] newX, float[] newY, int index)
Saves the current function and adds a blank new function.- Parameters:
newX
- array of which contains the x-coordinates for the new functionnewY
- an array of which contains the y-coordinates for the new functionsindex
- the index of the point to be updated
-
saveNewFunction
public void saveNewFunction(float[][] newX, float[][] newY, int ptIndex)
Replaces the first three functions (used with RGB images).- Parameters:
newX
- a 2-d array of which contains the x-coordinates for the three functions (RGB)newY
- a 2-d array of which contains the y-coordinates for the three functions (RGB)ptIndex
- the index of the point to be updated
-
setDefaultDirectory
public void setDefaultDirectory(java.lang.String dir)
Accessor that sets the default directory.- Parameters:
dir
- string to set the default directory to
-
setLabels
public void setLabels(java.lang.String labelX, java.lang.String labelY)
Sets the axis labels.- Parameters:
labelX
- DOCUMENT ME!labelY
- DOCUMENT ME!
-
setLabelY
public void setLabelY(java.lang.String labelY)
-
setResetEnabled
public void setResetEnabled(boolean enabled)
Accessor that enables or disables the reset item.- Parameters:
enabled
- boolean that enables if true, disables if false
-
setUnitsInLabel
public void setUnitsInLabel(java.lang.String units)
Sets the units in the default axis labels.- Parameters:
units
- the String representing the units to be displayed
-
setVisible
public void setVisible(boolean status)
Makes the dialog visible in center of screen.- Overrides:
setVisible
in classjava.awt.Window
- Parameters:
status
- - flag to indicating if the dialog should be visible
-
setVisibleNoLocChange
public void setVisibleNoLocChange(boolean status)
Makes the dialog visible without setting position.- Parameters:
status
- - flag to indicating if the dialog should be visible
-
setVOI
public void setVOI(VOI v)
Accessor that sets the VOI ViewJFrameGraph was made from.- Parameters:
v
- DOCUMENT ME!
-
showXYZLegends
public void showXYZLegends()
DOCUMENT ME!
-
stateChanged
public void stateChanged(javax.swing.event.ChangeEvent e)
ChangeListener************************************************************************* /** Sets values based on knob along slider- Specified by:
stateChanged
in interfacejavax.swing.event.ChangeListener
- Parameters:
e
- event that triggered this function
-
update
public void update(java.awt.Graphics g)
Calls paint instead of erasing.- Overrides:
update
in classjavax.swing.JFrame
- Parameters:
g
- graphics to paint in
-
update
public void update(float[] x, float[] y, int j)
Updates the graph by changing the plot to the desired new function / intensity plot.- Parameters:
x
- the array of x coordinates to be plotted in the graphy
- the array of y coordinates to be plotted in the graphj
- The function index of which point to be updated
-
update
public void update(float[][] x, float[][] y, int ptIndex)
Updates the graph by changing the plot to the desired new 3 functions (RGB).- Parameters:
x
- the 2-d array of x coordinates to be plotted in the graph for each functiony
- the 2-d array of y coordinates to be plotted in the graph for each functionptIndex
- the index of the point to be updated (will not do anything if trying to update of an index different than updateRGBIndex)
-
updateFittedFunctions
public void updateFittedFunctions()
Deprecated.If data were changed, this could be useful to refit data without pressing a new button, but this function is not currently utilized. Will be removed in future version of MIPAV unless a use can be found Updates Fitted Functions to accurately estimate the functions in the graph (Function data may have chaned due to realtime updating, and therefore the fitted functions must be updated).
-
windowActivated
public void windowActivated(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowActivated
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowClosed
public void windowClosed(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowClosed
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowClosing
public void windowClosing(java.awt.event.WindowEvent event)
Disposes of error dialog, then frame. Nullifies pointer to this in VOIPoint, if this graph was made from a VOIPoint.- Specified by:
windowClosing
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowDeactivated
public void windowDeactivated(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowDeactivated
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowDeiconified
public void windowDeiconified(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowDeiconified
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowIconified
public void windowIconified(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowIconified
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
windowOpened
public void windowOpened(java.awt.event.WindowEvent event)
Unchanged.- Specified by:
windowOpened
in interfacejava.awt.event.WindowListener
- Parameters:
event
- DOCUMENT ME!
-
buildFitFunctPanel
private void buildFitFunctPanel()
Creates a panel to edit various fitted function features. (Panel is to be used in the tabbed pane of the Modify Graph Dialog box
-
buildFunctionPanel
private void buildFunctionPanel()
Creates a panel where various features of the functions can be edited, such as showing the legend, and changing function names. This panel is used by the tabbed pane in Modify Graph Dialog Box.
-
buildMenu
private void buildMenu()
Function that builds the menu of various tools to be used in conjunction with the graph. ie: opening / saving files, changing gridlines, title / axis labels, etc.
-
buildModifyGraphPanel
private void buildModifyGraphPanel()
Creats a panel where various featuers of the graph can be edited, such as visbility of gridlines and minor tick marks, number of gridlines, background color, range, and labels for the title, x and y axiis.
-
createModifyDialog
private void createModifyDialog()
Creates a dialog box in which the user can modify various features of the graph.
-
getMedian
private float getMedian(float[] toSort)
DOCUMENT ME!- Parameters:
toSort
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
parseString
private float[] parseString(java.lang.String s, int len)
DOCUMENT ME!- Parameters:
s
- DOCUMENT ME!len
- DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
print
private void print()
Prints the current graph being displayed to the printer.
-
save
public void save() throws java.io.IOException
Saves this graph as Excel data so that Excel can read in the data and graph it as an Excel file. The file can also be saved to be viewed at a later time with MIPAV- Throws:
java.io.IOException
- DOCUMENT ME!
-
save
public void save(java.lang.String fileName) throws java.io.IOException
Saves this graph as Excel data so that Excel can read in the data and graph it as an Excel file. The file can also be saved to be viewed at a later time with MIPAV- Throws:
java.io.IOException
- DOCUMENT ME!
-
tableOutput
private void tableOutput()
-
testMaxParameter
private boolean testMaxParameter(java.lang.String str, float maxValue)
Tests that the entered parameter is above maxValue.- Parameters:
str
- the value entered by the usermaxValue
- the value that the entered paramater must be more than- Returns:
- boolean result of test
-
testMinParameter
private boolean testMinParameter(java.lang.String str, float minValue)
Tests that the entered parameter is below minValue.- Parameters:
str
- the value entered by the userminValue
- the value that the variable should be less than- Returns:
- boolean result of test
-
testParameter
private boolean testParameter(java.lang.String str, int minValue, int maxValue)
Tests that the entered parameter is in range.- Parameters:
str
- the value entered by the userminValue
- the minimum value this variable may be set tomaxValue
- the maximum value this variable may be set to- Returns:
- boolean result of test
-
updateModifyDialog
private void updateModifyDialog()
Updates fields of the Modify Graph Dialog which may have changed due to things such as adding/deleting functions.
-
getGraph
public ViewJComponentGraph getGraph()
-
getFrameGraphics
public java.awt.Graphics getFrameGraphics()
-
removeComponentListener
public void removeComponentListener()
-
-