Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic SwimLane implementation (Read 1639 times)
binuvc
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 46
Joined: Nov 7th, 2011
SwimLane implementation
Nov 17th, 2011 at 11:25am
Print Post  
Hi

It seems that swim lanes can be achieved by directly manipulating the LaneGrid property of the Diagram object.

How is the SwimLaneLayout different from this?

what additional feature do we get by implementing the swimlanelayout?

Also We had a scenario where we need to add lanes (rows and columns) dynamically, say , by clicking a button. Could you please provide some sample code to achieve this as well as the ISwimLaneGrid implementation..

Thanks in advance.
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: SwimLane implementation
Reply #1 - Nov 17th, 2011 at 12:00pm
Print Post  
Hi,

SwimlaneLayout will arrange nodes automatically along the LaneGrid lanes or your custom lanes. If nodes will be drawn by the user, you don't have to use the layout class.

You must implement the ISwimLaneGrid interface only if you need to use a custom grid and need to apply the SwimlaneLayout algorithm. You can create a custom grid by either composing it from locked background nodes, or by placing a grid control behind the diagram and setting the diagram's background to Transparent.

You can add a new row to the built-in grid like this:

Code
Select All
private void OnAddRow(object sender, RoutedEventArgs e)
{
	diagram.LaneGrid.RowHeaders.Add(
		new Header("row " + diagram.LaneGrid.RowHeaders.Count));
} 



I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint