![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
|
I can draw a line that has a pattern across the width of the line, but how do I draw a line that has a pattern along the length, other than a simple dash-dot combination. As per the attached example. I could do the shape as an endcap and then draw the line in segments, but that seems a lot of work for a simple repeating pattern. |
#2
| |||
| |||
|
|
You can use a custom dash-pattern to create whatever repeating pattern you desire. Take a look at the Pen.DashPattern property. -- Bob Powell [MVP] Visual C#, System.Drawing Ramuseco Limited .NET consulting http://www.ramuseco.com Find great Windows Forms articles in Windows Forms Tips and Tricks http://www.bobpowell.net/tipstricks.htm Answer those GDI+ questions with the GDI+ FAQ http://www.bobpowell.net/faqmain.htm All new articles provide code in C# and VB.NET. Subscribe to the RSS feeds provided and never miss a new article. James Hahn wrote: I can draw a line that has a pattern across the width of the line, but how do I draw a line that has a pattern along the length, other than a simple dash-dot combination. As per the attached example. I could do the shape as an endcap and then draw the line in segments, but that seems a lot of work for a simple repeating pattern. |
#3
| |||
| |||
|
|
The DashPattern property enables me to construct a line of dashes and dots. I need a line drawing procedure that enables me to insert a small vector symbol at points along the line (say, at the end of each dashpattern). I guess what I'm looking for is a CustomDashCap that works like CustomEndCap. |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |