Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Some queries (Read 2208 times)
anurodhora
Full Member
***
Offline


I love YaBB 1G - SP1!

Posts: 103
Joined: Jan 19th, 2009
Some queries
Mar 17th, 2009 at 8:50am
Print Post  
Hi,

Please look into following queries:

1) We want to show grid lines in the diagram and we are doing it with following code on a button click:

Code
Select All
diagram.ShowGrid = true;
diagram.GridStyle = GridStyle.Lines;
diagram.GridOffsetX = 0;
diagram.GridOffsetY = 0;
diagram.GridSizeX = 45;
diagram.GridSizeY = 45;
 



however, when the grid lines are on and you move the nodes they are getting placed in the grid cells only and we want this feature to be off and enable only when a button say Align is clicked.

Any suggestions on how to achieve above? So that even though if grid is on we should be able to move nodes freely on the diagram and at the same time we want to keep the grid size 45X45.

2) We want to be able to select a particular node and on a button click say "Hide Link" we want to hide the outgoing links and change the shape of the node from decision to octagon. Again there would be a button "Display Link" to again display the hidden links.

Also we want to have this shoe/hide buttons for the nodes also so that on their click a particular type of nodes get hide/display.

3) Can we give shadows to some of our nodes. If yes how to do this?

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


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Some queries
Reply #1 - Mar 17th, 2009 at 9:31am
Print Post  
Hi,

1. Use the Digram.AlignToGrid property.
2. foreach (DiagramLink link in selectedNode.OutgoingLinks) link.Visible = false;
3. node.Effect = new DropShadowEffect();

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
anurodhora
Full Member
***
Offline


I love YaBB 1G - SP1!

Posts: 103
Joined: Jan 19th, 2009
Re: Some queries
Reply #2 - Mar 17th, 2009 at 1:41pm
Print Post  
Thanks for the reply.

for 2) if i am not wrong we will get selectedNode as
ShapeNode selectedNode = diagram.ActiveItem as ShapeNode;

for 3) Can we extend the shadow length and change shadow color. So that this nodes can be easily distinguished from others.

Thanks again for reply.

Anurodh

  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Some queries
Reply #3 - Mar 17th, 2009 at 3:03pm
Print Post  
2) That's right.
3) I don't know. This is a feature of the WPF framework, so you could check the DropShadowEffect topic in the MSDN library.

Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint