yFiles for Silverlight Changelog
yFiles for Silverlight 2.4 - Changes Since 2.3.0.3
Major Features Added
Viewer
GraphClipboard
now supports copying independent items. This allows the user to copy labels, ports, bends, or edges to other elements without having to copy their owners. Also this technique allows for copying an item (for example a label) to multiple target elements at once.- The
GraphClipboard
now supports an optional target location for pasting and the new methodGraphEditorInputMode.PasteAtLocation
can be used for this end, too. In addition,ApplicationCommands.Paste
now supports an optional parameter of typeIPoint
to provide a target location. GraphEditorInputMode
now provides default action for duplicating single graph items or whole subgraphs. This also works with incomplete subgraphs, for example in a tree, it is possible to duplicate a subtree and the tree will never be disconnected.
In addition, the new commandGraphCommands.DuplicateSelectionCommand
(shortcut: Ctrl-D) and the new methodGraphClipboard.Duplicate
can be used to duplicate selected items without altering the clipboard contents.GraphEditorInputMode
now provides a default action for reversing edges. To this end, the methodsReverseEdge
andReverseEdges
have been added toGraphEditorInputMode
. Also, the new commandGraphCommands.ReverseEdgesCommand
(shortcut: Ctrl-R) has been added.- Node and edge labels can now snap to particular locations while moving them interactively. Both types of labels can be aligned horizontally or vertically to their original location. In addition, a node label can be aligned with the borders or the center of its owner, and during resizing of that owner, smartly keeps its relative location to the snapped position. An edge label can be snapped on the path of its owner, or at particular distances of it.
This feature can be enabled and configured with anLabelSnapContext
and is available for labels with one of these label models:SmartEdgeLabelModel
,FreeEdgeLabelModel
,FreeNodeLabelModel
, andFreeLabelModel
. - Interactive label editing and creation has the following new features:
- The current label visual can be hidden while the text editor is shown to reduce visual clutter. This feature is enabled by default and can be controlled through the property
GraphEditorInputMode.HideLabelDuringEditing
. GraphEditorInputMode
andTableEditorInputMode
provide new eventsLabelTextEditingStarted
andLabelTextEditingCanceled
that are raised directly before the label text editor is shown and after the label editing has been canceled, respectively.- Double clicking nodes and edges now opens the label editor. An existing label can be double clicked to edit the label text. This feature can be disabled with the property
GraphEditorInputMode.DoubleClickLabelEditingAllowed
. IEditLabelHelper
implementations provided by theILabel
's lookup can now be used to forbid or customize the editing of individual labels. ClassLabelDecorator
provides a new propertyEditLabelHelperDecorator
to customize this feature.GraphEditorInputMode.EditLabel
andTableEditorInputMode.EditLabel
can now be used withSimpleLabel
instances. This provides editing capabilities for dummy elements such as legends, page headers or other textual elements.
- Uses the various callback methods on
GraphEditorInputMode
,TableEditorInputMode
andIEditLabelHelper
implementations in a consistent way, regardless of how many labels or labeled items are edited or added, and independent from how the editing/label creation process has been started (e.g. through a command or programmatically through the input mode convenience methods). - Determines the actual labeled item that is modified when multiple elements are selected in a consistent way.
- The current label visual can be hidden while the text editor is shown to reduce visual clutter. This feature is enabled by default and can be controlled through the property
Layout
- Added new layout algorithm
RadialLayouter
that places nodes on concentric circles. Edges are routed in a radial fashion using one of several routing strategies. - Added support for terminating (layout) algorithms prematurely. To this end, new class
AbortHandler
provides methods for requesting early but graceful termination (see methodStop
) and immediate termination (see methodCancel
).The following layout algorithms have at least rudimentary support for immediate termination: Layout Algorithms Routing Algorithms Other Algorithms BalloonLayouter
CircularLayouter
CompactOrthogonalLayouter
DirectedOrthogonalLayouter
GenericTreeLayouter
GRIP
HierarchicGroupLayouter
HierarchicLayouter
IncrementalHierarchicLayouter
OrganicLayouter
OrthogonalGroupLayouter
OrthogonalLayouter
PartialLayouter
RadialLayouter
RecursiveGroupLayouter
SmartOrganicLayouter
BusRouter
Polyline.EdgeRouter
OrganicEdgeRouter
OrthogonalEdgeRouter
GreedyMISLabeling
SALabeling
The following layout algorithms also support graceful early termination: Layout Algorithms Routing Algorithms Other Algorithms HierarchicGroupLayouter
HierarchicLayouter
IncrementalHierarchicLayouter
OrganicLayouter
SmartOrganicLayouter
Polyline.EdgeRouter
SALabeling
- Added support for parallel execution of computationally intensive tasks.
Layout algorithmsSmartOrganicLayouter
andOrganicLayouter
may take advantage of multiple threads for layout calculations. Parallel execution is enabled using the algorithms'MultiThreadingAllowed
property.
InterfaceITaskExecutor
and factory classTaskExecutorFactory
make up the programmatic interface for the new concurrency support. - Introduced concept of node halos. Halos are reserved space around a node in which layout algorithms will not place other graph elements. Node halos are modelled using class
NodeHalo
.The following layout algorithms support node halos: Layout Algorithms Routing Algorithms Other Algorithms BalloonLayouter
CircularLayouter
CompactOrthogonalLayouter
ComponentLayouter
DirectedOrthogonalLayouter
GenericTreeLayouter
IncrementalHierarchicLayouter
OrthogonalGroupLayouter
OrthogonalLayouter
RadialLayouter
RecursiveGroupLayouter
SmartOrganicLayouter
TreeLayouter
Polyline.EdgeRouter
SelfLoopLayouter
GreedyMISLabeling
SALabeling
InsetsGroupBoundsCalculator
MinimumSizeGroupBoundsCalculator
SmartOrganicLayouter
: Added support for partition grid layout. SeePartitionGrid
.
Minor Features Added
Viewer
GraphEditorInputMode
got support for cyclic click selection. This helps in conveniently selecting items that are hidden behind other items. By default, this features is bound to the Alt-Key being pressed. It can be disabled by setting theCyclicSelectionRecognizer
property toEventRecognizers.Never
.ItemDropInputMode
is a newDropInputMode
that facilitates subclasses that support preview and snapping of the dragged item as well as highlighting potential drop targets.NodeDropInputMode
andStripeDropInputMode
have been refactored to useItemDropInputMode
as base class.ItemHoverInputMode
is a newIInputMode
that fires events when the mouse enters or leaves the visualization of a graph item.GraphEditorInputMode
andGraphViewerInputMode
provide a newCanvasClicked
event to detect clicks on an empty canvas location.- Node ports can now be moved by dragging their
IHandle
. - When zooming while editing a label, the label text editor now stays at its minimum (maximum) size when the zoom level becomes smaller (larger) than the specified threshold. Previously, the label text editor jumped back to the size of zoom level
1.0
for such values. GraphClipboard
has new propertiesCopyItems
,IndependentItems
, andDependentItems
that allow for restricting the types of items that can be copied at all, independently from their owners, or implicitly through their owners, respectively.GraphViewerInputMode
andGraphEditorInputMode
: TheirClickInputMode
now delivers both left and right clicks.GraphViewerInputMode
: The click hit test order can now be configured by propertyClickHitTestOrder
.GraphEditorInputMode
andGraphViewerInputMode
provide an explicit hit test order for double clicks that can be changed through theDoubleClickHitTestOrder
property. By default, this hit test order prefers labels over other graph elements.- Added new methods
ClickInputMode.PreventNextDoubleClick
andTapInputMode.PreventNextDoubleTap
that can be used in event handlers for single clicks/taps to prevent that this click can become part of a double click event. NodeDropInputMode
can now optionally drop nodes onto leaf nodes and thus convert the leaves into group nodes. Also it is possible to drop nodes into collapsed folder nodes. For both use-cases, an opt-in property has been added and a predicate property allows for fine-grained control over this feature.- Similarly, leaf nodes can now be the target of a reparenting gesture if the property
GraphEditorInputMode.ReparentToLeavesAllowed
is enabled. In this case, leaves are converted into group nodes. - Added support for deleting bends in a way that an orthogonal edge remains orthogonal after removing the bends. The new property
GraphEditorInputMode.OrthogonalBendRemoval
enables/disables this feature. GraphViewerInputMode
now supports multi-selection via Ctrl+Click and marquee selection. The latter is disabled by default.OverviewInputMode
and theGraphOverviewControl
have been optimized to improve the user experience when used on touch devices.OverviewInputMode
can be customized more easily. Minor modes can be replaced and adjusted, as well as the list of available default command bindings can be modified.- Improved
GraphModelManager
to allow for easier customizations. PropertyUseHierarchicNesting
was added to allow for adding custom logic that uses a different approach to hierarchic nesting. Also the return types of some of the factory methods where made less restrictive to allow for further modifications. FoldingManager
now offers two convenience methods,UpdateViewStates(INode)
andUpdateViewStates(IEdge)
, that will trigger update calls onIDummyNodeConverter
andIDummyEdgeConverter
for elements that are currently being displayed in a view. This makes it easier to synchronize state between the master graph and the folded graph views in case this is not automatically performed by the default implementation.
Layout
BalloonLayouter
: Added support for integrated node and edge labeling. See new propertiesIntegratedEdgeLabeling
,IntegratedNodeLabeling
, andNodeLabelingPolicy
.BalloonLayouter
: Added support for different policies to align nodes having the same root node. See new propertyChildAlignmentPolicy
.BalloonLayouter
: Added support for interleaved child node placement. With interleaved placement, child nodes are placed at different distances to their parent node to achieve a more compact layout. See new propertyInterleavedMode
.IncrementalHierarchicLayouter
: Improved partition grid support. Nodes can now be mapped to a multi-lane partition cell identifier, i.e., a cell spanning multiple columns and rows. See classPartitionGrid
.IncrementalHierarchicLayouter
: Improved edge label placement. Edge labels with preferred placement at source/target are placed closer to the corresponding node. Additionally,SimplexNodePlacer
offers the option to place adjacent edge labels in a compact, stacked style. See new propertyLabelCompaction
.Polyline.EdgeRouter
: Added a fine-granular configuration option to weigh the crossing costs for each label using the data provider look-up keyEdgeRouter.LabelCrossingCostFactorDpKey
.Polyline.EdgeRouter
: Added propertyIgnoreInnerNodeLabels
that allows to ignore node labels that are inside the bounds of their owner so they may be crossed by edges. This is especially useful if labels of group nodes may be crossed while outer labels of non-group nodes may not.Polyline.EdgeRouter
: Added support for customizing the order in which edges are routed. See new propertyEdgeOrderComparator
.GenericTreeLayouter
: When enablingGenericTreeLayouter.IntegratedNodeLabeling
and/orGenericTreeLayouter.IntegratedEdgeLabeling
, the respective labels will be taken into account during the calculation of group bounds.DelegatingNodePlacer
: Added keyDelegatingNodePlacer.LeftRightDpKey
that allows choosing on which side a node is placed.PartialLayouter
: Now supports handling of directed and undirected edges. See data provider keyDirectedEdgesDpKey
.FixNodeLayoutStage
: Added additionalFixPointPolicy
sUpperRight
,LowerRight
, andLowerLeft
.LabelLayoutTranslator
: Added propertiesWriteBackRelativeEdgeLabelLocation
andWriteBackRelativeNodeLabelLocation
that allow a core layouter to specify new node or edge label locations relative to the label's owner.LabelLayoutKeys
: Added keyIGNORE_LABEL_KEY
that allows specifying which edge and node labels should be ignored during layout calculations.- Added new class
OrganicRemoveOverlapsStage
that removes node overlaps while respecting a specified minimal node distance. Unlike the approach implemented in classRemoveOverlapsLayoutStage
, this approach tries to keep the original layout structure, i.e., it tries to keep the geometric distance between the nodes. - Added class
StraightLineEdgeRouter
that routes edges as straight lines considering specified port constraints.
Improvements
Viewer
- Various performance improvements for the rendering and the selection handling. This affects, amongst others,
ShapeNodeStyle
and styles that use aGeneralPath
. GraphEditorInputMode.DetailSelectionRecognizer
is now also applied for double clicks to determine the clicked item.- Improved options for internationalization of strings used in the library. Now custom resources with the names
yWorks.Canvas.CanvasResources
andyWorks.yFiles.GraphResources
can be added to the application project and override strings the library uses. GraphEditorInputMode
andGraphViewerInputMode
don't select or focus graph items styled with a void style (VoidNodeStyle
,VoidEdgeStyle
,VoidLabelStyle
, andVoidPortStyle
). The new propertyVoidStylesIgnored
specifies whether this feature is enabled.GraphEditorInputMode
andGraphViewerInputMode
: the new protected methodShouldSelect
can be overridden to determine whether an item can be selected in general.DropInputMode
: Added propertyLastDragEventArgs
.OverviewInputMode
: The new propertyMargins
specifies margins for the visible area of the boundGraphOverviewControl
. The new protected methodUpdateVisibleArea
provides further means for customizing the visible area.CompositePositionHandler
: Added methodsGetPositionHandler
andGetHandle
to retrieve an earlier addedIPositionHandler
orIHandle
.PortRelocationHandle
s now triggers theEdgePortsChanged
event of theGraphEditorInputMode
.EdgeStyleDecorationInstaller
can now be used with self loops without bends, too.ContextConfigurator
: The new propertyZoom
determines the zoom value that should be assumed on the canvas when creating the visual. This can affect the rendering of zoom dependent visuals.TableLayoutConfigurator
: Improved support for routing algorithms.IGraph
: The collection models of graph items returned by the propertiesNodes
,Edges
, etc. now support the methodsRemove
andClear
to remove graph items from the graph. Note that calling the methodAdd
is still not allowed.GraphModelManager
: New callback methodOnGraphChanged
.LayoutExecutor
: The new propertyConsiderViewportLimiter
can be enabled to let the target viewport after a layout respect theViewportLimiter
of theGraphControl
.
TheViewportAnimation
has a new propertyConsiderViewportLimiter
for the same purpose.LayoutGraphAdapter
now adds data providers that map each node, edge and label of aLayoutGraph
to their correspondingIModelItem
in the originalIGraph
. Especially, these data providers are available if a layout is run with aLayoutExecutor
or the convenience methodsLayoutExtensions.MorphLayout
andLayoutExtensions.ApplyLayout
.GeomSupport
: The new methodCreateSmoothedPath
creates a new path as copy of a given one but with smoothed bends.IconLabelStyle
: The icon is added to the hit test area for mouse clicks and marquee selection. This can be switched off by overridingIconLabelStyleRenderer.ShouldHitTestIcon
.CanvasControl
: MethodFitContent
now respects theViewportLimiter
. This might result in zoom levels greater than1.0
.DefaultDummyEdgeConverter
now synchronizes theTag
property of the first label if label synchronization is enabled.GraphCopier
has been improved to facilitate manipulation of the copied items:- The new events
NodeCopied
,EdgeCopied
,LabelCopied
, andPortCopied
are dispatched after a model item has been copied. - The method
GetOrCreateCopy<T>
is now public to facilitate copying of, for example, node tags.
- The new events
GraphClipboard
: In hierarchically organized graphs, nodes are now pasted into their previous parent group, the group at their target position, or the root, depending on the new propertyParentNodeDetection
.- Automatic installation of the integrated API documentation is now available for Visual Studio 2013 and 2015 and enabled for all supported Visual Studio versions by default.
Algorithms
Dfs
: Added methodCancel
that can be used by subclasses to cancel the search.Cycles
: Improved methodFindCycle
to stop the search as soon as the first cycle has been found.GraphConnectivity
: Improved methodMakeBiconnected
to work with graphs with self-loops (i.e. edges whose source node is also the target node).Groups
: Replaced recursive implementation of methodBiconnectedComponentGrouping
with an iterative algorithm to support larger graphs.
Layout
IncrementalHierarchicLayouter
: The default sequencing phase has been improved to produce less crossings and run faster.IncrementalHierarchicLayouter
: Now prevents overlaps among same layer edges attached to group nodes.IncrementalHierarchicLayouter
: Selfloop routing now takes the layout flow into account. For layout orientation top-to-bottom, selfloops will by default exit on the left or right and enter on top.IncrementalHierarchicLayouter
: Added option to route selfloops like backloops (starting at the bottom of the node and ending at the top of the node) when backloop routing is enabled.IncrementalHierarchicLayouter
: During layering, edges connected to group nodes may be redirected and replaced by dummy edges connected to the children of the group node. For these dummy edgesILayoutDataProvider.GetEdgeData
now returns anIEdgeData
of the new typeEdgeDataType.RedirectedGroupEdge
.PCListOptimizer
: Improved port candidate assignment calculated by methodOptimizeAfterSequencing
.SmartOrganicLayouter
: Now uses a more sophisticated approach to remove node overlaps if the scope is set toScope.All
and the quality to time ratio is greater than or equal to0.7
(propertyQualityTimeRatio
).InteractiveOrganicLayouter
: MethodStartLayout
now takes advantage of multiple threads for layout calculation which may reduce the required runtime.BalloonLayouter
: Reduced gaps between adjacent nodes.PartitionLayouter
: Added nested classPartitionLayouter.PolylineInterEdgeRouter
that routes inter-edges using classPolyline.EdgeRouter
.PartialLayouter
: Now considers port constraints independent of the specified layout orientation. Note that port constraints are only considered if the core layout algorithm supports port constraints as well.PartialLayouter.StraightLineEdgeRouter
: Added support for port constraints.RecursiveGroupLayouter
: Added optionReplacePortConstraints
that replaces port constraints by port candidates and, thus, may improve the layout result.Polyline.EdgeRouter
: Improved support for port candidate sets (see classPortCandidateSet
).Polyline.EdgeRouter
: Rerouting improved to provide better results.Polyline.EdgeRouter
: Memory usage has been reduced.Polyline.EdgeRouter
: Added penalty setting for edge length. SeePenaltySettings.EdgeLengthPenalty
.Polyline.EdgeRouter
: Added four predefined optimization strategies. SeePenaltySettings.OptimizationBalanced
,PenaltySettings.OptimizationEdgeBends
,PenaltySettings.OptimizationEdgeCrossings
, andPenaltySettings.OptimizationEdgeLengths
.Polyline.EdgeRouter
: Default penalty settings for minimal node to edge distance, minimal group node to edge distance, minimal first and last segment length, and bends in node to edge distance increased. As a result, these restrictions are considered more strongly.Polyline.EdgeRouter
: Now avoids very small octilinear segments.Polyline.EdgeRouter
: Edge grouping improved to keep edge segments grouped longer and to consider the paths of fixed edges when calculating the paths of edges having the same edge group.Polyline.EdgeRouter
: When using polyline routing, short orthogonal edge segments in a monotonic path section are replaced by a single diagonal segment instead of a short diagonal segment followed by an orthogonal segment followed by a second short diagonal segment.DirectedOrthogonalLayouter
andOrthogonalGroupLayouter
: Added optimization step that reduces the number of perceived bends. See new propertyPerceivedBendsOptimization
.OrthogonalLayouter
,OrthogonalGroupLayouter
andDirectedOrthogonalLayouter
: Added optimization step that aligns degree one nodes (i.e. nodes with one incident edge) that have the same neighbor. See new propertyAlignDegreeOneNodes
.OrthogonalGroupLayouter
: Improved routing and edge labeling for self-loops of normal (non-group) nodes.LayoutTool
: Added new rectangle arrangement methodArrangeRectangleMultiRows
suitable for arranging rows of rectangles with highly different sizes.ComponentLayouter
: Added the following new component arrangement strategies toComponentArrangementStyles
that are suitable for components with highly different sizes:MultiRows
,MultiRowsCompact
,MultiRowsHeightConstrained
,MultiRowsHeightConstrainedCompact
,MultiRowsWidthConstrained
, andMultiRowsWidthConstrainedCompact
Incompatible Changes
Changes in Default Behavior
GraphEditorInputMode
now by default supports the newGraphCommands.DuplicateCommand
that is bound to keyboard shortcut Ctrl-D. If this behavior is undesired new behavior, theDuplicateAllowed
property can be set tofalse
.TableEditorInputMode
now only handles left mouse clicks by default, which is consistent with the rest of the library.- The clipboard now supports copying and pasting of items independently from their owning elements. E.g. single selected labels can be copied to other elements, as well as edges without their source and target nodes. This behavior can be reverted to the old behavior by setting
GraphClipboard
'sIndependentItems
toNone
. GraphEditorInputMode
now by default allows for reversing selected edges using the Ctrl-R keyboard shortcut and the newGraphCommands.ReverseEdgeCommand
. This new behavior can be turned off by setting theEdgeReversalAllowed
property tofalse
.GraphEditorInputMode
andGraphViewerInputMode
: The default click actions that change the selection and create new nodes are only triggered on left mouse clicks now.- Previously, ports at nodes and edges that were copied and pasted to and from the clipboard were all copied, even if there where no edges attached to them after the operation. Now those empty ports are not copied/pasted anymore unless the
PortDefaults
'AutoCleanup
property is set to false or they were unoccupied before the operation already. In order to restore the old behavior, where all ports were copied, regardless of edges where adjacent to them, make sure to include them in the core predicate, since this behavior change just affects ports that had previously not been accepted by the core predicate function. CanvasControl
: MethodFitContent
now respects theViewportLimiter
. This might result in zoom levels greater than1.0
.GraphEditorInputMode
'sNodeCreated
event may now report nodes that are not part of the graph, when the user has dropped a node viaNodeDropInputMode
and the newNodeDropInputMode.FolderNodeParentsAllowed
property is enabled. By default this feature is disabled, though.IReparentNodeHandler
'sIsValidParent
method may now also be queried if the newGraphEditorInputMode.ReparentToLeavesAllowed
property is enabled. By default this property is disabled, though. Note that the method will also be queried if the reparent handler is used outside the context ofGraphEditorInputMode
.IValueSerializerContext.Instance
inside GraphML writing code now provide the object that should be converted, not the parent object. If you need to access the actual parent object, you can use theOwner
property on theGraphMLValueSerializerContext
implementation of this interface.GraphMLIOHandler.QueryReferenceId
now never is fired forMarkupExtensions
and other proxy objects for serialization, only for the original object references.Polyline.EdgeRouter
: MethodDoLayout
now throws anArgumentException
if there is a node with zero width or height in the given graph.FixedGroupLayoutStage
: MethodOrthogonalEdgeRouter
now returns an instance of classPolyline.EdgeRouter
instead of classOrthogonalEdgeRouter
.ComponentLayouter
: PropertyPreferredLayoutSize
now throws anArgumentException
when setting the preferred size to negative values or zero.- Changed default behavior of edge label placement in layouters with integrated edge labeling when using
LabelPlacements.Anywhere
. Now edge labels are placed on the edge and in the center between source and target node. This change affects the following layout algorithms:IncrementalHierarchicLayouter
,OrthogonalLayouter
,OrthogonalGroupLayouter
,DirectedOrthogonalLayouter
,GenericTreeLayouter
, andLabelLayoutDataRefinement
. LabelCandidateDescriptor
: The default values of the propertiesEdgeOverlapPenalty
andNodeOverlapPenalty
have been changed to0.0
. Values greater than0.0
trigger a known issue in all generic label placement algorithms that erroneously rejects all potential candidates. As a result, no suitable placement is calculated in this case.MoveInputMode
accepts mouse hovers with the Shift key held down again. This restores the default behavior in earlier versions of yFiles for Silverlight.GraphEditorInputMode
andGraphViewerInputMode
: By default, graph items styled with a void style (VoidNodeStyle
,VoidEdgeStyle
,VoidLabelStyle
,VoidPortStyle
) won't be selected or get the focus.GraphEditorInputMode
'sClickHitTestOrder
property default value has changed. Now it does not contain the redundantGraphItemTypes.All
as the last element in the array anymore.GraphViewerInputMode
: By default, clipboard commands are now disabled. This can be controlled with the new propertyClipboardCommandsEnabled
.- The default keyboard shortcut for deselecting elements (
GraphCommand.DeselectAllCommand
) has been changed toCtrl+Shift+A
.Ctrl+D
is now the default shortcut for duplicating selected elements (GraphCommand.DuplicateSelectionCommand
). Duplicating elements can be disabled via theDuplicateAllowed
property. GraphEditorInputMode.ShouldBeMarqueeSelected
is no longer queried by thePaste
command to determine the items which should be selected after paste. Instead, the new methodGraphEditorInputMode.ShouldBeSelectedAfterPaste
is queried. Note thatGraphEditorInputMode.ShouldBeMarqueeSelected
still is queried to determine the items which should be selected by marquee selection.- Now, all pasted items are selected after a
Paste
(was: only nodes, edges, and bends). This can be configured via the newPasteSelectableItems
property inGraphEditorInputMode
and the correspondingShouldBeSelectedAfterPaste
method. - The hit test order for double clicks in
GraphEditorInputMode
andGraphViewerInputMode
is now controlled through the separateDoubleClickHitTestOrder
property. By default, this hit test order prefers labels over other graph elements. - If
ClickInputMode
is configured to deliver both single and double clicks, double clicks are not reported if the first click has created a new node or if cyclic selection is currently active. The same holds forTapInputMode
and single/double taps. - The
Rotate
handle visualization is now a single circle, its very thin central point has been removed. - The segment index for label model parameters of
SliderEdgeLabelModel
andSideSliderEdgeLabelModel
now is related to the visible segments for edges styled withPolylineEdgeStyle
. - If an
IEditLabelHelper
implementation is present in anILabel
's lookup, itsEditLabel
method is now called in addition to an eventual owner's edit helper when the label text is edited. If implementations are present for both the label and the owner, editing is only allowed if both helpers returntrue
. Additionally, the predicate methodGraphEditorInputMode.ShouldLabelBeEdited
always has to returntrue
, whether edit helpers are present or not. - The label that is edited is now determined in the following order:
- If a label is explicitly provided as a command parameter or through a convenience method or is the only selected element, it is edited if the previous condition is satisfied. No other candidates are tried in that case.
- If a label owner is explicitly provided as a command parameter or through a convenience method, or is the only selected element, the first label that satisfies the condition above is edited if the previous condition is satisfied. If no such label exists, a new label is be added, provided that the owner allows adding. In either case, no other candidates are tried.
- The first selected label for which the previous condition is satisfied.
- If multiple label owners are selected, the first owner that has a label for which the previous condition is satisfied (in which case that label is edited).
- If
IEditLabelHelper.EditLabel
for either an editable label or its owner provides a different label instance, this instance is edited instead. - Otherwise, a label is added if an eligible owner can be found (see below).
- If an
IEditLabelHelper
implementation is present in anILabeledItem
's lookup, itsAddLabel
method is called to determine whether a label may be added and provide a suitable label instance. Additionally, the predicate methodGraphEditorInputMode.ShouldLabelBeAdded
always has to returntrue
, whether edit helpers are present or not. If the new label should be edited interactively after it's creation (the default behavior), it also must be editable, following the rules above. Therefore anIEditLabelHelper
implementation usually should allow editing of label instances that it has created itself inAddLabel
. - The label owner for which a label is added is now determined in the following order:
- If a label owner is explicitly provided as a command parameter or through a convenience method, or is the only selected element, a label is added if the previous condition is satisfied. No other candidates are tried in that case.
- If multiple label owners are selected, the first one for which the previous condition is satisfied.
API Changes
-
Changed
SnapLine
to support non-orthogonal snap lines as well: its propertiesFrom
andTo
have been changed from typedouble
toPointD
, its propertyOrientation
was removed, and its constructors have been changed accordingly.Orthogonal snap lines are now modeled by class
OrthogonalSnapLine
. It extendsSnapLine
and provides the propertyOrientation
. Existing API uses eitherSnapLine
orOrthogonalSnapLine
, depending on whether it works only with orthogonal snap lines or not.As a consequence, in class
SnapLineSnapResult
, the propertySnapLine
returns a non-orthogonalSnapLine
and the propertyDelta
returns aPointD
instead of adouble
. API related toGraphSnapContext
still works only with orthogonal snap lines and usesOrthogonalSnapLine
. - The
Key
property onSingleLineSnapLineControl
,FixedDistanceSnapLineControl
, andInBetweenSnapLineControl
, has been made read only. GraphModelManager
's factory methods for creating the installers now have a less restrictive return type. The default implementation still returns the same types as before, though.GraphClipboard
's factory methods for creating the predicates for the various cut and copy operations now require a second argument that is the graph that the predicate is working on. Usages typically use the graph in the graph control where the selection is also being used. If the default graph selection implementation is used. The graph instance can be obtained from its corresponding property.GraphModelManager
's installer related properties now use a weaker return type to simplify subclassing with new functionality. The instances used are the same and can be down-casted accordingly to the more specific types as documented.AlgorithmAbortedException
: Removed overloaded methodsCheck
. Client code that needs to terminate layout calculations prematurely must use new classAbortHandler
instead.- Moved classes
PartitionGrid
,PartitionCellId
,RowDescriptor
, andColumnDescriptor
from packageyWorks.yFiles.Layout.Hierarchic.Incremental
to packageyWorks.yFiles.Layout.Grid
. IItemFactory
: Added methodCreateRedirectedGroupEdge
.LayeredNodePlacer
: Removed data provider keyDpKeyDistanceToParentMap
from public API, since it is for internal use only.Polyline.EdgeRouter
: MethodDoLayout
now throws anArgumentException
if there is a node with zero width or height in the given graph.Polyline.EdgeRouter
: Penalty settings have been changed to double precision. See classPenaltySettings
.PathSearch
: Signature of methodCalculateCosts
has changed. It now takes an additional double array as parameter that is populated with the calculated costs instead of returning a new array.DrawingEmbedder
: Removed public methodPreprocessNodes
and protected methodPrintStatistics
.GraphClipboard
's protected methodCopy(IGraph, Predicate>IModelItem>, IGraph, ElementCopiedDelegate)
which was called byCut
,Copy
, andPaste
to invoke theGraphCopier
has been split:Copy(IGraph, Predicate >IModelItem>, IGraph, ElementCopiedDelegate)
now is called only byCut
andCopy
.Paste
now invokes the new methodPaste(IGraph, Predicate >IModelItem>, IGraph, ElementCopiedDelegate, Predicate >IModelItem>)
.- The type of
GraphMLAttribute
'sSerializable
property has been changed frombool
to the enumGraphMLSerializationMode
. GraphEditorInputMode
andTableEditorInputMode
: return value of callback methodsOnAddLabel
andOnEditLabel
has been changed fromvoid
tobool
. The return value should specify whether the operation in question was successful.
Bugfixes
Viewer
FoldedGraph
detects more carefully what has changed before invoking the methodsCreateDummyEdgeAppearance
andChangeDummyEdgeAppearance
ofIDummyEdgeConverter
. Previously, in some cases, these methods were called to often or not at all.- When both a group node and its child node were resized together the group node bounds shrunk to its original bounds once the child had reached the original bounds.
- Fixed problem in
LayoutGraphAdapter
where label candidates for edge labels were not always determined correctly. - Fixed
LayoutGraphAdapter
producing threading issues whenPortCalculator
was used during a multi-threaded layout. - When snapping was disabled temporarily (using Ctrl) during a move gesture the moved item snapped after finishing the gesture, anyway.
FoldedGraphUndoSupport
didn't add the correct bend information to its internal data structures.CreateEdgeInputMode
: Fixed some problems with mixed mouse and touch input.- When using an
IEditLabelHelper
and adding a label interactively, the helper'sEditLabel
callback was called instead ofAddLabel
. - Newly added labels could have had an empty size when an
IEditLabelHelper
instance was registered. - When a highlighted item was removed from the graph, the highlight was not cleaned up.
- Reparenting an empty group node displayed the target node highlight around the reparented node.
- The modified
MoveInputMode
created byMainInputMode.CreateMoveUnselectedInputMode
changed the cursor to indicate a movable object even when themodifierRecognizer
disabled moving. - When both a group node and its child node were resized together the group node bounds shrunk to its original bounds once the child had reached the original bounds.
ClickInputMode
: Cancelling the mode during clicks didn't work correctly and as a result, the location reported for the next click might have been wrong.CreateEdgeInputMode
now copies the dummy edge's tag to the created edge. This could have caused issues when theEdgeCreationStarted
was used to set a custom tag on the dummy edge.- When the pressed status of the Shift key changed during a reparenting gesture of a node, the bounds of its containing group node were not immediately updated.
- The secondary multi-tap gesture was not recognized correctly.
- When snapping was disabled temporarily (using Ctrl) during a move gesture the moved item snapped after finishing the gesture, anyway.
- Labels whose positions were determined by
NinePositionsEdgeLabelModel
,SliderEdgeLabelModel
, andSideSliderEdgeLabelModel
might have disappeared when one or more edge segments were hidden under the source or target node. SnapContext
: Snap results with anull
tag were erroneously always discarded.GeneralPath#Transform
and other GeneralPath methods usingMatrix2D
applied the transformation matrix incorrectly in the case of a rotation.BevelNodeStyle
: Fixed update of drop shadow afterRadius
has been changed.IconLabelStyle
: MethodGetBounds
inIconLabelStyleRenderer
returned a valid rectangle even if the label layout was invalid. As a consequence,IsVisible
erroneously returnedtrue
for labels with invalid bounds.- The
Name
property of theGraphMLAttribute
was not considered during deserialization. - Write events in
GraphML
were not always raised. - After setting an
ICanvasObjectGroup
'sVisible
property tofalse
the group was still visible. CanvasControl.EnsureVisible
hasn't worked for bounds larger than the current viewport.- Setting the view point on a
CanvasControl
with a width or height of 0.0 could cause an exception if aViewportLimiter
was enabled. GraphCopier
threw anConcurrentModificationException
if the source and the target graph are identical.- Prevent an
ArgumentNullException
in the print preview of theCanvasControl
. - When the
SelectionPaintManager
was disabled and a customFocusPaintManager
was used nodes styled withNodeControlNodeStyle
might not always have been updated after selection changes. GraphEditorInputMode
andGraphViewerInputMode
now respect theMultiSelectionRecognizer
for extending an existing selection via marquee.- Fixed
TableEditorInputMode
exhibiting problematic behavior under certain circumstances when theGraphControl
's graph is replaced. - GraphML could write incorrect values for bend tags.
- Properties
ShinyPlateNodeStyleRenderer.Radius
,ShinyPlateNodeStyleRenderer.Brush
,ShinyPlateNodeStyleRenderer.Pen
andBevelNodeStyleRenderer.Radius
were not used consistently. - Fixed memory leak that occurred when
CreateEdgeInputMode
was uninstalled. DefaultArrow.Length
did not take theScale
factor into account, sometimes leading to gaps between the edge and the arrow.- Custom selection visualizations using
EdgeStyleDecorationInstaller
were not animated correctly. - Custom selection visualizations using
EdgeStyleDecorationInstaller
inDecorationZoomMode.Mixed
orDecorationZoomMode.ViewCoordinates
did not work correctly together withBridgeManager
.
Layout
- Running any label placement algorithm had no effect for node/edge labels if the properties
RemoveNodeOverlaps
/RemoveEdgeOverlaps
were enabled because all potential candidates were erroneously rejected. AbstractLabelingAlgorithm
: Fixed bug that may cause removal of labels that don't overlap with other elements if optionRemoveNodeOverlaps
is enabled.IncrementalHierarchicLayouter
: Fixed rareInvalidOperationException
that may appear for grouped graphs containing nodes with fixed coordinates hint (see, e.g.,IncrementalHintsFactory.CreateUseExactCoordinatesHint
).IncrementalHierarchicLayouter
: Fixed bug that breaks incremental hints of grouped edges in incremental layout mode. (seeIncrementalHintsFactory.CreateSequenceIncrementallyHint
).IncrementalHierarchicLayouter
: Fixed bug that may cause a wrong order of fixed (non-incremental) elements if the layouter is applied in incremental mode and the graph contains sequence constraints.BorderLine
: Fixed bug in methodGrow
that may result in anArgumentException
because the minimum value of a BorderLine becomes greater than the maximum value.Polyline.EdgeRouter
: Fixed bug that may cause zero length routes of edges whose start and end point are at the same location.IncrementalHierarchicLayouter
: Fixed possibleIndexOutOfRangeException
ifPortConstraint
s are used together withPortCandidateSet
s.Polyline.EdgeRouter
: Minimum first and last segment length and minimum node to edge distance were sometimes ignored when used together with octilinear routing style.Grouping
: Fixed bug in methodNearestCommonAncestor
that sometimes caused wrong results if one of the specified nodes is the ancestor of the other node.InsetsGroupBoundsCalculator
: Fixed methodCalculateBounds
to consider only the given child nodes and all edges between those child nodes instead of all nodes and all edges in the graph.GenericTreeLayouter
: FixedNullReferenceException
that occurred when usingLayeredNodePlacer
as default node placer.LayoutTool
: Fixed calculation of lower width bound in methodArrangeRectangleRows
. Due to the better bound, the optimization procedure now needs less steps, especially for graphs with very wide components. Note, that the results may also slightly differ, because the optimization may now stop with slightly different values.SALabeling
andGreedyMISLabeling
: Fixed possibleNullReferenceException
caused by labels with zero width/height and a "free" edge label model.IncrementalHierarchicLayouter
: Fixed bug that caused wrong coordinates of empty rows (see classRowDescriptor
) whose minimum height is zero.DirectedOrthogonalLayouter
: Fixed a bug that sometimes caused misplaced edge labels of grouped edges.Polyline.EdgeRouter
: Fixed possibleNullReferenceException
for edge groups that contain fixed edges.Polyline.EdgeRouter
: Fixed bug that caused wrong routes for edges grouped with fixed edges.IncrementalHierarchicLayouter
andRankAssignments
: Fixed possibleNullReferenceException
that may occur if the maximal duration of the algorithm is limited.IncrementalHierarchicLayouter
: Fixed bug that may cause overlaps of edge labels with preferred placement at source/target.Polyline.EdgeRouter
: Fixed rareNullReferenceException
that mainly appears if there are overlapping nodes.PartialLayouter
: Fixed bug that may cause broken edge routes for edges incident to incremental group nodes if optionRouteInterEdgesImmediately
is enabled.CompactOrthogonalLayouter
: Fixed possibleArgumentException
caused by nodes without node-ids. This problem may only appear if the inter edge router is set toChannelInterEdgeRouter
.
yFiles for Silverlight 2.3.0.3 - Changes Since 2.3.0.2
Bugfixes
RotatedSideSliderEdgeLabelModel
: Label model parameters of this model were serialized as the respective parameters ofRotatedSliderEdgeLabelModel
. Thus, after loading, the positions of the labels are the expected ones but the label models changed.RotatedSliderEdgeLabelModel
: Parameters with ratio 0.5 were not correctly deserialized from GraphML.FilteredGraphWrapper
: TheEdgesAt
methods erroneously returned edges that were marked as hidden by theEdgePredicate
. The methodsDegree
,InDegree
, andOutDegree
are based on these methods and were affected, too.FilteredGraphWrapper.Dispose
did not clean up all event listeners.- Node ports could not be moved by dragging their
IHandle
. CollapsibleNodeStyleDecorator
andShadowNodeStyleDecorator
: Lookup requests forISizeConstraintProvider
,IGroupBoundsCalculator
, andIShapeGeometry
are now correctly delegated to the wrapped style.- The
EdgeStyleDecorationInstaller
did not copy the tags of dummy ports and edges used when displayed in view coordinates (ZoomMode
=DecorationZoomMode.ViewCoordinates
). BevelNodeStyle
: Fixed update of drop shadow afterRadius
has been changed.GraphMLIOHandler
: methodAddNamespace
had no effect, and adding a custom schema withAddSchemaLocation
triggered an exception.Folding
: Source port tags in view states were not parsed correctly from GraphML.ContextConfigurator
: propertyScale
did not throw an exception for invalid values.- Image export: Custom selection visualizations created with
NodeStyleDecorationInstaller
,LabelStyleDecorationInstaller
andEdgeStyleDecorationInstaller
in zoom invariant mode were not placed correctly. PixelImageExporter
: The default node and label selection markers were not exported correctly.GraphSnapContext
: Snapping nodes to vertical edge segments was not working ifNodeToEdgeDistance
was set to 0.CreateEdgeInputMode
: Mixing touch and mouse gestures did not always work as expected.
Automatic Layout
IncrementalHierarchicalLayouter
: Fixed possible exception caused by inconsistent grouping. The problem may only occur in incremental mode and if there are sequence constraints.IncrementalHierarchicLayouter
: Fixed broken edge routes that may occur for edges with labels if there are "critical" edges, seeCriticalEdgeDpKey
.IncrementalHierarchicLayouter
: FixedArgumentException
inConstraintIncrementalLayerer
that could appear when layer constraints were added in incremental mode.IncrementalHierarchicLayouter
: FixedArgumentException
that may appear for graphs containing nodes with fixed coordinates.IncrementalHierarchicLayouter
: Fixed bug that could result in infinite y-coordinates when octilinear edge routing was enabled.IncrementalHierarchicLayouter
: FixedArgumentException
(Graph is not acyclic) inSimplexNodePlacer
that could appear when sequence constraints were added to a graph with swimlanes and group nodes.SimplexNodePlacer
: Fixed broken edge routes that may occur for edges with labels if optionStraightenEdges
is enabled.TreeReductionStage
: Fixed wrong handling of group nodes which may cause aWrongGraphStructure
exception as well as broken routes of edges incident to group nodes.TreeLayouter
andGenericTreeLayouter
: Fixed possibleNullReferenceException
for trees with empty group nodes.- Fixed
NullReferenceException
when usingAssistantPlacer
together with distributed port assignment. BorderLine
: Fixed rareArgumentException
that was caused by numerical instability.OrthogonalLayouter
failed almost always with anArrayIndexOutOfRangeException
if the Mixed Layout style was used.CircularLayouter
: Fixed issue that may cause infinite/too large node coordinates for unfavorable input settings, for example, if the maximal deviation angle is to small. Note that such coordinates may produce infinite looping or other exceptions.CircularLayouter
: Fixed possibleNullReferenceException
when layout style is set toBccIsolated
and consider node labels is enabled.Polyline.EdgeRouter
: Fixed wrong heuristic bend calculation if grid is used.Polyline.EdgeRouter
: Fixed bug in calculation of edge to edge distance penalties which could reduce the space where edges can be routed causing them to take unnecessary long routes.Polyline.EdgeRouter
: Fixed bug that caused edges that connect a node with an ancestor group node to violate the minimal node to edge distance for the target node.Polyline.EdgeRouter
: Fixed bug that caused edges that connect a node with an ancestor group node to have unnecessary long and bended edge paths when using port constraints.Polyline.EdgeRouter
: Fixed bug that caused edges that connect a node with an ancestor group node to cross their source nodes when using port constraints.Polyline.EdgeRouter
: Fixed bug that makes it possible to group the source of one edge and the target of another edge at their common node.Polyline.EdgeRouter
: Fixed bug that sometimes causes superfluous edge overlaps.Polyline.EdgeRouter
: Fixed bug that caused minimum distance violation of grouped edges.Polyline.EdgeRouter
: Fixed rareNullReferenceException
while calculating edge crossing costs.Polyline.EdgeRouter
: Fixed bug that sometimes assumed wrong label bounds for labels of table nodes. This could result in too many bends for edges that were routed around those wrong boxes. Labels of table nodes are now ignored by the router ifTableLayoutConfigurator
is used to prepare the graph for layout calculations.Polyline.EdgeRouter
: Fixed bug that sometimes assumed wrong label bounds if the router was used directly after another layout algorithm. This could result in too many bends for edges that were routed around those wrong boxes and/or edges crossing labels because the actual label boxes were ignored.Polyline.EdgeRouter
: Fixed bug that may cause anArgumentException
if a grid is specified (see optionGrid
).PolylineLayoutStage
: Fixed possibleIndexOutOfRangeException
if there are fixed edges with a single, very short segment.BusRouter
: FixedNullReferenceException
that may appear for graphs containing isolated nodes with self-loops.BusRouter
: FixedNullReferenceException
inBusRepresentations
that could appear if the input graph contains overlapping nodes.BusRouter
: Fixed clean up of bends that resulted in unnecessary detours in edge paths.BusRouter
: Fixed possibleIndexOutOfRangeException
.BusRouter
: Fixed possibleInvalidOperationException
caused by non-orthogonal edge segments.BusRouter
: Fixed possibleNullReferenceException
when routing only a subset of edges without adding aDataProvider
to the graph that marks edges as selected.MultiPageLayouter
: Fixed possibleNullReferenceException
if the input graph contains empty group nodes.MultiPageLayouter
: Fixed possibleInvalidCastException
if group node insets are specified with classyWorks.yFiles.Util.Geom.Insets
.AbstractLabelingAlgorithm
: Fixed bug that causes poor results if optionRemoveEdgeOverlaps
is enabled and the labels should be placed on the edge.LabelLayoutDataRefinement
: Fixed possibleInvalidCastException
for unbuffered layout runs.RecursiveGroupLayouter
: Removed all temporarily inserted port candidates before calling the inter-edge routing because otherwise the edges routes may become corrupted.ShuffleLayouter
: Fixed bug that may cause small offsets of fixed nodes.OrthogonalGroupLayouter
: Fixed bug that may cause wrong group bounds calculation if a group node label lies outside of the group node.PartialLayouter
: Fixed possibleNullReferenceException
if the algorithm is applied to a graph with partition grid (seePartitionGrid
).
Demos
ImageExportDemo
: The hit test for the export rectangle was configured incorrectly.
Known Issues
- GraphML serialization of node label model parameters that are created with
FreeNodeLabelModel.CreateNodeRatioAnchored
is incorrect (the y ratio value is inverted). A fix for this issue will be part of the next feature and/or major release, since this would introduce an incompatible change in behavior.
yFiles for Silverlight 2.3.0.2 - Changes Since 2.3.0.1
Improvement
LayoutGraphAdapter
provides now the originalTag
data for temporary graph objects.
Bugfixes
- Undoing a reparent grouping gesture might have resulted in inconsistent group node sizes. Note: The fix results in a slightly incompatible behavior when nodes are reparented programmatically and multiple folding views are used. In that case, you need now to subscribe to hierarchy events and manually adjust the group node bounds.
- The default value of
AbstractTableNodeStyle#BackgroundStyle
was not serializable. - Manually bracketing undo edits with
BeginEdit
andEndEdit
might have led to exceptions when folding was active. RotatedSliderEdgeLabelModel
can now deal with edge paths that arenull
, e.g. when usingVoidEdgeStyle
.- GraphML: Primitive types like floats and doubles could not be read when used in element syntax and the current
CultureInfo
was notInvariant
.
Automatic Layout
DirectedOrthogonalLayouter
could throw aString.IndexOf
exception.IncrementalHierarchicLayouter
: Fixed a rare bug that caused broken edge routes if edges are routed polyline.PolylineLayoutStage
: Fixed possibleIndexOutOfRangeException
if there are fixed edges with a single, very short segment.Polyline.EdgeRouter
: Fixed a bug that makes it possible to group the source of one edge and the target of another edge at their common node.Polyline.EdgeRouter
: Fixed a bug that sometimes causes superfluous edge overlaps.Polyline.EdgeRouter
: Fixed a bug that causes that edges of a group starts in the node to edge distance area of another node.BusRouter
: Fixed clean up of unnecessary bends that were placed on a backbone but not cause detours in edges.
yFiles for Silverlight 2.3.0.1 - Changes Since 2.3
Bugfixes
- Fixed non-working printing.
ClickInputMode.SwallowFocusClick
had only an effect for the very first click.- Copying table stripes did not work correctly.
- GraphML: Properties with a text value containing nested
CDATA
sections were not parsed correctly. - Moving the viewport by clicking into the
GraphOverviewControl
did not honorCanvasControl.ViewportLimiter
restrictions. - Worked around
HRESULT E_FAIL
error that could occur under rare circumstances when components were removed from the visual tree.
Automatic Layout
EdgeRouter
: Fixed bug that may cause anArgumentException
if a grid is specified (see propertyGrid
).OrthogonalGroupLayouter
: Fixed bug that may cause a wrong group bounds calculation if a group node label lies outside of the group node.PartialLayouter
: Fixed possibleNullReferenceException
if the partial layouter is applied to a graph with partition grid (seePartitionGrid
).PartialLayouter
: Fixed bug that may cause a very long runtime if the algorithm considers node alignment (see propertyConsiderNodeAlignment
).IncrementalHierarchicLayouter
: Fixed bug that may cause broken edge routes for edges with port candidates if backloop routing is enabled (see propertyBackloopRouting
).ParallelEdgeLayouter
: FixedNullReferenceException
that appears if the leading edge has zero length.ParallelEdgeLayouter
: Fixed bug that may cause points withDouble.NaN
-coordinates for some edges.LayoutTool
: Fixed bug in methodRouteEdgesParallel
: that may cause points withDouble.NaN
-coordinates for some edges.EdgeRouter
: Fixed performance problems for graphs with overlapping fixed edges.
Demos
Demo.yFiles.ImageExport
: Demo claimed to be able to export other image formats than PNG.Demo.yFiles.ImageExport
: Disabling the setting 'Export Rectangle Contents' resulted in an empty preview.
yFiles for Silverlight 2.3 - Changes Since 2.2.0.4
Major Features Added
Automatic Layout
- Class
yWorks.yFiles.Layout.Router.Polyline.EdgeRouter
is a new edge routing algorithm that creates polyline edge routes. The segments of an edge are either orthogonal or octilinear, that means, the slope of each segment is a multiple of 90 degrees or a multiple of 45 degrees, respectively.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...] yWorks.yFiles.Layout.Router.Polyline.PolylineLayoutStage
: A new layout stage that adds polyline segments to the orthogonal edge paths of a graph.IncrementalHierarchicLayouter
: Added support for octilinear edge routing, i.e., a routing style where the slope of each edge segment is a multiple of 45 degrees. Different edge routing styles can be specified using classyWorks.yFiles.Layout.Hierarchic.Incremental.RoutingStyle
.yWorks.yFiles.Layout.PreferredPlacementDescriptor
: A new descriptor that allows to specify advanced preferred placement information for edge labels.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...]
Minor Features Added
ClickInputMode
,GraphEditorInputMode
,GraphViewerInputMode
: New events forLeftClicked
,RightClicked
,LeftDoubleClicked
andRightDoubleClicked
. Also,ClickInputMode
has been improved to handle multiple mouse buttons concurrently.MainInputMode
andGraphViewerInputMode
: Added new bulk selection eventsMultiSelectionStarted
andMultiSelectionFinished
.LayoutExecutor
can now safely handle concurrent layout requests. By default an already running layout will be short-cut and the next layout request will be processed. PropertySequentialExecution
can be set tofalse
to revert to the old (unsafe) behavior. The newStop
method and theIsRunning
property can also be used in this context.NodeControlNodeStyle
andLabelControlLabelStyle
now have the ability to automatically trigger a resize of their corresponding graph items whenever the desired size of the control contents change, e.g. in response to a dynamic UI.- New classes
NodeStyleDecorationInstaller
,EdgeStyleDecorationInstaller
, andLabelStyleDecorationInstaller
allow the use of a node, edge, or label style to render the selection, highlight, or focus indicator of nodes, edges, and labels, respectively.
Automatic Layout
BalloonLayouter
: New option to take into account the bounds of node labels when calculating a layout.LabelLayoutTranslator
: Added optionAutoFlippingEnabled
to specify whether or not edge labels should be automatically flipped if they would be upside-down.AbstractLabelingAlgorithm
: Added optionAutoFlippingEnabled
to specify whether or not edge labels associated with a "free" label model should be automatically flipped if they would be upside-down.
Improvements
- Optionally,
LayoutExecutor
usesWaitInputMode
while waiting during the calculation of a layout. - Added callback method
SetEdgePortLocation
toLayoutGraphAdapter
that is called while assigning a new location to a port that is owned by an edge. - Changing the event recognizers of an
IInputMode
after the mode has been installed has now an effect in all input modes. - Improved performance of table rendering and interaction.
- Refactored
MoveLabelInputMode
to make customizations easier. The moved label is now accessible and various new protected methods provide fine-grained control of the behavior. MoveLabelInputMode
now takes the position handler from the lookup of a label if one is present, and creates a new one only if none was found.- Custom context menus declared on controls that are rendered within the
CanvasControl
now play well withContextMenuInputMode
. The newSuppressChildMenus
property can be used to optionally prevent those menus from appearing if the mode is not enabled. IClipboardHelper
: The predicate functionsShouldCut
andShouldCopy
were not used for the default cut and copy operations provided byGraphEditorInputMode
andGraphControl
.- Child input modes of
GraphViewerInputMode
can now be changed similar toGraphEditorInputMode
. - Added explicit extension method
IGraph.CreateNode(PointD,INodeStyle)
. Arrow
: Setting the various properties now only recreates the arrow template if something actually changed.GraphEditorInputMode
andGraphViewerInputMode
provide a newCanvasClicked
event to detect clicks on the empty canvas area.
Automatic Layout
OrthogonalGroupLayouter
supports labels at edges incident to group nodes.IncrementalHierarchicLayouter
now treats edge groups at empty group nodes like those on regular nodes instead of ignoring them like it is done for non-empty group nodes.WeightedLayerer
: Improved quality by reducing the number of reversed edges ifWeightedCycleRemoval
is enabled.PartialLayouter
now considers edge ports when calculating the barycenter of a component (if its propertyPositioningStrategy
is set toSubgraphPositioningStrategy.Barycenter
).PartialLayouter
: Reduced cases where the result contains overlapping node elements.PartialLayouter
calculates improved routing if optionRouteInterEdgesImmediately
is enabled and generally for edges between fixed elements.SmartOrganicLayouter
: Fixed nodes are no longer moved by a fixed offset if scope is set toScope.Subset
.GenericTreeLayouter
creates more compact layouts, especially for trees with edge labels.- Added the ability to
DefaultNodePlacer
to create polyline-style edge routings with sloped edge segments. - Added the ability to
DefaultPortAssignment
to distribute edges at the border of the nodes. RecursiveGroupLayouter
: Improved performance for graphs with a mainly flat structure.GraphLayoutLineWrapper
: Improved edge routing for overlapping edges, for example grouped edges.- Added auto-flipping to
RotatedDiscreteEdgeLabelLayoutModel
andRotatedSliderEdgeLabelLayoutModel
. Labels that are placed upside down by a layouter will be flipped. - Improved the performance of
PortCandidate
which potentially improves the performance of theIncrementalHierarchicLayouter
with rotated graphs with PortCandidates. - Optimized number of generated
PortCandidate
s inRecursiveGroupLayouter
for the core layouter. GraphConnectivity
: Improved methodMakeBiconnected
to work with graphs with self-loops (i.e. edges whose source and target nodes are the same).
Demos
- Added new demo
Demo.yFiles.Graph.Input.HandleProvider
that shows how to add resize handles to graph elements that don't provide them out of the box. - Added new demo
Demo.yFiles.Graph.Input.SingleSelection
that shows how to configureGraphEditorInputMode
to enable single selection mode for interaction. - Added new demo
Demo.yFiles.Graph.StyleDecorators
and a corresponding step in the Custom Style Tutorial that shows how to correctly implement the decorator pattern for node styles. - Added new demo
Demo.yFiles.Graph.SelectionStyling
that shows how to use node, edge and label styles for the painting of the selection decorator. - Added new demo
Demo.yFiles.Layout.PreferredLabelPlacement
that shows how to use the newPreferredPlacementDescriptor
layout feature. - The layout modules now use the new preferred placement descriptor feature for label setup. Additionally, the previous label setup had no effect at all due to an erroneous configuration.
- Prevent negative edge weights in
Demo.yFiles.Algorithms.ShortestPath
since cycles with negative weights are not allowed by the algorithm.
Bugfixes
- If
NavigationInputMode
was used as child ofGraphViewerInputMode
orGraphEditorInputMode
, it didn't respect the selectable and focusable items of its parent input mode. - In
CreateEdgeInputMode
andMoveInputMode
, snapping may not have been re-enabled after disabling it temporarily. - Prevent a very rare bug caused by the preferred size calculation of labels of dummy elements of grouped graphs when
LabelControlLabelStyle
was used. IconLabelStyle
: Fixed exception when the icon size was not set or was empty.GraphClipboard.Cut
: The filter predicate was evaluated twice, resulting in unexpected behavior if the predicate evaluation depended on state that could change by removing graph elements.HorizontalScrollBarPolicy
andVerticalScrollBarPolicy
inCanvasControl
could not be set to different values at the same time. The value of the latter was used effectively, always.LabelControlLabelStyle
incorrectly triggered an update of the preferred label size calculation in folded graph scenarios under certain conditions.- In
CreateEdgeInputMode
, the compound undo unit is cancelled if the edge creation is implicitly cancelled. The old behavior can be restored by disablingCreateEdgeInputMode.CancelEditImplicitly
. MoveInputMode
only considers hovers without modifiers as valid to prevent "cursor fight" withMoveViewportInputMode
.NavigationInputMode.ToggleGroupNodeState
did not expand collapsed folder nodes.SimpleAbstractLabelStyle.IsInBox
always returned false.
Automatic Layout
IncrementalHierarchicLayouter
: Fixed incorrect handling of port candidates in layouts where rotation and a mirror was set.IncrementalHierarchicLayouter
: Fixed integer overflow when group compaction is activated while layouting extremely large, deeply nested graphs.IncrementalHierarchicLayouter
: Fixed port handling of edges with a single edge port candidate that is contained in a set of node port candidates.- Fixed bug with invalid array access in
AspectRatioComponentLayerer
. - Fixed bad edge routings in
FamilyTreeLayouter
when there are several marriages between generations. IsolatedGroupComponentLayouter
now considers labels in group bounds calculation if label awareness is enabled.PartialLayouter
: Fixed IndexOutOfRangeException that sometimes appears for large graphs.GroupNodeRouterStage
: Fixed possible exception that was caused by the missing removal of a temporarily added DataProvider.OrthogonalLayouter
andDirectedOrthogonalLayouter
: Fixed bug that caused an ArgumentException if input graph contains overlapping parallel edges and from sketch mode is enabled (see propertyUseSketchDrawing
).OrthogonalEdgeRouter
: Fixed exception that may appear when both optionsRerouting
andLocalCrossingMinimization
are enabled.RotatedSliderEdgeLabelLayoutModel
andSliderEdgeLabelLayoutModel
: Improved label placement at zero-length edge segments.GraphTransformer
: Fixed group nodes bounds after transforming a sub-graph only.ParallelEdgeLayouter
: FixedNullReferenceException
which may appear when source/target points of parallel edges are outside of the corresponding node.SmartOrganicLayouter
: Fixed problem that sometimes caused very long runtime for simple grouped graphs.SmartOrganicLayouter
: Fixed wrong calculation of group node sizes if optionConsiderNodeLabels
is enabled.YVector
: Fixed methodRotate(double)
to no longer return vertically mirrored results.Rectangle2D.Intersects
sometimes returnedtrue
for non-intersecting rectangles. This could cause infinite loops inBusRouter
.IncrementalHierarchicLayouter
: Fixed bug that caused violation of strong port constraints of typeAnySide
for backloop edges.RecursiveGroupLayouter
: FixedIllegalStateException
that may appear if there are edges that start/end at group nodes.BusRouter
: Fixed bug that may cause a broken bus structure.
Changes in Default Behavior
IClipboardHelper
: The predicate functionsShouldCut
andShouldCopy
are now taken into account for the default cut and copy operations provided byGraphEditorInputMode
andGraphControl
.ContextConfigurator.Setup
: TheIRenderContext
returned by this method now has a finiteClip
applied.- Concurrently executing layouts using
LayoutExecutor
will now result in the subsequent executions waiting for the previous execution to finish. PropertySequentialExecution
can be set tofalse
to revert to the old (unsafe) behavior. - The
ContextMenuInputMode
'sPopulateItemContextMenu
event will not fire anymore for context menus that are declared in controls inside the CanvasControl, but only for the menu that is managed by the input mode. - If the
PopulateContextMenuEventArgs
' propertyShowMenu
is set to true, now even empty menus will be displayed.
Automatic Layout
PartialLayouter
: PropertyEdgeRoutingStrategy
now disables a previously set customized edge router.
Incompatible API Changes
DefaultGraph.SetPreferredSize
does not callOnLabelChanged
any more. Thus, theLabelChanged
event is not fired.
Automatic Layout
IEdgeLabelLayout
: Removed propertyPreferredPlacement
and added propertyPreferredPlacementDescriptor
.PartialLayouter
: Replaced methodConfigureOrthogonalEdgeRouter
by methodConfigureEdgeRouter
.- Classes
yWorks.yFiles.Util.ISortedMap
andyWorks.yFiles.Util.ISortedSet
have been removed from the public API. These interface were never meant to be used by customers.
yFiles for Silverlight 2.2.0.4 - Changes Since 2.2.0.3
Bugfixes
GraphSource
: If an edge item is removed fromEdgesSource
, nodes connected to this edge are no longer removed. This only occurred ifDynamicUpdates
was enabled andLazyNodeDefinition
was set tofalse
.
yFiles for Silverlight 2.2.0.3 - Changes Since 2.2.0.2
Bugfixes
ContextConfigurator
: Left and top margins were not taken into account correctly.XamlSerializer
: Fixed potential exceptions that could occur with properties that are not serializable.- The default edge style used by the
GraphSource
was different from the one used in yFiles for Silverlight 2.1. This has been reverted. yWorks.yFiles.UI.Drawing.TableRenderingOrder
was not excluded from obfuscation.- The
IGraph
instance returned byGraphSource.Graph
was not obfuscated correctly, thus preventing binding to its properties. - The
IGraph
instance returned byGraphSource.Graph
threw an exception when callingSetStyle(IEdge, IEdgeStyle)
. Matrix2D.Scale(double,double,MatrixOrder)
did not work correctly forMatrixOrder.Append
.PointD
andGeneralPath
: Hit and equality tests that specify an option epsilon value now include the epsilon into the valid range.
Demos
Demo.yFiles.ImageExport
: Insets were not assigned correctly.
yFiles for Silverlight 2.2.0.2 - Changes Since 2.2.0.1
Bugfixes
- GraphML data for edges was not read anymore. This has been fixed.
yFiles for Silverlight 2.2.0.1 - Changes Since 2.2
Improvements
- The animation for bends has been slightly improved in the case where new bends are added during layout morphing.
Bugfixes
- Due to a bug in
UIElementExtensions.SetPen
, some of the styles that were using pens could trigger an exception when a pen without a dash and later on a dashed pen was assigned. - Fixed
DefaultGraph.Remove(IPort)
not working correctly in certain cases when there were edge-to-edge connections. This also affected the 'cut' clipboard operation in the same scenarios. InteractiveOrganicLayouter
'sSyncStructure
was broken and blocking forever causing the interactive organic demo to halt on graph modifications.- Fixed image resizing in
ImageNodeStyle
when node is made smaller than its initial size.
Demos
- Fixed the 'nesting' graph in
Demo.yFiles.Graph.Viewer
- Fixed
Demo.yFiles.Layout.InteractiveOrganic
freezing when the graph was modified structurally.
yFiles for Silverlight 2.2 - Changes Since 2.1.0.4
Framework Requirements
- yFiles for Silverlight now requires the Silverlight 5.0 framework and plugin or higher.
Major Features Added
- Touch input is now supported by all built-in input modes. New input mode class
TapInputMode
introduces transparent support for touch gestures in user interactions. This new input mode is part of the default configurations of GraphEditorInputMode and GraphViewerInputMode, respectively. - New support for edge-to-edge connections in user interactions. Edges can be connected to other edges during edge creation as well as by reconnecting edge ends.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...] - A great number of additional status-indicating events has been added to the various default input modes in order to provide fine-grained callbacks to customization code.
- The library no longer contains Apache licensed third party code.
Automatic Layout
- Class
yWorks.yFiles.Layout.Multipage.MultiPageLayouter
is a new layout algorithm that breaks apart a given graph into a set of smaller graphs so that each layout of a small graph fits into a given width and height.
TheDemo.yFiles.Layout.MultiPage
shows how to use classMultiPageLayouter
to sub-divide large graphs into smaller bits of navigable information.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...]
Minor Features Added
- New classes
AdjacentNodesGraphSource
andAdjacentEdgesGraphSource
provide data binding support for a much larger number of user data models. DefaultEdgeIntersectionCalculator
now supports cropping edges directly at the port instead of at the node's geometry. This can be used to easily have edges end at the port instead of at the geometry of the node. See the new propertiesCropAtPort
,ExtraCropLength
, and callback methodGetPortGeometry
.GraphSource
:- Added property
LazyNodeDefinition
which allows the usage of objects as source and target of edges that are not part of NodesSource. - Added the binding properties
LocationXBinding
andLocationYBinding
for specifying the node location. - Added the binding property
NodeIdBinding
for specifying the node id. This allows specifying the source and target node of an edge using the node id.
- Added property
TreeSource
: Added the bindingsLocationXBinding
andLocationYBinding
for specifying the node location.
Automatic Layout and Analysis
- The orthogonal layout algorithms
OrthogonalLayouter
,OrthogonalGroupLayouter
, andDirectedOrthogonalLayouter
now support specifying a minimum first/last segment length. See the corresponding descriptions ofOrthogonalLayouter.EdgeLayoutDescriptorDpKey
,OrthogonalGroupLayouter.EdgeLayoutDescriptorDpKey
, andDirectedOrthogonalLayouter.EdgeLayoutDescriptorDpKey
, respectively. SimplexNodePlacer
: Added an algorithm that reduces the number of bends. This option can be set using propertyBendReductionEnabled
and is enabled by default. Note: using this option increases the runtime of theIncrementalHierarchicLayouter
. If the runtime exceeds the maximal duration the number of bends is not reduced.- Added abstract class
AbstractPortConstraintOptimizer
, a partial implementation of interfaceIPortConstraintOptimizer
, to minimize the effort required to modify the port assignment after the sequencing phase of a hierarchic layout. TreeLayouter
: When using port stylesBorderCenter
andBorderDistributed
together with child placement policiesLeavesStacked
,LeavesStackedLeft
,LeavesStackedRight
, andLeavesStackedLeftAndRight
edges connect to the appropriate sides of their target nodes instead of to the top. Moreover, the order of outgoing edges no longer results in crossings for port styleBorderDistributed
.AbstractLabelingAlgorithm
: Added DataProvider keyLabelModelDpKey
that can be used to temporarily specify the model of labels that is used by the labeling algorithm.ShortestPaths
: Added methodShortestPair
.
Improvements
CanvasPrintDocument
: Added convenience overloads of thePrint
method that delegate to the new methods inPrintDocument
that have been added in Silverlight 5.GraphMLIOHandler
: AddedAddRegistryOutputMapper
overload that takes a serialization handler.
Automatic Layout
FamilyTreeLayouter
: Improved the algorithm with respect to the number of edge crossings.PCListOptimizer
: Improved the handling of port candidates and enhanced backloop routing support.
Demos
- Added new demos
Demo.yFiles.DataBinding.InteractiveNodesGraphSource
andDemo.yFiles.DataBinding.InteractiveEdgesGraphSource
that show data binding with classesAdjacentNodesGraphSource
andAdjacentEdgesGraphSource
, respectively. - Added new demo
Demo.yFiles.Graph.EdgeToEdge
that shows how to enable and make use of the new edge-to-edge connection feature. - Added new
Demo.yFiles.Layout.Multipage
that shows how to use classMultiPageLayouter
to sub-divide large graphs into smaller bits of navigable information.
Bugfixes
Automatic Layout
LabelLayoutDataRefinement
: Fixed InvalidCastException that could occur due to wrong type of label model parameters.
Incompatible API Changes
- yFiles for Silverlight now requires the Silverlight 5.0 framework and plugin or higher.
- yFiles for Silverlight now requires a reference to the
System.Numerics.dll
from the Silverlight 5.0 framework. - Methods
GetTargetPortCandidateProvider
andGetSourcePortCandidateProvider
inGraphEditorInputMode
changed their signatures to acceptIPortOwner
instances instead ofINode
instances. This was required to allow for interactive edge-to-edge connections. Overriding methods need to be adjusted accordingly. - Method
ShowHitNodeCandidatesOnly
in classPortRelocationHandle
has been renamed toShowHitPortOwnerCandidatesOnly
to support edge-to-edge connections. Also the behavior of this class has been changed to allow edge-to-edge connections if this feature has been enabled by providing port candidates at the edges. Should you wish to disallow edge-to-edge connection even though you are providing edge port candidates, the newEdgeToEdgeConnectionsAllowed
property can be set tofalse
. - Previously it was possible to cast
DefaultEdgeIntersectionCalculator.Instance
to the containing type. The singleton is not of the given type anymore. If you require an instance of that type, consider instantiating one instead. - Since with this release
LayoutGraphAdapter
translatesIMapper
instances in the graph's mapper registry asIDataMap
implementations that enable data write-back scenarios, the code that deals withIncrementalHierarchicLayouter.LayerValueHolderDpKey
now behaves differently. In older releases theIIntValueHolder
interface was queried from the mapper to write back the layer data. Now the data is written directly into the mapper and theIIntValueHolder
implementation is ignored. SeeDemo.yFiles.Layout.IncrementalHierarchicLayouter
for an example on how to use the respective key.
yFiles for Silverlight 2.1.0.4 - Changes Since 2.1.0.3
Minor Improvements
- Added public helper method
PreparePrinting
toCanvasPrintDocument
in order to better support Silverlight 5's newPrint
method overloads.
Bugfixes
- Setting
GraphOverviewControl.GraphPaintable
had no effect. - Deleting graph elements during interactive edge creation could throw an exception.
- Group node visualizations were not always removed correctly when the group node was deleted.
DefaultSelectionModel
was not always cleaned up correctly when the domain was changed.SliderEdgeLabelModel
threw an exception for paths with zero length segments.FilteredGraphWrapper
: The adjacency state of the filtered instance was wrong under certain conditions.FreeEdgeLabelModel
: Fixed bad positions returned by parameter finder.- Convenience class
LabelDecorator
was unusable because of a wrong type parameter.
yFiles for Silverlight 2.1.0.3 - Changes Since 2.1.0.2
Bugfixes
LayoutGraphAdapter
did not honor mapper in the registry registered under theLayoutGraphAdapter.EdgeLabelLayoutPreferredPlacementDpKey
key.BendAnchoredPortLocationModel
could throw an IndexOutOfRangeException under certain circumstances.- Child modes of a
MultiplexingInputMode
were not always disabled together with the parent mode.
Automatic Layout and Analysis
yWorks.yFiles.Algorithms.Groups
: Fixed possible NRE when calculating BCC for a graph containing self-loops in methodBiconnectedComponentGrouping(Graph, INodeMap)
.yWorks.yFiles.Algorithms.ShortestPaths
: Fixed an error in methodFindShortestUniformPaths(Graph,INodeMap,IDataProvider,bool,int,EdgeList,NodeList)
. In many cases, nodes and edges which did not belong to a shortest path were added to the result nevertheless.yWorks.yFiles.Algorithms.GraphConnectivity
: Fixed methods that calculate biconnected components to mark selfloops as not belonging to any biconnected component.yWorks.yFiles.Algorithms.Cycles
: MethodFindAllCycleEdges(Graph, bool)
has been improved to return only edges that belong to at least one simple cycle. Previously, all edges were returned for the undirected case.
yFiles for Silverlight 2.1.0.2 - Changes Since 2.1.0.1
Bugfixes
AbstractTableNodeStyle
did not provide the table to the background style.- Sharing objects in GraphML did not work in some cases when these objects were written through a markup extension.
CreateEdgeInputMode
did not highlight the closest target port candidate during the edge creation gesture.DropInputMode#AdjustEffects
: Setting a customValidHitTestable
had no effect.DropInputMode
: The mode did not exit cleany under some rare circumstances.- Fixed endless recursion in
CommandManager#SetManaged
. - Fixed superfluous repaints in
ShapeNodeStyleRenderer
. - Fixed an issue with custom license files that were valid for a specific version, only
- Fixed
IconLabelStyle
constructor not assigning icon size. TableEditorInputMode#EditLabel
did not work.
yFiles for Silverlight 2.1.0.1 - Changes Since 2.1
Bugfixes
- Fixed exception in
LayoutExecutor
when animation and grouping were both disabled. - Fixed potential memory leaks in
TableLayoutConfigurator
when exceptions occurred. yWorks.yFiles.Algorithms.Groups.EdgeBetweennessClustering
: The parametersminGroupCount
andmaxGroupCount
had no effect.
Automatic Layout
LayoutExecutor
did not provide the GraphControl's selection to the layout engine.- Fixed
NullReferenceException
inPartitionGridLayoutStage
if no partition cells were assigned to any nodes. - Fixed Exception that was triggered when using a generic labeling algorithm (i.e. a subclass of
yWorks.yFiles.Layout.Labeling.AbstractLabelingAlgorithm
) together with layout stageyWorks.yFiles.Layout.LabelLayoutDataRefinement
.
yFiles for Silverlight 2.1 - Changes Since 2.0.0.1
Major Features Added
New Comprehensive Support for Swimlane Diagrams
- New model class
yWorks.yFiles.UI.Model.Table
provides extensive support for tabular presentation of subgraphs which is well suited for the visual presentation of swimlane layouts.
Flexible visualization for table elements by means of existing node styles is provided by implementations of theyWorks.yFiles.UI.Drawing.ITableNodeStyle
interface.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...] - New dedicated InputMode
yWorks.yFiles.UI.Input.TableEditorInputMode
which can be used either standalone or as a child mode ofyWorks.yFiles.UI.Input.GraphEditorInputMode
and which provides support for user interaction specific to the tabular data representation of an associated node.
[To the corresponding section in the yFiles for Silverlight Developer's Guide...] - New support class
TableLayoutConfigurator
can automatically create a suitable partition grid setup from existing table structures in a graph. Also,LayoutExecutor
has been enhanced to optionally configure table specific layout features. [To the corresponding section in the yFiles for Silverlight Developer's Guide...] - The
Demo.yFiles.Graph.TableEditor
demo demonstrates the capabilities of table visualization editing, as well as automatic layout of swimlane diagrams.
Visual enhancements
- Added new edge label models
RotatedSliderEdgeLabelModel
andRotatedSideSliderEdgeLabelModel
which allow placement of rotated labels on a continuous set of positions along both sides of an edge or directly on the edge path.
Automatic Layout
- New support for rotated labels (e.g. using the new
RotatedSliderEdgeLabelModel
orRotatedSideSliderEdgeLabelModel
) in the yFiles generic labeling algorithms.
Minor Features Added
CanvasControl
now offers a method that yields theVisual
for a givenICanvasObject
. This can be leveraged by UI testing tools.- New class
NodeStylePortStyleAdapter
can be used to reuse existingINodeStyle
implementations for port visualization.
Improvements
- License failures in the algorithms assembly are reported more prominently when used through
LayoutExecutor
and related convenience methods. WaitInputMode
is automatically enabled while file I/O commands are executed.GraphEditorInputMode.DeleteSelection
now doesn't create an empty Undo edit if nothing would be deleted at all.CreateEdgeInputMode
:UpdateEdgeStyle
is now called after the source port candidate has been determined.Mouse2DEventTypes
now also includes the case where mouse capture is lost. All existing input modes have been improved to take advantage of this event, where appropriate.
Automatic Layout
LayoutExtensions
: Added and improved convenience methods that deal with sequence and layer constraints.- Edges that had both source and target group IDs were not grouped at all by EdgeGroupRouterStage.
OrientationLayouter
: Node insets as well as port constraints are now also translated correctly for each possible orientation.
Demos
- Added new
Demo.yFiles.Layout.MixedLayout
demo that shows how to recursively apply different layout algorithms to the contents of group nodes. - Added new
Demo.yFiles.Layout.PartialLayout
demo that presents specific setup of the new partial layout support in conjunction with Circular, Hierarchic, Organic, and Orthogonal Layout. - The new
Demo.yFiles.Layout.LayerConstraints
demo shows how to use layer constraints with the IncrementalHierarchicLayouter to restrict the node layering. - The new
Demo.yFiles.Layout.SequenceConstraints
demo shows how to use sequence constraints with the IncrementalHierarchicLayouter to restrict the node sequencing. - The new
Demo.yFiles.Layout.PortCandidate
demo shows how PortCandidateSets can be used with IncrementalHierarchicLayouter to control from what side edges connect to certain node types in the automatic layout process.
It also show-cases a custom node style that displays simple flowchart symbols and integrated port candidate visualization. - Added new
Demo.yFiles.Layout.LogicGate
demo that shows how to apply fixed PortConstraints to a layout and how to use PortCandidates for interactive edge creation (via IPortCandidateProvider).
It also show-cases a custom node style that displays logic gate symbols. - Added new
Demo.yFiles.Layout.GenericTree
demo that shows the effects of different NodePlacer implementations on a node and its subtree(s) in a tree layout calculated by GenericTreeLayouter. - The new
Demo.yFiles.Layout.EdgeLabeling
demo shows how to configure different edge label models as well as how to apply the generic edge labeling algorithm. - The new
Demo.yFiles.Layout.NodeLabeling
demo shows how to use the node label models in conjunction with the yFiles generic labeling algorithms. - Added new
Demo.yFiles.Graph.BusinessProcessDiagram
demo that presents bow to create, edit, and lay out business process diagrams that adhere to the Business Process Modeling Notation. - The new
Demo.yFiles.Layout.BusRouterDemo
shows how to use the orthogonal bus-style edge router.
Bugfixes
- Setting the
CanvasControl.MaximumZoom
property resulted inNotImplementedException
being thrown. - Resizing nodes interactively did not make use of additional snap lines from the
GraphSnapContext
. - The expand and collapse group node commands did not execute in case the
UseCurrentItemForCommand
property was being used. NavigationInputMode.ExitGroup
raised theGroupEntered
event instead of theGroupExited
event.CreateEdgeInputMode
started calculation of the target port candidates too early and did not remove the highlighting of the target node if the creation was canceled early during the gesture.- The default implementation of
ICanvasObjectGroup
returned a broken enumerator for theIListEnumerable
interface. - A memory leak in
CreateEdgeInputMode
made cleaning up a GraphControl impossible after an edge had been created interactively using that mode with snapping disabled. - CreateEdgeInputMode's
GetSourcePortCandidate
method was sometimes invoked with the wrong location. - MouseHoverInputMode now reacts during mouse drags, too and method
Show
respects parameter if it differs from the mouse location. - Mouse events were being redispatched, even if the mouse was outside the GraphControl. This resulted in tooltips being displayed and other potential issues when the overview was used to move the viewport.
Animator.Destroy()
caused subsequent Animator usages to fail.ClickInputMode.ValidHitTestable
was not always queried in certain double click configurations.- Minimum node size was not automatically provided to the algorithms library by LayoutGraphAdapter.
- The
GraphClipboard
did not always copy all state of items that were invisible in a folded graph view. - Fixed a bug that caused the
GraphCommands.CollapseGroupCommand
andGraphCommands.ToggleGroupStateCommand
to fail in case of certain multi-node selections. ControlStyleBase.StyleTag
was not excluded from obfuscation.
yFiles for Silverlight 2.0.0.1 - Changes Since 2.0
Bugfixes
- Licensing did not work when using empty hostnames.
- Minimum node size was not automatically provided to the algorithms library by LayoutGraphAdapter.
- Fixed wrong label candidate bounds for rotated edge label layout models.
- Overriding
yWorks.yFiles.Layout.Tree.DelegatingNodePlacer#GetLowerRightChildren
andGetUpperLeftChildren
had no effect. - Fixed potential
IndexOutOfRangeException
inyWorks.yFiles.Layout.RotatedSliderEdgeLabelLayoutModel
. - Fixed invalid cast in
yWorks.yFiles.Layout.Router.EdgeGroupRouterStage
. - Fixed
NullReferenceException
when usingyWorks.yFiles.Orthogonal.OrthogonalLayouter
in FromSketchMode.
Improvements
- Improved performance of orthogonal layout.
yFiles for Silverlight 2.0 - Changes Since 1.0.1
Major Features Added
Support for creating and working with orthogonal edge paths
- Class
yWorks.yFiles.UI.Input.OrthogonalEdgeEditingContext
now mediates between the various implementations that deal with repositioning nodes, bends, and ports to ensure that orthogonal edge paths stay orthogonal during the edit process. - Interface
yWorks.yFiles.UI.Input.IOrthogonalEdgeHelper
determines how edges should be treated during editing with respect to orthogonality. - The various
IInputMode
implementations support editing orthogonal edge paths, as well as allow for creating an orthogonal edge path in the first place.
Interactive snapping of graph elements to guide lines and other elements during editing
- Class
yWorks.yFiles.UI.Input.GraphSnapContext
supports snapping elements to lines while they are being moved or resized interactively. This allows for conveniently editing diagrams by hand and still obtain great results with fixed distances and angles between elements in the diagram. - Interfaces
yWorks.yFiles.UI.Input.ISnapLineProvider
and others can be used to influence the behavior, the types, and the display of the snap lines. - Support for intelligent magnetic grid has been integrated with the new snapping API.
- Three different visualizations for the grid have been implemented: dots, crosses and lines.
Built-in support for dragging nodes from other controls to the GraphControl
- Class
yWorks.yFiles.UI.Input.NodeDropInputMode
has been added to provide convenient drag and drop support on top of the existing DropInputMode implementation. - The specialized input mode can be configured to provide a live preview of the node that will be dropped.
- Dropping can be performed directly onto group nodes, making the dropped node a new child of the group.
- The new snapping features are also leveraged by this new implementation.
Printing support
- Class
yWorks.Canvas.CanvasControl
includes methods and commands needed for convenient printing of the canvas contents. - Class
CanvasPrintDocument
has been added to provide the printing capabilities forCanvasControl
. - A demo showing the printing functionality has been created.
Support for right-clicks and context menus
- Class
yWorks.Canvas.CanvasControl
offers support for right-click handling. - New class
yWorks.Canvas.Input.ContextMenuInputMode
can be used to leverage context menu functionality.GraphEditorInputMode
andGraphViewerInputMode
provide convenience methods to populate a context menu. - A demo showing how to use the context menu has been created.
Export to Bitmap
- Export to bitmap functionality has been added directly to
CanvasControl
. - A demo demonstrating the export functionality has been created.
New Generic Style Implementation for Edges Based on ContentControls
- Creating a new style is done by implementing a Silverlight Style (preferably using a XAML designer) that defines the control template and animations as well as the different visual states of the item (selection, highlight, focus) and the transitions between them for each edge segment.
FlowDirection RightToLeft
CanvasControl
as well as all styles support FlowDirection RightToLeft and thus can be used with languages with right to left direction.
Automatic Layout
- New support for rotated labels in the yFiles generic labeling algorithms.
PartialLayouter
: A new layout algorithm for partial layouts. This layout algorithm changes the coordinates for a given set of graph elements (called partial elements). The location or size of the remaining elements (called fixed elements) is not allowed to change. The layout algorithm aims to place the partial elements such that the resulting drawing (including the fixed elements) has a good quality with respect to common graph drawing aesthetics.PartialLayoutModule
represents an interactive configurator and launcher for this layout algorithm.BusRouter
: A new orthogonal bus-style edge routing algorithm. This algorithm combines the large number of edges of complete subgraphs in a concise, tree-like structure that consists only of vertical and horizontal line segments. The positions of the nodes in a graph are not altered by this algorithm.BusRouterModule
represents an interactive configurator and launcher for this layout algorithm.OrthogonalEdgeRouter
: Added support for monotonic path restrictions. Such restrictions specify that edges should be routed monotonically in vertical and/or horizontal direction. The restrictions can be set using theMonotonicPathRestriction
property.IncrementalHierarchicLayouter
: Added data provider keyCriticalEdgeDpKey
that allows to specify a priority value for edges that are part of critical paths. The layouter tries to vertically align each node pair that is connected by such a "critical" edge (an edge that has a non-zero, positive priority value). Conflicts between different critical edges are resolved in favor of the higher priority.SimplexNodePlacer
: Added optionStraightenEdges
which allows to specify whether or not a postprocessing step should be applied that tries to remove some bends. Enabling this option may violate some minimum distances specified by the user.OrthogonalEdgeRouter
: Added support forPortCandidateSet
s that allow to specify the available port candidates at a node.
Minor Features Added
- Added support for different double-click handling modes in
ClickInputMode
as well asGraphEditorInputMode
andGraphViewerInputMode
. - Added new layout module for PartialLayouter.
- Added new layout module for BusRouter.
- Class
yWorks.Support.Windows.Colors
containing standard colors has been added. - GraphML performance has been improved and now supports XAML 2009 features.
- The assemblies have been revised and annotated to correctly work with the new .NET 4.0 security transparency model.
yWorks.yFiles.UI.Input.IPortCandiate
and default implementations have been updated to allow for dynamically determined port candidates. This enables assignment of non-discrete port locations during edge creation and edge relocation.- More fine-grained events and callbacks have been added to the various input mode implementations making customization easier, because subclassing is now less frequently required for customizations.
- Redundant folding view state data in GraphML is now omitted by default, thus greatly reducing the size of GraphML files when folding is active.
Automatic Layout
- New layout stage class
PartitionGridRouterStage
enablesOrthogonalEdgeRouter
to properly route edges within a partition grid. RecursiveGroupLayouter
: Added data provider keyGroupNodeLayouterDpKey
that allows an easier way to specify the layout algorithm used for recursive group nodes. Furthermore, it allows to specify non-recursive group nodes, i.e., group nodes whose contents are laid out using theILayouter
instance specified by the nearest predecessor of the group node (with respect to the grouping hierarchy) which is associated with an ILayouter.TreeLayouter
: Added new support for child placement policies that can be used to achieve more compact tree layouts. SeeChildPlacementPolicy
.TreeLayouter
: Added new global layering option that ensures that large nodes never span more than their layer. SeeEnforceGlobalLayering
.OrthogonalEdgeRouter
: Added support for considering node labels, seeConsiderNodeLabels
.CircularLayouter
: Added data provider keyCircleIdHolderDpKey
that allows to obtain a mapping between nodes and the corresponding circle IDs.OrthogonalEdgeRouter
: Added new routing styleRoutingStyle.Balanced
which is based on the existingRoutingStyle.Prefermiddle
but draws segments between bends of the same direction (U-style turns) the short way.
Improvements
- Animation: The
GraphOverviewControl
has been revised to be less CPU-extensive while at the same time providing real-time viewport updates. This results in a much smoother overall animation experience. - Styles: Many of the predefined styles available in the core of the library have been further optimized for animation and fewer repaints, greatly improving the rendering speed in interactive scenarios.
- LayoutModules in the demo have been improved to show the new layout features.
GraphEditorInputMode
,NavigationInputMode
: Added UseCurrentItemForCommands property.yWorks.yFiles.UI.Model.GraphExtensions
: Added another extension method for creating labels with tag.yWorks.yFiles.UI.Model.FoldedGraph
:IsExpanded(INode)
raises correct exception if node is not part of the graph.yWorks.Canvas.Geometry.Structs.PointD
: addedGetRounded()
.- Rules for
DesignerSerializationVisibility
handling in GraphML are consistent now. yWorks.yFiles.GraphML.Parser.GraphMLParser
: XMLExceptions wrapped in IOExceptions.yWorks.yFiles.GraphML.Xaml.XamlSerializer
now supportsShouldSerialize*
predicates.- The GraphML XAML parser and writer both support generic type arguments as specified in the XAML 2009 specification.
- Made SimpleLabelStyle aware of RightToLeft flow direction of the GraphControl. The renderer now automatically mirrors the text contents to compensate the transform that has already been applied to the GraphControl.
NavigationInputMode
andCanvasControl
have been improved to be aware of the FlowDirection property of theCanvasControl
so that in case of a RightToLeft setting the commands behave correctly.- New overloads have been added in
GraphMLIOHandler
to theAddRegistryInputHandler
andAddInputMapperFuture
methods that make common tasks more easy to implement.
Automatic Layout
OrthogonalEdgeRouter
: Enhanced support for port candidates.IncrementalHierarchicLayouter
: Enhanced support for fixed nodes.GroupNodeHider
: Several layout algorithms (all tree layouters, circular, all orthogonal layouters, random, the fixed group layout stage) assigned relatively small dimensions to empty group nodes. Some of them also moved these nodes to (0,0). None of these layout algorithms treats groups directly, instead they use the group node hider. The group node hider now optionally does not hide empty groups (HidingEmptyGroupNodes
) enabling that these can be treated like normal nodes. This option is now used where appropriate. Note that some layout algorithms may still shrink empty group nodes depending on the particular choice of parameters, e.g., orthogonal layout with uniform node sizes.
Tutorials
- The Getting Started tutorial has been improved to show the new snapping and orthogonal edge editing features.
- The Style Tutorial has been improved to better demonstrate performance gain by implementing update and high-performance dropshadow.
Demos Added
- Demo styling and utilities have been extracted to source code project
Demo.yFiles.SilverlightToolkit
- Implementations of menu and toolbar have been added to project
Demo.yFiles.SilverlightToolkit
- GraphEditor demo has been added as a source code demo. This demo shows many of the major library features such as interactive editing and automatic layout.
- A demo showing context menus has been added.
- A demo that shows how the snapping feature can be customized has been added.
- A demo has been implemented that shows how to configure edges for orthogonal editing.
- The interactive drag and drop feature for nodes showing a preview and snapping is demonstrated in a new demo.
- A demo that shows how to print the canvas contents has been added.
- A demo that shows how to export the canvas contents to different image formats has been added.
IncrementalHierarchicLayouter
demo has been added to demonstrate the usage of Incremental Hierarchic Layouter.- The OptionHandler framework for querying and presenting options and settings to the user that has been part of the core library in yFiles for Silverlight 1.0.1 is now part of the demos in source code form.
- GraphML demo has been improved.
- A demo has been added that shows how to implement a UML node style that changes it's size dynamically.
- A data binding demo showing how to use
TreeSource
as a graph source has been added. - A data binding demo showing how to use
GraphSource
for data binding has been added. The GraphSource demo constructs the graph data from XML. - A data binding demo showing how to use an adapter to create an
IGraph
from an arbitrary business model has been added.
Bugfixes
- GraphML: Fixed broken serialization of primitives and string values in element syntax.
- GraphML: Public properties with a non-public getter or setter are ignored now.
yWorks.yFiles.GraphML.Xaml.XamlReader
: XML attributes that are bound to an XML namespace are ignored if they do not specify an attached property.- Fixed crash in
yWorks.yFiles.Layout.Hierarchic.IncrementalHierarchicLayouter
when a node has more than 60 selfloops. - Fixed crash when removing
IEdge
that has same source and target port. PanelNodestyle
can now deal with empty layout.yWorks.yFiles.UI.LabelModels.RotatingEdgeLabelModel
did not work for zero path lengths that have bends.- Fixed bend movement along with nested group nodes.
yWorks.Canvas.Geometry.OrientedRectangle
: Fixed Angle getter.yWorks.yFiles.UI.DataBinding.GraphSource
: Fixed a bug that prevented an edge that had previously been removed from the model could ever be part of the model again at a later point in time.yWorks.yFiles.GraphML.Xaml.XamlReader
:- In some cases, collection content wasn't handled correctly for writeable properties.
- XML comments were not skipped when reading collection content.
- Fixed bug with interface typed properties.
- Primitives in a collection context were not always serialized correctly.
- Public properties with a non-public accessor are now correctly handled by the GraphML XAML framework.
yWorks.yFiles.GraphML.Parser.GraphMLParser#Parse
will not overwrite an explicitely setyWorks.yFiles.GraphML.Writer.SerializationProperties#BaseUri
.yWorks.Canvas.Input.OverviewInputMode
: Fixed a possibleNullReferenceException
that could happen if the control had not yet been bound to a master canvas control.- Undo/Redo did not always work properly when group node contents were moved, resized, or moved to different group nodes.
- All overloads of
yWorks.Canvas.Geometry.Matrix2D#Transform
now behave consistently. yWorks.yFiles.UI.PortLocationModels.BendAnchoredPortLocationModel
was not always serialized correctly.- Fixed an exception in the undo code that occurred in the context of
FoldingManager
when nodes where moved into a collapsed group node. - Fixed a problem that resulted in edges created interactively where there were no port candidates available but the
CreateEdgeInputMode.ConnectToPortCandidatesOnly
property was set to false had the wrong source port location model assigned. This resulted in these edges unexpectedly jumping to the mouse cursor. - String values in list and array contexts in GraphML files did not have an enclosing tag. This has been fixed.
- Fixed an exception that occurred when disabling shared references in
GraphMLIOHandler
.
Folding bugfixes
A great number of bugs have been fixed in the folding environment. All of them could only be triggered programmatically.
- Fixed programmatic edge creation.
yWorks.yFiles.UI.Model.GroupedGraphExtensions.CreateGroupNode(INode parent)
: Fixed extension method ignoring parent.- Fixed
yWorks.yFiles.UI.Model.HierarchyExtensions.GetNearestCommonAncestor()
not returning correct ancestor in some cases. SetLeaf()
and setLocalRoot
not included in Undo queue.yWorks.yFiles.UI.Model.GroupedGraphExtensions.GroupNodes(IEnumerable<INode>)
called with empty enumerable callsCreateGroupNode()
instead of creating group node with empty layout.- Various bugs that occurred in rare cases due to corrupted internal data structures have been fixed.
Automatic Layout
InteractiveOrganicLayouter
: Fixed bug that prevented the calculation of any layout before the first call toWakeUp
.ComponentLayouter
: Fixed bug that caused a wrong component assignment if customized component IDs were used.IncrementalHierarchicLayouter
: Fixed bug that sometimes caused an assignment of infinite coordinates to group nodes as well as to points of edges incident to group nodes.IncrementalHierarchicLayouter
: Fixed bug that caused unnecessary crossings when using node grouping.
Changes in Default Behavior
- GraphML resource paths are now resolved and written relative to the location of the GraphML document where possible.
- Structural errors in GraphML files now always throw an
IOException
instead of being ignored silently. - Redundant view state data in GraphML is now omitted by default, which is incompatible with yFiles for Silverlight 1.0 and earlier. Set
yWorks.yFiles.GraphML.Writer.SerializationProperties#FoldingVersion
to1.0
to use the old behavior.
Incompatible Changes
- The attached CommandBindings and InputBindings property provided by
CommandManager
have been made read-only. This makes previous XAML code illegal. Instead the container classes need to be omitted as they are now automatically created on first access to the property. See the source code demos for an example of a correct usage (Note that at the time of writing Resharper incorrectly marks the XAML code red, although it compiles and works as expected). - Group nodes no longer automatically adjust their bounds if the bounds of the contained nodes are changed programmatically. In all interactive scenarios the bounds are updated automatically but programmatic changes to the layout of nodes need an additional call to one of the
EnlargeGroupNode
extension methods ofIGroupedGraph
. This greatly simplifies the changing of the coordinates of nodes programmatically in a consistent manner and also enables automatic rerouting of orthogonal edge paths adjacent to parent nodes, among other things. Usages of theIMovable
interface should be replaced by usages of theIPositionHandler
interface instead for the same reason. Also, the newIReshapeHandler
interface needs to be used instead of theIReshapeable
interface to provide a context to the implementation again for the same reasons. - The
IPortCandidate
interface has been changed to allow the implementation of dynamic port candidates that are aware of a specific user-specified location. For this to work the booleanValid
flag has been replaced by the three-stateValidity
enum-backed property.false
andtrue
directly map toInvalid
andValid
. The third possible valueDynamic
does not need to be considered in existing applications because it will only come into play if the new feature is being used actively. Also, theCreateInstance
method has been changed to now take a parameter of typeIInputModeContext
and may not returnnull
anymore. Please see the compatibility source code project and the migration guide on how to properly adjust existing code. - The undo mechanism has been improved so that beginning a compound edit does not place it into the undo queue immediately. Thus the rest of the queue is not discarded anymore if the edit is canceled afterwards. The compound edit will only become visible in the undo queue once its
End
method has been called. - Serialization and deserialization properties now use the strongly typed
yWorks.Support.TypedKey<T>
class. For the predefined properties inyWorks.yFiles.GraphML.Writer.SerializationProperties
, this change should be mostly transparent from user code. - Redundant serialization property
yWorks.yFiles.GraphML.Writer.SerializationProperties#DocumentLocation
has been removed. UseyWorks.yFiles.GraphML.Writer.SerializationProperties#BaseUri
instead. yWorks.yFiles.GraphML.Xaml.GraphMLValueSerializerContext
cannot be instantiated directly anymore.yWorks.yFiles.Algorithms.Util.DoubleObjectPQ
: Changed the type of parameterpriority
fromint
todouble
for methodsDecreasePriority
,IncreasePriority
andChangePriority
.
Of course, the yFiles for Silverlight support team will aid existing customers in migrating their code and possibly data to the new API based on their subscription.
yFiles for Silverlight 1.0.1.1
Bugfixes
- Fixed memory leak in folding infrastructure.
- Fixed
ConcurrentModificationException
in folding infrastructure. - Licensing did not work when using empty hostnames.
- Fixed possible
NullReferenceException
inAbstractXmlWriter
when explicitely using anull
namespace prefix.
yFiles for Silverlight 1.0.1
Major New Features
- yFiles for Silverlight is now fully compatible with the Silverlight 4 SDK.
Bugfixes
- Changed signature of
yWorks.Support.Windows.CommandManager.GetCommand
andyWorks.Support.Windows.CommandManager.SetCommand
to useyWorks.Support.Windows.RoutedCommand
which fixes a compatibility problem with Silverlight 4.
New demos
- For all demos and tutorials, separate projects that target Silverlight 4 are provided.
yFiles for Silverlight 1.0
Major New Features
- yFiles for Silverlight 1.0 is the initial release of yFiles for Silverlight.