yFiles for Java Release Notes

yFiles for Java 3.1 is the newest major release available. (See also the entire yFiles for Java change log.)

Technical Requirements

  • To develop yFiles for Java 3.x-based applications, a Java 8 (or greater) Java Development Kit (JDK) is required.
  • To run yFiles for Java 3.x-based applications, a Java 8 (or greater) Java Runtime Environment (JRE) is required.

yFiles for Java 3.1 - Changes Since 3.0.0.4

Hide Description
Open in yEd LiveDownload
yFiles for Java 3.1 Release Notes
New support for Sankey diagrams with thick edges
yFiles for Java 3.1 Release Notes
New support for port grouping
yFiles for Java 3.1 Release Notes
New support in the Hierarchic layout for non-structural edges

General Improvements

  • The naming of classes, members and parameters has been reviewed and now uses more consistent and intuitive names. Please consult the Developer's Guide for a complete list of renamings.
  • Some functionality has been removed from the API to reduce its complexity and some of the functionality has been moved to different classes or packages. Again, see the Developer's Guide to get a full list of moved/removed functionality.

Features

Layout

  • HierarchicLayout: Added support for port grouping, see PortConstraintKeys#SOURCE_GROUP_ID_DPKEY and PortConstraintKeys#TARGET_GROUP_ID_DPKEY. Edges are bundled at their ports, but routed independently.
  • HierarchicLayout now allows to specify the directedness of edges, see HierarchicLayout#EDGE_DIRECTEDNESS_DPKEY. This new feature enables to, for example, support mixed graphs that contain both directed and undirected edges: While for directed edges the layering step tries to find a solution where the source of an edge is placed above the target (with respect to the main layout direction), for undirected edges the direction doesn't matter and the edge may also be inserted as same-layer edge. This feature also enables to force some edges to specifically point against the main layout direction.
  • HierarchicLayout: Added support for edges with a specific thickness. Minimum distances in the layout will consider these thicknesses, see HierarchicLayout#EDGE_THICKNESS_DPKEY.
  • LabelPlacements: Added preferred placement specifiers #AT_SOURCE_PORT and #AT_TARGET_PORT for edge labels which express that the label should be placed directly at the source/target port of the edge. Currently, the specifiers are only considered by the integrated labeling of the HierarchicLayout and can be specified with property PreferredPlacementDescriptor#PlaceAlongEdge.
  • OrganicLayout now supports the detection of regular substructures in the graph (see methods #setChainSubstructureStyle(ChainSubstructureStyle), #setStarSubstructureStyle(StarSubstructureStyle), #setCycleSubstructureStyle(CycleSubstructureStyle), and #setParallelSubstructureStyle(ParallelSubstructureStyle) and applies a specific layout style to them such that they can be better recognized.
  • TreeReductionStage: Added possibility to specify a custom labeling algorithm that places labels of non-tree edges. Now, users do not need to take care of such edge labels themselves after using a tree layout algorithm on a non-tree input graph in conjunction with the reduction stage. See properties #NonTreeEdgeLabelingAlgorithm and #NonTreeEdgeLabelSelectionKey.
  • SeriesParallelLayout: Added possibility to specify a custom labeling algorithm that places labels of non-series-parallel edges. Such labels are now automatically handled. Users do not need to handle them after running the algorithm with a non-series-parallel input graph. See properties #NonSeriesParallelEdgeLabelingAlgorithm and #NonSeriesParallelEdgeLabelSelectionKey.

Improvements

Viewer

  • IGraph: The default methods #applyLayout(ILayoutAlgorithm) and #applyLayout(ILayoutAlgorithm, LayoutData) have been added.
  • FilteredGraphWrapper now no longer queries the node and edge predicates as often.
  • IMapperRegistry: Several overloads for the #create*Mapper methods have been added that take more specific tags but allow to omit the keyType parameter.
  • GraphComponent: Four #morphLayout convenience methods have been added that run a layout on the graph of the component and animate the results.
  • The property GraphComponent#GraphMLIOHandler has been added to set a custom GraphMLIOHandler to be used by the IO commands and convenience IO methods. Previously the lookup of the class needed to be decorated.
  • GraphComponent: The overloads #importFromGraphML(java.io.Reader), #importFromGraphML(java.io.InputStream), #exportToGraphML(java.io.OutputStream, java.net.URI) and #exportToGraphML(java.io.Writer, java.net.URI) have been added.
  • Animator: A getter for the CanvasComponent, which had been passed to the constructor, was added.
  • The types of the static #INSTANCE fields of VoidNodeStyle, VoidEdgeStyle, VoidLabelStyle, VoidPortStyle, VoidStripeStyle and VoidStripeStyleRenderer have been changed to the concrete types instead of the interface types (e.g. INodeStyle).
  • IconLabelStyle: A constructor has been added that only takes a custom renderer as argument.
  • Class DefaultPortCandidateDescriptor, which is used to visualize IPortCandidates, now provides static ResourceKey fields that are used to lookup IVisualTemplates for the different states of IPortCandidates. Custom IVisualTemplates can be used by either registering them via CanvasComponent#putClientProperty or by the new convenience method DefaultPortCandidateDescriptor#setTemplate.
  • Resizing a table row or column now respects the GraphEditorInputMode#AdjustContentRectPolicy.
  • CreateEdgeInputMode now respects the settings #SnappingBendsToSnapLinesEnabled and #SnappingBendAdjacentSegmentsEnabled on GraphSnapContext. It also handles grid snapping according to the configuration for snapping.
  • Nodes now show their target grouping hierarchy z-order during a reparenting gesture.
  • GraphMLIOHandler now has #addXamlNamespaceMapping methods for easier control of the XML namespace for certain types.
  • GraphMLIOHandler has two new events, #QueryType and #QueryName that allow for fine-grained control over XML namespace writing and parsing for certain types.
  • GraphMLIOHandler: The overloads #read(IGraph,java.io.Reader), #read(IGraph, java.io.InputStream), #write(IGraph, java.io.OutputStream, java.nio.charset.Charset, java.net.URI) and #write(IGraph, java.io.Writer, java.net.URI) have been added.
  • GraphMLParser: The overloads #parse(IGraph,Reader,IGraphElementFactory) and #parse(IGraph, InputStream, IGraphElementFactory) have been added.
  • GraphML: The performance for parsing java enums and FlagsEnums has been improved.
  • GraphML: Parsing java enums and FlagsEnums has been refactored and now respects SerializationProperties#IGNORE_PROPERTY_CASE.

Layout

  • HierarchicLayout: Slightly reduced the number of bends when integrated edge labeling is enabled.
  • HierarchicLayout: Fixed unstable from-sketch behavior for non-default layout orientations when group nodes are folded or expanded. Applies to orientations LayoutOrientation#LEFT_TO_RIGHT, LayoutOrientation#RIGHT_TO_LEFT and LayoutOrientation#BOTTOM_TO_TOP. Geometry information registered with data providers with keys HierarchicLayout#ALTERNATIVE_GROUP_BOUNDS_DP_KEY and HierarchicLayout#ALTERNATIVE_EDGE_PATH_DP_KEY is now automatically rotated according to the specified layout orientation.
  • HierarchicLayout: Improved support for PortCandidates at group nodes. Previously, they were only obeyed if there was just a single candidate defined, which also applied to the opposite node (not necessarily a group node). Now, out of the given candidates, one is selected and considered for the routing. Still, fixed candidates are treated like free ones and are not supported at the side of group nodes.
  • HierarchicLayout: Routing of grouped edges that connect to nodes of different groups now assures that the whole bus segment remains outside the different group nodes. This avoids that group nodes get unnecessarily large and potentially makes drawings more symmetric.
  • HierarchicLayout: Improved edge grouping such that it is now possible to group incoming/outgoing edges as well as same-layer/backloop edges with common edges.
  • HierarchicLayout: Can now take the original edge route into account to determine the route of a self-loop.
  • MultiPageLayout: Added new option #StrictClusterSeparationEnabled that allows to specify whether or not nodes with different cluster IDs may be placed onto the same page.
  • The tree algorithms BalloonLayout, TreeLayout and AspectRatioTreeLayout now support custom selection of the root node of the tree.
  • BalloonLayout: Interleaved child placement now works in conjunction with from sketch-mode and custom child order comparators. This means that the settings #FromSketchModeEnabled and #Comparator are no longer ignored when enabling the interleaved placement mode (see #InterleavedMode).
  • TreeLayout: Now take into consideration the minimum group node size specified by the user with a IDataProvider registered with the graph with key GroupingKeys#MINIMUM_NODE_SIZE_DPKEY.
  • SeriesParallelLayout: Now takes into consideration the minimum node size specified by the user with a IDataProvider registered with the graph with key GroupingKeys#MINIMUM_NODE_SIZE_DPKEY.
  • Improved the runtime of EdgeRouter when routing edges that have PortConstraints or PortCandidates.
  • Improved the performance of OrthogonalSegmentDistributionStage and thus also ChannelEdgeRouter which by default uses the mentioned stage as edge distribution strategy.
  • ChannelRouter: Improved order of segments to avoid edge crossings when there are multiple segments that have one common end point.
  • Improved the performance of PartialLayout for input graphs that feature a high number of large subgraph components. Does not apply for component assignment strategy ComponentAssignmentStrategy#SINGLE.
  • LayoutUtilities#applyLayout now supports layout of tables.
  • ItemMapping: The property #Mapper is now automatically set on first read-access to the property, enabling more convenient use of the mapper without first having to instantiate a matching instance.
  • PartitionGridData: It is now sufficient to specify one of a row mapping or the column mapping. The unspecified one will automatically be set to 0, resulting in a single row or column being used.
  • BalloonLayoutData, HierarchicLayoutData, LabelingData, OrthogonalLayoutData, SeriesParallelLayoutData and TreeLayoutData now have an EdgeLabelPreferredPlacement property which supports an ItemMapping for edge labels to provide a PrefererredPlacementDescriptor. Can be used as alternative to mappers registered with LayoutGraphAdapter#EDGE_LABEL_LAYOUT_PREFERRED_PLACEMENT_DESCRIPTOR_DPKEY.
  • PlanarEmbedding has been added and allows to calculate and query an embedding of a planar graph.

Bugfixes

Viewer

Model

  • Fixed a bug in IGraph#addLabel that ignored an explicitly specified preferred size if folding is enabled.
  • FilteredGraphWrapper: The fail-fast mechanism to detect concurrent modification changes in the #Nodes, #Edges, #Labels and #Ports IListEnumerables didn't detect all modifications correctly.
  • Folding:
    • Fixed a bug that sometimes ignored the view state for a port on a folder node when a folding edge was created.
    • Fixed a potential exception when using folding on a filtered graph when either nodes with labels or ports, or edges with bends or labels are shown for the first time after being hidden before.
    • Fixed a bug that treated group nodes with no children als non-group nodes after they have been expanded.
    • Fixed a bug that creates folders with empty size when manually creating groups and the folding view is configured to collapse group nodes by default.
  • SandwichLabelModel: Fixed incorrect DefaultValue annotation for some created parameters.
  • SmartEdgeLabelModel: An exception was thrown if the path of the corresponding edge contained bends that were close together or at the same location.
  • NinePositionsEdgeLabelModel: Fixed the placement for the positions #SOURCE_BELOW and #TARGET_BELOW.

Geometry

  • GeneralPath#equals does no longer check for path equivalence (same coordinates etc.), but simply checks reference equality. This makes it consistent with the #hashCode method. To check for path value equivalence, use the new method #isEquivalentTo instead.

View

  • Fixed GraphComponent's #importFromGraphML(java.io.File) method to respect the GraphMLIOHandler's #ClearingGraphBeforeReadEnabled property. (All the other #importFromGraphML methods already did so.)
  • Label text isn't mirrored anymore if ComponentOrientation#RIGHT_TO_LEFT is set on the GraphComponent.
  • GraphOverviewComponent: Setting a new #OverviewInputMode updates now the #InputMode property accordingly.
  • Fixed a bug that might occur when changing wrapped styles in CollapsibleNodeStyleDecorator, ShadowNodeStyleDecorator, NodeStyleLabelStyleAdapter and NodeStylePortStyleAdapter.
  • Fixed a bug in GraphModelManager that didn't update the child groups if a new #ContentGroup is set.
  • Fixed a bug in GraphModelManager where #HierarchicEdgeNestingEnabled set to false was not respected when the graph changed or a group node was created first on a yet ungrouped graph.
  • Fixed some styles to call IRenderContext#childVisualRemoved after the IVisual actually has been removed instead of just before the removal.
  • Fixed a possible NullPointerException in the graph rendering code when items were removed from the graph during their style's #updateVisual method. This could happen when removing graph items from a different thread (which is still not supported, but at least this particular case won't crash anymore).
  • Fixed the maximum y-coordinate for horizontal grid lines produced by GridVisualCreator with grid style LINES.

Input

  • All shortcuts have been adapted to the operation system conventions, e.g. shortcuts on Mac do not use the Control key anymore but the Command key as modifier instead.
  • CreateEdgeInputMode: Fixed a bug that didn't show the edge preview when the edge would be created between a node and one of its ancestors or vice versa.
  • CreateEdgeInputMode: The #EdgeCreated event triggered before the corresponding undoable edit was committed. This could result in a broken undo queue, if e.g. an animated layout was started during in the event listener. The event now triggers after the edit has been committed. With automatic undo unit merging, this should not make a difference for the end user, however from the perspective of the code there will be two subsequent edits, rather than one compound, if the code in the listener actually modifies the edge.
  • CreateEdgeInputMode: Fixed a bug that broke the edge preview after the input mode was uninstalled and reinstalled again.
  • Fixed a bug in bend creation for orthogonal edges when grid snapping was enabled.
  • A bug in orthogonal edge editing was fixed where an edge could become non-orthogonal when a non-selected bend was moved.
  • Fixed an issue with orthogonal edge editing where canceling moving a port or node would add bends to otherwise straight edge segments.
  • Self-loops with same source and target location are now treated as orthogonal.
  • When dragging an unselected bend and canceling the gesture by pressing ESC, the dragged bend was removed.
  • Fixed a bug that prevented individually disabling certain grouping commands.
  • OverviewInputMode: Fixed a bug that could break the overview visualization if the overview has a specific very small width or height.
  • StripeDropInputMode: Fixed a bug that could result in nodes being moved to a wrong stripe when a new stripe was created or an existing one relocated.
  • NodeDropInputMode: Fixed a possible exception when snapping is enabled, but preview disabled.
  • When a node and its parent group node were both selected and moved with the SHIFT key held down the node was erroneously reparented to the root.
  • Fixed reparent highlighting when multiple nodes are reparented together.
  • Fixed an issue where the parameter finder for FreeEdgeLabelModel cannot place the label correctly for self-loops. Labels previously always appeared at the port location in this case.
  • Hiding INodeSnapResultProvider or IBendSnapResultProvider from the lookup no longer leads to a crash when nodes or bends are moved.
  • Fixed an issue where ICommand#EDIT_LABEL would not work directly on labels when a TableEditorInputMode is active.

Styles

  • DefaultLabelStyle: Fixed vertical text alignment for instances with non-empty insets.
  • IconLabelStyle: Fixed a NullPointerException that occurred when rendering the style while the #Icon property is set to null

GraphML

  • Fixed a bug in GraphML parsing that prevented finding the annotated @GraphML#contentProperty of a class.
  • Fixed a bug in GraphML parsing that could result in an exception when parsing an empty text element.
  • Fixed a bug in GraphML serialization that ignored @GraphML annotations for static fields.
  • Fixed structured GraphML serialization of DashStyle, Pen and URL instances.
  • The ValueSerializer used for predefined Pens and IArrows now also respects the SerializationProperty#IGNORE_PROPERTY_CASE.
  • Methods GraphMLIOHandler#addRegistryOutputMapper(String,Object) and #addRegistryOutputMapper(String, String, Object, IEventListener) created multiple GraphML key definitions for the same mapper instance
  • Arrow: Added @Obfuscation annotation to exclude the class from obfuscation. Excluding Arrow from obfuscation is necessary for properly reading (and writing) GraphML files.
  • Fixed the @DefaultValue annotations for the #Pen and #Paint properties in ArcEdgeStyle, PolylineEdgeStyle, GeneralPathNodeStyle and ShapeNodeStyle.
  • Fixed GraphML (de-)serialization of ports using SegmentRatioPortLocationModel and corresponding port location parameter instances.

Layout

  • HierarchicLayout: Fixed bug that caused a violation of the specified minimum distance or edge overlaps in the case of same-layer edges.
  • HierarchicLayout: Fixed rare bug that caused same-layer edge to cross through their source or target node, e.g., the port was at the top of the source node but the edge crossed through the source node to leave it at the bottom.
  • HierarchicLayout: Fixed bug that sometimes caused the route of back-loop edges with at least one endpoint incident to a group node to unnecessarily enter this group node.
  • HierarchicLayout: Fixed bug that sometimes caused superfluous bends in edge routes when integrated edge labeling was enabled.
  • HierarchicLayout: Fixed bug that caused that the directedness of edges incident to groups wasn't considered correctly (see HierarchicLayout#EDGE_DIRECTEDNESS_DP_KEY).
  • HierarchicLayout: Fixed bug that caused node-edge overlaps in conjunction with some complex edge grouping specifications.
  • RecursiveGroupLayout when used with HierarchicLayout as core layout algorithm: Fixed IllegalStateException that could be triggered when group nodes of the input graph have PortCandidates.
  • RecursiveGroupLayout: Fixed bug that caused edges to share the same port even though they should be assigned to different ports. Note that this problem only appeared if the core layout algorithm (see CoreLayout) is an instance of class HierarchicLayout.
  • SimplexNodePlacer: Fixed bug that caused overlaps between edges and nodes when enabling node compaction (see #NodeCompaction) and having edges with either strong PortConstraints or PortCandidates.
  • OrganicLayout: Fixed bug that caused group nodes with zero height/width in the layout result. The bug appeared when having empty groups, group node insets smaller than one (defined via GroupingKeys#GROUP_NODE_INSETS_DPKEY) and no minimum group node size specified (GroupingKeys#MINIMUM_NODE_SIZE_DPKEY).
  • OrganicLayout and ClassicOrganicLayout: Fixed bug that caused the algorithm to not consider the specified custom IGroupBoundsCalculator (see ClassicOrganicLayout#GroupBoundsCalculator).
  • Fixed OrganicLayout ignoring the GroupNodeMode settings.
  • OrganicLayout, ClassicOrganicLayout and InteractiveOrganicLayout: Fixed IllegalArgumentException that was triggered due to NaN values that could occur in case the input graph has a very large number of nodes.
  • CircularLayout and RadialLayout: Fixed bug that caused that always all edges are bundled if bundling is enabled for at least one single edge. More precisely, property EdgeBundleDescriptor#Bundled wasn't considered correctly.
  • CircularLayout: Fixed bug that in some cases produced self-intersecting edges when edge bundling is enabled.
  • SingleCycleLayout: Fixed bug that may lead to a ClassCastException if edge bundling is enabled and a custom node sequencer is specified (see SingleCycleLayout#NodeSequencer).
  • AspectRatioTreeLayout#ROOT_PLACEMENT_DPKEY is now of type NodeDpKey<RootPlacement>.
  • AspectRatioTreeLayout#SUBTREE_ROUTING_POLICY_DPKEY is now of type NodeDpKey<SubtreeArrangement>.
  • AspectRatioTreeLayoutData did not register the correct values with the graph for the root placement and the subtree routing policy.
  • MultiPageLayout: Fixed rare bug that sometimes caused straight-line edge routes instead of orthogonal routes.
  • IsolatedGroupComponentLayout: Fixed bug that caused edge labels that intersect with group nodes even though option ComponentLayout#LabelConsiderationEnabled is enabled.
  • EdgeRouter: Fixed rare RuntimeException that appeared if there were fixed (see #Scope) and grouped edges at the same time.
  • EdgeRouter: Fixed rare IllegalArgumentException that was triggered when having multiple target port candidates, where at least one must be fixed. Furthermore, to trigger the exception it is necessary that the path search algorithm tries to perform an early exit due to maximum duration restrictions or a stop request via AbortHandler.
  • EdgeRouter: Fixed bug that caused violations of minimum first/last segment lengths of grouped edges when using different edge layout descriptors and, second, made the layout algorithm remove a user-registered IDataProvider with key EdgeRouter#EDGE_LAYOUT_DESCRIPTOR_DPKEY.
  • EdgeRouter: Fixed rare node overlaps in conjunction with monotonic path restrictions (see EdgeLayoutDescriptor.MonotonicPathRestriction).
  • ChannelEdgeRouter: Fixed routing of self-loops that have both source and target end point at the same side of the node. Previously, when multiple such self-loops were present at the same node, the routing produced bad end points located outside of the node.
  • Groups#hierarchicalClustering(Graph,int,INodeMap,INodeDistanceProvider,Linkage): Fixed NullPointerException that occurred when the given maximum number of clusters was 0 or 1.
  • Fixed NullPointerExceptions in some LayoutData implementations that could happen if some of the mappings where accessed but were never really used in client code.
  • Fixed a bug in TableLayoutConfigurator which altered the size of a column or row if an edge routing algorithm has been applied.
  • Fixed a bug in TableLayoutConfigurator which sometimes used the wrong table insets.
  • LayoutGraphAdapter/CopiedLayoutIGraph: IMappers which use ILabels as key and boolean, int or double as value are now correctly translated into data providers for layout algorithms.
  • Fixed a bug that a dataprovider with key LayoutGraphAdapter#EDGE_LABEL_LAYOUT_PREFERRED_PLACEMENT_DESCRIPTOR_DPKEY that has been filled by a LayoutData has been ignored.

Incompatible Changes

Viewer

Model

  • IGraph: The signature of method #addBend(IEdge, int, PointD) has been changed to #addBend(IEdge, PointD, int).
  • IMapperRegistry: Renamed the methods #add* to #create*. The type of property #MapperMetadata has been changed from IMapperMetadata to MapperMetadata.
  • DefaultGraph and AbstractGraphWrapper: The signature of method #addBend(IEdge, int, PointD) has been changed to #addBend(IEdge, PointD, int).
  • FoldingEdgeState: The signature of method #addBend(int, PointD) has been changed to #addBend(PointD, int).

Geometry

  • GeneralPath: The return value type of method createPath has been changed from Path2D.Double to Path2D.

View

  • Most implementations and some usages of IAnimation have been removed and are now available as factory methods in IAnimation. This included the classes LayoutMorpher, EasedAnimation, GeneralPathAnimation, ParallelAnimation, LabelAnimation, NodeAnimation, PortAnimation, EdgeAnimation.
  • GraphModelManager: Signature of method #typedHitElementsAt(IInputModeContext, Class<T>, PointD, ICanvasObjectGroup) has been changed to #typedHitElementsAt(Class<T>, IInputModeContext, PointD, ICanvasObjectGroup).
  • CanvasComponent: The property #Editable has been removed. It had no effect on almost all input modes anyway. To no longer allow editing a CanvasComponent use a different input mode instead, e.g. GraphViewerInputMode, or configure the current input mode in a way that it no longer allows changes.
  • GraphComponent: Decorating the lookup of GraphComponent or IGraph to set the GraphMLIOHandler used by the IO commands and convenience IO methods on GraphComponent is no longer supported. Use the #GraphMLIOHandler property on GraphComponent instead.
  • The interface IRectanglePainter has been replaced by the more powerful interface IVisualTemplate. Implementations have been adjusted accordingly and members and classes with name *Painter or *RectanglePainter have been renamed to *Template or *VisualTemplate.
  • EdgeDecorationInstaller: The method #getBendVisual(IRenderContext,IBend) returning an IVisual was replaced by the method #getBendDrawing(CanvasComponent,IEdge) returning an IVisualTemplate that is used for all bends of the passed edge.
    The subclasses EdgeFocusIndicatorInstaller, EdgeHighlightIndicatorInstaller and EdgeSelectionIndicatorInstaller now contain static ResourceKey fields #BEND_TEMPLATE_KEY that can be used to register custom IVisualTemplates for bends on the GraphComponent.

Input

  • The command mechanism has been refactored:

    • ICommand, CommandAction, CommandBindingAction have been moved to package com.yworks.yfiles.view.input. Classes Command, CommandBinding, CommandManager, CanExecuteRoutedEventArgs, ExecutedRoutedEventArgs as well as the related properties on CanvasComponent have been removed. KeyboardInputMode offers new methods #addCommandBinding and #addKeyBinding for binding commands to actions and keyboard gestures to commands.
    • Class KeyboardInputMode has been refactored. New interfaces CanExecuteCommandHandler and ExecuteCommandHandler for handling commands have been introduced. All methods for binding commands to IEventListener implementations have been retrofitted to the aforementioned handlers. All methods for removing command or key bindings have been removed. Methods for adding such bindings now return a KeyboardInputModeBinding instance that offers a #remove method for this purpose.
  • OverviewInputMode now allows to zoom out further.
  • OrthogonalEdgeEditingContext: Changed return value of methods #getMovementInfos(IEdge) and #getSegmentOrientations(IEdge) to IListEnumerable.
  • HandleInputMode: For all HandleTypes a corresponding ResourceKey was added as static field that can be used to register a custom IVisualTemplate for this handle type. Per default the #createVisual(IRenderContext,IHandle) method now looks up the IVisualTemplate for the ResourceKey matching the HandleType for the passed IHandle. The #updateVisual method is no longer used and was removed.
  • An initially collapsed group node as a result of ICommand#GROUP_SELECTION now has a reasonable size.
  • IClipboardIdProvider: Signature of method #getId(IModelItem, IGraphClipboardContext) has been changed to #getId(IGraphClipboardContext, IModelItem).
  • GraphCopier: Changed signature of method #addBend(IGraph, IGraph, IEdge, IBend, int, PointD) to #addBend(IGraph, IGraph, IEdge, IBend, PointD, int).

Styles

  • AbstractEdgeStyle and AbstractStripeStyle: The return type of method #clone() has been changed from AbstractEdgeStyle<TVisual> to AbstractEdgeStyle. Furthermore, the return type of methods #createVisual(IRenderContext, IEdge) and #updateVisual(IRenderContext, IVisual, IEdge) has been changed from TVisual extends IVisual to IVisual.
  • IconLabelStyle:
    • The type of property #Url has been changed from String to java.net.URL.
    • The constructors have been changed and now take the URL of the icon instead of its Image.
  • MemoryIconLabelStyle: Simplified constructors that now only allow to specify the image of the icon as well as a custom renderer.
  • The type of ArcEdgeStyle#Renderer has been changed from IEdgeStyleRenderer to ArcEdgeStyleRenderer.
  • The type of PolylineEdgeStyle#Renderer has been changed from IEdgeStyleRenderer to PolylineEdgeStyleRenderer.
  • TableNodeStyle: The type of property #Renderer has been changed from INodeStyleRenderer to TableNodeStyleRenderer. Furthermore, the parameter type of methods #addPropertyChangedListener(IEventListener<PropertyChangedEventArgs>) and #removePropertyChangedListener(IEventListener<PropertyChangedEventArgs>) has been changed from IEventListener to IEventListener<PropertyChangedEventArgs>.
  • The type of VoidStripeStyle#Renderer has been changed from IStripeStyleRenderer to VoidStripeStyleRenderer.

GraphML

  • GraphML annotations: SerializationVisibilityType and GraphMLSerializationMode have been merged to GraphMLMemberVisibility.
  • Property: The properties #Value and #OwnerInstance have been removed. The new methods getValue and setValue now take the owner instance as parameter.
  • HandleSerializationEventArgs: The property #SourceType is now of type java.lang.reflect.Type instead of java.lang.Class.
  • IWriteContext and IParseContext: A parameter of type Class<T> that describes the target type has been added to the #getCurrent methods.
  • XamlSerializer: Signature of method #serialize(Type, IWriteContext, Object) has been changed to #serialize(IWriteContext, Object).
  • IXamlNameMapper: The return type of method getName(IWriteContext, Type) has been changed from String to XmlName.
  • QueryOutputHandlersEventArgs: Constructor QueryOutputHandlersEventArgs(IWriteContext, KeyScope, Map<Object, IOutputHandler>) has been changed to QueryOutputHandlersEventArgs(IWriteContext, KeyScope).
  • GraphMLWriter: Return type of method #getOutputHandlers(IWriteContext, KeyScope) has been changed from Map<Object, IOutputHandler> to Iterable<IOutputHandler>.
  • AbstractInputHandler: The return type of method #initializeFromKeyDefinition(IParseContext, Element) has been changed from boolean to void.

Algorithms

  • The following classes have been deprecated: GraphEvent, IGraphListener, Maps.HighPerformanceIntMap and Maps.HighPerformanceDoubleMap.
  • YList: The constructor YList(Collection<Object>) has been changed to YList(Collection<Iterable>). Method #remove(int) has been deprecated.
  • Comparators: Method #compare(int, int) has been deprecated.
  • Graph: Methods #addGraphListener(IGraphListener), #edgeObjects(), #getSource(Object), #getTarget(Object), #nodeObjects(), #removeGraphListener(IGraphListener), #firePostEvent() and #firePreEvent() have been deprecated.

Layout

  • ClassicOrganicLayout: The return type of method property #PreferredEdgeLength has been changed from int to double. Note that this also induces a corresponding change in class OrganicLayoutData.
  • OrganicLayout and ClassicOrganicLayout: The type of constant #PREFERRED_EDGE_LENGTH_DPKEY has been changed from EdgeDpKey<Integer> to EdgeDpKey<Double>.
  • LayoutGraph: Methods #getEdgeLabelLayout(Object), #getEdgeLayout(Object), #getNodeLabelLayout(Object) and #getNodeLayout(Object) have been deprecated.
  • HierarchicLayoutCore.IncrementalHint has been deprecated. Method INodeData#getIncrementalHint() now returns Object.
  • LayoutGraphAdapter: The type of the provided data provider keys have been changed from Object to a more specific type.
  • PartitionCellId: The return type of property #Cells has been changed from Collection<Object> to Iterable<Cell>.
  • HierarchicLayout:
    • The edge grouping now supports to group incoming and outgoing edges of a node. In previous versions incoming and outgoing edges always defined separate groups even though the user specified the same group IDs for such edges.
    • Method #isIntegratedEdgeLabelingEnabled does now always return false if the labeling algorithm is disabled (see MultiStageLayout#isLabelingEnabled. In previous versions it was only required that an appropriate labeling algorithm was specified, but it was not necessary that it is enabled. Therefore, the integrated labeling state queried from the property might not have corresponded to what the layout algorithm actually did. The same behavior change applies for the following methods:
      • HierarchicLayout#isNodeLabelConsiderationEnabled
      • OrthogonalLayout#isIntegratedEdgeLabelingEnabled
      • OrthogonalLayout#isNodeLabelConsiderationEnabled
    • HierarchicLayout may now place source/target labels in layers that contain common nodes. In previous versions such labels were always placed in separate layers which often led to less compact drawings with superfluous bends.
    • Geometry information registered with data providers with keys #ALTERNATIVE_GROUP_BOUNDS_DP_KEY and #ALTERNATIVE_EDGE_PATH_DP_KEY is now automatically rotated according to the specified layout orientation. This fixes unstable from-sketch behavior in incremental layout mode when using an orientation other than top-to-bottom. User that
  • OrganicLayout does no longer resize empty group nodes, possible ignoring a minimum group node size for them (see GroupingKeys#MINIMUM_NODE_SIZE_DPKEY). The behavior with respect to empty group nodes is now in line with the behavior of other common layout algorithms.
  • Method Centrality#closenessCentrality now sets the closeness of a node to Infinity if the sum of the shortest path distances is 0. Before, it was set to NaN in such cases.
  • Groups.Dendrogram does no longer extend class Graph. To enable convenient iteration of a dendrogram, method #getChildren(Node) was added.
  • SingleCycleLayout: Property #NodeSequencer now allows to specify null to return to the default sequencer. In previous versions, specifying null leads to an IllegalStateException.

Demo Improvements

  • The package structure of the source code demos has been changed to a more intuitive structure.
  • The Viewer distribution now provides several source code demos.
  • The layout code in the BPMN demo was simplified and is now easier to adjust
  • A new demo application that shows how to configure hierarchic layout for arranging Sankey diagrams was added.
  • The new GraphMLCompatibilityDemo that shows how to load GraphML files created by yFiles for Java 3.0.x was added.