Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic How to create a Dashed Link using DiagramLink? (Read 1889 times)
venki5star
Junior Member
**
Offline



Posts: 82
Location: India
Joined: Mar 9th, 2010
How to create a Dashed Link using DiagramLink?
Sep 30th, 2010 at 10:01am
Print Post  
Hi All,
I am using 2.4.0.21968 version of WPF Diagram. I am trying to Style the DiagramLink to Dashed link using StrokeDashStyle of the DiagramLink. But it still shows as a solid line.

How to do it?
  

Castle Rider
Back to top
WWW  
IP Logged
 
venki5star
Junior Member
**
Offline



Posts: 82
Location: India
Joined: Mar 9th, 2010
Re: How to create a Dashed Link using DiagramLink?
Reply #1 - Sep 30th, 2010 at 10:36am
Print Post  
Found it my self.

[code]
DoubleCollection doubleCollection = new DoubleCollection();
doubleCollection.Add(5d);
doubleCollection.Add(2d);

Link.StrokeThickness = 1.0d;
Link.StrokeDashStyle = new DashStyle(doubleCollection, 1);[/code]
  

Castle Rider
Back to top
WWW  
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: How to create a Dashed Link using DiagramLink?
Reply #2 - Sep 30th, 2010 at 10:45am
Print Post  
If you meant assigning a Style to link.Style, you might have to call the link's ClearStyleableProperties() method to remove any local values associated with the link's dependency properties. Such values are copied from the diagram in some cases, and prevent inheriting property values from a Style.

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