markgojs
Version:
Interactive diagrams, charts, and graphs, such as trees, flowcharts, orgcharts, UML, BPMN, or business diagrams
1,361 lines (388 loc) • 47.6 kB
HTML
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>GoJS® DiagramEvent Class</title>
<script src="../../assets/js/jquery.min.js"></script>
<script src="../../assets/js/bootstrap.min.js"></script>
<script src="../../assets/js/highlight.js"></script>
<script src="../../assets/js/api.js"></script>
<script src="../../assets/js/fuse.min.js"></script>
<link href="../../assets/css/bootstrap.min.css" rel="stylesheet" >
<!-- custom CSS after bootstrap -->
<link href="../../assets/css/main.css" rel="stylesheet" type="text/css"/>
<link href="../../assets/css/api.css" rel="stylesheet" type="text/css"/>
<!--<link rel="stylesheet" href="../../assets/css/api.css" type="text/css" media="all" />-->
<link rel="stylesheet" href="../../assets/css/highlight.css" type="text/css" media="all" />
</head>
<body>
<!-- non-fixed navbar -->
<nav id="non-fixed-nav" class="navbar navbar-inverse navbar-top">
<div class="container-fluid">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#navbar">
<a id="toplogo" class="navbar-brand" href="../../index.html">GoJS</a>
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
</div>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav navbar-right">
<li><a href="../../index.html">Home</a></li>
<li><a href="../../learn/index.html">Learn</a></li>
<li><a href="../../samples/index.html">Samples</a></li>
<li><a href="../../intro/index.html">Intro</a></li>
<li><a href="../../api/index.html">API</a></li>
<li><a href="https://www.nwoods.com/components/evalform.htm">Register</a></li>
<li><a href="../../download.html">Download</a></li>
<li><a href="https://forum.nwoods.com/c/gojs">Forum</a></li>
<li><a href="https://www.nwoods.com/contact.html" onclick="ga('send','event','Outbound Link','click','contact');">Contact</a></li>
<li class="buy"><a href="https://www.nwoods.com/sales/index.html" onclick="ga('send','event','Outbound Link','click','buy');">Buy</a></li>
<li class="activate"><a href="https://www.nwoods.com/app/activate.aspx?sku=gojs">Activate</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</nav>
<div class="container-fluid">
<!-- ============================== classes index ============================ -->
<div id="navindex" class="col-md-2">
<!-- begin publish.classesIndex -->
<!-- <div><a href="../index.html">GoJS Class Index</a></div> -->
<div class="sidebar-nav">
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#DiagramNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#DiagramNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Diagram Classes</span>
</div>
</div>
<div id="DiagramNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/Adornment.html" class="linkConstructor">Adornment</a></li>
<li><a href="../symbols/AnimationManager.html" class="linkConstructor">AnimationManager</a></li>
<li><a href="../symbols/CommandHandler.html" class="linkConstructor">CommandHandler</a></li>
<li><a href="../symbols/Diagram.html" class="linkConstructor">Diagram</a></li>
<li><a href="../symbols/DiagramEvent.html" class="linkConstructor">DiagramEvent</a></li>
<li><a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a></li>
<li><a href="../symbols/Group.html" class="linkConstructor">Group</a></li>
<li><a href="../symbols/InputEvent.html" class="linkConstructor">InputEvent</a></li>
<li><a href="../symbols/Layer.html" class="linkConstructor">Layer</a></li>
<li><a href="../symbols/Link.html" class="linkConstructor">Link</a></li>
<li><a href="../symbols/Node.html" class="linkConstructor">Node</a></li>
<li><a href="../symbols/Overview.html" class="linkConstructor">Overview</a></li>
<li><a href="../symbols/Palette.html" class="linkConstructor">Palette</a></li>
<li><a href="../symbols/Panel.html" class="linkConstructor">Panel</a></li>
<li><a href="../symbols/Part.html" class="linkConstructor">Part</a></li>
<li><a href="../symbols/Picture.html" class="linkConstructor">Picture</a></li>
<li><a href="../symbols/Placeholder.html" class="linkConstructor">Placeholder</a></li>
<li><a href="../symbols/RowColumnDefinition.html" class="linkConstructor">RowColumnDefinition</a></li>
<li><a href="../symbols/Shape.html" class="linkConstructor">Shape</a></li>
<li><a href="../symbols/TextBlock.html" class="linkConstructor">TextBlock</a></li>
</ul>
</div>
</div>
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#GeometryNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#GeometryNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Geometry Classes</span>
</div>
</div>
<div id="GeometryNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/Brush.html" class="linkConstructor">Brush</a></li>
<li><a href="../symbols/Geometry.html" class="linkConstructor">Geometry</a></li>
<li><a href="../symbols/Margin.html" class="linkConstructor">Margin</a></li>
<li><a href="../symbols/PathFigure.html" class="linkConstructor">PathFigure</a></li>
<li><a href="../symbols/PathSegment.html" class="linkConstructor">PathSegment</a></li>
<li><a href="../symbols/Point.html" class="linkConstructor">Point</a></li>
<li><a href="../symbols/Rect.html" class="linkConstructor">Rect</a></li>
<li><a href="../symbols/Size.html" class="linkConstructor">Size</a></li>
<li><a href="../symbols/Spot.html" class="linkConstructor">Spot</a></li>
</ul>
</div>
</div>
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#ModelNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#ModelNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Model Classes</span>
</div>
</div>
<div id="ModelNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/Binding.html" class="linkConstructor">Binding</a></li>
<li><a href="../symbols/ChangedEvent.html" class="linkConstructor">ChangedEvent</a></li>
<li><a href="../symbols/GraphLinksModel.html" class="linkConstructor">GraphLinksModel</a></li>
<li><a href="../symbols/Model.html" class="linkConstructor">Model</a></li>
<li><a href="../symbols/Transaction.html" class="linkConstructor">Transaction</a></li>
<li><a href="../symbols/TreeModel.html" class="linkConstructor">TreeModel</a></li>
<li><a href="../symbols/UndoManager.html" class="linkConstructor">UndoManager</a></li>
</ul>
</div>
</div>
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#LayoutNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#LayoutNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Layout Classes</span>
</div>
</div>
<div id="LayoutNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/CircularLayout.html" class="linkConstructor">CircularLayout</a></li>
<li><a href="../symbols/ForceDirectedLayout.html" class="linkConstructor">ForceDirectedLayout</a></li>
<li><a href="../symbols/GridLayout.html" class="linkConstructor">GridLayout</a></li>
<li><a href="../symbols/LayeredDigraphLayout.html" class="linkConstructor">LayeredDigraphLayout</a></li>
<li><a href="../symbols/Layout.html" class="linkConstructor">Layout</a></li>
<li><a href="../symbols/LayoutNetwork.html" class="linkConstructor">LayoutNetwork</a></li>
<li><a href="../symbols/TreeLayout.html" class="linkConstructor">TreeLayout</a></li>
</ul>
</div>
</div>
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#ToolNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#ToolNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Tool Classes</span>
</div>
</div>
<div id="ToolNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/ActionTool.html" class="linkConstructor">ActionTool</a></li>
<li><a href="../symbols/ClickCreatingTool.html" class="linkConstructor">ClickCreatingTool</a></li>
<li><a href="../symbols/ClickSelectingTool.html" class="linkConstructor">ClickSelectingTool</a></li>
<li><a href="../symbols/ContextMenuTool.html" class="linkConstructor">ContextMenuTool</a></li>
<li><a href="../symbols/DraggingTool.html" class="linkConstructor">DraggingTool</a></li>
<li><a href="../symbols/DragSelectingTool.html" class="linkConstructor">DragSelectingTool</a></li>
<li><a href="../symbols/HTMLInfo.html" class="linkConstructor">HTMLInfo</a></li>
<li><a href="../symbols/LinkingBaseTool.html" class="linkConstructor">LinkingBaseTool</a></li>
<li><a href="../symbols/LinkingTool.html" class="linkConstructor">LinkingTool</a></li>
<li><a href="../symbols/LinkReshapingTool.html" class="linkConstructor">LinkReshapingTool</a></li>
<li><a href="../symbols/PanningTool.html" class="linkConstructor">PanningTool</a></li>
<li><a href="../symbols/RelinkingTool.html" class="linkConstructor">RelinkingTool</a></li>
<li><a href="../symbols/ResizingTool.html" class="linkConstructor">ResizingTool</a></li>
<li><a href="../symbols/RotatingTool.html" class="linkConstructor">RotatingTool</a></li>
<li><a href="../symbols/TextEditingTool.html" class="linkConstructor">TextEditingTool</a></li>
<li><a href="../symbols/Tool.html" class="linkConstructor">Tool</a></li>
<li><a href="../symbols/ToolManager.html" class="linkConstructor">ToolManager</a></li>
</ul>
</div>
</div>
<div class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<div class="navheader-container">
<div class="navheader-collapse" data-toggle="collapse" data-target="#CollectionNavbar">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#CollectionNavbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<span class="navbar-brand">Collection Classes</span>
</div>
</div>
<div id="CollectionNavbar" class="navbar-collapse collapse sidebar-navbar-collapse">
<ul class="classList nav navbar-nav">
<li><a href="../symbols/Iterable.html" class="linkConstructor">Iterable</a></li>
<li><a href="../symbols/Iterator.html" class="linkConstructor">Iterator</a></li>
<li><a href="../symbols/List.html" class="linkConstructor">List</a></li>
<li><a href="../symbols/Map.html" class="linkConstructor">Map</a></li>
<li><a href="../symbols/Set.html" class="linkConstructor">Set</a></li>
</ul>
</div>
</div>
</div> <!-- /class="sidebar-nav -->
<!-- end publish.classesIndex -->
</div>
<div id="contentBody" class="col-md-10">
<div class="searchsumm">
<div class="table-wrap">
<div class="table-cell" id="apisearch" data-base="../">
<div class="title">Search API</div>
<div class="field">
<label for="search-field" class="search-icon"></label>
<input id="search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
</div>
<div class="table-cell" id="apisumm">
<input type="checkbox" id="showsumms" />
<label class="apisumms" for="showsumms">Show Summaries</label>
</div>
</div>
</div>
<!-- ============================== header ================================= -->
<div id="header" class="fineprint">
<b>GoJS</b>® Diagramming Components<br/>version 1.8.36 for JavaScript/HTML<br/>by <a href="https://www.nwoods.com/">Northwoods Software®</a>
</div>
<!-- ============================== class title ============================ -->
<h2 class="classTitle">
Class DiagramEvent
</h2>
<!-- ============================== class summary ========================== -->
<p class="classsummary">
A DiagramEvent represents a more abstract event than an <a href="../symbols/InputEvent.html" class="linkConstructor">InputEvent</a>.
They are raised on the <a href="../symbols/Diagram.html" class="linkConstructor">Diagram</a> class.
One can receive such events by registering a DiagramEvent listener on a Diagram
by calling <a href="../symbols/Diagram.html#addDiagramListener" class="linkMethod">Diagram.addDiagramListener</a>.
The listener function, when called, will be passed an instance of a <a href="../symbols/DiagramEvent.html" class="linkConstructor">DiagramEvent</a>.
Use the <a href="../symbols/DiagramEvent.html#name" class="linkProperty">name</a> property to decide what kind of diagram event it is.
The <a href="../symbols/DiagramEvent.html#diagram" class="linkProperty">diagram</a> property refers to the Diagram, and you can get additional information
from that, such as the <a href="../symbols/Diagram.html#lastInput" class="linkProperty">Diagram.lastInput</a>, which in turn provides information
such as <a href="../symbols/InputEvent.html#documentPoint" class="linkProperty">InputEvent.documentPoint</a> that may be relevant for that kind of DiagramEvent.
<p>
The <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">subject</a> and <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">parameter</a> properties optionally provide additional information
about the diagram event. The subject could be a collection of <a href="../symbols/Part.html" class="linkConstructor">Part</a>s or it could be
an individual object such as a <a href="../symbols/Link.html" class="linkConstructor">Link</a> or a <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a> within a <a href="../symbols/Node.html" class="linkConstructor">Node</a>.
Everything depends on the kind of diagram event that it is.
<p>
Some DiagramEvents such as "ObjectSingleClicked" or "BackgroundDoubleClicked" are normally
associated with <a href="../symbols/InputEvent.html" class="linkConstructor">InputEvent</a>s.
Some DiagramEvents such as "SelectionMoved" or "PartRotated" are associated with the
results of <a href="../symbols/Tool.html" class="linkConstructor">Tool</a>-handled gestures or <a href="../symbols/CommandHandler.html" class="linkConstructor">CommandHandler</a> 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 <a href="../symbols/Diagram.html#position" class="linkProperty">Diagram.position</a> and <a href="../symbols/Diagram.html#scale" class="linkProperty">Diagram.scale</a> properties.
<p>
DiagramEvents that occur during a transaction may be called before the state of the whole diagram has settled down.
This often means that such events occur before a layout, so nodes may not have their final positions,
links may not have their final routes, and the <a>Diagram.documentBounds</a> and <a>Diagram.viewportBounds</a>
may not yet have been updated.
Such events may make additional changes to the diagram, which may in turn result in additional side-effects.
<p>
DiagramEvents that occur outside of a transaction require you to start and commit a transaction around any side-effects that you want to do.
However, some DiagramEvents do not allow you to make any changes to the Diagram or Model.
<p>
Currently defined diagram event names include:
<ul>
<li><b>"AnimationStarting"</b>, an animation is about to start;<br/>
do not modify the Diagram or its Model in the event listener.</li>
<li><b>"AnimationFinished"</b>, an animation just completed;<br/>
do not modify the Diagram or its Model in the event listener.</li>
<li><b>"BackgroundSingleClicked"</b>, a click that was not on any Part;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"BackgroundDoubleClicked"</b>, a double-click that was not on any Part;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"BackgroundContextClicked"</b>, a context-click that was not on any Part;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"ChangingSelection"</b>, an operation is about to change the <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a> collection;<br/>
do not make any changes to the selection or the diagram in the event listener;
note that just setting <a>Part.isSelected</a> will not raise this event, but tools and commands will.</li>
<li><b>"ChangedSelection"</b>, an operation has just changed the <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a> collection;<br/>
do not make any changes to the selection or the diagram in the event listener;
note that just setting <a>Part.isSelected</a> will not raise this event, but tools and commands will.</li>
<li><b>"ClipboardChanged"</b>, Parts have been copied to the clipboard by <a href="../symbols/CommandHandler.html#copySelection" class="linkMethod">CommandHandler.copySelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Part.html" class="linkConstructor">Part</a>s;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"ClipboardPasted"</b>, Parts have been copied from the clipboard into the Diagram by <a href="../symbols/CommandHandler.html#pasteSelection" class="linkMethod">CommandHandler.pasteSelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a>,<br/>
and this is called within a transaction.</li>
<li><b>"DocumentBoundsChanged"</b>, the area of the diagram's Parts, <a href="../symbols/Diagram.html#documentBounds" class="linkProperty">Diagram.documentBounds</a>, has changed;<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the old <a href="../symbols/Rect.html" class="linkConstructor">Rect</a></li>
<li><b>"ExternalObjectsDropped"</b>, Parts have been copied into the Diagram by drag-and-drop from outside of the Diagram;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the set of <a href="../symbols/Part.html" class="linkConstructor">Part</a>s that were dropped (which is also the <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a>),
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the source <a href="../symbols/Diagram.html" class="linkConstructor">Diagram</a>,
and this is called within a transaction.</li>
<li><b>"InitialLayoutCompleted"</b>, the whole diagram layout has updated for the first time since a major change to the Diagram, such as replacing the Model;<br/>
if you make any changes, you do not need to perform a transaction.</li>
<li><b>"LayoutCompleted"</b>, the whole diagram layout has just been updated;<br/>
if you make any changes, you do not need to perform a transaction.</li>
<li><b>"LinkDrawn"</b>, the user has just created a new Link using <a href="../symbols/LinkingTool.html" class="linkConstructor">LinkingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the new <a href="../symbols/Link.html" class="linkConstructor">Link</a>,<br/>
and this is called within a transaction.</li>
<li><b>"LinkRelinked"</b>, the user has just reconnected an existing Link using <a href="../symbols/RelinkingTool.html" class="linkConstructor">RelinkingTool</a> or <a href="../symbols/DraggingTool.html" class="linkConstructor">DraggingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the modified <a href="../symbols/Link.html" class="linkConstructor">Link</a>,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a> port that the link was disconnected from,<br/>
and this is called within a transaction.</li>
<li><b>"LinkReshaped"</b>, the user has just rerouted an existing Link using <a href="../symbols/LinkReshapingTool.html" class="linkConstructor">LinkReshapingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the modified <a href="../symbols/Link.html" class="linkConstructor">Link</a>,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the List of Points of the link's original route,
and this is called within a transaction.</li>
<li><b>"Modified"</b>, the <a href="../symbols/Diagram.html#isModified" class="linkProperty">Diagram.isModified</a> property has been set to a new value --
useful for marking a window as having been modified since the last save;<br/>
do not modify the Diagram or its Model in the event listener.</li>
<li><b>"ObjectSingleClicked"</b>, a click that occurred on a GraphObject;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a>;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"ObjectDoubleClicked"</b>, a double-click that occurred on a GraphObject;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a>;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"ObjectContextClicked"</b>, a context-click that occurred on a GraphObject;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a>;<br/>
if you make any changes, start and commit your own transaction.</li>
<li><b>"PartCreated"</b>, the user inserted a new Part by <a href="../symbols/ClickCreatingTool.html" class="linkConstructor">ClickCreatingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the new <a href="../symbols/Part.html" class="linkConstructor">Part</a>,<br/>
and this is called within a transaction.</li>
<li><b>"PartResized"</b>, the user has changed the size of a GraphObject by <a href="../symbols/ResizingTool.html" class="linkConstructor">ResizingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a>,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the original Size,<br/>
and this is called within a transaction.</li>
<li><b>"PartRotated"</b>, the user has changed the angle of a GraphObject by <a href="../symbols/RotatingTool.html" class="linkConstructor">RotatingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/GraphObject.html" class="linkConstructor">GraphObject</a>,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the original angle in degrees,<br/>
and this is called within a transaction.</li>
<li><b>"SelectionMoved"</b>, the user has moved selected Parts by <a href="../symbols/DraggingTool.html" class="linkConstructor">DraggingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the moved <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a>,<br/>
and this is called within a transaction.</li>
<li><b>"SelectionCopied"</b>, the user has copied selected Parts by <a href="../symbols/DraggingTool.html" class="linkConstructor">DraggingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the newly copied <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a>,<br/>
and this is called within a transaction.</li>
<li><b>"SelectionDeleted"</b>, the user has deleted selected Parts by <a href="../symbols/CommandHandler.html#deleteSelection" class="linkMethod">CommandHandler.deleteSelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Part.html" class="linkConstructor">Part</a>s that were deleted,<br/>
and this is called within a transaction.</li>
<li><b>"SelectionDeleting"</b>, the user is about to delete selected Parts by <a href="../symbols/CommandHandler.html#deleteSelection" class="linkMethod">CommandHandler.deleteSelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the <a href="../symbols/Diagram.html#selection" class="linkProperty">Diagram.selection</a> collection of Parts to be deleted.</li>
<li><b>"SelectionGrouped"</b>, the user has made a new Group out of the selected Parts by <a href="../symbols/CommandHandler.html#groupSelection" class="linkMethod">CommandHandler.groupSelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the new <a href="../symbols/Group.html" class="linkConstructor">Group</a>,<br/>
and this is called within a transaction.</li>
<li><b>"SelectionUngrouped"</b>, the user has removed a selected Group but kept its members by <a href="../symbols/CommandHandler.html#ungroupSelection" class="linkMethod">CommandHandler.ungroupSelection</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Group.html" class="linkConstructor">Group</a>s that were ungrouped,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the collection of former member <a href="../symbols/Part.html" class="linkConstructor">Part</a>s that were ungrouped,<br/>
and this is called within a transaction.</li>
<li><b>"SubGraphCollapsed"</b>, the user has collapsed selected Groups by <a href="../symbols/CommandHandler.html#collapseSubGraph" class="linkMethod">CommandHandler.collapseSubGraph</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Group.html" class="linkConstructor">Group</a>s that were collapsed,<br/>
and this is called within a transaction.</li>
<li><b>"SubGraphExpanded"</b>, the user has expanded selected Groups by <a href="../symbols/CommandHandler.html#expandSubGraph" class="linkMethod">CommandHandler.expandSubGraph</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Group.html" class="linkConstructor">Group</a>s that were expanded,<br/>
and this is called within a transaction.</li>
<li><b>"TextEdited"</b>, the user has changed the string value of a TextBlock by <a href="../symbols/TextEditingTool.html" class="linkConstructor">TextEditingTool</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the edited <a href="../symbols/TextBlock.html" class="linkConstructor">TextBlock</a>,<br/>
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is the original string,<br/>
and this is called within a transaction.</li>
<li><b>"TreeCollapsed"</b>, the user has collapsed selected Nodes with subtrees by <a href="../symbols/CommandHandler.html#collapseTree" class="linkMethod">CommandHandler.collapseTree</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Node.html" class="linkConstructor">Node</a>s that were collapsed,<br/>
and this is called within a transaction.</li>
<li><b>"TreeExpanded"</b>, the user has expanded selected Nodes with subtrees by <a href="../symbols/CommandHandler.html#expandTree" class="linkMethod">CommandHandler.expandTree</a>;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is the collection of <a href="../symbols/Node.html" class="linkConstructor">Node</a>s that were expanded,<br/>
and this is called within a transaction.</li>
<li><b>"ViewportBoundsChanged"</b>, the visible area of the Diagram, <a href="../symbols/Diagram.html#viewportBounds" class="linkProperty">Diagram.viewportBounds</a>, has changed;<br/>
the <a href="../symbols/DiagramEvent.html#subject" class="linkProperty">DiagramEvent.subject</a> is an object whose "scale" property is the old <a href="../symbols/Diagram.html#scale" class="linkProperty">Diagram.scale</a> value,
whose "position" property is the old <a href="../symbols/Diagram.html#position" class="linkProperty">Diagram.position</a> value,
and whose "bounds" property is the old <a href="../symbols/Diagram.html#viewportBounds" class="linkProperty">Diagram.viewportBounds</a> value;
the <a href="../symbols/DiagramEvent.html#parameter" class="linkProperty">DiagramEvent.parameter</a> is also the old viewportBounds <a href="../symbols/Rect.html" class="linkConstructor">Rect</a>.</li>
</ul>
</p>
<!-- ============================== constructor summary ==================== -->
<h2 id="constructor" class="summaryCaption"> Constructor <span class="nodetails"> Summary</span><span class="details"> Details</span></h2>
<div class="table-responsive">
<table class="summaryTable table table-bordered table-condensed" summary="A summary of the constructor documented in the class DiagramEvent.">
<thead>
<tr>
<th scope="col" class="name">Name</th>
<th scope="col" class="description">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name" >
<div class="name">
DiagramEvent()
</div>
</td>
<td class="description">
<div class="description">
<!--newp--><p><p>The DiagramEvent class constructor produces an empty DiagramEvent.<span class="nodetails" id="xconDiagramEvent"><a class="morelink" onclick="hst('conDiagramEvent')">More...</a></span> <span class="details" id="conDiagramEvent">
You should not need to call this constructor.</span>
</div>
</td>
</tr>
</tbody>
</table>
</div><!-- class="table-responsive">-->
<!-- ============================== properties summary ===================== -->
<h2 class="summaryCaption">Properties<span class="nodetails"> Summary</span><span class="details"> Details</span></h2>
<div class="table-responsive">
<table class="summaryTable table table-bordered table-condensed" summary="A summary of the properties documented in the class DiagramEvent.">
<thead>
<tr>
<th scope="col" class="name">Name, Value Type</th>
<th scope="col" class="description">Description</th>
</tr>
</thead>
<tbody>
<tr id="diagram" >
<td class="name">
<div class="name">
diagram
</div>
<div class="attributes">
<span class="light">{<a href="../symbols/Diagram.html" class="linkConstructor">Diagram</a>}</span>
</div>
</td>
<td class="description">
<div class="description">
<!--newp <p> -->
<p>Gets the diagram associated with the event.
</div>
</td>
</tr>
<tr id="name" >
<td class="name">
<div class="name">
name
</div>
<div class="attributes">
<span class="light">{string}</span>
</div>
</td>
<td class="description">
<div class="description">
<!--newp <p> -->
<p>Gets or sets the name of the kind of diagram event that this represents.<span class="nodetails" id="xpropname"><a class="morelink" onclick="hst('propname')">More...</a></span> <span class="details" id="propname">
This property should always be set to one of the recognized list of names,
as listed in the documentation for <a href="../symbols/DiagramEvent.html" class="linkConstructor">DiagramEvent</a>.</span>
</div>
</td>
</tr>
<tr id="parameter" >
<td class="name">
<div class="name">
parameter
</div>
<div class="attributes">
<span class="light">{*}</span>
</div>
</td>
<td class="description">
<div class="description">
<!--newp <p> -->
<p>Gets or sets an optional object that describes the change to the subject of the diagram event.<span class="nodetails" id="xpropparameter"><a class="morelink" onclick="hst('propparameter')">More...</a></span> <span class="details" id="propparameter">
This property defaults to null.</span>
</div>
</td>
</tr>
<tr id="subject" >
<td class="name">
<div class="name">
subject
</div>
<div class="attributes">
<span class="light">{Object}</span>
</div>
</td>
<td class="description">
<div class="description">
<!--newp <p> -->
<p>Gets or sets an optional object that is the subject of the diagram event.<span class="nodetails" id="xpropsubject"><a class="morelink" onclick="hst('propsubject')">More...</a></span> <span class="details" id="propsubject">
This property defaults to null.</span>
</div>
</td>
</tr>
</tbody>
</table>
</div><!-- class="table-responsive">-->
<!-- ============================== methods summary ======================== -->
<!-- ============================== events summary ======================== -->
<!-- ============================== fields summary ===================== -->
<!-- ============================== constructor details ==================== -->
</div> <!-- end contentBody -->
</div> <!-- end container-fluid -->
<!-- ============================== footer ================================= -->
<div id="footer" class="fineprint" style="clear:both">
Copyright © 1998-2019 by <a href="https://www.nwoods.com/">Northwoods Software Corporation.</a>
</div>
</body>
</html>