|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.umd.cs.piccolo.PNode
org.simbrain.network.nodes.ScreenElement
org.simbrain.network.nodes.SubnetworkNode
public abstract class SubnetworkNode
Abstract subnetwork node.
| Field Summary | |
|---|---|
static double |
OUTLINE_INSET_HEIGHT
Outline inset or border height. |
static double |
OUTLINE_INSET_WIDTH
Outline inset or border width. |
static double |
TAB_HEIGHT
Tab height. |
| Fields inherited from class edu.umd.cs.piccolo.PNode |
|---|
PROPERTY_BOUNDS, PROPERTY_CHILDREN, PROPERTY_CHILDREN_PICKABLE, PROPERTY_CLIENT_PROPERTIES, PROPERTY_FULL_BOUNDS, PROPERTY_PAINT, PROPERTY_PARENT, PROPERTY_PICKABLE, PROPERTY_TRANSFORM, PROPERTY_TRANSPARENCY, PROPERTY_VISIBLE |
| Fields inherited from interface java.awt.print.Printable |
|---|
NO_SUCH_PAGE, PAGE_EXISTS |
| Constructor Summary | |
|---|---|
protected |
SubnetworkNode(NetworkPanel networkPanel,
Network subnetwork,
double x,
double y)
Create a new abstract subnetwork node from the specified parameters. |
| Method Summary | |
|---|---|
void |
addChild(PNode child)
|
protected JPopupMenu |
getContextMenu()
Return a context menu specific to this screen element. |
String |
getLabel()
Return the label for this subnetwork node. |
Stroke |
getOutlineStroke()
Return the outline stroke for this subnetwork node. |
Paint |
getOutlineStrokePaint()
Return the outline stroke paint for this subnetwork node. |
Action |
getSetPropertiesAction()
|
Network |
getSubnetwork()
Return the subnetwork for this subnetwork node. |
Paint |
getTabPaint()
Return the tab paint for this subnetwork node. |
Stroke |
getTabStroke()
Return the tab stroke for this subnetwork node. |
Paint |
getTabStrokePaint()
Return the tab stroke paint for this subnetwork node. |
boolean |
isDraggable()
Return true if this screen element is draggable. |
boolean |
isSelectable()
Return true if this screen element is selectable. |
protected void |
layoutChildren()
|
void |
propertyChange(PropertyChangeEvent event)
|
PNode |
removeChild(PNode child)
|
void |
resetColors()
Reset colors when default colors have been changed in NetworkPreferences. |
void |
setLabel(String label)
Set the label for this subnetwork node to label. |
void |
setOutlineStroke(Stroke outlineStroke)
Set the outline stroke for this subnetwork node to outlineStroke. |
void |
setOutlineStrokePaint(Paint outlineStrokePaint)
Set the outline stroke paint for this subnetwork node to outlineStrokePaint. |
void |
setSetPropertiesAction(Action setPropertiesAction)
|
void |
setShowOutline(boolean showOutline)
Set to true if this subnetwork node is to show its outline. |
void |
setTabPaint(Paint tabPaint)
Set the tab paint for this subnetwork node to tabPaint. |
void |
setTabStroke(Stroke tabStroke)
Set the tab stroke for this subnetwork node to tabStroke. |
void |
setTabStrokePaint(Paint tabStrokePaint)
Set the tab stroke paint for this subnetwork node to tabStrokePaint. |
boolean |
showSelectionHandle()
Return true if this screen element should show a
selection handle. |
| Methods inherited from class org.simbrain.network.nodes.ScreenElement |
|---|
getNetworkPanel, getPropertyDialog, getToolTipText, hasContextMenu, hasPropertyDialog, hasToolTipText, initCastor, setNetworkPanel |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final double TAB_HEIGHT
public static final double OUTLINE_INSET_HEIGHT
public static final double OUTLINE_INSET_WIDTH
| Constructor Detail |
|---|
protected SubnetworkNode(NetworkPanel networkPanel,
Network subnetwork,
double x,
double y)
networkPanel - networkPanel for this subnetwork node, must not be nullsubnetwork - subnetwork for this subnetwork node, must not be nullx - x offset for this subnetwork nodey - y offset for this subnetwork node| Method Detail |
|---|
protected JPopupMenu getContextMenu()
ScreenElementnull if this screen element does not have a context
menu.
getContextMenu in class ScreenElementScreenElementpublic void setShowOutline(boolean showOutline)
This is a bound property.
showOutline - true if this subnetwork node is to show its outlinepublic final boolean isSelectable()
ScreenElementtrue if this screen element is selectable.
Being selectable requires that this screen element is pickable
as far as the Piccolo API is concerned, so if this method returns
true, be sure that this class also returns true
for its getPickable() method.
isSelectable in class ScreenElementScreenElementpublic final boolean showSelectionHandle()
ScreenElementtrue if this screen element should show a
selection handle.
Showing a selection handle requires that this screen element is pickable
as far as the Piccolo API is concerned, so if this method returns
true, be sure that this class also returns true
for its getPickable() method.
Showing a selection handle also requires that this screen element is selectable,
so if this method returns true, be sure that this class also
returns true for its isSelectable() method.
showSelectionHandle in class ScreenElementScreenElementpublic final boolean isDraggable()
ScreenElementtrue if this screen element is draggable.
Being draggable requires that this screen element is pickable
as far as the Piccolo API is concerned, so if this method returns
true, be sure that this class also returns true
for its getPickable() method.
Being draggable also requires that this screen element is selectable,
so if this method returns true, be sure that this class also
returns true for its isSelectable() method.
isDraggable in class ScreenElementScreenElementpublic final void resetColors()
ScreenElementNetworkPreferences.
resetColors in class ScreenElementScreenElementpublic final String getLabel()
public void setLabel(String label)
label.
This is a bound property.
label - label for this subnetwork nodepublic final Network getSubnetwork()
public final Paint getTabPaint()
public final void setTabPaint(Paint tabPaint)
tabPaint.
This is a bound property.
tabPaint - tab paint for this subnetwork nodepublic final Stroke getTabStroke()
public final void setTabStroke(Stroke tabStroke)
tabStroke.
This is a bound property.
tabStroke - tab stroke for this subnetwork nodepublic final Paint getTabStrokePaint()
public final void setTabStrokePaint(Paint tabStrokePaint)
tabStrokePaint.
This is a bound property.
tabStrokePaint - tab stroke paint for this subnetwork nodepublic final Stroke getOutlineStroke()
public final void setOutlineStroke(Stroke outlineStroke)
outlineStroke.
This is a bound property.
outlineStroke - outline stroke for this subnetwork nodepublic final Paint getOutlineStrokePaint()
public final void setOutlineStrokePaint(Paint outlineStrokePaint)
outlineStrokePaint.
This is a bound property.
outlineStrokePaint - outline stroke paint for this subnetwork nodeprotected void layoutChildren()
layoutChildren in class PNodePNodepublic void addChild(PNode child)
addChild in class PNodePNodepublic PNode removeChild(PNode child)
removeChild in class PNodePNodepublic void propertyChange(PropertyChangeEvent event)
propertyChange in interface PropertyChangeListenerPropertyChangeListenerpublic Action getSetPropertiesAction()
public void setSetPropertiesAction(Action setPropertiesAction)
setPropertiesAction - The setPropertiesAction to set.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||