Class DiagramEvent

A DiagramEvent represents a more abstract event than an InputEvent. They are raised on the Diagram class. One can receive such events by registering a DiagramEvent listener on a Diagram by calling Diagram#addDiagramListener. Some DiagramEvents such as "ObjectSingleClicked" are normally associated with InputEvents. Some DiagramEvents such as "SelectionMoved" or "PartRotated" are associated with the results of Tool-handled gestures or CommandHandler actions. Some DiagramEvents are not necessarily associated with any input events at all, such as "ViewportBoundsChanged", which can happen due to programmatic changes to the Diagram#position and Diagram#scale properties.

Index

Constructor methods

Properties

Constructor methods

constructor(): DiagramEvent

The DiagramEvent class constructor produces an empty DiagramEvent.

Returns

DiagramEvent

Properties

public cancel: boolean

Gets or sets whether any default actions associated with this diagram event should be avoided or cancelled.

public diagram: Diagram

Gets the diagram associated with the event.

public name: string

Gets or sets the name of the kind of diagram event that this represents.

public parameter: any

Gets or sets an optional object that describes the change to the subject of the diagram event.

public subject: Object

Gets or sets an optional object that is the subject of the diagram event.