Allows the use of an IPortStyle to render the selection, highlight or focus indicator of ports.
Remarks
The renderer of the portStyle used by this class must create SvgVisuals.
The zoomPolicy property defines how the zoom level affects the rendering of the indicator. It can either scale according to the zoom level similar to regular graph items or have always to same thickness regardless of the zoom, similar to the default yFiles indicators.
An alternative to this class is setting an instance of IndicatorPortStyleDecorator to the portStyle property of the GraphSelectionIndicatorManager, GraphFocusIndicatorManager or GraphHighlightIndicatorManager classes.
Type Details
- yfiles module
- view-component
- yfiles-umd modules
- All view modules
- Legacy UMD name
- yfiles.view.PortStyleDecorationInstaller
See Also
Properties
Gets or sets the style to use for the rendering.
Remarks
Changes of the value of this property are not propagated to already created styles.
The default value is an instance of NodeStylePortStyleAdapter with ellipse as shape and a size of (10, 10)
.
Gets or sets how the style is affected by the current zoom level.
Remarks
Changes of the value of this property are propagated to all styles created by this instance and become immediately visible.
The default value is VIEW_COORDINATES.
Methods
Installs a rendering for the item
if it is an IPort.
Parameters
A map of options to pass to the method.
- context - ICanvasContext
- The canvas context.
- group - ICanvasObjectGroup
- The canvas object group to add the newly created canvas object to.
- item - Object
- The item to install.
Returns
- ↪ICanvasObject
- The canvas object representing the item.