Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Diagramming for JavaScript, V2.8 (Read 2546 times)
Forum Admin
YaBB Administrator
*****
Offline


Rock and Roll

Posts: 564
Joined: Apr 6th, 2003
Diagramming for JavaScript, V2.8
Nov 21st, 2016 at 9:08am
Print Post  
We have released version 2.8 of JavaScript Diagram library. It contains the following new features:

Fluent API
Builder objects with property setters and shortcut methods for font and brush creation add support for fluent programming style. Static With and instance init methods in DiagramItem, Style and Layout -derived classes return a builder instance that can be used to set up respective new or existing objects:
Code
Select All
diagram.addItem(
	ShapeNode.With()
		.brush("lightGray")
		.font("Arial", 4)
		.enableStyledText(true)
		.text("Task <i>1</i>")
		.tooltip("This is the task")
		.create());

diagram.getFactory()
	.createShapeNode(20, 20, 20, 20).init()
		.brush("lightGray", "white", 20)
		.font("Arial", 4)
		.enableStyledText(true)
		.text("Task <i>2</i>")
		.tooltip("This is the second task");

diagram.arrange(
	TreeLayout.With()
		.levelDistance(20)
		.nodeDistance(20)
		.linkType(TreeLayoutLinkType.Cascading)
		.create()); 



DiagramLink improvements
  • HeadStroke, HeadStrokeThickness and HeadStrokeDashStyle properties let you customize arrowhead strokes independently of line segments strokes;
  • the AllowSelfLoops property of Diagram class controls whether users are allowed to draw self-loop links;
  • the new Spline element of LinkShape enumeration draws links as interpolating splines that pass through all of their control points:



Miscellaneous
  • TextAlignment and LineAlignment properties moved from ShapeNode to DiagramItem; you can now use them to set alignment for table and container captions as well;
  • enable the AllowResizeHeaders property of swimlanes Grid to let users resize grid rows and columns interactively. The control raises headerStartResizing validation event when the user tries to resize, and headerResized event when the operation completes.
  • IconSize and DefaultNodeSize properties of NodeListView can be set to null, in which case the control will use the sizes stored in node.Bounds;
  • implemented backward compatibility for XML files as old as v13 format (created by MindFusion diagram versions released in 2008);
  • the control now supports cyclic attachment created using DiagramNode.attachTo method, where moving any of the attached nodes will move all other nodes in the cycle;
  • Shape.RoundRect corner arcs keep constant radius and no longer deform when the node size changes to non-rectangular;
  • itemAdded and itemRemoved events raised when an item is added or removed, either from code or interactively;

Registered customers with an active upgrade subscription can download the licensed version from the clients area on our site.

A trial version is available for download here:
http://mindfusion.eu/JsDiagramTrial.zip

Enjoy!
  
Back to top
WWW  
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint