Skip to main content
StraightConnectorEditorOptions
Options for a straight connector editor.
NameTypeDescription
activeMode?booleanWhen true (which is the default), tells the EdgePathEditor to mark any new connection dragged with the mouse as "edited", ie. to fix the initial geometry. This is particularly beneficial when using an anchorPositionFinder: it results in every new edge having a 'geometry' object, so that if you export the dataset, you will get the anchor values you chose in your anchorPositionFinder. If an edge does not get exported with geometry for its path, next time it is loaded it will be assigned anchors automatically, which may or may not match the anchors you actually wanted.
anchorPlaceholderSize?numberThe width and height in pixels of the element used to show the current position of a dynamic anchor, and the positions to which it may be dragged. Defaults to DEFAULT_ANCHOR_PLACEHOLDER_SIZE
buttonSize?numberThe width and height of the buttons added by this editor.
hoverMode?booleanWhen true, the path editor is activated when the user hovers over an edge. For touch devices this is ignored, since there are no hover events.
showGuidelines?booleanDefaults to true - when the connector is smoothed, show guidelines linking each of the control points in the path.
splitMode?StraightConnectorEditorSplitModeIdentifies the mode to use to split segments. STRAIGHT_CONNECTOR_AUTO_SPLIT creates a new segment handle when the user performs a mousedown or touchstart, at the location of the event. This is the default. STRAIGHT_CONNECTOR_CLICK_SPLIT displays a button on the midpoint of each segment which the user can click on to split the segment.