public class Presenter
extends javax.swing.JFrame
implements java.awt.event.ActionListener
javax.swing.JFrame.AccessibleJFrame
java.awt.Window.AccessibleAWTWindow, java.awt.Window.Type
Modifier and Type | Field and Description |
---|---|
javax.swing.JComponent |
itsCanvas |
java.awt.Rectangle |
itsDefaultCoordinateMap |
PresenterPanel |
itsPresenterPanel |
static int |
kMenuBarHeight |
protected int |
kPaspart |
protected javax.swing.JMenuItem |
miClear |
protected javax.swing.JMenuItem |
miClose |
protected javax.swing.JMenuItem |
miCopy |
protected javax.swing.JMenuItem |
miCut |
protected javax.swing.JMenuItem |
miNew |
protected javax.swing.JMenuItem |
miOpen |
protected javax.swing.JMenuItem |
miPaste |
protected javax.swing.JMenuItem |
miSave |
protected javax.swing.JMenuItem |
miSaveAs |
protected javax.swing.JMenuItem |
miSelectAll |
protected javax.swing.JMenuItem |
miUndo |
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
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
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Constructor and Description |
---|
Presenter()
Constructor for the Presenter class
|
Presenter(double sizingValue)
Constructor for the Presenter class
|
Presenter(java.lang.String frameTitle)
Constructor for the Presenter class
|
Presenter(java.lang.String frameTitle,
double sizingValue)
Standard constructor for the Presenter class
|
Presenter(java.lang.String frameTitle,
double sizingValue,
PresenterPanel aPanel)
Standard constructor for the Presenter class
|
Presenter(java.lang.String frameTitle,
PresenterPanel aPanel)
Standard constructor for the Presenter class
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(java.awt.event.ActionEvent newEvent)
ActionListener interface (for menus)
|
void |
addEditMenuItems() |
void |
addFileMenuItems()
adds the file menu items
|
void |
addMenus()
adds menus to the JFrame
|
void |
asCircularGraph(com.lobsterman.JavaGrinders.spatial.AngleVariable theAngles)
coordinates a JFrame with a circular graph for the provided angles
|
void |
asColorHistogram(ContingencyTable theTable)
coordinates a JFrame with a histogram for the provided table
|
void |
asColorHistogram(ContingencyTable theTable,
boolean labelBars)
coordinates a JFrame with a histogram for the provided table
|
void |
asHistogram(ContingencyTable theTable)
coordinates a JFrame with a circular graph for the provided angles
|
void |
asSpatialMap(com.lobsterman.JavaGrinders.spatial.CaptureVariable theCaptures,
boolean xDir,
boolean yDir)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asSpatialMap(com.lobsterman.JavaGrinders.spatial.CaptureVariable theCaptures,
com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asXYPlot(com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asXYPlot(NumberVariable theXs,
NumberVariable theYs)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asXYPlot(NumberVariable theXs,
NumberVariable theYs,
boolean xDir,
boolean yDir)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asXYPlot(NumberVariable theXs,
NumberVariable theYs,
com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
asXYPlot(NumberVariable theXs,
NumberVariable theYs,
com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace,
boolean connected)
coordinates a JFrame with a spatial map graph for the provided captures
|
void |
doClear()
handles a clear event
|
void |
doClose()
handles a close Document event
|
void |
doCopy()
handles a copy event
|
void |
doCut()
handles a cut event
|
void |
doNew()
handles a new Document event
|
void |
doOpen()
handles an open Document event
|
void |
doPaste()
handles a paste event
|
void |
doSave()
handles a save Document event
|
void |
doSaveAs()
handles a save as ...
|
void |
doSelectAll()
handles a select all event
|
void |
doUndo()
handles an undo event
|
void |
handleQuit()
handles a quit event
|
void |
initializeCanvas()
initializes the canvas
|
static void |
main(java.lang.String[] args)
main routine
|
javax.swing.JComponent |
makeCanvasPanel()
makes the main canvas panel
|
PresenterPanel |
makePresenterPanel()
creates the Panel for presenting the active data
|
java.awt.Dimension |
maxWindowRatioSize(double aWidthHeightRatio)
scales the frame with a given width/height ratio to the full screen
|
java.awt.Dimension |
maxWindowSize()
scales the frame to the full screen available
|
void |
saveToSVGFile(java.lang.String filePath)
saves the content of the PresenterPanel to an SVG file
|
void |
setFrameSize(double sizeValue)
scales the frame to a given screen size
|
void |
setPlotDimensions()
sets the plot dimensions
|
void |
setPresenterPanel(PresenterPanel aPanel)
sets the panel for the presenter
|
void |
setScalesForPanel(PresenterPanel aPanel)
creates the Panel for presenting the active data
|
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, update
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
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, setVisible, show, toBack, toFront
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
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, getPeer, 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, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
protected javax.swing.JMenuItem miNew
protected javax.swing.JMenuItem miOpen
protected javax.swing.JMenuItem miClose
protected javax.swing.JMenuItem miSave
protected javax.swing.JMenuItem miSaveAs
protected javax.swing.JMenuItem miUndo
protected javax.swing.JMenuItem miCut
protected javax.swing.JMenuItem miCopy
protected javax.swing.JMenuItem miPaste
protected javax.swing.JMenuItem miClear
protected javax.swing.JMenuItem miSelectAll
public javax.swing.JComponent itsCanvas
public PresenterPanel itsPresenterPanel
public java.awt.Rectangle itsDefaultCoordinateMap
public static int kMenuBarHeight
protected final int kPaspart
public Presenter() throws java.lang.Exception
java.lang.Exception
public Presenter(java.lang.String frameTitle) throws java.lang.Exception
frameTitle
- the title on the presenter's framejava.lang.Exception
public Presenter(double sizingValue) throws java.lang.Exception
sizingValue
- controls whether sizing occurs with a width/height ratio (greater than 0), to the
full screen (0), or not at all (less than 0);java.lang.Exception
public Presenter(java.lang.String frameTitle, double sizingValue) throws java.lang.Exception
frameTitle
- title for the framesizingValue
- controls whether sizing occurs with a width/height ratio (greater than 0), to the
full screen (0), or not at all (less than 0);java.lang.Exception
public Presenter(java.lang.String frameTitle, PresenterPanel aPanel) throws java.lang.Exception
frameTitle
- title for the frameaPanel
- the panel to display the contentjava.lang.Exception
public Presenter(java.lang.String frameTitle, double sizingValue, PresenterPanel aPanel) throws java.lang.Exception
frameTitle
- title for the framesizingValue
- controls whether sizing occurs with a width/height ratio (greater than 0), to the
full screen (0), or not at all (less than 0);aPanel
- the panel to display the contentjava.lang.Exception
public void initializeCanvas() throws java.lang.Exception
java.lang.Exception
public javax.swing.JComponent makeCanvasPanel() throws java.lang.Exception
java.lang.Exception
public PresenterPanel makePresenterPanel() throws java.lang.Exception
java.lang.Exception
public void setScalesForPanel(PresenterPanel aPanel) throws java.lang.Exception
java.lang.Exception
public void setPresenterPanel(PresenterPanel aPanel) throws java.lang.Exception
aPanel
- the panel to display the contentjava.lang.Exception
public void addFileMenuItems()
public void addEditMenuItems()
public void addMenus()
public void handleQuit()
public void actionPerformed(java.awt.event.ActionEvent newEvent)
actionPerformed
in interface java.awt.event.ActionListener
newEvent
- the event to handlepublic void doNew()
public void doOpen()
public void doClose()
public void saveToSVGFile(java.lang.String filePath)
public void doSave()
public void doSaveAs()
public void doUndo()
public void doCut()
public void doCopy()
public void doPaste()
public void doClear()
public void doSelectAll()
public java.awt.Dimension maxWindowSize()
public java.awt.Dimension maxWindowRatioSize(double aWidthHeightRatio)
aWidthHeightRatio
- the requested ratio for width to height of the framepublic void setFrameSize(double sizeValue) throws java.lang.Exception
sizeValue
- controls whether sizing occurs with a width/height ratio (greater than 0), to the
full screen (0), or not at all (less than 0);java.lang.Exception
public void setPlotDimensions() throws java.lang.Exception
java.lang.Exception
public void asHistogram(ContingencyTable theTable) throws java.lang.Exception
theTable
- the distribution of anglesjava.lang.Exception
public void asColorHistogram(ContingencyTable theTable) throws java.lang.Exception
theTable
- the distribution of anglesjava.lang.Exception
public void asColorHistogram(ContingencyTable theTable, boolean labelBars) throws java.lang.Exception
theTable
- the distribution of angleslabelBars
- plot labels for the barsjava.lang.Exception
public void asXYPlot(NumberVariable theXs, NumberVariable theYs) throws java.lang.Exception
theXs
- the x coordinates of the captures to plottheYs
- the y coordinates of the captures to plotjava.lang.Exception
public void asXYPlot(NumberVariable theXs, NumberVariable theYs, boolean xDir, boolean yDir) throws java.lang.Exception
theXs
- the x coordinates of the captures to plottheYs
- the y coordinates of the captures to plotxDir
- is the direction of the gridyDir
- is the direction of the gridjava.lang.Exception
public void asXYPlot(com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace) throws java.lang.Exception
theGridSpace
- the Gridspace3D to usejava.lang.Exception
public void asXYPlot(NumberVariable theXs, NumberVariable theYs, com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace) throws java.lang.Exception
theXs
- the x coordinates of the captures to plottheYs
- the y coordinates of the captures to plottheGridSpace
- the Gridspace3D to usejava.lang.Exception
public void asXYPlot(NumberVariable theXs, NumberVariable theYs, com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace, boolean connected) throws java.lang.Exception
theXs
- the x coordinates of the captures to plottheYs
- the y coordinates of the captures to plottheGridSpace
- the Gridspace3D to usejava.lang.Exception
public void asCircularGraph(com.lobsterman.JavaGrinders.spatial.AngleVariable theAngles) throws java.lang.Exception
theAngles
- the angles to plotjava.lang.Exception
public void asSpatialMap(com.lobsterman.JavaGrinders.spatial.CaptureVariable theCaptures, boolean xDir, boolean yDir) throws java.lang.Exception
theCaptures
- the captures to plotjava.lang.Exception
public void asSpatialMap(com.lobsterman.JavaGrinders.spatial.CaptureVariable theCaptures, com.lobsterman.JavaGrinders.spatial.GridSpace3D theGridSpace) throws java.lang.Exception
theCaptures
- the captures to plottheGridSpace
- the GridSpace to usejava.lang.Exception
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
Copyright 2016