public class NetworkPanel
extends javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
javax.swing.JComponent.AccessibleJComponent
Modifier and Type | Field and Description |
---|---|
protected NetworkActionManager |
actionManager
Action manager.
|
static int |
DEFAULT_SPACING
Default spacing for new points.
|
protected javax.swing.JToggleButton |
neuronClampButton
Toggle button for neuron clamping.
|
protected javax.swing.JCheckBoxMenuItem |
neuronClampMenuItem
Menu item for neuron clamping.
|
protected javax.swing.JToggleButton |
synapseClampButton
Toggle button for weight clamping.
|
protected javax.swing.JCheckBoxMenuItem |
synapseClampMenuItem
Menu item for weight clamping.
|
protected UndoManager |
undoManager
Undo manager.
|
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Constructor and Description |
---|
NetworkPanel(Network Network)
Create a new Network panel.
|
Modifier and Type | Method and Description |
---|---|
void |
addInternalMenuBar()
Adds an internal menu bar; used in applets.
|
SynapseGroupNode |
addMenuToSynapseGroupNode(SynapseGroupNode node)
Overriden by NetworkPanelDesktop to adorn node with coupling menus.
|
void |
addNeuron()
Use the GUI to add a new neuron to the underlying network model.
|
void |
addNeuronsToPanel(java.util.List<Neuron> neurons,
Layout layout)
Using the GUI to add a set of neurons to the underlying network panel.
|
void |
addSelection(java.lang.Object element)
Add objects to the current selection.
|
void |
addSelectionListener(NetworkSelectionListener l)
Add the specified Network selection listener.
|
void |
alignHorizontal()
Aligns neurons horizontally.
|
void |
alignVertical()
Aligns neurons vertically.
|
void |
clearPanel()
Remove all nodes from panel.
|
void |
clearSelection()
Clear the selection.
|
void |
clearSourceElements()
Clear all source elements.
|
void |
closeNetwork()
Close model Network.
|
void |
componentUpdated() |
void |
contextualDecrementSelectedObjects()
Invoke contextual decrement (which respects neuron specific rules) on
selected objects.
|
void |
contextualIncrementSelectedObjects()
Invoke contextual increment (which respects neuron specific rules) on
selected objects.
|
void |
copy()
Copy to the clipboard.
|
javax.swing.JMenu |
createAlignMenu()
Return the align sub menu.
|
protected CustomToolBar |
createEditToolBar()
Create the edit tool bar.
|
protected CustomToolBar |
createMainToolBar()
Create the main tool bar.
|
javax.swing.JPopupMenu |
createNetworkContextMenu()
Create a new context menu for this Network panel.
|
protected CustomToolBar |
createRunToolBar()
Create the iteration tool bar.
|
javax.swing.JMenu |
createSpacingMenu()
Return the space sub menu.
|
javax.swing.JToolTip |
createToolTip()
Overridden so that multi-line tooltips can be used.
|
void |
cut()
Cut to the clipboard.
|
java.lang.String |
debugString() |
void |
decrementSelectedObjects()
Decreases neuron and synapse activation levels.
|
void |
deleteSelectedObjects()
Delete selected items.
|
GenericFrame |
displayPanel(javax.swing.JPanel panel,
java.lang.String title)
Display a panel in a dialog.
|
javax.swing.JDialog |
displayPanelInWindow(javax.swing.JPanel panel,
java.lang.String title)
A copy of displayPanel except returning a subclass of Window.
|
NetworkActionManager |
getActionManager() |
boolean |
getAutoZoomMode() |
static java.awt.Color |
getBackgroundColor() |
java.awt.geom.Point2D |
getBeginPosition() |
org.piccolo2d.PCanvas |
getCanvas() |
(package private) javax.swing.JPopupMenu |
getContextMenu()
Return the context menu for this Network panel.
|
javax.swing.JPopupMenu |
getContextMenuAlt() |
EditMode |
getEditMode()
Return the current edit mode for this Network panel.
|
CustomToolBar |
getEditToolBar() |
java.awt.geom.Point2D |
getEndPosition() |
boolean |
getInOutMode() |
java.awt.geom.Point2D |
getLastClickedPosition() |
NeuronNode |
getLastSelectedNeuron() |
CustomToolBar |
getMainToolBar() |
Network |
getNetwork() |
NetworkDialog |
getNetworkDialog(NetworkPanel networkPanel)
Returns a NetworkDialog.
|
javax.swing.JPopupMenu |
getNeuronContextMenu(Neuron neuron)
Creates the context menu for neurons.
|
StandardDialog |
getNeuronDialog(java.util.Collection<NeuronNode> nns) |
javax.swing.JMenu |
getNeuronGroupConsumerMenu(NeuronGroup neuronGroup)
Creates the consumer menu for neuron groups.
|
StandardDialog |
getNeuronGroupDialog(NeuronGroupNode node)
Overridden by NetworkPanelDesktop to ensure modeless-ness relative to
SimbrainDesktop.
|
javax.swing.JMenu |
getNeuronGroupProducerMenu(NeuronGroup neuronGroup)
Creates the producer menu for neuron groups.
|
java.util.Collection<NeuronNode> |
getNeuronNodes()
Return a collection of all neuron nodes.
|
static double |
getNudgeAmount() |
double |
getNumberOfPastes() |
java.util.Map<java.lang.Object,org.piccolo2d.PNode> |
getObjectNodeMap() |
java.util.Collection |
getParentNodes()
Return a collection of all parent nodes.
|
double |
getPasteX() |
double |
getPasteY() |
boolean |
getPrioritiesVisible() |
QuickConnectionManager |
getQuickConnector() |
CustomToolBar |
getRunToolBar() |
java.util.Collection<ScreenElement> |
getSelectableNodes()
Return a collection of all persistent nodes, that is all neuron nodes and
all synapse nodes.
|
java.util.Collection |
getSelectedModelElements()
Returns model Network elements corresponding to selected screen elements.
|
java.util.ArrayList<NeuronGroup> |
getSelectedModelNeuronGroups()
Returns selected neuron groups.
|
java.util.ArrayList<Neuron> |
getSelectedModelNeurons()
Returns selected Neurons.
|
java.util.ArrayList<SynapseGroup> |
getSelectedModelSynapseGroups()
Returns selected synapse groups.
|
java.util.ArrayList<Synapse> |
getSelectedModelSynapses()
Returns selected synapses.
|
java.util.Collection<org.piccolo2d.PNode> |
getSelectedNeuronGroups() |
java.util.Collection<NeuronNode> |
getSelectedNeurons()
Returns selected Neurons.
|
java.util.Collection<ScreenElement> |
getSelectedScreenElements()
Return a collection of all persistent nodes, that is all neuron nodes and
all synapse nodes.
|
java.util.Collection<SynapseNode> |
getSelectedSynapses()
Returns selected Synapses.
|
java.util.ArrayList<TextNode> |
getSelectedText()
Returns the selected Text objects.
|
java.util.Collection<org.piccolo2d.PNode> |
getSelection()
Return the selection as a collection of selected elements.
|
boolean |
getShowSubnetOutline() |
boolean |
getShowTime() |
java.util.ArrayList<NeuronGroup> |
getSourceModelGroups()
Returns neuron groups which are "source elements" that can be connected
to other neuron groups.
|
java.util.ArrayList<Neuron> |
getSourceModelNeurons() |
javax.swing.JPopupMenu |
getSynapseContextMenu(Synapse synapse) |
StandardDialog |
getSynapseDialog(java.util.Collection<SynapseNode> sns) |
javax.swing.JMenu |
getSynapseGroupConsumerMenu(SynapseGroup synapseGroup)
Creates the consumer menu for synapse groups.
|
StandardDialog |
getSynapseGroupDialog(SynapseGroupInteractionBox sgib)
Creates a synapse group dialog from a synapse group interaction box,
overrriden in NetworkPanelDesktop to make it modeless relative to the
SimbrainDesktop.
|
javax.swing.JMenu |
getSynapseGroupProducerMenu(SynapseGroup synapseGroup)
Creates the producer menu for synapse groups.
|
java.util.Collection<SynapseNode> |
getSynapseNodes()
Return a collection of all synapse nodes.
|
TextEventHandler |
getTextHandle() |
java.util.Collection<TextNode> |
getTextNodes()
Return a collection of all text nodes.
|
UndoManager |
getUndoManager() |
boolean |
getUpdateComplete() |
ViewGroupNode |
getViewGroupNode() |
boolean |
getWeightsVisible() |
java.awt.geom.Point2D.Double |
getWhereToAdd() |
void |
groupSelectedObjects()
Create a group of GUI objects.
|
void |
incrementSelectedObjects()
Increases neuron and synapse activation levels.
|
void |
initGui()
Initialize the Gui.
|
boolean |
isGuiOn() |
boolean |
isRunning() |
boolean |
isSelected(java.lang.Object element)
Return true if the specified element is selected.
|
boolean |
isSelectionEmpty()
Return true if the selection is empty.
|
void |
modelCleared(NetworkEvent e) |
protected void |
nudge(int offsetX,
int offsetY)
Nudge selected objects.
|
void |
paste()
Paste from the clipboard.
|
void |
removeSelectionListener(NetworkSelectionListener l)
Remove the specified Network selection listener.
|
void |
repaint() |
void |
resetColors()
Called by Network preferences as preferences are changed.
|
void |
resetSynapseDiameters()
Called by Network preferences as preferences are changed.
|
void |
selectAll()
Select all elements.
|
void |
setAutoZoomMode(boolean autoZoomMode) |
static void |
setBackgroundColor(java.awt.Color backgroundColor) |
void |
setBeginPosition(java.awt.geom.Point2D beginPosition)
Beginning position used in calculating offsets for multiple pastes.
|
void |
setEditMode(EditMode newEditMode)
Set the current edit mode for this Network panel to
editMode
. |
void |
setEndPosition(java.awt.geom.Point2D endPosition) |
void |
setGuiOn(boolean guiOn) |
void |
setHierarchyPanelVisible(boolean showIt)
Set the visibility of the hiearchy panel.
|
void |
setLastClickedPosition(java.awt.geom.Point2D lastLeftClicked)
Set the last position clicked on screen.
|
void |
setLastSelectedNeuron(NeuronNode lastSelectedNeuron) |
void |
setNetwork(Network network)
Set Root network.
|
static void |
setNudgeAmount(double nudgeAmount) |
void |
setNumberOfPastes(double numberOfPastes) |
void |
setPasteDelta()
Set the offset used in multiple pastes.
|
void |
setPasteX(double pasteX) |
void |
setPasteY(double pasteY) |
void |
setPrioritiesVisible(boolean prioritiesOn)
Turns the displaying of neuron priorities on or off.
|
void |
setRunning(boolean isRunning) |
void |
setSelection(java.util.Collection elements)
Set the selection to the specified collection of elements.
|
void |
setShowSubnetOutline(boolean showSubnetOutline) |
void |
setShowTime(boolean showTime) |
void |
setSourceElements()
Set selected elements to be source elements (with red rectangles around
them).
|
void |
setTitle(java.lang.String name) |
void |
setUpdateComplete(boolean updateComplete) |
void |
setWeightsVisible(boolean weightsVisible)
Turns the displaying of loose synapses on and off (for performance
increase or visual clarity).
|
void |
showSelectedNeuronProperties()
Creates and displays the neuron properties dialog.
|
void |
showSelectedSynapseProperties()
Creates and displays the synapse properties dialog.
|
void |
showTextPropertyDialog()
Creates and displays the text properties dialog.
|
void |
spaceHorizontal()
TODO: Push this and related methods to model? Spaces neurons
horizontally.
|
void |
spaceVertical()
Spaces neurons vertically.
|
void |
syncToModel()
Synchronize model and view.
|
void |
toggleSelection(java.lang.Object element)
Toggle the selected state of the specified element; if it is selected,
remove it from the selection, if it is not selected, add it to the
selection.
|
java.lang.String |
toString() |
void |
unGroup(ViewGroupNode vgn,
boolean selectConstituents)
Ungroup specified object.
|
void |
updateCursor()
Update the cursor.
|
void |
updateTime() |
void |
zoomToFitPage(boolean forceZoom)
Rescales the camera so that all objects in the canvas can be seen.
|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycle
public static final int DEFAULT_SPACING
protected NetworkActionManager actionManager
protected final UndoManager undoManager
protected javax.swing.JToggleButton neuronClampButton
protected javax.swing.JToggleButton synapseClampButton
protected javax.swing.JCheckBoxMenuItem neuronClampMenuItem
protected javax.swing.JCheckBoxMenuItem synapseClampMenuItem
public NetworkPanel(Network Network)
Network
- the network panel being created.public void updateTime()
public void addNeuron()
public void addNeuronsToPanel(java.util.List<Neuron> neurons, Layout layout)
neurons
- the set of neuronslayout
- the layout to use in adding thempublic javax.swing.JPopupMenu createNetworkContextMenu()
javax.swing.JPopupMenu getContextMenu()
This context menu should return actions that are appropriate for the Network panel as a whole, e.g. actions that change modes, actions that operate on the selection, actions that add new components, etc. Actions specific to a node of interest should be built into a node-specific context menu.
protected CustomToolBar createRunToolBar()
protected CustomToolBar createMainToolBar()
protected CustomToolBar createEditToolBar()
public javax.swing.JMenu createAlignMenu()
public javax.swing.JMenu createSpacingMenu()
public EditMode getEditMode()
public void setEditMode(EditMode newEditMode)
editMode
.
This is a bound property.
newEditMode
- edit mode for this Network panel, must not be nullpublic void updateCursor()
public void deleteSelectedObjects()
public void copy()
public void cut()
public void paste()
public void alignHorizontal()
public void alignVertical()
public void spaceHorizontal()
public void spaceVertical()
public void showSelectedNeuronProperties()
public void showSelectedSynapseProperties()
public void showTextPropertyDialog()
public void clearSelection()
public void selectAll()
public boolean isSelectionEmpty()
public boolean isSelected(java.lang.Object element)
element
- elementpublic java.util.Collection<org.piccolo2d.PNode> getSelection()
public void setSelection(java.util.Collection elements)
elements
- elementspublic void toggleSelection(java.lang.Object element)
element
- elementpublic void addSelection(java.lang.Object element)
element
- the element to "select."public void addSelectionListener(NetworkSelectionListener l)
l
- Network selection listener to addpublic void removeSelectionListener(NetworkSelectionListener l)
l
- Network selection listener to removepublic java.util.Collection<NeuronNode> getSelectedNeurons()
public java.util.Collection<SynapseNode> getSelectedSynapses()
public java.util.Collection<org.piccolo2d.PNode> getSelectedNeuronGroups()
public java.util.ArrayList<TextNode> getSelectedText()
public java.util.ArrayList<Neuron> getSelectedModelNeurons()
public java.util.ArrayList<Synapse> getSelectedModelSynapses()
public java.util.ArrayList<NeuronGroup> getSelectedModelNeuronGroups()
public java.util.ArrayList<NeuronGroup> getSourceModelGroups()
public java.util.ArrayList<SynapseGroup> getSelectedModelSynapseGroups()
public java.util.Collection getSelectedModelElements()
public java.util.Collection<NeuronNode> getNeuronNodes()
public java.util.Collection<SynapseNode> getSynapseNodes()
public java.util.Collection<TextNode> getTextNodes()
public java.util.Collection getParentNodes()
public java.util.Collection<ScreenElement> getSelectableNodes()
public java.util.Collection<ScreenElement> getSelectedScreenElements()
public void resetColors()
public void resetSynapseDiameters()
public java.lang.String toString()
toString
in class java.awt.Component
public java.lang.String debugString()
public Network getNetwork()
public void setNetwork(Network network)
network
- The Network to set.public java.awt.geom.Point2D getLastClickedPosition()
public void zoomToFitPage(boolean forceZoom)
forceZoom
- if true force the zoom to happenpublic void setLastClickedPosition(java.awt.geom.Point2D lastLeftClicked)
lastLeftClicked
- The lastClickedPosition to set.public void modelCleared(NetworkEvent e)
e
- NetworkListener
public void syncToModel()
public void unGroup(ViewGroupNode vgn, boolean selectConstituents)
vgn
- the group to remove.selectConstituents
- whether to select the grouped items or not.public void groupSelectedObjects()
public void setLastSelectedNeuron(NeuronNode lastSelectedNeuron)
lastSelectedNeuron
- The lastSelectedNeuron to set.public NeuronNode getLastSelectedNeuron()
public void repaint()
repaint
in class java.awt.Component
PCanvas
public boolean getAutoZoomMode()
public void setAutoZoomMode(boolean autoZoomMode)
autoZoomMode
- Auto zoom mode.public boolean getInOutMode()
public double getNumberOfPastes()
public void setNumberOfPastes(double numberOfPastes)
numberOfPastes
- The numberOfPastes to set.public boolean getShowSubnetOutline()
public void setShowSubnetOutline(boolean showSubnetOutline)
showSubnetOutline
- Sets Show subnet outline.public boolean getShowTime()
public void setShowTime(boolean showTime)
showTime
- Sets the show time.public void incrementSelectedObjects()
public void decrementSelectedObjects()
public void contextualIncrementSelectedObjects()
public void contextualDecrementSelectedObjects()
protected void nudge(int offsetX, int offsetY)
offsetX
- amount to nudge in the x direction (multiplied by
nudgeAmount)offsetY
- amount to nudge in the y direction (multiplied by
nudgeAmount)public void closeNetwork()
public CustomToolBar getEditToolBar()
public CustomToolBar getRunToolBar()
public CustomToolBar getMainToolBar()
public void clearSourceElements()
public void setSourceElements()
public void setWeightsVisible(boolean weightsVisible)
weightsVisible
- if true loose weights should be visiblepublic boolean getWeightsVisible()
public void setPrioritiesVisible(boolean prioritiesOn)
prioritiesOn
- whether to show priorities or notpublic void setHierarchyPanelVisible(boolean showIt)
showIt
- whether it should be visible or notpublic boolean getPrioritiesVisible()
public java.util.ArrayList<Neuron> getSourceModelNeurons()
public void setPasteDelta()
public java.awt.geom.Point2D getBeginPosition()
public void setBeginPosition(java.awt.geom.Point2D beginPosition)
beginPosition
- The beginPosition to set.public java.awt.geom.Point2D getEndPosition()
public void setEndPosition(java.awt.geom.Point2D endPosition)
endPosition
- The endPosition to set.public void setPasteX(double pasteX)
pasteX
- pasteX to set.public double getPasteX()
public void setPasteY(double pasteY)
pasteY
- paste_y to set.public double getPasteY()
public boolean isGuiOn()
public void setGuiOn(boolean guiOn)
guiOn
- The guiOn to set.public javax.swing.JToolTip createToolTip()
createToolTip
in class javax.swing.JComponent
public NetworkActionManager getActionManager()
public javax.swing.JPopupMenu getContextMenuAlt()
public TextEventHandler getTextHandle()
public ViewGroupNode getViewGroupNode()
public void componentUpdated()
public void setTitle(java.lang.String name)
name
- public NetworkDialog getNetworkDialog(NetworkPanel networkPanel)
networkPanel
- network panelpublic SynapseGroupNode addMenuToSynapseGroupNode(SynapseGroupNode node)
node
- the SynapseGroupNode.public StandardDialog getNeuronGroupDialog(NeuronGroupNode node)
node
- the neuron group node to display the dialog forpublic StandardDialog getSynapseGroupDialog(SynapseGroupInteractionBox sgib)
sgib
- must be a synapse group interaction box because SynapseGroupBidirectional
does not inhereit from SynapseGroupNode and the interaction box is the only visual
and interactable object with a 1:1 correspondence to synapse groups.public StandardDialog getNeuronDialog(java.util.Collection<NeuronNode> nns)
public StandardDialog getSynapseDialog(java.util.Collection<SynapseNode> sns)
public void clearPanel()
public void addInternalMenuBar()
public boolean isRunning()
public void setRunning(boolean isRunning)
isRunning
- the isRunning to setpublic void initGui()
public org.piccolo2d.PCanvas getCanvas()
public GenericFrame displayPanel(javax.swing.JPanel panel, java.lang.String title)
panel
- panel to displaytitle
- title for the framepublic javax.swing.JDialog displayPanelInWindow(javax.swing.JPanel panel, java.lang.String title)
panel
- the display paneltitle
- the title of the panelpublic java.util.Map<java.lang.Object,org.piccolo2d.PNode> getObjectNodeMap()
public UndoManager getUndoManager()
public static java.awt.Color getBackgroundColor()
public static void setBackgroundColor(java.awt.Color backgroundColor)
backgroundColor
- the backgroundColor to setpublic static double getNudgeAmount()
public static void setNudgeAmount(double nudgeAmount)
nudgeAmount
- the nudgeAmount to setpublic javax.swing.JPopupMenu getNeuronContextMenu(Neuron neuron)
NetworkPanelDesktop
which adds a
coupling menu.neuron
- neuron which needs a menupublic javax.swing.JPopupMenu getSynapseContextMenu(Synapse synapse)
public javax.swing.JMenu getNeuronGroupProducerMenu(NeuronGroup neuronGroup)
NetworkPanelDesktop
which has access
to workspace level coupling menus.neuronGroup
- the neuron group that can produce vectors for
couplings.public javax.swing.JMenu getNeuronGroupConsumerMenu(NeuronGroup neuronGroup)
NetworkPanelDesktop
which has access
to workspace level coupling menus.neuronGroup
- the neuron group that can consume vectors for
couplings.public javax.swing.JMenu getSynapseGroupProducerMenu(SynapseGroup synapseGroup)
NetworkPanelDesktop
which has access
to workspace level coupling menus.synapseGroup
- the neuron group that can produce vectors for
couplings.public javax.swing.JMenu getSynapseGroupConsumerMenu(SynapseGroup synapseGroup)
NetworkPanelDesktop
which has access
to workspace level coupling menus.synapseGroup
- the neuron group that can consume vectors for
couplings.public java.awt.geom.Point2D.Double getWhereToAdd()
public QuickConnectionManager getQuickConnector()
public boolean getUpdateComplete()
public void setUpdateComplete(boolean updateComplete)