Class FreeConnectionWidget
java.lang.Object
org.netbeans.api.visual.widget.Widget
org.netbeans.api.visual.widget.ConnectionWidget
org.netbeans.api.visual.widget.FreeConnectionWidget
- All Implemented Interfaces:
Accessible
,org.openide.util.Lookup.Provider
This class is an extension of the ConnectionWidget. Primarily it is used with FreeRouter and optionally Free*Anchor.
It has a method for adding and removing control points on specific locations.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.netbeans.api.visual.widget.ConnectionWidget
ConnectionWidget.RoutingPolicy
Nested classes/interfaces inherited from class org.netbeans.api.visual.widget.Widget
Widget.Dependency
-
Constructor Summary
ConstructorsConstructorDescriptionFreeConnectionWidget
(Scene scene) Creates a free connection widget.FreeConnectionWidget
(Scene scene, double createSensitivity, double deleteSensitivity) Creates a free connection widget with a specified create/delete sensitivity. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addRemoveControlPoint
(Point localLocation) Adds or removes a control point on a specified locationvoid
setSensitivity
(double createSensitivity, double deleteSensitivity) Sets a sensitivity.Methods inherited from class org.netbeans.api.visual.widget.ConnectionWidget
calculateClientArea, calculateRouting, getControlPoint, getControlPointCutDistance, getControlPointHitAt, getControlPoints, getControlPointsCursor, getControlPointShape, getCursorAt, getEndPointShape, getFirstControlPoint, getLastControlPoint, getLineColor, getRouter, getRoutingPolicy, getSourceAnchor, getSourceAnchorEntry, getSourceAnchorShape, getStroke, getTargetAnchor, getTargetAnchorEntry, getTargetAnchorShape, getTargetAnchorShapeRotation, isFirstControlPointHitAt, isHitAt, isLastControlPointHitAt, isPaintControlPoints, isRouted, isValidated, notifyStateChanged, paintWidget, removeConstraint, reroute, setConstraint, setConstraint, setControlPointCutDistance, setControlPoints, setControlPointsCursor, setControlPointShape, setEndPointShape, setLineColor, setPaintControlPoints, setRouter, setRoutingPolicy, setSourceAnchor, setSourceAnchorShape, setStroke, setTargetAnchor, setTargetAnchorShape
Methods inherited from class org.netbeans.api.visual.widget.Widget
addChild, addChild, addChild, addChild, addChildren, addDependency, bringToBack, bringToFront, convertLocalToScene, convertLocalToScene, convertSceneToLocal, convertSceneToLocal, createActions, equals, getAccessibleContext, getActions, getActions, getBackground, getBorder, getBounds, getChildConstraint, getChildren, getClientArea, getCursor, getDependencies, getFont, getForeground, getGraphics, getLayout, getLocation, getLookup, getMaximumSize, getMinimumSize, getParentWidget, getPreferredBounds, getPreferredLocation, getPreferredSize, getResourceTable, getScene, getState, getToolTipText, hashCode, isCheckClipping, isEnabled, isOpaque, isPreferredBoundsSet, isRepaintRequiredForRevalidating, isVisible, notifyAdded, notifyBackgroundChanged, notifyFontChanged, notifyForegroundChanged, notifyRemoved, paint, paintBackground, paintBorder, paintChildren, removeChild, removeChildren, removeChildren, removeDependency, removeFromParent, repaint, resolveBounds, revalidate, revalidate, setAccessibleContext, setBackground, setBackgroundFromResource, setBorder, setBorder, setCheckClipping, setChildConstraint, setCursor, setEnabled, setFont, setFontFromResource, setForeground, setForegroundFromResource, setLayout, setMaximumSize, setMinimumSize, setOpaque, setPreferredBounds, setPreferredLocation, setPreferredSize, setResourceTable, setState, setToolTipText, setVisible, updateResources
-
Constructor Details
-
FreeConnectionWidget
Creates a free connection widget.- Parameters:
scene
- the scene
-
FreeConnectionWidget
Creates a free connection widget with a specified create/delete sensitivity.- Parameters:
scene
- the scenecreateSensitivity
- the sensitivity for adding a control pointdeleteSensitivity
- the sensitivity for removing a control point
-
-
Method Details
-
addRemoveControlPoint
Adds or removes a control point on a specified location- Parameters:
localLocation
- the local location
-
setSensitivity
public void setSensitivity(double createSensitivity, double deleteSensitivity) Sets a sensitivity.- Parameters:
createSensitivity
- the sensitivity for adding a control pointdeleteSensitivity
- the sensitivity for removing a control point
-